<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[200775] trunk/Source/WebCore</title>
</head>
<body>
<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; }
#msg dl a { font-weight: bold}
#msg dl a:link { color:#fc3; }
#msg dl a:active { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/200775">200775</a></dd>
<dt>Author</dt> <dd>cdumez@apple.com</dd>
<dt>Date</dt> <dd>2016-05-12 09:07:13 -0700 (Thu, 12 May 2016)</dd>
</dl>
<h3>Log Message</h3>
<pre>Avoid unnecessary null checks in toJS() when the implementation returns a reference or Ref<>
https://bugs.webkit.org/show_bug.cgi?id=157604
Reviewed by Darin Adler.
Avoid unnecessary null checks in toJS() when the implementation returns
a C++ reference or Ref<>. To achieve this, the following changes were
made:
1. Have toJS() overload that takes a raw pointer call the one that
takes in a C++ reference, instead of the other way around. This way,
we only do the null check when passing a raw pointer in.
2. Stop calling WTF::getPtr() on the value returned by the
implementation because this causes us to call toJS() with a raw
pointer every time.
3. Add an toJS() overload in JSDOMBinding.h that takes a Ref<T> in and
that calls toJS() with a C++ reference internally. This way, we
bypass the null check if the implementation returns a Ref<T>.
Further refactoring could be done but I try to keep the size of this
patch as small as possible. toJS() should probably take the ExecState
and the globalObject by reference, for e.g.
* bindings/js/JSAnimationTimelineCustom.cpp:
(WebCore::toJS):
* bindings/js/JSBlobCustom.cpp:
(WebCore::toJS):
(WebCore::constructJSBlob): Deleted.
* bindings/js/JSCSSRuleCustom.cpp:
(WebCore::toJS):
* bindings/js/JSCSSStyleDeclarationCustom.cpp:
(WebCore::JSCSSStyleDeclaration::getPropertyCSSValue):
* bindings/js/JSCSSValueCustom.cpp:
(WebCore::toJS):
* bindings/js/JSCanvasRenderingContextCustom.cpp:
(WebCore::toJS):
* bindings/js/JSCustomElementInterface.cpp:
(WebCore::JSCustomElementInterface::attributeChanged):
* bindings/js/JSDOMBinding.h:
(WebCore::toJS):
(WebCore::toJSNewlyCreated):
* bindings/js/JSDOMFormDataCustom.cpp:
(WebCore::constructJSDOMFormData):
* bindings/js/JSDOMMimeTypeArrayCustom.cpp:
(WebCore::JSDOMMimeTypeArray::nameGetter):
* bindings/js/JSDOMNamedFlowCollectionCustom.cpp:
(WebCore::JSDOMNamedFlowCollection::nameGetter):
* bindings/js/JSDOMPluginArrayCustom.cpp:
(WebCore::JSDOMPluginArray::nameGetter):
* bindings/js/JSDOMPluginCustom.cpp:
(WebCore::JSDOMPlugin::nameGetter):
* bindings/js/JSDOMWindowBase.cpp:
(WebCore::toJS):
* bindings/js/JSDOMWindowBase.h:
(WebCore::toJS):
* bindings/js/JSDOMWindowCustom.cpp:
(WebCore::jsDOMWindowGetOwnPropertySlotNamedItemGetter):
* bindings/js/JSDocumentCustom.cpp:
(WebCore::toJS):
(WebCore::toJSNewlyCreated):
(WebCore::JSDocument::createTouchList):
(WebCore::JSDocument::prepend): Deleted.
* bindings/js/JSDocumentFragmentCustom.cpp:
(WebCore::toJSNewlyCreated):
(WebCore::toJS):
* bindings/js/JSEventCustom.cpp:
(WebCore::toJS):
(WebCore::toJSNewlyCreated):
* bindings/js/JSEventTargetCustom.cpp:
(WebCore::toJS):
* bindings/js/JSFileReaderCustom.cpp:
(WebCore::JSFileReader::result):
* bindings/js/JSHTMLAllCollectionCustom.cpp:
(WebCore::namedItems):
(WebCore::callHTMLAllCollection):
* bindings/js/JSHTMLCanvasElementCustom.cpp:
(WebCore::JSHTMLCanvasElement::getContext):
* bindings/js/JSHTMLCollectionCustom.cpp:
(WebCore::JSHTMLCollection::nameGetter):
(WebCore::toJS):
* bindings/js/JSHTMLDocumentCustom.cpp:
(WebCore::JSHTMLDocument::nameGetter):
* bindings/js/JSHTMLElementCustom.cpp:
(WebCore::constructJSHTMLElement):
(WebCore::JSHTMLElement::pushEventHandlerScope):
* bindings/js/JSHTMLFormControlsCollectionCustom.cpp:
(WebCore::namedItems):
* bindings/js/JSHTMLFormElementCustom.cpp:
(WebCore::JSHTMLFormElement::nameGetter):
* bindings/js/JSHTMLOptionsCollectionCustom.cpp:
(WebCore::JSHTMLOptionsCollection::nameGetter):
* bindings/js/JSIDBCursorCustom.cpp:
(WebCore::JSIDBCursor::source):
(WebCore::toJS):
* bindings/js/JSIDBDatabaseCustom.cpp:
(WebCore::JSIDBDatabase::createObjectStore):
(WebCore::JSIDBDatabase::transaction):
* bindings/js/JSIDBRequestCustom.cpp:
(WebCore::JSIDBRequest::result):
(WebCore::JSIDBRequest::source):
* bindings/js/JSImageConstructor.cpp:
(WebCore::JSImageConstructor::construct):
* bindings/js/JSImageDataCustom.cpp:
(WebCore::toJS):
* bindings/js/JSLazyEventListener.cpp:
(WebCore::JSLazyEventListener::initializeJSFunction):
* bindings/js/JSMediaSessionCustom.cpp:
(WebCore::constructJSMediaSession):
* bindings/js/JSMediaStreamCapabilitiesCustom.cpp:
(WebCore::toJS):
* bindings/js/JSNamedNodeMapCustom.cpp:
(WebCore::JSNamedNodeMap::nameGetter):
* bindings/js/JSNodeCustom.cpp:
(WebCore::createWrapperInline):
(WebCore::toJSNewlyCreated):
(WebCore::willCreatePossiblyOrphanedTreeByRemovalSlowCase):
(WebCore::getOutOfLineCachedWrapper): Deleted.
* bindings/js/JSNodeCustom.h:
(WebCore::toJS):
* bindings/js/JSNodeListCustom.cpp:
(WebCore::toJSNewlyCreated):
* bindings/js/JSNodeListCustom.h:
(WebCore::toJS):
* bindings/js/JSPerformanceEntryCustom.cpp:
(WebCore::toJS):
* bindings/js/JSPopStateEventCustom.cpp:
(WebCore::JSPopStateEvent::state):
* bindings/js/JSRTCStatsResponseCustom.cpp:
(WebCore::JSRTCStatsResponse::nameGetter):
* bindings/js/JSSVGPathSegCustom.cpp:
(WebCore::toJS):
* bindings/js/JSStyleSheetCustom.cpp:
(WebCore::toJS):
* bindings/js/JSTextTrackCueCustom.cpp:
(WebCore::toJS):
* bindings/js/JSTrackCustom.cpp:
(WebCore::toJS):
* bindings/js/JSTrackCustom.h:
* bindings/js/JSTrackEventCustom.cpp:
(WebCore::JSTrackEvent::track):
* bindings/js/JSUserMessageHandlersNamespaceCustom.cpp:
(WebCore::JSUserMessageHandlersNamespace::getOwnPropertySlotDelegate):
* bindings/js/JSWorkerCustom.cpp:
(WebCore::constructJSWorker):
* bindings/js/ReadableStreamController.cpp:
(WebCore::createReadableStream):
* bindings/scripts/CodeGeneratorJS.pm:
(GenerateHeader):
(GenerateImplementation):
(GenerateCallbackHeader):
(GenerateCallbackImplementation):
(NativeToJSValue):
(GenerateConstructorDefinition):
(ceilingToPowerOf2): Deleted.
(ConstructorHasProperties): Deleted.
* bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
(WebCore::toJSNewlyCreated):
(WebCore::toJS):
(WebCore::JSTestActiveDOMObject::toWrapped): Deleted.
* bindings/scripts/test/JS/JSTestActiveDOMObject.h:
(WebCore::toJS):
(WebCore::toJSNewlyCreated):
* bindings/scripts/test/JS/JSTestCallback.cpp:
(WebCore::JSTestCallback::callbackWithArrayParam):
(WebCore::JSTestCallback::callbackWithStringList):
(WebCore::JSTestCallback::callbackRequiresThisToPass):
(WebCore::toJS):
* bindings/scripts/test/JS/JSTestCallback.h:
(WebCore::toJS):
* bindings/scripts/test/JS/JSTestCallbackFunction.cpp:
(WebCore::JSTestCallbackFunction::callbackWithArrayParam):
(WebCore::JSTestCallbackFunction::callbackWithStringList):
(WebCore::JSTestCallbackFunction::callbackRequiresThisToPass):
(WebCore::toJS):
* bindings/scripts/test/JS/JSTestCallbackFunction.h:
(WebCore::toJS):
* bindings/scripts/test/JS/JSTestClassWithJSBuiltinConstructor.cpp:
(WebCore::toJSNewlyCreated):
(WebCore::toJS):
(WebCore::JSTestClassWithJSBuiltinConstructor::toWrapped): Deleted.
* bindings/scripts/test/JS/JSTestClassWithJSBuiltinConstructor.h:
(WebCore::toJS):
(WebCore::toJSNewlyCreated):
* bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.cpp:
(WebCore::toJSNewlyCreated):
(WebCore::toJS):
(WebCore::JSTestCustomConstructorWithNoInterfaceObject::toWrapped): Deleted.
* bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.h:
(WebCore::toJS):
(WebCore::toJSNewlyCreated):
* bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
(WebCore::toJSNewlyCreated):
(WebCore::toJS):
(WebCore::JSTestCustomNamedGetter::toWrapped): Deleted.
* bindings/scripts/test/JS/JSTestCustomNamedGetter.h:
(WebCore::toJS):
(WebCore::toJSNewlyCreated):
* bindings/scripts/test/JS/JSTestEventConstructor.cpp:
(WebCore::JSTestEventConstructorConstructor::construct):
(WebCore::toJSNewlyCreated):
(WebCore::toJS):
(WebCore::JSTestEventConstructor::toWrapped): Deleted.
* bindings/scripts/test/JS/JSTestEventConstructor.h:
(WebCore::toJS):
(WebCore::toJSNewlyCreated):
* bindings/scripts/test/JS/JSTestEventTarget.cpp:
(WebCore::jsTestEventTargetPrototypeFunctionItem):
(WebCore::toJSNewlyCreated):
(WebCore::toJS):
(WebCore::JSTestEventTarget::toWrapped): Deleted.
* bindings/scripts/test/JS/JSTestEventTarget.h:
(WebCore::toJS):
(WebCore::toJSNewlyCreated):
* bindings/scripts/test/JS/JSTestException.cpp:
(WebCore::toJSNewlyCreated):
(WebCore::toJS):
(WebCore::JSTestException::toWrapped): Deleted.
* bindings/scripts/test/JS/JSTestException.h:
(WebCore::toJS):
(WebCore::toJSNewlyCreated):
* bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
(WebCore::toJSNewlyCreated):
(WebCore::toJS):
(WebCore::JSTestGenerateIsReachable::toWrapped): Deleted.
* bindings/scripts/test/JS/JSTestGenerateIsReachable.h:
(WebCore::toJS):
(WebCore::toJSNewlyCreated):
* bindings/scripts/test/JS/JSTestGlobalObject.cpp:
(WebCore::toJSNewlyCreated):
(WebCore::toJS):
(WebCore::JSTestGlobalObject::toWrapped): Deleted.
* bindings/scripts/test/JS/JSTestGlobalObject.h:
(WebCore::toJS):
(WebCore::toJSNewlyCreated):
* bindings/scripts/test/JS/JSTestInterface.cpp:
(WebCore::JSTestInterfaceConstructor::construct):
(WebCore::jsTestInterfaceImplementsNode):
(WebCore::jsTestInterfaceSupplementalNode):
(WebCore::jsTestInterfacePrototypeFunctionImplementsMethod2):
(WebCore::jsTestInterfacePrototypeFunctionSupplementalMethod2):
(WebCore::toJSNewlyCreated):
(WebCore::toJS):
(WebCore::JSTestInterface::toWrapped): Deleted.
* bindings/scripts/test/JS/JSTestInterface.h:
(WebCore::toJS):
(WebCore::toJSNewlyCreated):
* bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
(WebCore::toJSNewlyCreated):
(WebCore::toJS):
(WebCore::JSTestMediaQueryListListener::toWrapped): Deleted.
* bindings/scripts/test/JS/JSTestMediaQueryListListener.h:
(WebCore::toJS):
(WebCore::toJSNewlyCreated):
* bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
(WebCore::JSTestNamedConstructorNamedConstructor::construct):
(WebCore::toJSNewlyCreated):
(WebCore::toJS):
(WebCore::JSTestNamedConstructor::toWrapped): Deleted.
* bindings/scripts/test/JS/JSTestNamedConstructor.h:
(WebCore::toJS):
(WebCore::toJSNewlyCreated):
* bindings/scripts/test/JS/JSTestNode.cpp:
(WebCore::JSTestNodeConstructor::construct):
* bindings/scripts/test/JS/JSTestNondeterministic.cpp:
(WebCore::toJSNewlyCreated):
(WebCore::toJS):
(WebCore::JSTestNondeterministic::toWrapped): Deleted.
* bindings/scripts/test/JS/JSTestNondeterministic.h:
(WebCore::toJS):
(WebCore::toJSNewlyCreated):
* bindings/scripts/test/JS/JSTestObj.cpp:
(WebCore::JSTestObjConstructor::construct):
(WebCore::jsTestObjReadOnlyTestObjAttr):
(WebCore::jsTestObjTestObjAttr):
(WebCore::jsTestObjTestNullableObjAttr):
(WebCore::jsTestObjLenientTestObjAttr):
(WebCore::jsTestObjXMLObjAttr):
(WebCore::jsTestObjTypedArrayAttr):
(WebCore::jsTestObjStrictTypeCheckingAttribute):
(WebCore::jsTestObjWithScriptExecutionContextAttribute):
(WebCore::jsTestObjWithScriptStateAttributeRaises):
(WebCore::jsTestObjWithScriptExecutionContextAttributeRaises):
(WebCore::jsTestObjWithScriptExecutionContextAndScriptStateAttribute):
(WebCore::jsTestObjWithScriptExecutionContextAndScriptStateAttributeRaises):
(WebCore::jsTestObjWithScriptExecutionContextAndScriptStateWithSpacesAttribute):
(WebCore::jsTestObjWithScriptArgumentsAndCallStackAttribute):
(WebCore::jsTestObjContentDocument):
(WebCore::jsTestObjMutablePoint):
(WebCore::jsTestObjImmutablePoint):
(WebCore::jsTestObjPutForwardsAttribute):
(WebCore::jsTestObjPutForwardsNullableAttribute):
(WebCore::jsTestObjPrototypeFunctionObjMethod):
(WebCore::jsTestObjPrototypeFunctionObjMethodWithArgs):
(WebCore::jsTestObjPrototypeFunctionMethodThatRequiresAllArgsAndThrows):
(WebCore::jsTestObjPrototypeFunctionWithScriptStateObj):
(WebCore::jsTestObjPrototypeFunctionWithScriptStateObjException):
(WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContextAndScriptStateObjException):
(WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContextAndScriptStateWithSpaces):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethod):
(WebCore::jsTestObjPrototypeFunctionDomStringListFunction):
(WebCore::jsTestObjPrototypeFunctionGetElementById):
(WebCore::jsTestObjPrototypeFunctionGetSVGDocument):
(WebCore::jsTestObjPrototypeFunctionMutablePointFunction):
(WebCore::jsTestObjPrototypeFunctionImmutablePointFunction):
(WebCore::toJSNewlyCreated):
(WebCore::toJS):
(WebCore::JSTestObj::toWrapped): Deleted.
* bindings/scripts/test/JS/JSTestObj.h:
(WebCore::toJS):
(WebCore::toJSNewlyCreated):
* bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
(WebCore::constructJSTestOverloadedConstructors1):
(WebCore::constructJSTestOverloadedConstructors2):
(WebCore::constructJSTestOverloadedConstructors3):
(WebCore::constructJSTestOverloadedConstructors4):
(WebCore::constructJSTestOverloadedConstructors5):
(WebCore::toJSNewlyCreated):
(WebCore::toJS):
(WebCore::JSTestOverloadedConstructors::toWrapped): Deleted.
* bindings/scripts/test/JS/JSTestOverloadedConstructors.h:
(WebCore::toJS):
(WebCore::toJSNewlyCreated):
* bindings/scripts/test/JS/JSTestOverrideBuiltins.cpp:
(WebCore::jsTestOverrideBuiltinsPrototypeFunctionNamedItem):
(WebCore::toJSNewlyCreated):
(WebCore::toJS):
(WebCore::JSTestOverrideBuiltins::toWrapped): Deleted.
* bindings/scripts/test/JS/JSTestOverrideBuiltins.h:
(WebCore::toJS):
(WebCore::toJSNewlyCreated):
* bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
(WebCore::toJSNewlyCreated):
(WebCore::toJS):
(WebCore::JSTestSerializedScriptValueInterface::toWrapped): Deleted.
* bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h:
(WebCore::toJS):
(WebCore::toJSNewlyCreated):
* bindings/scripts/test/JS/JSTestTypedefs.cpp:
(WebCore::JSTestTypedefsConstructor::construct):
(WebCore::jsTestTypedefsPrototypeFunctionImmutablePointFunction):
(WebCore::toJSNewlyCreated):
(WebCore::toJS):
(WebCore::JSTestTypedefs::toWrapped): Deleted.
* bindings/scripts/test/JS/JSTestTypedefs.h:
(WebCore::toJS):
(WebCore::toJSNewlyCreated):
* bindings/scripts/test/JS/JSattribute.cpp:
(WebCore::toJSNewlyCreated):
(WebCore::toJS):
(WebCore::JSattribute::toWrapped): Deleted.
* bindings/scripts/test/JS/JSattribute.h:
(WebCore::toJS):
(WebCore::toJSNewlyCreated):
* bindings/scripts/test/JS/JSreadonly.cpp:
(WebCore::toJSNewlyCreated):
(WebCore::toJS):
(WebCore::JSreadonly::toWrapped): Deleted.
* bindings/scripts/test/JS/JSreadonly.h:
(WebCore::toJS):
(WebCore::toJSNewlyCreated):
* html/HTMLMediaElement.cpp:
(WebCore::controllerJSValue):
(WebCore::HTMLMediaElement::didAddUserAgentShadowRoot):</pre>
<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSAnimationTimelineCustomcpp">trunk/Source/WebCore/bindings/js/JSAnimationTimelineCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSBlobCustomcpp">trunk/Source/WebCore/bindings/js/JSBlobCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSCSSRuleCustomcpp">trunk/Source/WebCore/bindings/js/JSCSSRuleCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSCSSStyleDeclarationCustomcpp">trunk/Source/WebCore/bindings/js/JSCSSStyleDeclarationCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSCSSValueCustomcpp">trunk/Source/WebCore/bindings/js/JSCSSValueCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSCanvasRenderingContextCustomcpp">trunk/Source/WebCore/bindings/js/JSCanvasRenderingContextCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSCustomElementInterfacecpp">trunk/Source/WebCore/bindings/js/JSCustomElementInterface.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSDOMBindingh">trunk/Source/WebCore/bindings/js/JSDOMBinding.h</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSDOMFormDataCustomcpp">trunk/Source/WebCore/bindings/js/JSDOMFormDataCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSDOMMimeTypeArrayCustomcpp">trunk/Source/WebCore/bindings/js/JSDOMMimeTypeArrayCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSDOMNamedFlowCollectionCustomcpp">trunk/Source/WebCore/bindings/js/JSDOMNamedFlowCollectionCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSDOMPluginArrayCustomcpp">trunk/Source/WebCore/bindings/js/JSDOMPluginArrayCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSDOMPluginCustomcpp">trunk/Source/WebCore/bindings/js/JSDOMPluginCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSDOMWindowBasecpp">trunk/Source/WebCore/bindings/js/JSDOMWindowBase.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSDOMWindowBaseh">trunk/Source/WebCore/bindings/js/JSDOMWindowBase.h</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSDOMWindowCustomcpp">trunk/Source/WebCore/bindings/js/JSDOMWindowCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSDocumentCustomcpp">trunk/Source/WebCore/bindings/js/JSDocumentCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSDocumentFragmentCustomcpp">trunk/Source/WebCore/bindings/js/JSDocumentFragmentCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSEventCustomcpp">trunk/Source/WebCore/bindings/js/JSEventCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSEventTargetCustomcpp">trunk/Source/WebCore/bindings/js/JSEventTargetCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSFileReaderCustomcpp">trunk/Source/WebCore/bindings/js/JSFileReaderCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSHTMLAllCollectionCustomcpp">trunk/Source/WebCore/bindings/js/JSHTMLAllCollectionCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSHTMLCanvasElementCustomcpp">trunk/Source/WebCore/bindings/js/JSHTMLCanvasElementCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSHTMLCollectionCustomcpp">trunk/Source/WebCore/bindings/js/JSHTMLCollectionCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSHTMLDocumentCustomcpp">trunk/Source/WebCore/bindings/js/JSHTMLDocumentCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSHTMLElementCustomcpp">trunk/Source/WebCore/bindings/js/JSHTMLElementCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSHTMLFormControlsCollectionCustomcpp">trunk/Source/WebCore/bindings/js/JSHTMLFormControlsCollectionCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSHTMLFormElementCustomcpp">trunk/Source/WebCore/bindings/js/JSHTMLFormElementCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSHTMLOptionsCollectionCustomcpp">trunk/Source/WebCore/bindings/js/JSHTMLOptionsCollectionCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSIDBCursorCustomcpp">trunk/Source/WebCore/bindings/js/JSIDBCursorCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSIDBDatabaseCustomcpp">trunk/Source/WebCore/bindings/js/JSIDBDatabaseCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSIDBRequestCustomcpp">trunk/Source/WebCore/bindings/js/JSIDBRequestCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSImageConstructorcpp">trunk/Source/WebCore/bindings/js/JSImageConstructor.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSImageDataCustomcpp">trunk/Source/WebCore/bindings/js/JSImageDataCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSLazyEventListenercpp">trunk/Source/WebCore/bindings/js/JSLazyEventListener.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSMediaSessionCustomcpp">trunk/Source/WebCore/bindings/js/JSMediaSessionCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSMediaStreamCapabilitiesCustomcpp">trunk/Source/WebCore/bindings/js/JSMediaStreamCapabilitiesCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSNamedNodeMapCustomcpp">trunk/Source/WebCore/bindings/js/JSNamedNodeMapCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSNodeCustomcpp">trunk/Source/WebCore/bindings/js/JSNodeCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSNodeCustomh">trunk/Source/WebCore/bindings/js/JSNodeCustom.h</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSNodeListCustomcpp">trunk/Source/WebCore/bindings/js/JSNodeListCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSNodeListCustomh">trunk/Source/WebCore/bindings/js/JSNodeListCustom.h</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSPerformanceEntryCustomcpp">trunk/Source/WebCore/bindings/js/JSPerformanceEntryCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSPopStateEventCustomcpp">trunk/Source/WebCore/bindings/js/JSPopStateEventCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSRTCStatsResponseCustomcpp">trunk/Source/WebCore/bindings/js/JSRTCStatsResponseCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSSVGPathSegCustomcpp">trunk/Source/WebCore/bindings/js/JSSVGPathSegCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSStyleSheetCustomcpp">trunk/Source/WebCore/bindings/js/JSStyleSheetCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSTextTrackCueCustomcpp">trunk/Source/WebCore/bindings/js/JSTextTrackCueCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSTrackCustomcpp">trunk/Source/WebCore/bindings/js/JSTrackCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSTrackCustomh">trunk/Source/WebCore/bindings/js/JSTrackCustom.h</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSTrackEventCustomcpp">trunk/Source/WebCore/bindings/js/JSTrackEventCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSUserMessageHandlersNamespaceCustomcpp">trunk/Source/WebCore/bindings/js/JSUserMessageHandlersNamespaceCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSWorkerCustomcpp">trunk/Source/WebCore/bindings/js/JSWorkerCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSWorkerGlobalScopeBasecpp">trunk/Source/WebCore/bindings/js/JSWorkerGlobalScopeBase.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSWorkerGlobalScopeBaseh">trunk/Source/WebCore/bindings/js/JSWorkerGlobalScopeBase.h</a></li>
<li><a href="#trunkSourceWebCorebindingsjsReadableStreamControllercpp">trunk/Source/WebCore/bindings/js/ReadableStreamController.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptsCodeGeneratorJSpm">trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestActiveDOMObjectcpp">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestActiveDOMObject.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestActiveDOMObjecth">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestActiveDOMObject.h</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestCallbackcpp">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCallback.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestCallbackh">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCallback.h</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestCallbackFunctioncpp">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCallbackFunction.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestCallbackFunctionh">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCallbackFunction.h</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestClassWithJSBuiltinConstructorcpp">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestClassWithJSBuiltinConstructor.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestClassWithJSBuiltinConstructorh">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestClassWithJSBuiltinConstructor.h</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestCustomConstructorWithNoInterfaceObjectcpp">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestCustomConstructorWithNoInterfaceObjecth">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.h</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestCustomNamedGettercpp">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestCustomNamedGetterh">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCustomNamedGetter.h</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestEventConstructorcpp">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventConstructor.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestEventConstructorh">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventConstructor.h</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestEventTargetcpp">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventTarget.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestEventTargeth">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventTarget.h</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestExceptioncpp">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestException.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestExceptionh">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestException.h</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestGenerateIsReachablecpp">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestGenerateIsReachableh">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestGenerateIsReachable.h</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestGlobalObjectcpp">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestGlobalObject.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestGlobalObjecth">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestGlobalObject.h</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestInterfacecpp">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestInterface.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestInterfaceh">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestInterface.h</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestMediaQueryListListenercpp">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestMediaQueryListListenerh">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestMediaQueryListListener.h</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestNamedConstructorcpp">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedConstructor.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestNamedConstructorh">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedConstructor.h</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestNodecpp">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNode.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestNondeterministiccpp">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNondeterministic.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestNondeterministich">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNondeterministic.h</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestObjcpp">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestObjh">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.h</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestOverloadedConstructorscpp">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestOverloadedConstructorsh">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructors.h</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestOverrideBuiltinscpp">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverrideBuiltins.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestOverrideBuiltinsh">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverrideBuiltins.h</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestSerializedScriptValueInterfacecpp">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestSerializedScriptValueInterfaceh">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestTypedefscpp">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestTypedefsh">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.h</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSattributecpp">trunk/Source/WebCore/bindings/scripts/test/JS/JSattribute.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSattributeh">trunk/Source/WebCore/bindings/scripts/test/JS/JSattribute.h</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSreadonlycpp">trunk/Source/WebCore/bindings/scripts/test/JS/JSreadonly.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSreadonlyh">trunk/Source/WebCore/bindings/scripts/test/JS/JSreadonly.h</a></li>
<li><a href="#trunkSourceWebCorehtmlHTMLMediaElementcpp">trunk/Source/WebCore/html/HTMLMediaElement.cpp</a></li>
</ul>
</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/ChangeLog        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -1,3 +1,368 @@
</span><ins>+2016-05-12 Chris Dumez <cdumez@apple.com>
+
+ Avoid unnecessary null checks in toJS() when the implementation returns a reference or Ref<>
+ https://bugs.webkit.org/show_bug.cgi?id=157604
+
+ Reviewed by Darin Adler.
+
+ Avoid unnecessary null checks in toJS() when the implementation returns
+ a C++ reference or Ref<>. To achieve this, the following changes were
+ made:
+ 1. Have toJS() overload that takes a raw pointer call the one that
+ takes in a C++ reference, instead of the other way around. This way,
+ we only do the null check when passing a raw pointer in.
+ 2. Stop calling WTF::getPtr() on the value returned by the
+ implementation because this causes us to call toJS() with a raw
+ pointer every time.
+ 3. Add an toJS() overload in JSDOMBinding.h that takes a Ref<T> in and
+ that calls toJS() with a C++ reference internally. This way, we
+ bypass the null check if the implementation returns a Ref<T>.
+
+ Further refactoring could be done but I try to keep the size of this
+ patch as small as possible. toJS() should probably take the ExecState
+ and the globalObject by reference, for e.g.
+
+ * bindings/js/JSAnimationTimelineCustom.cpp:
+ (WebCore::toJS):
+ * bindings/js/JSBlobCustom.cpp:
+ (WebCore::toJS):
+ (WebCore::constructJSBlob): Deleted.
+ * bindings/js/JSCSSRuleCustom.cpp:
+ (WebCore::toJS):
+ * bindings/js/JSCSSStyleDeclarationCustom.cpp:
+ (WebCore::JSCSSStyleDeclaration::getPropertyCSSValue):
+ * bindings/js/JSCSSValueCustom.cpp:
+ (WebCore::toJS):
+ * bindings/js/JSCanvasRenderingContextCustom.cpp:
+ (WebCore::toJS):
+ * bindings/js/JSCustomElementInterface.cpp:
+ (WebCore::JSCustomElementInterface::attributeChanged):
+ * bindings/js/JSDOMBinding.h:
+ (WebCore::toJS):
+ (WebCore::toJSNewlyCreated):
+ * bindings/js/JSDOMFormDataCustom.cpp:
+ (WebCore::constructJSDOMFormData):
+ * bindings/js/JSDOMMimeTypeArrayCustom.cpp:
+ (WebCore::JSDOMMimeTypeArray::nameGetter):
+ * bindings/js/JSDOMNamedFlowCollectionCustom.cpp:
+ (WebCore::JSDOMNamedFlowCollection::nameGetter):
+ * bindings/js/JSDOMPluginArrayCustom.cpp:
+ (WebCore::JSDOMPluginArray::nameGetter):
+ * bindings/js/JSDOMPluginCustom.cpp:
+ (WebCore::JSDOMPlugin::nameGetter):
+ * bindings/js/JSDOMWindowBase.cpp:
+ (WebCore::toJS):
+ * bindings/js/JSDOMWindowBase.h:
+ (WebCore::toJS):
+ * bindings/js/JSDOMWindowCustom.cpp:
+ (WebCore::jsDOMWindowGetOwnPropertySlotNamedItemGetter):
+ * bindings/js/JSDocumentCustom.cpp:
+ (WebCore::toJS):
+ (WebCore::toJSNewlyCreated):
+ (WebCore::JSDocument::createTouchList):
+ (WebCore::JSDocument::prepend): Deleted.
+ * bindings/js/JSDocumentFragmentCustom.cpp:
+ (WebCore::toJSNewlyCreated):
+ (WebCore::toJS):
+ * bindings/js/JSEventCustom.cpp:
+ (WebCore::toJS):
+ (WebCore::toJSNewlyCreated):
+ * bindings/js/JSEventTargetCustom.cpp:
+ (WebCore::toJS):
+ * bindings/js/JSFileReaderCustom.cpp:
+ (WebCore::JSFileReader::result):
+ * bindings/js/JSHTMLAllCollectionCustom.cpp:
+ (WebCore::namedItems):
+ (WebCore::callHTMLAllCollection):
+ * bindings/js/JSHTMLCanvasElementCustom.cpp:
+ (WebCore::JSHTMLCanvasElement::getContext):
+ * bindings/js/JSHTMLCollectionCustom.cpp:
+ (WebCore::JSHTMLCollection::nameGetter):
+ (WebCore::toJS):
+ * bindings/js/JSHTMLDocumentCustom.cpp:
+ (WebCore::JSHTMLDocument::nameGetter):
+ * bindings/js/JSHTMLElementCustom.cpp:
+ (WebCore::constructJSHTMLElement):
+ (WebCore::JSHTMLElement::pushEventHandlerScope):
+ * bindings/js/JSHTMLFormControlsCollectionCustom.cpp:
+ (WebCore::namedItems):
+ * bindings/js/JSHTMLFormElementCustom.cpp:
+ (WebCore::JSHTMLFormElement::nameGetter):
+ * bindings/js/JSHTMLOptionsCollectionCustom.cpp:
+ (WebCore::JSHTMLOptionsCollection::nameGetter):
+ * bindings/js/JSIDBCursorCustom.cpp:
+ (WebCore::JSIDBCursor::source):
+ (WebCore::toJS):
+ * bindings/js/JSIDBDatabaseCustom.cpp:
+ (WebCore::JSIDBDatabase::createObjectStore):
+ (WebCore::JSIDBDatabase::transaction):
+ * bindings/js/JSIDBRequestCustom.cpp:
+ (WebCore::JSIDBRequest::result):
+ (WebCore::JSIDBRequest::source):
+ * bindings/js/JSImageConstructor.cpp:
+ (WebCore::JSImageConstructor::construct):
+ * bindings/js/JSImageDataCustom.cpp:
+ (WebCore::toJS):
+ * bindings/js/JSLazyEventListener.cpp:
+ (WebCore::JSLazyEventListener::initializeJSFunction):
+ * bindings/js/JSMediaSessionCustom.cpp:
+ (WebCore::constructJSMediaSession):
+ * bindings/js/JSMediaStreamCapabilitiesCustom.cpp:
+ (WebCore::toJS):
+ * bindings/js/JSNamedNodeMapCustom.cpp:
+ (WebCore::JSNamedNodeMap::nameGetter):
+ * bindings/js/JSNodeCustom.cpp:
+ (WebCore::createWrapperInline):
+ (WebCore::toJSNewlyCreated):
+ (WebCore::willCreatePossiblyOrphanedTreeByRemovalSlowCase):
+ (WebCore::getOutOfLineCachedWrapper): Deleted.
+ * bindings/js/JSNodeCustom.h:
+ (WebCore::toJS):
+ * bindings/js/JSNodeListCustom.cpp:
+ (WebCore::toJSNewlyCreated):
+ * bindings/js/JSNodeListCustom.h:
+ (WebCore::toJS):
+ * bindings/js/JSPerformanceEntryCustom.cpp:
+ (WebCore::toJS):
+ * bindings/js/JSPopStateEventCustom.cpp:
+ (WebCore::JSPopStateEvent::state):
+ * bindings/js/JSRTCStatsResponseCustom.cpp:
+ (WebCore::JSRTCStatsResponse::nameGetter):
+ * bindings/js/JSSVGPathSegCustom.cpp:
+ (WebCore::toJS):
+ * bindings/js/JSStyleSheetCustom.cpp:
+ (WebCore::toJS):
+ * bindings/js/JSTextTrackCueCustom.cpp:
+ (WebCore::toJS):
+ * bindings/js/JSTrackCustom.cpp:
+ (WebCore::toJS):
+ * bindings/js/JSTrackCustom.h:
+ * bindings/js/JSTrackEventCustom.cpp:
+ (WebCore::JSTrackEvent::track):
+ * bindings/js/JSUserMessageHandlersNamespaceCustom.cpp:
+ (WebCore::JSUserMessageHandlersNamespace::getOwnPropertySlotDelegate):
+ * bindings/js/JSWorkerCustom.cpp:
+ (WebCore::constructJSWorker):
+ * bindings/js/ReadableStreamController.cpp:
+ (WebCore::createReadableStream):
+ * bindings/scripts/CodeGeneratorJS.pm:
+ (GenerateHeader):
+ (GenerateImplementation):
+ (GenerateCallbackHeader):
+ (GenerateCallbackImplementation):
+ (NativeToJSValue):
+ (GenerateConstructorDefinition):
+ (ceilingToPowerOf2): Deleted.
+ (ConstructorHasProperties): Deleted.
+ * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
+ (WebCore::toJSNewlyCreated):
+ (WebCore::toJS):
+ (WebCore::JSTestActiveDOMObject::toWrapped): Deleted.
+ * bindings/scripts/test/JS/JSTestActiveDOMObject.h:
+ (WebCore::toJS):
+ (WebCore::toJSNewlyCreated):
+ * bindings/scripts/test/JS/JSTestCallback.cpp:
+ (WebCore::JSTestCallback::callbackWithArrayParam):
+ (WebCore::JSTestCallback::callbackWithStringList):
+ (WebCore::JSTestCallback::callbackRequiresThisToPass):
+ (WebCore::toJS):
+ * bindings/scripts/test/JS/JSTestCallback.h:
+ (WebCore::toJS):
+ * bindings/scripts/test/JS/JSTestCallbackFunction.cpp:
+ (WebCore::JSTestCallbackFunction::callbackWithArrayParam):
+ (WebCore::JSTestCallbackFunction::callbackWithStringList):
+ (WebCore::JSTestCallbackFunction::callbackRequiresThisToPass):
+ (WebCore::toJS):
+ * bindings/scripts/test/JS/JSTestCallbackFunction.h:
+ (WebCore::toJS):
+ * bindings/scripts/test/JS/JSTestClassWithJSBuiltinConstructor.cpp:
+ (WebCore::toJSNewlyCreated):
+ (WebCore::toJS):
+ (WebCore::JSTestClassWithJSBuiltinConstructor::toWrapped): Deleted.
+ * bindings/scripts/test/JS/JSTestClassWithJSBuiltinConstructor.h:
+ (WebCore::toJS):
+ (WebCore::toJSNewlyCreated):
+ * bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.cpp:
+ (WebCore::toJSNewlyCreated):
+ (WebCore::toJS):
+ (WebCore::JSTestCustomConstructorWithNoInterfaceObject::toWrapped): Deleted.
+ * bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.h:
+ (WebCore::toJS):
+ (WebCore::toJSNewlyCreated):
+ * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
+ (WebCore::toJSNewlyCreated):
+ (WebCore::toJS):
+ (WebCore::JSTestCustomNamedGetter::toWrapped): Deleted.
+ * bindings/scripts/test/JS/JSTestCustomNamedGetter.h:
+ (WebCore::toJS):
+ (WebCore::toJSNewlyCreated):
+ * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
+ (WebCore::JSTestEventConstructorConstructor::construct):
+ (WebCore::toJSNewlyCreated):
+ (WebCore::toJS):
+ (WebCore::JSTestEventConstructor::toWrapped): Deleted.
+ * bindings/scripts/test/JS/JSTestEventConstructor.h:
+ (WebCore::toJS):
+ (WebCore::toJSNewlyCreated):
+ * bindings/scripts/test/JS/JSTestEventTarget.cpp:
+ (WebCore::jsTestEventTargetPrototypeFunctionItem):
+ (WebCore::toJSNewlyCreated):
+ (WebCore::toJS):
+ (WebCore::JSTestEventTarget::toWrapped): Deleted.
+ * bindings/scripts/test/JS/JSTestEventTarget.h:
+ (WebCore::toJS):
+ (WebCore::toJSNewlyCreated):
+ * bindings/scripts/test/JS/JSTestException.cpp:
+ (WebCore::toJSNewlyCreated):
+ (WebCore::toJS):
+ (WebCore::JSTestException::toWrapped): Deleted.
+ * bindings/scripts/test/JS/JSTestException.h:
+ (WebCore::toJS):
+ (WebCore::toJSNewlyCreated):
+ * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
+ (WebCore::toJSNewlyCreated):
+ (WebCore::toJS):
+ (WebCore::JSTestGenerateIsReachable::toWrapped): Deleted.
+ * bindings/scripts/test/JS/JSTestGenerateIsReachable.h:
+ (WebCore::toJS):
+ (WebCore::toJSNewlyCreated):
+ * bindings/scripts/test/JS/JSTestGlobalObject.cpp:
+ (WebCore::toJSNewlyCreated):
+ (WebCore::toJS):
+ (WebCore::JSTestGlobalObject::toWrapped): Deleted.
+ * bindings/scripts/test/JS/JSTestGlobalObject.h:
+ (WebCore::toJS):
+ (WebCore::toJSNewlyCreated):
+ * bindings/scripts/test/JS/JSTestInterface.cpp:
+ (WebCore::JSTestInterfaceConstructor::construct):
+ (WebCore::jsTestInterfaceImplementsNode):
+ (WebCore::jsTestInterfaceSupplementalNode):
+ (WebCore::jsTestInterfacePrototypeFunctionImplementsMethod2):
+ (WebCore::jsTestInterfacePrototypeFunctionSupplementalMethod2):
+ (WebCore::toJSNewlyCreated):
+ (WebCore::toJS):
+ (WebCore::JSTestInterface::toWrapped): Deleted.
+ * bindings/scripts/test/JS/JSTestInterface.h:
+ (WebCore::toJS):
+ (WebCore::toJSNewlyCreated):
+ * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
+ (WebCore::toJSNewlyCreated):
+ (WebCore::toJS):
+ (WebCore::JSTestMediaQueryListListener::toWrapped): Deleted.
+ * bindings/scripts/test/JS/JSTestMediaQueryListListener.h:
+ (WebCore::toJS):
+ (WebCore::toJSNewlyCreated):
+ * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
+ (WebCore::JSTestNamedConstructorNamedConstructor::construct):
+ (WebCore::toJSNewlyCreated):
+ (WebCore::toJS):
+ (WebCore::JSTestNamedConstructor::toWrapped): Deleted.
+ * bindings/scripts/test/JS/JSTestNamedConstructor.h:
+ (WebCore::toJS):
+ (WebCore::toJSNewlyCreated):
+ * bindings/scripts/test/JS/JSTestNode.cpp:
+ (WebCore::JSTestNodeConstructor::construct):
+ * bindings/scripts/test/JS/JSTestNondeterministic.cpp:
+ (WebCore::toJSNewlyCreated):
+ (WebCore::toJS):
+ (WebCore::JSTestNondeterministic::toWrapped): Deleted.
+ * bindings/scripts/test/JS/JSTestNondeterministic.h:
+ (WebCore::toJS):
+ (WebCore::toJSNewlyCreated):
+ * bindings/scripts/test/JS/JSTestObj.cpp:
+ (WebCore::JSTestObjConstructor::construct):
+ (WebCore::jsTestObjReadOnlyTestObjAttr):
+ (WebCore::jsTestObjTestObjAttr):
+ (WebCore::jsTestObjTestNullableObjAttr):
+ (WebCore::jsTestObjLenientTestObjAttr):
+ (WebCore::jsTestObjXMLObjAttr):
+ (WebCore::jsTestObjTypedArrayAttr):
+ (WebCore::jsTestObjStrictTypeCheckingAttribute):
+ (WebCore::jsTestObjWithScriptExecutionContextAttribute):
+ (WebCore::jsTestObjWithScriptStateAttributeRaises):
+ (WebCore::jsTestObjWithScriptExecutionContextAttributeRaises):
+ (WebCore::jsTestObjWithScriptExecutionContextAndScriptStateAttribute):
+ (WebCore::jsTestObjWithScriptExecutionContextAndScriptStateAttributeRaises):
+ (WebCore::jsTestObjWithScriptExecutionContextAndScriptStateWithSpacesAttribute):
+ (WebCore::jsTestObjWithScriptArgumentsAndCallStackAttribute):
+ (WebCore::jsTestObjContentDocument):
+ (WebCore::jsTestObjMutablePoint):
+ (WebCore::jsTestObjImmutablePoint):
+ (WebCore::jsTestObjPutForwardsAttribute):
+ (WebCore::jsTestObjPutForwardsNullableAttribute):
+ (WebCore::jsTestObjPrototypeFunctionObjMethod):
+ (WebCore::jsTestObjPrototypeFunctionObjMethodWithArgs):
+ (WebCore::jsTestObjPrototypeFunctionMethodThatRequiresAllArgsAndThrows):
+ (WebCore::jsTestObjPrototypeFunctionWithScriptStateObj):
+ (WebCore::jsTestObjPrototypeFunctionWithScriptStateObjException):
+ (WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContextAndScriptStateObjException):
+ (WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContextAndScriptStateWithSpaces):
+ (WebCore::jsTestObjPrototypeFunctionOverloadedMethod):
+ (WebCore::jsTestObjPrototypeFunctionDomStringListFunction):
+ (WebCore::jsTestObjPrototypeFunctionGetElementById):
+ (WebCore::jsTestObjPrototypeFunctionGetSVGDocument):
+ (WebCore::jsTestObjPrototypeFunctionMutablePointFunction):
+ (WebCore::jsTestObjPrototypeFunctionImmutablePointFunction):
+ (WebCore::toJSNewlyCreated):
+ (WebCore::toJS):
+ (WebCore::JSTestObj::toWrapped): Deleted.
+ * bindings/scripts/test/JS/JSTestObj.h:
+ (WebCore::toJS):
+ (WebCore::toJSNewlyCreated):
+ * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
+ (WebCore::constructJSTestOverloadedConstructors1):
+ (WebCore::constructJSTestOverloadedConstructors2):
+ (WebCore::constructJSTestOverloadedConstructors3):
+ (WebCore::constructJSTestOverloadedConstructors4):
+ (WebCore::constructJSTestOverloadedConstructors5):
+ (WebCore::toJSNewlyCreated):
+ (WebCore::toJS):
+ (WebCore::JSTestOverloadedConstructors::toWrapped): Deleted.
+ * bindings/scripts/test/JS/JSTestOverloadedConstructors.h:
+ (WebCore::toJS):
+ (WebCore::toJSNewlyCreated):
+ * bindings/scripts/test/JS/JSTestOverrideBuiltins.cpp:
+ (WebCore::jsTestOverrideBuiltinsPrototypeFunctionNamedItem):
+ (WebCore::toJSNewlyCreated):
+ (WebCore::toJS):
+ (WebCore::JSTestOverrideBuiltins::toWrapped): Deleted.
+ * bindings/scripts/test/JS/JSTestOverrideBuiltins.h:
+ (WebCore::toJS):
+ (WebCore::toJSNewlyCreated):
+ * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
+ (WebCore::toJSNewlyCreated):
+ (WebCore::toJS):
+ (WebCore::JSTestSerializedScriptValueInterface::toWrapped): Deleted.
+ * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h:
+ (WebCore::toJS):
+ (WebCore::toJSNewlyCreated):
+ * bindings/scripts/test/JS/JSTestTypedefs.cpp:
+ (WebCore::JSTestTypedefsConstructor::construct):
+ (WebCore::jsTestTypedefsPrototypeFunctionImmutablePointFunction):
+ (WebCore::toJSNewlyCreated):
+ (WebCore::toJS):
+ (WebCore::JSTestTypedefs::toWrapped): Deleted.
+ * bindings/scripts/test/JS/JSTestTypedefs.h:
+ (WebCore::toJS):
+ (WebCore::toJSNewlyCreated):
+ * bindings/scripts/test/JS/JSattribute.cpp:
+ (WebCore::toJSNewlyCreated):
+ (WebCore::toJS):
+ (WebCore::JSattribute::toWrapped): Deleted.
+ * bindings/scripts/test/JS/JSattribute.h:
+ (WebCore::toJS):
+ (WebCore::toJSNewlyCreated):
+ * bindings/scripts/test/JS/JSreadonly.cpp:
+ (WebCore::toJSNewlyCreated):
+ (WebCore::toJS):
+ (WebCore::JSreadonly::toWrapped): Deleted.
+ * bindings/scripts/test/JS/JSreadonly.h:
+ (WebCore::toJS):
+ (WebCore::toJSNewlyCreated):
+ * html/HTMLMediaElement.cpp:
+ (WebCore::controllerJSValue):
+ (WebCore::HTMLMediaElement::didAddUserAgentShadowRoot):
+
</ins><span class="cx"> 2016-05-12 Konstantin Tokarev <annulen@yandex.ru>
</span><span class="cx">
</span><span class="cx"> Use reference instead of pointer in FrameLoaderClient::saveViewStateToItem.
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSAnimationTimelineCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSAnimationTimelineCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSAnimationTimelineCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSAnimationTimelineCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -39,20 +39,17 @@
</span><span class="cx">
</span><span class="cx"> namespace WebCore {
</span><span class="cx">
</span><del>-JSValue toJS(ExecState*, JSDOMGlobalObject* globalObject, AnimationTimeline* value)
</del><ins>+JSValue toJS(ExecState*, JSDOMGlobalObject* globalObject, AnimationTimeline& value)
</ins><span class="cx"> {
</span><del>- if (!value)
- return jsNull();
</del><ins>+ JSObject* wrapper = getCachedWrapper(globalObject->world(), &value);
</ins><span class="cx">
</span><del>- JSObject* wrapper = getCachedWrapper(globalObject->world(), value);
-
</del><span class="cx"> if (wrapper)
</span><span class="cx"> return wrapper;
</span><span class="cx">
</span><del>- if (value->isDocumentTimeline())
- wrapper = CREATE_DOM_WRAPPER(globalObject, DocumentTimeline, value);
</del><ins>+ if (value.isDocumentTimeline())
+ wrapper = CREATE_DOM_WRAPPER(globalObject, DocumentTimeline, &value);
</ins><span class="cx"> else
</span><del>- wrapper = CREATE_DOM_WRAPPER(globalObject, AnimationTimeline, value);
</del><ins>+ wrapper = CREATE_DOM_WRAPPER(globalObject, AnimationTimeline, &value);
</ins><span class="cx">
</span><span class="cx"> return wrapper;
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSBlobCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSBlobCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSBlobCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSBlobCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -48,15 +48,12 @@
</span><span class="cx">
</span><span class="cx"> namespace WebCore {
</span><span class="cx">
</span><del>-JSValue toJS(ExecState*, JSDOMGlobalObject* globalObject, Blob* blob)
</del><ins>+JSValue toJS(ExecState*, JSDOMGlobalObject* globalObject, Blob& blob)
</ins><span class="cx"> {
</span><del>- if (!blob)
- return jsNull();
</del><ins>+ if (is<File>(blob))
+ return wrap<JSFile>(globalObject, downcast<File>(blob));
</ins><span class="cx">
</span><del>- if (is<File>(*blob))
- return wrap<JSFile>(globalObject, downcast<File>(*blob));
-
- return wrap<JSBlob>(globalObject, *blob);
</del><ins>+ return wrap<JSBlob>(globalObject, blob);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> EncodedJSValue JSC_HOST_CALL constructJSBlob(ExecState* exec)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSCSSRuleCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSCSSRuleCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSCSSRuleCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSCSSRuleCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -60,55 +60,52 @@
</span><span class="cx"> visitor.addOpaqueRoot(root(&wrapped()));
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSValue toJS(ExecState*, JSDOMGlobalObject* globalObject, CSSRule* rule)
</del><ins>+JSValue toJS(ExecState*, JSDOMGlobalObject* globalObject, CSSRule& rule)
</ins><span class="cx"> {
</span><del>- if (!rule)
- return jsNull();
-
- JSObject* wrapper = getCachedWrapper(globalObject->world(), rule);
</del><ins>+ JSObject* wrapper = getCachedWrapper(globalObject->world(), &rule);
</ins><span class="cx"> if (wrapper)
</span><span class="cx"> return wrapper;
</span><span class="cx">
</span><del>- switch (rule->type()) {
</del><ins>+ switch (rule.type()) {
</ins><span class="cx"> case CSSRule::STYLE_RULE:
</span><del>- wrapper = CREATE_DOM_WRAPPER(globalObject, CSSStyleRule, rule);
</del><ins>+ wrapper = CREATE_DOM_WRAPPER(globalObject, CSSStyleRule, &rule);
</ins><span class="cx"> break;
</span><span class="cx"> case CSSRule::MEDIA_RULE:
</span><del>- wrapper = CREATE_DOM_WRAPPER(globalObject, CSSMediaRule, rule);
</del><ins>+ wrapper = CREATE_DOM_WRAPPER(globalObject, CSSMediaRule, &rule);
</ins><span class="cx"> break;
</span><span class="cx"> case CSSRule::FONT_FACE_RULE:
</span><del>- wrapper = CREATE_DOM_WRAPPER(globalObject, CSSFontFaceRule, rule);
</del><ins>+ wrapper = CREATE_DOM_WRAPPER(globalObject, CSSFontFaceRule, &rule);
</ins><span class="cx"> break;
</span><span class="cx"> case CSSRule::PAGE_RULE:
</span><del>- wrapper = CREATE_DOM_WRAPPER(globalObject, CSSPageRule, rule);
</del><ins>+ wrapper = CREATE_DOM_WRAPPER(globalObject, CSSPageRule, &rule);
</ins><span class="cx"> break;
</span><span class="cx"> case CSSRule::IMPORT_RULE:
</span><del>- wrapper = CREATE_DOM_WRAPPER(globalObject, CSSImportRule, rule);
</del><ins>+ wrapper = CREATE_DOM_WRAPPER(globalObject, CSSImportRule, &rule);
</ins><span class="cx"> break;
</span><span class="cx"> case CSSRule::CHARSET_RULE:
</span><del>- wrapper = CREATE_DOM_WRAPPER(globalObject, CSSCharsetRule, rule);
</del><ins>+ wrapper = CREATE_DOM_WRAPPER(globalObject, CSSCharsetRule, &rule);
</ins><span class="cx"> break;
</span><span class="cx"> case CSSRule::KEYFRAME_RULE:
</span><del>- wrapper = CREATE_DOM_WRAPPER(globalObject, CSSKeyframeRule, rule);
</del><ins>+ wrapper = CREATE_DOM_WRAPPER(globalObject, CSSKeyframeRule, &rule);
</ins><span class="cx"> break;
</span><span class="cx"> case CSSRule::KEYFRAMES_RULE:
</span><del>- wrapper = CREATE_DOM_WRAPPER(globalObject, CSSKeyframesRule, rule);
</del><ins>+ wrapper = CREATE_DOM_WRAPPER(globalObject, CSSKeyframesRule, &rule);
</ins><span class="cx"> break;
</span><span class="cx"> case CSSRule::SUPPORTS_RULE:
</span><del>- wrapper = CREATE_DOM_WRAPPER(globalObject, CSSSupportsRule, rule);
</del><ins>+ wrapper = CREATE_DOM_WRAPPER(globalObject, CSSSupportsRule, &rule);
</ins><span class="cx"> break;
</span><span class="cx"> #if ENABLE(CSS_DEVICE_ADAPTATION)
</span><span class="cx"> case CSSRule::WEBKIT_VIEWPORT_RULE:
</span><del>- wrapper = CREATE_DOM_WRAPPER(globalObject, WebKitCSSViewportRule, rule);
</del><ins>+ wrapper = CREATE_DOM_WRAPPER(globalObject, WebKitCSSViewportRule, &rule);
</ins><span class="cx"> break;
</span><span class="cx"> #endif
</span><span class="cx"> #if ENABLE(CSS_REGIONS)
</span><span class="cx"> case CSSRule::WEBKIT_REGION_RULE:
</span><del>- wrapper = CREATE_DOM_WRAPPER(globalObject, WebKitCSSRegionRule, rule);
</del><ins>+ wrapper = CREATE_DOM_WRAPPER(globalObject, WebKitCSSRegionRule, &rule);
</ins><span class="cx"> break;
</span><span class="cx"> #endif
</span><span class="cx"> default:
</span><del>- wrapper = CREATE_DOM_WRAPPER(globalObject, CSSRule, rule);
</del><ins>+ wrapper = CREATE_DOM_WRAPPER(globalObject, CSSRule, &rule);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> return wrapper;
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSCSSStyleDeclarationCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSCSSStyleDeclarationCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSCSSStyleDeclarationCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSCSSStyleDeclarationCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -358,7 +358,7 @@
</span><span class="cx"> return jsNull();
</span><span class="cx">
</span><span class="cx"> globalObject()->world().m_cssValueRoots.add(cssValue.get(), root(&wrapped())); // Balanced by JSCSSValueOwner::finalize().
</span><del>- return toJS(&state, globalObject(), WTF::getPtr(cssValue));
</del><ins>+ return toJS(&state, globalObject(), *cssValue);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> void JSCSSStyleDeclaration::getOwnPropertyNames(JSObject* object, ExecState* exec, PropertyNameArray& propertyNames, EnumerationMode mode)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSCSSValueCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSCSSValueCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSCSSValueCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSCSSValueCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -64,37 +64,34 @@
</span><span class="cx"> uncacheWrapper(world, &jsCSSValue->wrapped(), jsCSSValue);
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSValue toJS(ExecState*, JSDOMGlobalObject* globalObject, CSSValue* value)
</del><ins>+JSValue toJS(ExecState*, JSDOMGlobalObject* globalObject, CSSValue& value)
</ins><span class="cx"> {
</span><del>- if (!value)
- return jsNull();
-
</del><span class="cx"> // Scripts should only ever see cloned CSSValues, never the internal ones.
</span><del>- ASSERT(value->isCSSOMSafe());
</del><ins>+ ASSERT(value.isCSSOMSafe());
</ins><span class="cx">
</span><span class="cx"> // If we're here under erroneous circumstances, prefer returning null over a potentially insecure value.
</span><del>- if (!value->isCSSOMSafe())
</del><ins>+ if (!value.isCSSOMSafe())
</ins><span class="cx"> return jsNull();
</span><span class="cx">
</span><del>- JSObject* wrapper = getCachedWrapper(globalObject->world(), value);
</del><ins>+ JSObject* wrapper = getCachedWrapper(globalObject->world(), &value);
</ins><span class="cx">
</span><span class="cx"> if (wrapper)
</span><span class="cx"> return wrapper;
</span><span class="cx">
</span><del>- if (value->isWebKitCSSTransformValue())
- wrapper = CREATE_DOM_WRAPPER(globalObject, WebKitCSSTransformValue, value);
- else if (value->isWebKitCSSFilterValue())
- wrapper = CREATE_DOM_WRAPPER(globalObject, WebKitCSSFilterValue, value);
- else if (value->isValueList())
- wrapper = CREATE_DOM_WRAPPER(globalObject, CSSValueList, value);
- else if (value->isSVGPaint())
- wrapper = CREATE_DOM_WRAPPER(globalObject, SVGPaint, value);
- else if (value->isSVGColor())
- wrapper = CREATE_DOM_WRAPPER(globalObject, SVGColor, value);
- else if (value->isPrimitiveValue())
- wrapper = CREATE_DOM_WRAPPER(globalObject, CSSPrimitiveValue, value);
</del><ins>+ if (value.isWebKitCSSTransformValue())
+ wrapper = CREATE_DOM_WRAPPER(globalObject, WebKitCSSTransformValue, &value);
+ else if (value.isWebKitCSSFilterValue())
+ wrapper = CREATE_DOM_WRAPPER(globalObject, WebKitCSSFilterValue, &value);
+ else if (value.isValueList())
+ wrapper = CREATE_DOM_WRAPPER(globalObject, CSSValueList, &value);
+ else if (value.isSVGPaint())
+ wrapper = CREATE_DOM_WRAPPER(globalObject, SVGPaint, &value);
+ else if (value.isSVGColor())
+ wrapper = CREATE_DOM_WRAPPER(globalObject, SVGColor, &value);
+ else if (value.isPrimitiveValue())
+ wrapper = CREATE_DOM_WRAPPER(globalObject, CSSPrimitiveValue, &value);
</ins><span class="cx"> else
</span><del>- wrapper = CREATE_DOM_WRAPPER(globalObject, CSSValue, value);
</del><ins>+ wrapper = CREATE_DOM_WRAPPER(globalObject, CSSValue, &value);
</ins><span class="cx">
</span><span class="cx"> return wrapper;
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSCanvasRenderingContextCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSCanvasRenderingContextCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSCanvasRenderingContextCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSCanvasRenderingContextCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -47,20 +47,17 @@
</span><span class="cx"> visitor.addOpaqueRoot(root(wrapped().canvas()));
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, CanvasRenderingContext* object)
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, CanvasRenderingContext& object)
</ins><span class="cx"> {
</span><del>- if (!object)
- return jsNull();
-
</del><span class="cx"> #if ENABLE(WEBGL)
</span><del>- if (is<WebGLRenderingContext>(*object))
- return wrap<JSWebGLRenderingContext>(globalObject, downcast<WebGLRenderingContext>(*object));
</del><ins>+ if (is<WebGLRenderingContext>(object))
+ return wrap<JSWebGLRenderingContext>(globalObject, downcast<WebGLRenderingContext>(object));
</ins><span class="cx"> #if ENABLE(WEBGL2)
</span><del>- if (is<WebGL2RenderingContext>(*object))
- return wrap<JSWebGL2RenderingContext>(globalObject, downcast<WebGL2RenderingContext>(*object));
</del><ins>+ if (is<WebGL2RenderingContext>(object))
+ return wrap<JSWebGL2RenderingContext>(globalObject, downcast<WebGL2RenderingContext>(object));
</ins><span class="cx"> #endif
</span><span class="cx"> #endif
</span><del>- return wrap<JSCanvasRenderingContext2D>(globalObject, downcast<CanvasRenderingContext2D>(*object));
</del><ins>+ return wrap<JSCanvasRenderingContext2D>(globalObject, downcast<CanvasRenderingContext2D>(object));
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSCustomElementInterfacecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSCustomElementInterface.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSCustomElementInterface.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSCustomElementInterface.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -168,7 +168,7 @@
</span><span class="cx"> JSDOMGlobalObject* globalObject = toJSDOMGlobalObject(context, *m_isolatedWorld);
</span><span class="cx"> ExecState* state = globalObject->globalExec();
</span><span class="cx">
</span><del>- JSObject* jsElement = asObject(toJS(state, globalObject, &element));
</del><ins>+ JSObject* jsElement = asObject(toJS(state, globalObject, element));
</ins><span class="cx">
</span><span class="cx"> PropertyName attributeChanged(Identifier::fromString(state, "attributeChangedCallback"));
</span><span class="cx"> JSValue callback = jsElement->get(state, attributeChanged);
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSDOMBindingh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSDOMBinding.h (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSDOMBinding.h        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSDOMBinding.h        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -251,8 +251,12 @@
</span><span class="cx"> JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, JSC::ArrayBuffer*);
</span><span class="cx"> JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, JSC::ArrayBufferView*);
</span><span class="cx"> JSC::JSValue toJS(JSC::ExecState*, JSC::JSGlobalObject*, JSC::ArrayBufferView*);
</span><del>-template<typename T> JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, RefPtr<T>);
-template<typename T> JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, PassRefPtr<T>);
</del><ins>+template<typename T> JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, const RefPtr<T>&);
+template<typename T> JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, const PassRefPtr<T>&);
+template<typename T> JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, const Ref<T>&);
+template<typename T> JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, const RefPtr<T>&);
+template<typename T> JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, const PassRefPtr<T>&);
+template<typename T> JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, const Ref<T>&);
</ins><span class="cx"> template<typename T> JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, const Vector<T>&);
</span><span class="cx"> template<typename T> JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, const Vector<RefPtr<T>>&);
</span><span class="cx"> JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, const String&);
</span><span class="lines">@@ -540,16 +544,36 @@
</span><span class="cx"> return view->wrap(exec, globalObject);
</span><span class="cx"> }
</span><span class="cx">
</span><del>-template<typename T> inline JSC::JSValue toJS(JSC::ExecState* exec, JSDOMGlobalObject* globalObject, RefPtr<T> ptr)
</del><ins>+template<typename T> inline JSC::JSValue toJS(JSC::ExecState* exec, JSDOMGlobalObject* globalObject, const RefPtr<T>& ptr)
</ins><span class="cx"> {
</span><span class="cx"> return toJS(exec, globalObject, ptr.get());
</span><span class="cx"> }
</span><span class="cx">
</span><del>-template<typename T> inline JSC::JSValue toJS(JSC::ExecState* exec, JSDOMGlobalObject* globalObject, PassRefPtr<T> ptr)
</del><ins>+template<typename T> inline JSC::JSValue toJS(JSC::ExecState* exec, JSDOMGlobalObject* globalObject, const PassRefPtr<T>& ptr)
</ins><span class="cx"> {
</span><span class="cx"> return toJS(exec, globalObject, ptr.get());
</span><span class="cx"> }
</span><span class="cx">
</span><ins>+template<typename T> inline JSC::JSValue toJS(JSC::ExecState* exec, JSDOMGlobalObject* globalObject, const Ref<T>& ptr)
+{
+ return toJS(exec, globalObject, const_cast<T&>(ptr.get()));
+}
+
+template<typename T> inline JSC::JSValue toJSNewlyCreated(JSC::ExecState* exec, JSDOMGlobalObject* globalObject, const RefPtr<T>& ptr)
+{
+ return toJSNewlyCreated(exec, globalObject, ptr.get());
+}
+
+template<typename T> inline JSC::JSValue toJSNewlyCreated(JSC::ExecState* exec, JSDOMGlobalObject* globalObject, const PassRefPtr<T>& ptr)
+{
+ return toJSNewlyCreated(exec, globalObject, ptr.get());
+}
+
+template<typename T> inline JSC::JSValue toJSNewlyCreated(JSC::ExecState* exec, JSDOMGlobalObject* globalObject, const Ref<T>& ptr)
+{
+ return toJSNewlyCreated(exec, globalObject, const_cast<T&>(ptr.get()));
+}
+
</ins><span class="cx"> template<typename T> inline JSC::JSValue toJS(JSC::ExecState* exec, JSDOMGlobalObject* globalObject, const Vector<T>& vector)
</span><span class="cx"> {
</span><span class="cx"> JSC::JSArray* array = constructEmptyArray(exec, nullptr, vector.size());
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSDOMFormDataCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSDOMFormDataCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSDOMFormDataCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSDOMFormDataCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -51,8 +51,8 @@
</span><span class="cx"> DOMConstructorObject* jsConstructor = jsCast<DOMConstructorObject*>(exec->callee());
</span><span class="cx">
</span><span class="cx"> HTMLFormElement* form = toHTMLFormElementOrNull(exec->argument(0));
</span><del>- RefPtr<DOMFormData> domFormData = DOMFormData::create(form);
- return JSValue::encode(asObject(toJS(exec, jsConstructor->globalObject(), domFormData.get())));
</del><ins>+ auto domFormData = DOMFormData::create(form);
+ return JSValue::encode(asObject(toJS(exec, jsConstructor->globalObject(), domFormData)));
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> JSValue JSDOMFormData::append(ExecState& state)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSDOMMimeTypeArrayCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSDOMMimeTypeArrayCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSDOMMimeTypeArrayCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSDOMMimeTypeArrayCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -35,7 +35,7 @@
</span><span class="cx"> if (!item)
</span><span class="cx"> return false;
</span><span class="cx">
</span><del>- value = toJS(exec, globalObject(), item);
</del><ins>+ value = toJS(exec, globalObject(), *item);
</ins><span class="cx"> return true;
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSDOMNamedFlowCollectionCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSDOMNamedFlowCollectionCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSDOMNamedFlowCollectionCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSDOMNamedFlowCollectionCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -42,7 +42,7 @@
</span><span class="cx"> if (!item)
</span><span class="cx"> return false;
</span><span class="cx">
</span><del>- value = toJS(exec, globalObject(), item);
</del><ins>+ value = toJS(exec, globalObject(), *item);
</ins><span class="cx"> return true;
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSDOMPluginArrayCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSDOMPluginArrayCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSDOMPluginArrayCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSDOMPluginArrayCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -35,7 +35,7 @@
</span><span class="cx"> if (!item)
</span><span class="cx"> return false;
</span><span class="cx">
</span><del>- value = toJS(exec, globalObject(), item);
</del><ins>+ value = toJS(exec, globalObject(), *item);
</ins><span class="cx"> return true;
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSDOMPluginCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSDOMPluginCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSDOMPluginCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSDOMPluginCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -33,7 +33,7 @@
</span><span class="cx"> if (!item)
</span><span class="cx"> return false;
</span><span class="cx">
</span><del>- value = toJS(exec, globalObject(), item);
</del><ins>+ value = toJS(exec, globalObject(), *item);
</ins><span class="cx"> return true;
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSDOMWindowBasecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSDOMWindowBase.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSDOMWindowBase.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSDOMWindowBase.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -282,16 +282,14 @@
</span><span class="cx">
</span><span class="cx"> // JSDOMGlobalObject* is ignored, accessing a window in any context will
</span><span class="cx"> // use that DOMWindow's prototype chain.
</span><del>-JSValue toJS(ExecState* exec, JSDOMGlobalObject*, DOMWindow* domWindow)
</del><ins>+JSValue toJS(ExecState* exec, JSDOMGlobalObject*, DOMWindow& domWindow)
</ins><span class="cx"> {
</span><span class="cx"> return toJS(exec, domWindow);
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSValue toJS(ExecState* exec, DOMWindow* domWindow)
</del><ins>+JSValue toJS(ExecState* exec, DOMWindow& domWindow)
</ins><span class="cx"> {
</span><del>- if (!domWindow)
- return jsNull();
- Frame* frame = domWindow->frame();
</del><ins>+ Frame* frame = domWindow.frame();
</ins><span class="cx"> if (!frame)
</span><span class="cx"> return jsNull();
</span><span class="cx"> return frame->script().windowShell(currentWorld(exec));
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSDOMWindowBaseh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSDOMWindowBase.h (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSDOMWindowBase.h        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSDOMWindowBase.h        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -90,8 +90,10 @@
</span><span class="cx"> // Returns a JSDOMWindow or jsNull()
</span><span class="cx"> // JSDOMGlobalObject* is ignored, accessing a window in any context will
</span><span class="cx"> // use that DOMWindow's prototype chain.
</span><del>- WEBCORE_EXPORT JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, DOMWindow*);
- JSC::JSValue toJS(JSC::ExecState*, DOMWindow*);
</del><ins>+ WEBCORE_EXPORT JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, DOMWindow&);
+ inline JSC::JSValue toJS(JSC::ExecState* exec, JSDOMGlobalObject* globalObject, DOMWindow* window) { return window ? toJS(exec, globalObject, *window) : JSC::jsNull(); }
+ JSC::JSValue toJS(JSC::ExecState*, DOMWindow&);
+ inline JSC::JSValue toJS(JSC::ExecState* exec, DOMWindow* window) { return window ? toJS(exec, *window) : JSC::jsNull(); }
</ins><span class="cx">
</span><span class="cx"> // Returns JSDOMWindow or 0
</span><span class="cx"> JSDOMWindow* toJSDOMWindow(Frame*, DOMWrapperWorld&);
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSDOMWindowCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSDOMWindowCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSDOMWindowCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSDOMWindowCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -203,7 +203,7 @@
</span><span class="cx"> if (UNLIKELY(htmlDocument.windowNamedItemContainsMultipleElements(*atomicPropertyName))) {
</span><span class="cx"> Ref<HTMLCollection> collection = document->windowNamedItems(atomicPropertyName);
</span><span class="cx"> ASSERT(collection->length() > 1);
</span><del>- namedItem = toJS(exec, thisObject->globalObject(), collection.ptr());
</del><ins>+ namedItem = toJS(exec, thisObject->globalObject(), collection);
</ins><span class="cx"> } else
</span><span class="cx"> namedItem = toJS(exec, thisObject->globalObject(), htmlDocument.windowNamedItem(*atomicPropertyName));
</span><span class="cx"> slot.setValue(thisObject, ReadOnly | DontDelete | DontEnum, namedItem);
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSDocumentCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSDocumentCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSDocumentCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSDocumentCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -79,29 +79,26 @@
</span><span class="cx"> return wrapper;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSValue toJS(ExecState* state, JSDOMGlobalObject* globalObject, Document* document)
</del><ins>+JSValue toJS(ExecState* state, JSDOMGlobalObject* globalObject, Document& document)
</ins><span class="cx"> {
</span><del>- if (!document)
- return jsNull();
-
- JSObject* wrapper = getCachedWrapper(globalObject->world(), document);
</del><ins>+ JSObject* wrapper = getCachedWrapper(globalObject->world(), &document);
</ins><span class="cx"> if (wrapper)
</span><span class="cx"> return wrapper;
</span><span class="cx">
</span><del>- if (DOMWindow* domWindow = document->domWindow()) {
- globalObject = toJSDOMWindow(toJS(state, domWindow));
</del><ins>+ if (DOMWindow* domWindow = document.domWindow()) {
+ globalObject = toJSDOMWindow(toJS(state, *domWindow));
</ins><span class="cx"> // Creating a wrapper for domWindow might have created a wrapper for document as well.
</span><del>- wrapper = getCachedWrapper(globalObject->world(), document);
</del><ins>+ wrapper = getCachedWrapper(globalObject->world(), &document);
</ins><span class="cx"> if (wrapper)
</span><span class="cx"> return wrapper;
</span><span class="cx"> }
</span><span class="cx">
</span><del>- return createNewDocumentWrapper(*state, *globalObject, *document);
</del><ins>+ return createNewDocumentWrapper(*state, *globalObject, document);
</ins><span class="cx"> }
</span><span class="cx">
</span><del>-JSValue toJSNewlyCreated(ExecState* state, JSDOMGlobalObject* globalObject, Document* document)
</del><ins>+JSValue toJSNewlyCreated(ExecState* state, JSDOMGlobalObject* globalObject, Document& document)
</ins><span class="cx"> {
</span><del>- return document ? createNewDocumentWrapper(*state, *globalObject, *document) : jsNull();
</del><ins>+ return createNewDocumentWrapper(*state, *globalObject, document);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> JSValue JSDocument::prepend(ExecState& state)
</span><span class="lines">@@ -125,12 +122,12 @@
</span><span class="cx"> #if ENABLE(TOUCH_EVENTS)
</span><span class="cx"> JSValue JSDocument::createTouchList(ExecState& state)
</span><span class="cx"> {
</span><del>- RefPtr<TouchList> touchList = TouchList::create();
</del><ins>+ auto touchList = TouchList::create();
</ins><span class="cx">
</span><span class="cx"> for (size_t i = 0; i < state.argumentCount(); i++)
</span><span class="cx"> touchList->append(JSTouch::toWrapped(state.argument(i)));
</span><span class="cx">
</span><del>- return toJS(&state, globalObject(), touchList.release());
</del><ins>+ return toJS(&state, globalObject(), touchList);
</ins><span class="cx"> }
</span><span class="cx"> #endif
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSDocumentFragmentCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSDocumentFragmentCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSDocumentFragmentCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSDocumentFragmentCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -61,20 +61,17 @@
</span><span class="cx"> return createNewWrapper<JSDocumentFragment>(&globalObject, &impl);
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSValue toJSNewlyCreated(ExecState*, JSDOMGlobalObject* globalObject, DocumentFragment* impl)
</del><ins>+JSValue toJSNewlyCreated(ExecState*, JSDOMGlobalObject* globalObject, DocumentFragment& impl)
</ins><span class="cx"> {
</span><del>- return impl ? createNewDocumentFragmentWrapper(*globalObject, *impl) : jsNull();
</del><ins>+ return createNewDocumentFragmentWrapper(*globalObject, impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><del>-JSValue toJS(ExecState*, JSDOMGlobalObject* globalObject, DocumentFragment* impl)
</del><ins>+JSValue toJS(ExecState*, JSDOMGlobalObject* globalObject, DocumentFragment& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
-
- if (JSValue result = getExistingWrapper<JSDocumentFragment>(globalObject, impl))
</del><ins>+ if (JSValue result = getExistingWrapper<JSDocumentFragment>(globalObject, &impl))
</ins><span class="cx"> return result;
</span><span class="cx">
</span><del>- return createNewDocumentFragmentWrapper(*globalObject, *impl);
</del><ins>+ return createNewDocumentFragmentWrapper(*globalObject, impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSEventCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSEventCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSEventCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSEventCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -62,24 +62,21 @@
</span><span class="cx"> return CREATE_DOM_WRAPPER(&globalObject, Event, &event);
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSValue toJS(ExecState*, JSDOMGlobalObject* globalObject, Event* event)
</del><ins>+JSValue toJS(ExecState*, JSDOMGlobalObject* globalObject, Event& event)
</ins><span class="cx"> {
</span><span class="cx"> JSLockHolder lock(globalObject->vm());
</span><span class="cx">
</span><del>- if (!event)
- return jsNull();
-
- JSObject* wrapper = getCachedWrapper(globalObject->world(), event);
</del><ins>+ JSObject* wrapper = getCachedWrapper(globalObject->world(), &event);
</ins><span class="cx"> if (wrapper)
</span><span class="cx"> return wrapper;
</span><span class="cx">
</span><del>- return createNewEventWrapper(*globalObject, *event);
</del><ins>+ return createNewEventWrapper(*globalObject, event);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx">
</span><del>-JSValue toJSNewlyCreated(ExecState*, JSDOMGlobalObject* globalObject, Event* event)
</del><ins>+JSValue toJSNewlyCreated(ExecState*, JSDOMGlobalObject* globalObject, Event& event)
</ins><span class="cx"> {
</span><del>- return event ? createNewEventWrapper(*globalObject, *event) : jsNull();
</del><ins>+ return createNewEventWrapper(*globalObject, event);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> #undef TRY_TO_WRAP_WITH_INTERFACE
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSEventTargetCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSEventTargetCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSEventTargetCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSEventTargetCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -42,14 +42,11 @@
</span><span class="cx">
</span><span class="cx"> #define TRY_TO_WRAP_WITH_INTERFACE(interfaceName) \
</span><span class="cx"> case interfaceName##EventTargetInterfaceType: \
</span><del>- return toJS(exec, globalObject, static_cast<interfaceName*>(target));
</del><ins>+ return toJS(exec, globalObject, static_cast<interfaceName&>(target));
</ins><span class="cx">
</span><del>-JSValue toJS(ExecState* exec, JSDOMGlobalObject* globalObject, EventTarget* target)
</del><ins>+JSValue toJS(ExecState* exec, JSDOMGlobalObject* globalObject, EventTarget& target)
</ins><span class="cx"> {
</span><del>- if (!target)
- return jsNull();
-
- switch (target->eventTargetInterface()) {
</del><ins>+ switch (target.eventTargetInterface()) {
</ins><span class="cx"> DOM_EVENT_TARGET_INTERFACES_FOR_EACH(TRY_TO_WRAP_WITH_INTERFACE)
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSFileReaderCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSFileReaderCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSFileReaderCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSFileReaderCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -45,7 +45,7 @@
</span><span class="cx"> {
</span><span class="cx"> FileReader& imp = wrapped();
</span><span class="cx"> if (imp.readType() == FileReaderLoader::ReadAsArrayBuffer)
</span><del>- return toJS(&state, globalObject(), WTF::getPtr(imp.arrayBufferResult()));
</del><ins>+ return toJS(&state, globalObject(), imp.arrayBufferResult().get());
</ins><span class="cx"> return jsOwnedStringOrNull(&state, imp.stringResult());
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSHTMLAllCollectionCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSHTMLAllCollectionCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSHTMLAllCollectionCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSHTMLAllCollectionCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -43,11 +43,11 @@
</span><span class="cx"> if (namedItems.isEmpty())
</span><span class="cx"> return jsUndefined();
</span><span class="cx"> if (namedItems.size() == 1)
</span><del>- return toJS(&state, collection->globalObject(), namedItems[0].ptr());
</del><ins>+ return toJS(&state, collection->globalObject(), namedItems[0]);
</ins><span class="cx">
</span><span class="cx"> // FIXME: HTML5 specification says this should be a HTMLCollection.
</span><span class="cx"> // http://www.whatwg.org/specs/web-apps/current-work/multipage/common-dom-interfaces.html#htmlallcollection
</span><del>- return toJS(&state, collection->globalObject(), StaticElementList::adopt(namedItems).get());
</del><ins>+ return toJS(&state, collection->globalObject(), StaticElementList::adopt(namedItems));
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> // HTMLAllCollections are strange objects, they support both get and call.
</span><span class="lines">@@ -80,7 +80,7 @@
</span><span class="cx"> return JSValue::encode(jsUndefined());
</span><span class="cx"> if (Optional<uint32_t> index = parseIndex(*exec->argument(1).toWTFString(exec).impl())) {
</span><span class="cx"> if (auto* item = collection.namedItemWithIndex(string, index.value()))
</span><del>- return JSValue::encode(toJS(exec, jsCollection->globalObject(), item));
</del><ins>+ return JSValue::encode(toJS(exec, jsCollection->globalObject(), *item));
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> return JSValue::encode(jsUndefined());
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSHTMLCanvasElementCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSHTMLCanvasElementCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSHTMLCanvasElementCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSHTMLCanvasElementCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -84,7 +84,7 @@
</span><span class="cx"> CanvasRenderingContext* context = canvas.getContext(contextId, attrs.get());
</span><span class="cx"> if (!context)
</span><span class="cx"> return jsNull();
</span><del>- return toJS(&state, globalObject(), WTF::getPtr(context));
</del><ins>+ return toJS(&state, globalObject(), *context);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> JSValue JSHTMLCanvasElement::probablySupportsContext(ExecState& state)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSHTMLCollectionCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSHTMLCollectionCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSHTMLCollectionCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSHTMLCollectionCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -49,32 +49,29 @@
</span><span class="cx"> if (!item)
</span><span class="cx"> return false;
</span><span class="cx">
</span><del>- value = toJS(exec, globalObject(), item);
</del><ins>+ value = toJS(exec, globalObject(), *item);
</ins><span class="cx"> return true;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSValue toJS(ExecState*, JSDOMGlobalObject* globalObject, HTMLCollection* collection)
</del><ins>+JSValue toJS(ExecState*, JSDOMGlobalObject* globalObject, HTMLCollection& collection)
</ins><span class="cx"> {
</span><del>- if (!collection)
- return jsNull();
</del><ins>+ JSObject* wrapper = getCachedWrapper(globalObject->world(), &collection);
</ins><span class="cx">
</span><del>- JSObject* wrapper = getCachedWrapper(globalObject->world(), collection);
-
</del><span class="cx"> if (wrapper)
</span><span class="cx"> return wrapper;
</span><span class="cx">
</span><del>- switch (collection->type()) {
</del><ins>+ switch (collection.type()) {
</ins><span class="cx"> case FormControls:
</span><del>- return CREATE_DOM_WRAPPER(globalObject, HTMLFormControlsCollection, collection);
</del><ins>+ return CREATE_DOM_WRAPPER(globalObject, HTMLFormControlsCollection, &collection);
</ins><span class="cx"> case SelectOptions:
</span><del>- return CREATE_DOM_WRAPPER(globalObject, HTMLOptionsCollection, collection);
</del><ins>+ return CREATE_DOM_WRAPPER(globalObject, HTMLOptionsCollection, &collection);
</ins><span class="cx"> case DocAll:
</span><del>- return CREATE_DOM_WRAPPER(globalObject, HTMLAllCollection, collection);
</del><ins>+ return CREATE_DOM_WRAPPER(globalObject, HTMLAllCollection, &collection);
</ins><span class="cx"> default:
</span><span class="cx"> break;
</span><span class="cx"> }
</span><span class="cx">
</span><del>- return CREATE_DOM_WRAPPER(globalObject, HTMLCollection, collection);
</del><ins>+ return CREATE_DOM_WRAPPER(globalObject, HTMLCollection, &collection);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSHTMLDocumentCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSHTMLDocumentCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSHTMLDocumentCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSHTMLDocumentCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -87,13 +87,13 @@
</span><span class="cx"> if (UNLIKELY(document.documentNamedItemContainsMultipleElements(*atomicPropertyName))) {
</span><span class="cx"> Ref<HTMLCollection> collection = document.documentNamedItems(atomicPropertyName);
</span><span class="cx"> ASSERT(collection->length() > 1);
</span><del>- value = toJS(exec, globalObject(), WTF::getPtr(collection));
</del><ins>+ value = toJS(exec, globalObject(), collection);
</ins><span class="cx"> return true;
</span><span class="cx"> }
</span><span class="cx">
</span><del>- Element* element = document.documentNamedItem(*atomicPropertyName);
- if (UNLIKELY(is<HTMLIFrameElement>(*element))) {
- if (Frame* frame = downcast<HTMLIFrameElement>(*element).contentFrame()) {
</del><ins>+ Element& element = *document.documentNamedItem(*atomicPropertyName);
+ if (UNLIKELY(is<HTMLIFrameElement>(element))) {
+ if (Frame* frame = downcast<HTMLIFrameElement>(element).contentFrame()) {
</ins><span class="cx"> value = toJS(exec, frame);
</span><span class="cx"> return true;
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSHTMLElementCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSHTMLElementCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSHTMLElementCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSHTMLElementCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -78,7 +78,7 @@
</span><span class="cx"> return JSValue::encode(jsUndefined());
</span><span class="cx"> }
</span><span class="cx">
</span><del>- JSValue elementWrapperValue = toJS(state, jsConstructor->globalObject(), elementToUpgrade);
</del><ins>+ JSValue elementWrapperValue = toJS(state, jsConstructor->globalObject(), *elementToUpgrade);
</ins><span class="cx"> ASSERT(elementWrapperValue.isObject());
</span><span class="cx">
</span><span class="cx"> JSValue newPrototype = newTarget->get(state, vm.propertyNames->prototype);
</span><span class="lines">@@ -108,14 +108,14 @@
</span><span class="cx"> VM& vm = exec->vm();
</span><span class="cx"> JSGlobalObject* lexicalGlobalObject = exec->lexicalGlobalObject();
</span><span class="cx">
</span><del>- scope = JSWithScope::create(vm, lexicalGlobalObject, asObject(toJS(exec, globalObject(), &element.document())), scope);
</del><ins>+ scope = JSWithScope::create(vm, lexicalGlobalObject, asObject(toJS(exec, globalObject(), element.document())), scope);
</ins><span class="cx">
</span><span class="cx"> // The form is next, searched before the document, but after the element itself.
</span><span class="cx"> if (HTMLFormElement* form = element.form())
</span><del>- scope = JSWithScope::create(vm, lexicalGlobalObject, asObject(toJS(exec, globalObject(), form)), scope);
</del><ins>+ scope = JSWithScope::create(vm, lexicalGlobalObject, asObject(toJS(exec, globalObject(), *form)), scope);
</ins><span class="cx">
</span><span class="cx"> // The element is on top, searched first.
</span><del>- return JSWithScope::create(vm, lexicalGlobalObject, asObject(toJS(exec, globalObject(), &element)), scope);
</del><ins>+ return JSWithScope::create(vm, lexicalGlobalObject, asObject(toJS(exec, globalObject(), element)), scope);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSHTMLFormControlsCollectionCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSHTMLFormControlsCollectionCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSHTMLFormControlsCollectionCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSHTMLFormControlsCollectionCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -38,7 +38,7 @@
</span><span class="cx"> if (namedItems.isEmpty())
</span><span class="cx"> return jsUndefined();
</span><span class="cx"> if (namedItems.size() == 1)
</span><del>- return toJS(&state, collection->globalObject(), namedItems[0].ptr());
</del><ins>+ return toJS(&state, collection->globalObject(), namedItems[0]);
</ins><span class="cx">
</span><span class="cx"> ASSERT(collection->wrapped().type() == FormControls);
</span><span class="cx"> return toJS(&state, collection->globalObject(), collection->wrapped().ownerNode().radioNodeList(name).get());
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSHTMLFormElementCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSHTMLFormElementCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSHTMLFormElementCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSHTMLFormElementCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -43,7 +43,7 @@
</span><span class="cx"> if (namedItems.isEmpty())
</span><span class="cx"> return false;
</span><span class="cx"> if (namedItems.size() == 1) {
</span><del>- value = toJS(exec, globalObject(), namedItems[0].ptr());
</del><ins>+ value = toJS(exec, globalObject(), namedItems[0]);
</ins><span class="cx"> return true;
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSHTMLOptionsCollectionCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSHTMLOptionsCollectionCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSHTMLOptionsCollectionCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSHTMLOptionsCollectionCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -43,7 +43,7 @@
</span><span class="cx"> if (!item)
</span><span class="cx"> return false;
</span><span class="cx">
</span><del>- value = toJS(exec, globalObject(), item);
</del><ins>+ value = toJS(exec, globalObject(), *item);
</ins><span class="cx"> return true;
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSIDBCursorCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSIDBCursorCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSIDBCursorCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSIDBCursorCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -48,19 +48,16 @@
</span><span class="cx"> {
</span><span class="cx"> auto& cursor = wrapped();
</span><span class="cx"> if (auto* index = cursor.index())
</span><del>- return toJS(&state, globalObject(), index);
</del><ins>+ return toJS(&state, globalObject(), *index);
</ins><span class="cx"> return toJS(&state, globalObject(), cursor.objectStore());
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, IDBCursor* cursor)
</del><ins>+JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, IDBCursor& cursor)
</ins><span class="cx"> {
</span><del>- if (!cursor)
- return JSC::jsNull();
</del><ins>+ if (is<IDBCursorWithValue>(cursor))
+ return wrap<JSIDBCursorWithValue>(globalObject, downcast<IDBCursorWithValue>(cursor));
</ins><span class="cx">
</span><del>- if (is<IDBCursorWithValue>(*cursor))
- return wrap<JSIDBCursorWithValue>(globalObject, downcast<IDBCursorWithValue>(*cursor));
-
- return wrap<JSIDBCursor>(globalObject, *cursor);
</del><ins>+ return wrap<JSIDBCursor>(globalObject, cursor);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSIDBDatabaseCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSIDBDatabaseCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSIDBDatabaseCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSIDBDatabaseCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -77,7 +77,7 @@
</span><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> ExceptionCodeWithMessage ec;
</span><del>- JSValue result = toJS(&state, globalObject(), wrapped().createObjectStore(name, keyPath, autoIncrement, ec).get());
</del><ins>+ JSValue result = toJS(&state, globalObject(), wrapped().createObjectStore(name, keyPath, autoIncrement, ec));
</ins><span class="cx"> setDOMException(&state, ec);
</span><span class="cx"> return result;
</span><span class="cx"> }
</span><span class="lines">@@ -116,7 +116,7 @@
</span><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> ExceptionCodeWithMessage ec;
</span><del>- JSValue result = toJS(&exec, globalObject(), wrapped().transaction(scriptContext, scope, mode, ec).get());
</del><ins>+ JSValue result = toJS(&exec, globalObject(), wrapped().transaction(scriptContext, scope, mode, ec));
</ins><span class="cx"> setDOMException(&exec, ec);
</span><span class="cx"> return result;
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSIDBRequestCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSIDBRequestCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSIDBRequestCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSIDBRequestCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -50,9 +50,9 @@
</span><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> if (auto* cursor = request.cursorResult())
</span><del>- return toJS(&state, globalObject(), cursor);
</del><ins>+ return toJS(&state, globalObject(), *cursor);
</ins><span class="cx"> if (auto* database = request.databaseResult())
</span><del>- return toJS(&state, globalObject(), database);
</del><ins>+ return toJS(&state, globalObject(), *database);
</ins><span class="cx"> if (auto result = request.scriptResult())
</span><span class="cx"> return result;
</span><span class="cx"> return jsNull();
</span><span class="lines">@@ -62,9 +62,9 @@
</span><span class="cx"> {
</span><span class="cx"> auto& request = wrapped();
</span><span class="cx"> if (auto* cursor = request.cursorSource())
</span><del>- return toJS(&state, globalObject(), cursor);
</del><ins>+ return toJS(&state, globalObject(), *cursor);
</ins><span class="cx"> if (auto* index = request.indexSource())
</span><del>- return toJS(&state, globalObject(), index);
</del><ins>+ return toJS(&state, globalObject(), *index);
</ins><span class="cx"> return toJS(&state, globalObject(), request.objectStoreSource());
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSImageConstructorcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSImageConstructor.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSImageConstructor.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSImageConstructor.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -54,7 +54,7 @@
</span><span class="cx"> // Calling toJS on the document causes the JS document wrapper to be
</span><span class="cx"> // added to the window object. This is done to ensure that JSDocument::visit
</span><span class="cx"> // will be called, which will cause the image element to be marked if necessary.
</span><del>- toJS(state, jsConstructor->globalObject(), document);
</del><ins>+ toJS(state, jsConstructor->globalObject(), *document);
</ins><span class="cx"> int width;
</span><span class="cx"> int height;
</span><span class="cx"> int* optionalWidth = 0;
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSImageDataCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSImageDataCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSImageDataCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSImageDataCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -35,21 +35,18 @@
</span><span class="cx">
</span><span class="cx"> namespace WebCore {
</span><span class="cx">
</span><del>-JSValue toJS(ExecState* exec, JSDOMGlobalObject* globalObject, ImageData* imageData)
</del><ins>+JSValue toJS(ExecState* exec, JSDOMGlobalObject* globalObject, ImageData& imageData)
</ins><span class="cx"> {
</span><del>- if (!imageData)
- return jsNull();
-
- JSObject* wrapper = getCachedWrapper(globalObject->world(), imageData);
</del><ins>+ JSObject* wrapper = getCachedWrapper(globalObject->world(), &imageData);
</ins><span class="cx"> if (wrapper)
</span><span class="cx"> return wrapper;
</span><span class="cx">
</span><del>- wrapper = CREATE_DOM_WRAPPER(globalObject, ImageData, imageData);
</del><ins>+ wrapper = CREATE_DOM_WRAPPER(globalObject, ImageData, &imageData);
</ins><span class="cx"> Identifier dataName = Identifier::fromString(exec, "data");
</span><del>- wrapper->putDirect(exec->vm(), dataName, toJS(exec, globalObject, imageData->data()), DontDelete | ReadOnly);
</del><ins>+ wrapper->putDirect(exec->vm(), dataName, toJS(exec, globalObject, imageData.data()), DontDelete | ReadOnly);
</ins><span class="cx"> // FIXME: Adopt reportExtraMemoryVisited, and switch to reportExtraMemoryAllocated.
</span><span class="cx"> // https://bugs.webkit.org/show_bug.cgi?id=142595
</span><del>- exec->heap()->deprecatedReportExtraMemory(imageData->data()->length());
</del><ins>+ exec->heap()->deprecatedReportExtraMemory(imageData.data()->length());
</ins><span class="cx">
</span><span class="cx"> return wrapper;
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSLazyEventListenercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSLazyEventListener.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSLazyEventListener.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSLazyEventListener.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -125,7 +125,7 @@
</span><span class="cx"> // Ensure that 'node' has a JavaScript wrapper to mark the event listener we're creating.
</span><span class="cx"> JSLockHolder lock(exec);
</span><span class="cx"> // FIXME: Should pass the global object associated with the node
</span><del>- setWrapper(exec->vm(), asObject(toJS(exec, globalObject, m_originalNode)));
</del><ins>+ setWrapper(exec->vm(), asObject(toJS(exec, globalObject, *m_originalNode)));
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> // Add the event's home element to the scope
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSMediaSessionCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSMediaSessionCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSMediaSessionCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSMediaSessionCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -57,8 +57,8 @@
</span><span class="cx"> } else
</span><span class="cx"> kind = "content";
</span><span class="cx">
</span><del>- RefPtr<MediaSession> object = MediaSession::create(*context, kind);
- return JSValue::encode(asObject(toJS(exec, castedThis->globalObject(), object.get())));
</del><ins>+ auto object = MediaSession::create(*context, kind);
+ return JSValue::encode(asObject(toJS(exec, castedThis->globalObject(), object)));
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSMediaStreamCapabilitiesCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSMediaStreamCapabilitiesCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSMediaStreamCapabilitiesCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSMediaStreamCapabilitiesCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -37,15 +37,12 @@
</span><span class="cx">
</span><span class="cx"> namespace WebCore {
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, MediaStreamCapabilities* object)
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, MediaStreamCapabilities& object)
</ins><span class="cx"> {
</span><del>- if (!object)
- return jsNull();
</del><ins>+ if (object.hasVideoSource())
+ return wrap<JSAllVideoCapabilities>(globalObject, static_cast<AllVideoCapabilities&>(object));
</ins><span class="cx">
</span><del>- if (object->hasVideoSource())
- return wrap<JSAllVideoCapabilities>(globalObject, static_cast<AllVideoCapabilities>(*object));
-
- return wrap<JSAllAudioCapabilities>(globalObject, static_cast<AllAudioCapabilities>(*object));
</del><ins>+ return wrap<JSAllAudioCapabilities>(globalObject, static_cast<AllAudioCapabilities&>(object));
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSNamedNodeMapCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSNamedNodeMapCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSNamedNodeMapCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSNamedNodeMapCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -41,7 +41,7 @@
</span><span class="cx"> if (!item)
</span><span class="cx"> return false;
</span><span class="cx">
</span><del>- value = toJS(exec, globalObject(), item);
</del><ins>+ value = toJS(exec, globalObject(), *item);
</ins><span class="cx"> return true;
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSNodeCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSNodeCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSNodeCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSNodeCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -228,7 +228,7 @@
</span><span class="cx"> break;
</span><span class="cx"> case Node::DOCUMENT_NODE:
</span><span class="cx"> // we don't want to cache the document itself in the per-document dictionary
</span><del>- return toJS(exec, globalObject, downcast<Document>(node));
</del><ins>+ return toJS(exec, globalObject, downcast<Document>(*node));
</ins><span class="cx"> case Node::DOCUMENT_TYPE_NODE:
</span><span class="cx"> wrapper = CREATE_DOM_WRAPPER(globalObject, DocumentType, node);
</span><span class="cx"> break;
</span><span class="lines">@@ -252,12 +252,9 @@
</span><span class="cx"> return createWrapperInline(exec, globalObject, node);
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSValue toJSNewlyCreated(ExecState* exec, JSDOMGlobalObject* globalObject, Node* node)
</del><ins>+JSValue toJSNewlyCreated(ExecState* exec, JSDOMGlobalObject* globalObject, Node& node)
</ins><span class="cx"> {
</span><del>- if (!node)
- return jsNull();
-
- return createWrapperInline(exec, globalObject, node);
</del><ins>+ return createWrapperInline(exec, globalObject, &node);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> JSC::JSObject* getOutOfLineCachedWrapper(JSDOMGlobalObject* globalObject, Node* node)
</span><span class="lines">@@ -273,7 +270,7 @@
</span><span class="cx"> return;
</span><span class="cx">
</span><span class="cx"> JSLockHolder lock(scriptState);
</span><del>- toJS(scriptState, static_cast<JSDOMGlobalObject*>(scriptState->lexicalGlobalObject()), root);
</del><ins>+ toJS(scriptState, static_cast<JSDOMGlobalObject*>(scriptState->lexicalGlobalObject()), *root);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSNodeCustomh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSNodeCustom.h (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSNodeCustom.h        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSNodeCustom.h        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -34,20 +34,17 @@
</span><span class="cx"> WEBCORE_EXPORT JSC::JSValue createWrapper(JSC::ExecState*, JSDOMGlobalObject*, Node*);
</span><span class="cx"> WEBCORE_EXPORT JSC::JSObject* getOutOfLineCachedWrapper(JSDOMGlobalObject*, Node*);
</span><span class="cx">
</span><del>-inline JSC::JSValue toJS(JSC::ExecState* exec, JSDOMGlobalObject* globalObject, Node* node)
</del><ins>+inline JSC::JSValue toJS(JSC::ExecState* exec, JSDOMGlobalObject* globalObject, Node& node)
</ins><span class="cx"> {
</span><del>- if (!node)
- return JSC::jsNull();
-
</del><span class="cx"> if (LIKELY(globalObject->worldIsNormal())) {
</span><del>- if (auto* wrapper = node->wrapper())
</del><ins>+ if (auto* wrapper = node.wrapper())
</ins><span class="cx"> return wrapper;
</span><span class="cx"> } else {
</span><del>- if (auto* wrapper = getOutOfLineCachedWrapper(globalObject, node))
</del><ins>+ if (auto* wrapper = getOutOfLineCachedWrapper(globalObject, &node))
</ins><span class="cx"> return wrapper;
</span><span class="cx"> }
</span><span class="cx">
</span><del>- return createWrapper(exec, globalObject, node);
</del><ins>+ return createWrapper(exec, globalObject, &node);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> // In the C++ DOM, a node tree survives as long as there is a reference to its
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSNodeListCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSNodeListCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSNodeListCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSNodeListCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -59,12 +59,9 @@
</span><span class="cx"> return createNewWrapper<JSNodeList>(&globalObject, &nodeList);
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, NodeList* nodeList)
</del><ins>+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, NodeList& nodeList)
</ins><span class="cx"> {
</span><del>- if (!nodeList)
- return JSC::jsNull();
-
- return createWrapper(*globalObject, *nodeList);
</del><ins>+ return createWrapper(*globalObject, nodeList);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSNodeListCustomh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSNodeListCustom.h (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSNodeListCustom.h        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSNodeListCustom.h        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -33,13 +33,11 @@
</span><span class="cx">
</span><span class="cx"> WEBCORE_EXPORT JSC::JSValue createWrapper(JSDOMGlobalObject&, NodeList&);
</span><span class="cx">
</span><del>-ALWAYS_INLINE JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, NodeList* nodeList)
</del><ins>+ALWAYS_INLINE JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, NodeList& nodeList)
</ins><span class="cx"> {
</span><del>- if (!nodeList)
- return JSC::jsNull();
- if (JSC::JSValue existingWrapper = getExistingWrapper<JSNodeList>(globalObject, nodeList))
</del><ins>+ if (JSC::JSValue existingWrapper = getExistingWrapper<JSNodeList>(globalObject, &nodeList))
</ins><span class="cx"> return existingWrapper;
</span><del>- return createWrapper(*globalObject, *nodeList);
</del><ins>+ return createWrapper(*globalObject, nodeList);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSPerformanceEntryCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSPerformanceEntryCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSPerformanceEntryCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSPerformanceEntryCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -47,23 +47,20 @@
</span><span class="cx">
</span><span class="cx"> namespace WebCore {
</span><span class="cx">
</span><del>-JSValue toJS(ExecState*, JSDOMGlobalObject* globalObject, PerformanceEntry* entry)
</del><ins>+JSValue toJS(ExecState*, JSDOMGlobalObject* globalObject, PerformanceEntry& entry)
</ins><span class="cx"> {
</span><del>- if (!entry)
- return jsNull();
</del><ins>+ if (is<PerformanceResourceTiming>(entry))
+ return wrap<JSPerformanceResourceTiming>(globalObject, downcast<PerformanceResourceTiming>(entry));
</ins><span class="cx">
</span><del>- if (is<PerformanceResourceTiming>(*entry))
- return wrap<JSPerformanceResourceTiming>(globalObject, downcast<PerformanceResourceTiming>(*entry));
-
</del><span class="cx"> #if ENABLE(USER_TIMING)
</span><del>- if (is<PerformanceMark>(*entry))
- return wrap<JSPerformanceMark>(globalObject, downcast<PerformanceMark>(*entry));
</del><ins>+ if (is<PerformanceMark>(entry))
+ return wrap<JSPerformanceMark>(globalObject, downcast<PerformanceMark>(entry));
</ins><span class="cx">
</span><del>- if (is<PerformanceMeasure>(*entry))
- return wrap<JSPerformanceMeasure>(globalObject, downcast<PerformanceMeasure>(*entry));
</del><ins>+ if (is<PerformanceMeasure>(entry))
+ return wrap<JSPerformanceMeasure>(globalObject, downcast<PerformanceMeasure>(entry));
</ins><span class="cx"> #endif
</span><span class="cx">
</span><del>- return wrap<JSPerformanceEntry>(globalObject, *entry);
</del><ins>+ return wrap<JSPerformanceEntry>(globalObject, entry);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSPopStateEventCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSPopStateEventCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSPopStateEventCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSPopStateEventCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -84,7 +84,7 @@
</span><span class="cx"> JSValue result;
</span><span class="cx">
</span><span class="cx"> if (isSameState) {
</span><del>- JSHistory* jsHistory = jsCast<JSHistory*>(toJS(&state, globalObject(), history).asCell());
</del><ins>+ JSHistory* jsHistory = jsCast<JSHistory*>(toJS(&state, globalObject(), *history).asCell());
</ins><span class="cx"> result = jsHistory->state(state);
</span><span class="cx"> } else
</span><span class="cx"> result = event.serializedState()->deserialize(&state, globalObject(), 0);
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSRTCStatsResponseCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSRTCStatsResponseCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSRTCStatsResponseCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSRTCStatsResponseCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -42,7 +42,7 @@
</span><span class="cx"> if (!item)
</span><span class="cx"> return false;
</span><span class="cx">
</span><del>- value = toJS(exec, globalObject(), item);
</del><ins>+ value = toJS(exec, globalObject(), *item);
</ins><span class="cx"> return true;
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSSVGPathSegCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSSVGPathSegCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSSVGPathSegCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSSVGPathSegCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -59,56 +59,53 @@
</span><span class="cx">
</span><span class="cx"> namespace WebCore {
</span><span class="cx">
</span><del>-JSValue toJS(ExecState*, JSDOMGlobalObject* globalObject, SVGPathSeg* object)
</del><ins>+JSValue toJS(ExecState*, JSDOMGlobalObject* globalObject, SVGPathSeg& object)
</ins><span class="cx"> {
</span><del>- if (!object)
- return jsNull();
-
- if (JSObject* wrapper = getCachedWrapper(globalObject->world(), object))
</del><ins>+ if (JSObject* wrapper = getCachedWrapper(globalObject->world(), &object))
</ins><span class="cx"> return wrapper;
</span><span class="cx">
</span><del>- switch (object->pathSegType()) {
</del><ins>+ switch (object.pathSegType()) {
</ins><span class="cx"> case SVGPathSeg::PATHSEG_CLOSEPATH:
</span><del>- return CREATE_DOM_WRAPPER(globalObject, SVGPathSegClosePath, object);
</del><ins>+ return CREATE_DOM_WRAPPER(globalObject, SVGPathSegClosePath, &object);
</ins><span class="cx"> case SVGPathSeg::PATHSEG_MOVETO_ABS:
</span><del>- return CREATE_DOM_WRAPPER(globalObject, SVGPathSegMovetoAbs, object);
</del><ins>+ return CREATE_DOM_WRAPPER(globalObject, SVGPathSegMovetoAbs, &object);
</ins><span class="cx"> case SVGPathSeg::PATHSEG_MOVETO_REL:
</span><del>- return CREATE_DOM_WRAPPER(globalObject, SVGPathSegMovetoRel, object);
</del><ins>+ return CREATE_DOM_WRAPPER(globalObject, SVGPathSegMovetoRel, &object);
</ins><span class="cx"> case SVGPathSeg::PATHSEG_LINETO_ABS:
</span><del>- return CREATE_DOM_WRAPPER(globalObject, SVGPathSegLinetoAbs, object);
</del><ins>+ return CREATE_DOM_WRAPPER(globalObject, SVGPathSegLinetoAbs, &object);
</ins><span class="cx"> case SVGPathSeg::PATHSEG_LINETO_REL:
</span><del>- return CREATE_DOM_WRAPPER(globalObject, SVGPathSegLinetoRel, object);
</del><ins>+ return CREATE_DOM_WRAPPER(globalObject, SVGPathSegLinetoRel, &object);
</ins><span class="cx"> case SVGPathSeg::PATHSEG_CURVETO_CUBIC_ABS:
</span><del>- return CREATE_DOM_WRAPPER(globalObject, SVGPathSegCurvetoCubicAbs, object);
</del><ins>+ return CREATE_DOM_WRAPPER(globalObject, SVGPathSegCurvetoCubicAbs, &object);
</ins><span class="cx"> case SVGPathSeg::PATHSEG_CURVETO_CUBIC_REL:
</span><del>- return CREATE_DOM_WRAPPER(globalObject, SVGPathSegCurvetoCubicRel, object);
</del><ins>+ return CREATE_DOM_WRAPPER(globalObject, SVGPathSegCurvetoCubicRel, &object);
</ins><span class="cx"> case SVGPathSeg::PATHSEG_CURVETO_QUADRATIC_ABS:
</span><del>- return CREATE_DOM_WRAPPER(globalObject, SVGPathSegCurvetoQuadraticAbs, object);
</del><ins>+ return CREATE_DOM_WRAPPER(globalObject, SVGPathSegCurvetoQuadraticAbs, &object);
</ins><span class="cx"> case SVGPathSeg::PATHSEG_CURVETO_QUADRATIC_REL:
</span><del>- return CREATE_DOM_WRAPPER(globalObject, SVGPathSegCurvetoQuadraticRel, object);
</del><ins>+ return CREATE_DOM_WRAPPER(globalObject, SVGPathSegCurvetoQuadraticRel, &object);
</ins><span class="cx"> case SVGPathSeg::PATHSEG_ARC_ABS:
</span><del>- return CREATE_DOM_WRAPPER(globalObject, SVGPathSegArcAbs, object);
</del><ins>+ return CREATE_DOM_WRAPPER(globalObject, SVGPathSegArcAbs, &object);
</ins><span class="cx"> case SVGPathSeg::PATHSEG_ARC_REL:
</span><del>- return CREATE_DOM_WRAPPER(globalObject, SVGPathSegArcRel, object);
</del><ins>+ return CREATE_DOM_WRAPPER(globalObject, SVGPathSegArcRel, &object);
</ins><span class="cx"> case SVGPathSeg::PATHSEG_LINETO_HORIZONTAL_ABS:
</span><del>- return CREATE_DOM_WRAPPER(globalObject, SVGPathSegLinetoHorizontalAbs, object);
</del><ins>+ return CREATE_DOM_WRAPPER(globalObject, SVGPathSegLinetoHorizontalAbs, &object);
</ins><span class="cx"> case SVGPathSeg::PATHSEG_LINETO_HORIZONTAL_REL:
</span><del>- return CREATE_DOM_WRAPPER(globalObject, SVGPathSegLinetoHorizontalRel, object);
</del><ins>+ return CREATE_DOM_WRAPPER(globalObject, SVGPathSegLinetoHorizontalRel, &object);
</ins><span class="cx"> case SVGPathSeg::PATHSEG_LINETO_VERTICAL_ABS:
</span><del>- return CREATE_DOM_WRAPPER(globalObject, SVGPathSegLinetoVerticalAbs, object);
</del><ins>+ return CREATE_DOM_WRAPPER(globalObject, SVGPathSegLinetoVerticalAbs, &object);
</ins><span class="cx"> case SVGPathSeg::PATHSEG_LINETO_VERTICAL_REL:
</span><del>- return CREATE_DOM_WRAPPER(globalObject, SVGPathSegLinetoVerticalRel, object);
</del><ins>+ return CREATE_DOM_WRAPPER(globalObject, SVGPathSegLinetoVerticalRel, &object);
</ins><span class="cx"> case SVGPathSeg::PATHSEG_CURVETO_CUBIC_SMOOTH_ABS:
</span><del>- return CREATE_DOM_WRAPPER(globalObject, SVGPathSegCurvetoCubicSmoothAbs, object);
</del><ins>+ return CREATE_DOM_WRAPPER(globalObject, SVGPathSegCurvetoCubicSmoothAbs, &object);
</ins><span class="cx"> case SVGPathSeg::PATHSEG_CURVETO_CUBIC_SMOOTH_REL:
</span><del>- return CREATE_DOM_WRAPPER(globalObject, SVGPathSegCurvetoCubicSmoothRel, object);
</del><ins>+ return CREATE_DOM_WRAPPER(globalObject, SVGPathSegCurvetoCubicSmoothRel, &object);
</ins><span class="cx"> case SVGPathSeg::PATHSEG_CURVETO_QUADRATIC_SMOOTH_ABS:
</span><del>- return CREATE_DOM_WRAPPER(globalObject, SVGPathSegCurvetoQuadraticSmoothAbs, object);
</del><ins>+ return CREATE_DOM_WRAPPER(globalObject, SVGPathSegCurvetoQuadraticSmoothAbs, &object);
</ins><span class="cx"> case SVGPathSeg::PATHSEG_CURVETO_QUADRATIC_SMOOTH_REL:
</span><del>- return CREATE_DOM_WRAPPER(globalObject, SVGPathSegCurvetoQuadraticSmoothRel, object);
</del><ins>+ return CREATE_DOM_WRAPPER(globalObject, SVGPathSegCurvetoQuadraticSmoothRel, &object);
</ins><span class="cx"> case SVGPathSeg::PATHSEG_UNKNOWN:
</span><span class="cx"> default:
</span><del>- return CREATE_DOM_WRAPPER(globalObject, SVGPathSeg, object);
</del><ins>+ return CREATE_DOM_WRAPPER(globalObject, SVGPathSeg, &object);
</ins><span class="cx"> }
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSStyleSheetCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSStyleSheetCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSStyleSheetCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSStyleSheetCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -35,18 +35,15 @@
</span><span class="cx"> visitor.addOpaqueRoot(root(&wrapped()));
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, StyleSheet* styleSheet)
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, StyleSheet& styleSheet)
</ins><span class="cx"> {
</span><del>- if (!styleSheet)
- return JSC::jsNull();
-
- if (JSC::JSObject* wrapper = getCachedWrapper(globalObject->world(), styleSheet))
</del><ins>+ if (JSC::JSObject* wrapper = getCachedWrapper(globalObject->world(), &styleSheet))
</ins><span class="cx"> return wrapper;
</span><span class="cx">
</span><del>- if (styleSheet->isCSSStyleSheet())
- return CREATE_DOM_WRAPPER(globalObject, CSSStyleSheet, styleSheet);
</del><ins>+ if (styleSheet.isCSSStyleSheet())
+ return CREATE_DOM_WRAPPER(globalObject, CSSStyleSheet, &styleSheet);
</ins><span class="cx">
</span><del>- return CREATE_DOM_WRAPPER(globalObject, StyleSheet, styleSheet);
</del><ins>+ return CREATE_DOM_WRAPPER(globalObject, StyleSheet, &styleSheet);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSTextTrackCueCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSTextTrackCueCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSTextTrackCueCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSTextTrackCueCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -59,23 +59,20 @@
</span><span class="cx"> return visitor.containsOpaqueRoot(root(textTrackCue.track()));
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSValue toJS(ExecState*, JSDOMGlobalObject* globalObject, TextTrackCue* cue)
</del><ins>+JSValue toJS(ExecState*, JSDOMGlobalObject* globalObject, TextTrackCue& cue)
</ins><span class="cx"> {
</span><del>- if (!cue)
- return jsNull();
</del><ins>+ JSObject* wrapper = getCachedWrapper(globalObject->world(), &cue);
</ins><span class="cx">
</span><del>- JSObject* wrapper = getCachedWrapper(globalObject->world(), cue);
-
</del><span class="cx"> if (wrapper)
</span><span class="cx"> return wrapper;
</span><span class="cx">
</span><span class="cx"> // This switch will make more sense once we support DataCue
</span><del>- switch (cue->cueType()) {
</del><ins>+ switch (cue.cueType()) {
</ins><span class="cx"> case TextTrackCue::Data:
</span><del>- return CREATE_DOM_WRAPPER(globalObject, DataCue, cue);
</del><ins>+ return CREATE_DOM_WRAPPER(globalObject, DataCue, &cue);
</ins><span class="cx"> case TextTrackCue::WebVTT:
</span><span class="cx"> case TextTrackCue::Generic:
</span><del>- return CREATE_DOM_WRAPPER(globalObject, VTTCue, cue);
</del><ins>+ return CREATE_DOM_WRAPPER(globalObject, VTTCue, &cue);
</ins><span class="cx"> default:
</span><span class="cx"> ASSERT_NOT_REACHED();
</span><span class="cx"> return jsNull();
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSTrackCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSTrackCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSTrackCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSTrackCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -53,31 +53,28 @@
</span><span class="cx"> return 0;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TrackBase* track)
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TrackBase& track)
</ins><span class="cx"> {
</span><del>- if (!track)
- return jsNull();
-
- switch (track->type()) {
</del><ins>+ switch (track.type()) {
</ins><span class="cx"> case TrackBase::BaseTrack:
</span><span class="cx"> // This should never happen.
</span><span class="cx"> ASSERT_NOT_REACHED();
</span><span class="cx"> break;
</span><span class="cx">
</span><span class="cx"> case TrackBase::AudioTrack:
</span><del>- if (auto* wrapper = getCachedWrapper(globalObject->world(), toAudioTrack(track)))
</del><ins>+ if (auto* wrapper = getCachedWrapper(globalObject->world(), toAudioTrack(&track)))
</ins><span class="cx"> return wrapper;
</span><del>- return CREATE_DOM_WRAPPER(globalObject, AudioTrack, track);
</del><ins>+ return CREATE_DOM_WRAPPER(globalObject, AudioTrack, &track);
</ins><span class="cx">
</span><span class="cx"> case TrackBase::VideoTrack:
</span><del>- if (auto* wrapper = getCachedWrapper(globalObject->world(), toVideoTrack(track)))
</del><ins>+ if (auto* wrapper = getCachedWrapper(globalObject->world(), toVideoTrack(&track)))
</ins><span class="cx"> return wrapper;
</span><del>- return CREATE_DOM_WRAPPER(globalObject, VideoTrack, track);
</del><ins>+ return CREATE_DOM_WRAPPER(globalObject, VideoTrack, &track);
</ins><span class="cx">
</span><span class="cx"> case TrackBase::TextTrack:
</span><del>- if (auto* wrapper = getCachedWrapper(globalObject->world(), toTextTrack(track)))
</del><ins>+ if (auto* wrapper = getCachedWrapper(globalObject->world(), toTextTrack(&track)))
</ins><span class="cx"> return wrapper;
</span><del>- return CREATE_DOM_WRAPPER(globalObject, TextTrack, track);
</del><ins>+ return CREATE_DOM_WRAPPER(globalObject, TextTrack, &track);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> return jsNull();
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSTrackCustomh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSTrackCustom.h (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSTrackCustom.h        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSTrackCustom.h        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -36,7 +36,7 @@
</span><span class="cx"> namespace WebCore {
</span><span class="cx">
</span><span class="cx"> TrackBase* toTrack(JSC::JSValue);
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TrackBase*);
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TrackBase&);
</ins><span class="cx">
</span><span class="cx"> inline void* root(TrackBase* track)
</span><span class="cx"> {
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSTrackEventCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSTrackEventCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSTrackEventCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSTrackEventCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -42,7 +42,7 @@
</span><span class="cx"> if (!track)
</span><span class="cx"> return jsNull();
</span><span class="cx">
</span><del>- return toJS(&state, globalObject(), track);
</del><ins>+ return toJS(&state, globalObject(), *track);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSUserMessageHandlersNamespaceCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSUserMessageHandlersNamespaceCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSUserMessageHandlersNamespaceCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSUserMessageHandlersNamespaceCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -38,7 +38,7 @@
</span><span class="cx"> bool JSUserMessageHandlersNamespace::getOwnPropertySlotDelegate(ExecState* exec, PropertyName propertyName, PropertySlot& slot)
</span><span class="cx"> {
</span><span class="cx"> if (UserMessageHandler* handler = wrapped().handler(propertyNameToAtomicString(propertyName), globalObject()->world())) {
</span><del>- slot.setValue(this, ReadOnly | DontDelete | DontEnum, toJS(exec, globalObject(), handler));
</del><ins>+ slot.setValue(this, ReadOnly | DontDelete | DontEnum, toJS(exec, globalObject(), *handler));
</ins><span class="cx"> return true;
</span><span class="cx"> }
</span><span class="cx"> return false;
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSWorkerCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSWorkerCustom.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSWorkerCustom.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSWorkerCustom.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -67,7 +67,7 @@
</span><span class="cx"> return JSValue::encode(JSValue());
</span><span class="cx"> }
</span><span class="cx">
</span><del>- return JSValue::encode(asObject(toJS(exec, jsConstructor->globalObject(), worker.release())));
</del><ins>+ return JSValue::encode(asObject(toJS(exec, jsConstructor->globalObject(), *worker)));
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSWorkerGlobalScopeBasecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSWorkerGlobalScopeBase.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSWorkerGlobalScopeBase.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSWorkerGlobalScopeBase.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -104,16 +104,14 @@
</span><span class="cx"> thisObject->scriptExecutionContext()->postTask(JSGlobalObjectTask((JSDOMGlobalObject*)thisObject, task));
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSValue toJS(ExecState* exec, JSDOMGlobalObject*, WorkerGlobalScope* workerGlobalScope)
</del><ins>+JSValue toJS(ExecState* exec, JSDOMGlobalObject*, WorkerGlobalScope& workerGlobalScope)
</ins><span class="cx"> {
</span><span class="cx"> return toJS(exec, workerGlobalScope);
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSValue toJS(ExecState*, WorkerGlobalScope* workerGlobalScope)
</del><ins>+JSValue toJS(ExecState*, WorkerGlobalScope& workerGlobalScope)
</ins><span class="cx"> {
</span><del>- if (!workerGlobalScope)
- return jsNull();
- WorkerScriptController* script = workerGlobalScope->script();
</del><ins>+ WorkerScriptController* script = workerGlobalScope.script();
</ins><span class="cx"> if (!script)
</span><span class="cx"> return jsNull();
</span><span class="cx"> JSWorkerGlobalScope* contextWrapper = script->workerGlobalScopeWrapper();
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSWorkerGlobalScopeBaseh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSWorkerGlobalScopeBase.h (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSWorkerGlobalScopeBase.h        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/JSWorkerGlobalScopeBase.h        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -70,8 +70,10 @@
</span><span class="cx">
</span><span class="cx"> // Returns a JSWorkerGlobalScope or jsNull()
</span><span class="cx"> // Always ignores the execState and passed globalObject, WorkerGlobalScope is itself a globalObject and will always use its own prototype chain.
</span><del>- JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, WorkerGlobalScope*);
- JSC::JSValue toJS(JSC::ExecState*, WorkerGlobalScope*);
</del><ins>+ JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, WorkerGlobalScope&);
+ inline JSC::JSValue toJS(JSC::ExecState* exec, JSDOMGlobalObject* globalObject, WorkerGlobalScope* scope) { return scope ? toJS(exec, globalObject, *scope) : JSC::jsNull(); }
+ JSC::JSValue toJS(JSC::ExecState*, WorkerGlobalScope&);
+ inline JSC::JSValue toJS(JSC::ExecState* exec, WorkerGlobalScope* scope) { return scope ? toJS(exec, *scope) : JSC::jsNull(); }
</ins><span class="cx">
</span><span class="cx"> JSDedicatedWorkerGlobalScope* toJSDedicatedWorkerGlobalScope(JSC::JSValue);
</span><span class="cx"> JSWorkerGlobalScope* toJSWorkerGlobalScope(JSC::JSValue);
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsReadableStreamControllercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/ReadableStreamController.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/ReadableStreamController.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/js/ReadableStreamController.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -88,7 +88,7 @@
</span><span class="cx"> {
</span><span class="cx"> JSC::JSLockHolder lock(&state);
</span><span class="cx">
</span><del>- auto jsSource = source ? toJS(&state, globalObject, source) : JSC::jsUndefined();
</del><ins>+ auto jsSource = source ? toJS(&state, globalObject, *source) : JSC::jsUndefined();
</ins><span class="cx"> JSC::Strong<JSC::Unknown> protect(state.vm(), jsSource);
</span><span class="cx">
</span><span class="cx"> JSC::MarkedArgumentBuffer arguments;
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptsCodeGeneratorJSpm"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -1462,13 +1462,14 @@
</span><span class="cx"> # Node and NodeList have custom inline implementations which thus cannot be exported.
</span><span class="cx"> # FIXME: The special case for Node and NodeList should probably be implemented via an IDL attribute.
</span><span class="cx"> if ($implType eq "Node" or $implType eq "NodeList") {
</span><del>- push(@headerContent, "JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, $implType*);\n");
</del><ins>+ push(@headerContent, "JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, $implType&);\n");
</ins><span class="cx"> } else {
</span><del>- push(@headerContent, $exportMacro."JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, $implType*);\n");
</del><ins>+ push(@headerContent, $exportMacro."JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, $implType&);\n");
</ins><span class="cx"> }
</span><del>- push(@headerContent, "inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, $implType& impl) { return toJS(state, globalObject, &impl); }\n");
</del><ins>+ push(@headerContent, "inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, $implType* impl) { return impl ? toJS(state, globalObject, *impl) : JSC::jsNull(); }\n");
</ins><span class="cx">
</span><del>- push(@headerContent, "JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, $implType*);\n");
</del><ins>+ push(@headerContent, "JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, $implType&);\n");
+ push(@headerContent, "inline JSC::JSValue toJSNewlyCreated(JSC::ExecState* state, JSDOMGlobalObject* globalObject, $implType* impl) { return impl ? toJSNewlyCreated(state, globalObject, *impl) : JSC::jsNull(); }\n");
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> push(@headerContent, "\n");
</span><span class="lines">@@ -3389,37 +3390,28 @@
</span><span class="cx">
</span><span class="cx"> END
</span><span class="cx">
</span><del>- push(@implContent, "JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, $implType* impl)\n");
</del><ins>+ push(@implContent, "JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, $implType& impl)\n");
</ins><span class="cx"> push(@implContent, "{\n");
</span><del>-push(@implContent, <<END);
- if (!impl)
- return jsNull();
-END
</del><span class="cx"> if ($svgPropertyType) {
</span><del>- push(@implContent, " return createNewWrapper<$className, $implType>(globalObject, impl);\n");
</del><ins>+ push(@implContent, " return createNewWrapper<$className, $implType>(globalObject, &impl);\n");
</ins><span class="cx"> } else {
</span><del>- push(@implContent, " return createNewWrapper<$className>(globalObject, impl);\n");
</del><ins>+ push(@implContent, " return createNewWrapper<$className>(globalObject, &impl);\n");
</ins><span class="cx"> }
</span><span class="cx"> push(@implContent, "}\n\n");
</span><span class="cx">
</span><del>- push(@implContent, "JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, $implType* impl)\n");
</del><ins>+ push(@implContent, "JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, $implType& impl)\n");
</ins><span class="cx"> push(@implContent, "{\n");
</span><del>- push(@implContent, <<END);
- if (!impl)
- return jsNull();
-END
-
</del><span class="cx"> if ($svgPropertyType) {
</span><del>- push(@implContent, " if (JSValue result = getExistingWrapper<$className, $implType>(globalObject, impl))\n");
</del><ins>+ push(@implContent, " if (JSValue result = getExistingWrapper<$className, $implType>(globalObject, &impl))\n");
</ins><span class="cx"> push(@implContent, " return result;\n");
</span><span class="cx"> } else {
</span><del>- push(@implContent, " if (JSValue result = getExistingWrapper<$className>(globalObject, impl))\n");
</del><ins>+ push(@implContent, " if (JSValue result = getExistingWrapper<$className>(globalObject, &impl))\n");
</ins><span class="cx"> push(@implContent, " return result;\n");
</span><span class="cx"> }
</span><span class="cx"> push(@implContent, <<END) if $vtableNameGnu;
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span><del>- void* actualVTablePointer = *(reinterpret_cast<void**>(impl));
</del><ins>+ void* actualVTablePointer = *(reinterpret_cast<void**>(&impl));
</ins><span class="cx"> #if PLATFORM(WIN)
</span><span class="cx"> void* expectedVTablePointer = reinterpret_cast<void*>(${vtableRefWin});
</span><span class="cx"> #else
</span><span class="lines">@@ -3447,13 +3439,13 @@
</span><span class="cx"> #endif
</span><span class="cx"> END
</span><span class="cx"> push(@implContent, <<END) if $interface->extendedAttributes->{"ReportExtraMemoryCost"};
</span><del>- globalObject->vm().heap.reportExtraMemoryAllocated(impl->memoryCost());
</del><ins>+ globalObject->vm().heap.reportExtraMemoryAllocated(impl.memoryCost());
</ins><span class="cx"> END
</span><span class="cx">
</span><span class="cx"> if ($svgPropertyType) {
</span><del>- push(@implContent, " return createNewWrapper<$className, $implType>(globalObject, impl);\n");
</del><ins>+ push(@implContent, " return createNewWrapper<$className, $implType>(globalObject, &impl);\n");
</ins><span class="cx"> } else {
</span><del>- push(@implContent, " return createNewWrapper<$className>(globalObject, impl);\n");
</del><ins>+ push(@implContent, " return createNewWrapper<$className>(globalObject, &impl);\n");
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> push(@implContent, "}\n\n");
</span><span class="lines">@@ -3914,8 +3906,8 @@
</span><span class="cx"> push(@headerContent, "};\n\n");
</span><span class="cx">
</span><span class="cx"> # toJS().
</span><del>- push(@headerContent, "JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, $interfaceName*);\n");
- push(@headerContent, "inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, $interfaceName& impl) { return toJS(state, globalObject, &impl); }\n\n");
</del><ins>+ push(@headerContent, "JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, $interfaceName&);\n");
+ push(@headerContent, "inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, $interfaceName* impl) { return impl ? toJS(state, globalObject, *impl) : JSC::jsNull(); }\n\n");
</ins><span class="cx">
</span><span class="cx"> push(@headerContent, "} // namespace WebCore\n");
</span><span class="cx">
</span><span class="lines">@@ -4092,11 +4084,11 @@
</span><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> # toJS() implementation.
</span><del>- push(@implContent, "\nJSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, $interfaceName* impl)\n");
</del><ins>+ push(@implContent, "\nJSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, $interfaceName& impl)\n");
</ins><span class="cx"> push(@implContent, "{\n");
</span><del>- push(@implContent, " if (!impl || !static_cast<${className}&>(*impl).callbackData())\n");
</del><ins>+ push(@implContent, " if (!static_cast<${className}&>(impl).callbackData())\n");
</ins><span class="cx"> push(@implContent, " return jsNull();\n\n");
</span><del>- push(@implContent, " return static_cast<${className}&>(*impl).callbackData()->callback();\n\n");
</del><ins>+ push(@implContent, " return static_cast<${className}&>(impl).callbackData()->callback();\n\n");
</ins><span class="cx"> push(@implContent, "}\n");
</span><span class="cx">
</span><span class="cx"> push(@implContent, "\n}\n");
</span><span class="lines">@@ -4561,8 +4553,7 @@
</span><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> my $function = $signature->extendedAttributes->{"NewObject"} ? "toJSNewlyCreated" : "toJS";
</span><del>-
- return "$function(state, $globalObject, WTF::getPtr($value))";
</del><ins>+ return "$function(state, $globalObject, $value)";
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> sub ceilingToPowerOf2
</span><span class="lines">@@ -5019,8 +5010,8 @@
</span><span class="cx"> return JSValue::encode(jsUndefined());
</span><span class="cx"> }
</span><span class="cx">
</span><del>- RefPtr<${interfaceName}> event = ${interfaceName}::createForBindings(eventType, eventInit);
- return JSValue::encode(toJS(state, jsConstructor->globalObject(), event.get()));
</del><ins>+ Ref<${interfaceName}> event = ${interfaceName}::createForBindings(eventType, eventInit);
+ return JSValue::encode(toJS(state, jsConstructor->globalObject(), event));
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> bool fill${interfaceName}Init(${interfaceName}Init& eventInit, JSDictionary& dictionary)
</span><span class="lines">@@ -5133,9 +5124,9 @@
</span><span class="cx"> }
</span><span class="cx"> my $constructorArg = join(", ", @constructorArgList);
</span><span class="cx"> if ($generatingNamedConstructor) {
</span><del>- push(@$outputArray, " RefPtr<${interfaceName}> object = ${interfaceName}::createForJSConstructor(${constructorArg});\n");
</del><ins>+ push(@$outputArray, " auto object = ${interfaceName}::createForJSConstructor(${constructorArg});\n");
</ins><span class="cx"> } else {
</span><del>- push(@$outputArray, " RefPtr<${interfaceName}> object = ${interfaceName}::create(${constructorArg});\n");
</del><ins>+ push(@$outputArray, " auto object = ${interfaceName}::create(${constructorArg});\n");
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> if ($interface->extendedAttributes->{"ConstructorRaisesException"}) {
</span><span class="lines">@@ -5150,7 +5141,7 @@
</span><span class="cx"> push(@$outputArray, " return JSValue::encode(jsUndefined());\n");
</span><span class="cx"> }
</span><span class="cx">
</span><del>- push(@$outputArray, " return JSValue::encode(asObject(toJS(state, castedThis->globalObject(), object.get())));\n");
</del><ins>+ push(@$outputArray, " return JSValue::encode(asObject(toJS(state, castedThis->globalObject(), object)));\n");
</ins><span class="cx"> push(@$outputArray, "}\n\n");
</span><span class="cx"> }
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestActiveDOMObjectcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestActiveDOMObject.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestActiveDOMObject.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestActiveDOMObject.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -250,22 +250,18 @@
</span><span class="cx"> #endif
</span><span class="cx"> #endif
</span><span class="cx">
</span><del>-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestActiveDOMObject* impl)
</del><ins>+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestActiveDOMObject& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- return createNewWrapper<JSTestActiveDOMObject>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestActiveDOMObject>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestActiveDOMObject* impl)
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestActiveDOMObject& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- if (JSValue result = getExistingWrapper<JSTestActiveDOMObject>(globalObject, impl))
</del><ins>+ if (JSValue result = getExistingWrapper<JSTestActiveDOMObject>(globalObject, &impl))
</ins><span class="cx"> return result;
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span><del>- void* actualVTablePointer = *(reinterpret_cast<void**>(impl));
</del><ins>+ void* actualVTablePointer = *(reinterpret_cast<void**>(&impl));
</ins><span class="cx"> #if PLATFORM(WIN)
</span><span class="cx"> void* expectedVTablePointer = reinterpret_cast<void*>(__identifier("??_7TestActiveDOMObject@WebCore@@6B@"));
</span><span class="cx"> #else
</span><span class="lines">@@ -282,7 +278,7 @@
</span><span class="cx"> // by adding the SkipVTableValidation attribute to the interface IDL definition
</span><span class="cx"> RELEASE_ASSERT(actualVTablePointer == expectedVTablePointer);
</span><span class="cx"> #endif
</span><del>- return createNewWrapper<JSTestActiveDOMObject>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestActiveDOMObject>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> TestActiveDOMObject* JSTestActiveDOMObject::toWrapped(JSC::JSValue value)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestActiveDOMObjecth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestActiveDOMObject.h (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestActiveDOMObject.h        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestActiveDOMObject.h        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -82,9 +82,10 @@
</span><span class="cx"> return wrappableObject;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestActiveDOMObject*);
-inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestActiveDOMObject& impl) { return toJS(state, globalObject, &impl); }
-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestActiveDOMObject*);
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestActiveDOMObject&);
+inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestActiveDOMObject* impl) { return impl ? toJS(state, globalObject, *impl) : JSC::jsNull(); }
+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestActiveDOMObject&);
+inline JSC::JSValue toJSNewlyCreated(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestActiveDOMObject* impl) { return impl ? toJSNewlyCreated(state, globalObject, *impl) : JSC::jsNull(); }
</ins><span class="cx">
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestCallbackcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCallback.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCallback.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCallback.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -126,7 +126,7 @@
</span><span class="cx">
</span><span class="cx"> ExecState* state = m_data->globalObject()->globalExec();
</span><span class="cx"> MarkedArgumentBuffer args;
</span><del>- args.append(toJS(state, m_data->globalObject(), WTF::getPtr(arrayParam)));
</del><ins>+ args.append(toJS(state, m_data->globalObject(), arrayParam));
</ins><span class="cx">
</span><span class="cx"> NakedPtr<Exception> returnedException;
</span><span class="cx"> m_data->invokeCallback(args, JSCallbackData::CallbackType::Object, Identifier::fromString(state, "callbackWithArrayParam"), returnedException);
</span><span class="lines">@@ -167,7 +167,7 @@
</span><span class="cx">
</span><span class="cx"> ExecState* state = m_data->globalObject()->globalExec();
</span><span class="cx"> MarkedArgumentBuffer args;
</span><del>- args.append(toJS(state, m_data->globalObject(), WTF::getPtr(listParam)));
</del><ins>+ args.append(toJS(state, m_data->globalObject(), listParam));
</ins><span class="cx">
</span><span class="cx"> NakedPtr<Exception> returnedException;
</span><span class="cx"> m_data->invokeCallback(args, JSCallbackData::CallbackType::Object, Identifier::fromString(state, "callbackWithStringList"), returnedException);
</span><span class="lines">@@ -208,7 +208,7 @@
</span><span class="cx"> ExecState* state = m_data->globalObject()->globalExec();
</span><span class="cx"> MarkedArgumentBuffer args;
</span><span class="cx"> args.append(jsNumber(longParam));
</span><del>- args.append(toJS(state, m_data->globalObject(), WTF::getPtr(testNodeParam)));
</del><ins>+ args.append(toJS(state, m_data->globalObject(), testNodeParam));
</ins><span class="cx">
</span><span class="cx"> NakedPtr<Exception> returnedException;
</span><span class="cx"> m_data->invokeCallback(args, JSCallbackData::CallbackType::Object, Identifier::fromString(state, "callbackRequiresThisToPass"), returnedException);
</span><span class="lines">@@ -217,12 +217,12 @@
</span><span class="cx"> return !returnedException;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestCallback* impl)
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestCallback& impl)
</ins><span class="cx"> {
</span><del>- if (!impl || !static_cast<JSTestCallback&>(*impl).callbackData())
</del><ins>+ if (!static_cast<JSTestCallback&>(impl).callbackData())
</ins><span class="cx"> return jsNull();
</span><span class="cx">
</span><del>- return static_cast<JSTestCallback&>(*impl).callbackData()->callback();
</del><ins>+ return static_cast<JSTestCallback&>(impl).callbackData()->callback();
</ins><span class="cx">
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestCallbackh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCallback.h (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCallback.h        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCallback.h        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -58,8 +58,8 @@
</span><span class="cx"> JSCallbackDataStrong* m_data;
</span><span class="cx"> };
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestCallback*);
-inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestCallback& impl) { return toJS(state, globalObject, &impl); }
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestCallback&);
+inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestCallback* impl) { return impl ? toJS(state, globalObject, *impl) : JSC::jsNull(); }
</ins><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestCallbackFunctioncpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCallbackFunction.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCallbackFunction.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCallbackFunction.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -91,7 +91,7 @@
</span><span class="cx">
</span><span class="cx"> ExecState* state = m_data->globalObject()->globalExec();
</span><span class="cx"> MarkedArgumentBuffer args;
</span><del>- args.append(toJS(state, m_data->globalObject(), WTF::getPtr(arrayParam)));
</del><ins>+ args.append(toJS(state, m_data->globalObject(), arrayParam));
</ins><span class="cx">
</span><span class="cx"> NakedPtr<Exception> returnedException;
</span><span class="cx"> UNUSED_PARAM(state);
</span><span class="lines">@@ -134,7 +134,7 @@
</span><span class="cx">
</span><span class="cx"> ExecState* state = m_data->globalObject()->globalExec();
</span><span class="cx"> MarkedArgumentBuffer args;
</span><del>- args.append(toJS(state, m_data->globalObject(), WTF::getPtr(listParam)));
</del><ins>+ args.append(toJS(state, m_data->globalObject(), listParam));
</ins><span class="cx">
</span><span class="cx"> NakedPtr<Exception> returnedException;
</span><span class="cx"> UNUSED_PARAM(state);
</span><span class="lines">@@ -177,7 +177,7 @@
</span><span class="cx"> ExecState* state = m_data->globalObject()->globalExec();
</span><span class="cx"> MarkedArgumentBuffer args;
</span><span class="cx"> args.append(jsNumber(longParam));
</span><del>- args.append(toJS(state, m_data->globalObject(), WTF::getPtr(testNodeParam)));
</del><ins>+ args.append(toJS(state, m_data->globalObject(), testNodeParam));
</ins><span class="cx">
</span><span class="cx"> NakedPtr<Exception> returnedException;
</span><span class="cx"> UNUSED_PARAM(state);
</span><span class="lines">@@ -187,12 +187,12 @@
</span><span class="cx"> return !returnedException;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestCallbackFunction* impl)
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestCallbackFunction& impl)
</ins><span class="cx"> {
</span><del>- if (!impl || !static_cast<JSTestCallbackFunction&>(*impl).callbackData())
</del><ins>+ if (!static_cast<JSTestCallbackFunction&>(impl).callbackData())
</ins><span class="cx"> return jsNull();
</span><span class="cx">
</span><del>- return static_cast<JSTestCallbackFunction&>(*impl).callbackData()->callback();
</del><ins>+ return static_cast<JSTestCallbackFunction&>(impl).callbackData()->callback();
</ins><span class="cx">
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestCallbackFunctionh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCallbackFunction.h (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCallbackFunction.h        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCallbackFunction.h        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -57,8 +57,8 @@
</span><span class="cx"> JSCallbackDataStrong* m_data;
</span><span class="cx"> };
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestCallbackFunction*);
-inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestCallbackFunction& impl) { return toJS(state, globalObject, &impl); }
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestCallbackFunction&);
+inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestCallbackFunction* impl) { return impl ? toJS(state, globalObject, *impl) : JSC::jsNull(); }
</ins><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestClassWithJSBuiltinConstructorcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestClassWithJSBuiltinConstructor.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestClassWithJSBuiltinConstructor.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestClassWithJSBuiltinConstructor.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -176,22 +176,18 @@
</span><span class="cx"> #endif
</span><span class="cx"> #endif
</span><span class="cx">
</span><del>-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestClassWithJSBuiltinConstructor* impl)
</del><ins>+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestClassWithJSBuiltinConstructor& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- return createNewWrapper<JSTestClassWithJSBuiltinConstructor>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestClassWithJSBuiltinConstructor>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestClassWithJSBuiltinConstructor* impl)
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestClassWithJSBuiltinConstructor& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- if (JSValue result = getExistingWrapper<JSTestClassWithJSBuiltinConstructor>(globalObject, impl))
</del><ins>+ if (JSValue result = getExistingWrapper<JSTestClassWithJSBuiltinConstructor>(globalObject, &impl))
</ins><span class="cx"> return result;
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span><del>- void* actualVTablePointer = *(reinterpret_cast<void**>(impl));
</del><ins>+ void* actualVTablePointer = *(reinterpret_cast<void**>(&impl));
</ins><span class="cx"> #if PLATFORM(WIN)
</span><span class="cx"> void* expectedVTablePointer = reinterpret_cast<void*>(__identifier("??_7TestClassWithJSBuiltinConstructor@WebCore@@6B@"));
</span><span class="cx"> #else
</span><span class="lines">@@ -208,7 +204,7 @@
</span><span class="cx"> // by adding the SkipVTableValidation attribute to the interface IDL definition
</span><span class="cx"> RELEASE_ASSERT(actualVTablePointer == expectedVTablePointer);
</span><span class="cx"> #endif
</span><del>- return createNewWrapper<JSTestClassWithJSBuiltinConstructor>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestClassWithJSBuiltinConstructor>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> TestClassWithJSBuiltinConstructor* JSTestClassWithJSBuiltinConstructor::toWrapped(JSC::JSValue value)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestClassWithJSBuiltinConstructorh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestClassWithJSBuiltinConstructor.h (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestClassWithJSBuiltinConstructor.h        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestClassWithJSBuiltinConstructor.h        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -81,9 +81,10 @@
</span><span class="cx"> return wrappableObject;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestClassWithJSBuiltinConstructor*);
-inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestClassWithJSBuiltinConstructor& impl) { return toJS(state, globalObject, &impl); }
-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestClassWithJSBuiltinConstructor*);
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestClassWithJSBuiltinConstructor&);
+inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestClassWithJSBuiltinConstructor* impl) { return impl ? toJS(state, globalObject, *impl) : JSC::jsNull(); }
+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestClassWithJSBuiltinConstructor&);
+inline JSC::JSValue toJSNewlyCreated(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestClassWithJSBuiltinConstructor* impl) { return impl ? toJSNewlyCreated(state, globalObject, *impl) : JSC::jsNull(); }
</ins><span class="cx">
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestCustomConstructorWithNoInterfaceObjectcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -166,22 +166,18 @@
</span><span class="cx"> #endif
</span><span class="cx"> #endif
</span><span class="cx">
</span><del>-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestCustomConstructorWithNoInterfaceObject* impl)
</del><ins>+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestCustomConstructorWithNoInterfaceObject& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- return createNewWrapper<JSTestCustomConstructorWithNoInterfaceObject>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestCustomConstructorWithNoInterfaceObject>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestCustomConstructorWithNoInterfaceObject* impl)
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestCustomConstructorWithNoInterfaceObject& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- if (JSValue result = getExistingWrapper<JSTestCustomConstructorWithNoInterfaceObject>(globalObject, impl))
</del><ins>+ if (JSValue result = getExistingWrapper<JSTestCustomConstructorWithNoInterfaceObject>(globalObject, &impl))
</ins><span class="cx"> return result;
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span><del>- void* actualVTablePointer = *(reinterpret_cast<void**>(impl));
</del><ins>+ void* actualVTablePointer = *(reinterpret_cast<void**>(&impl));
</ins><span class="cx"> #if PLATFORM(WIN)
</span><span class="cx"> void* expectedVTablePointer = reinterpret_cast<void*>(__identifier("??_7TestCustomConstructorWithNoInterfaceObject@WebCore@@6B@"));
</span><span class="cx"> #else
</span><span class="lines">@@ -198,7 +194,7 @@
</span><span class="cx"> // by adding the SkipVTableValidation attribute to the interface IDL definition
</span><span class="cx"> RELEASE_ASSERT(actualVTablePointer == expectedVTablePointer);
</span><span class="cx"> #endif
</span><del>- return createNewWrapper<JSTestCustomConstructorWithNoInterfaceObject>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestCustomConstructorWithNoInterfaceObject>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> TestCustomConstructorWithNoInterfaceObject* JSTestCustomConstructorWithNoInterfaceObject::toWrapped(JSC::JSValue value)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestCustomConstructorWithNoInterfaceObjecth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.h (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.h        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.h        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -78,9 +78,10 @@
</span><span class="cx"> return wrappableObject;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestCustomConstructorWithNoInterfaceObject*);
-inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestCustomConstructorWithNoInterfaceObject& impl) { return toJS(state, globalObject, &impl); }
-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestCustomConstructorWithNoInterfaceObject*);
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestCustomConstructorWithNoInterfaceObject&);
+inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestCustomConstructorWithNoInterfaceObject* impl) { return impl ? toJS(state, globalObject, *impl) : JSC::jsNull(); }
+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestCustomConstructorWithNoInterfaceObject&);
+inline JSC::JSValue toJSNewlyCreated(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestCustomConstructorWithNoInterfaceObject* impl) { return impl ? toJSNewlyCreated(state, globalObject, *impl) : JSC::jsNull(); }
</ins><span class="cx">
</span><span class="cx"> // Custom constructor
</span><span class="cx"> JSC::EncodedJSValue JSC_HOST_CALL constructJSTestCustomConstructorWithNoInterfaceObject(JSC::ExecState*);
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestCustomNamedGettercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -223,22 +223,18 @@
</span><span class="cx"> #endif
</span><span class="cx"> #endif
</span><span class="cx">
</span><del>-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestCustomNamedGetter* impl)
</del><ins>+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestCustomNamedGetter& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- return createNewWrapper<JSTestCustomNamedGetter>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestCustomNamedGetter>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestCustomNamedGetter* impl)
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestCustomNamedGetter& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- if (JSValue result = getExistingWrapper<JSTestCustomNamedGetter>(globalObject, impl))
</del><ins>+ if (JSValue result = getExistingWrapper<JSTestCustomNamedGetter>(globalObject, &impl))
</ins><span class="cx"> return result;
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span><del>- void* actualVTablePointer = *(reinterpret_cast<void**>(impl));
</del><ins>+ void* actualVTablePointer = *(reinterpret_cast<void**>(&impl));
</ins><span class="cx"> #if PLATFORM(WIN)
</span><span class="cx"> void* expectedVTablePointer = reinterpret_cast<void*>(__identifier("??_7TestCustomNamedGetter@WebCore@@6B@"));
</span><span class="cx"> #else
</span><span class="lines">@@ -255,7 +251,7 @@
</span><span class="cx"> // by adding the SkipVTableValidation attribute to the interface IDL definition
</span><span class="cx"> RELEASE_ASSERT(actualVTablePointer == expectedVTablePointer);
</span><span class="cx"> #endif
</span><del>- return createNewWrapper<JSTestCustomNamedGetter>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestCustomNamedGetter>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> TestCustomNamedGetter* JSTestCustomNamedGetter::toWrapped(JSC::JSValue value)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestCustomNamedGetterh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCustomNamedGetter.h (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCustomNamedGetter.h        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCustomNamedGetter.h        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -85,9 +85,10 @@
</span><span class="cx"> return wrappableObject;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestCustomNamedGetter*);
-inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestCustomNamedGetter& impl) { return toJS(state, globalObject, &impl); }
-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestCustomNamedGetter*);
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestCustomNamedGetter&);
+inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestCustomNamedGetter* impl) { return impl ? toJS(state, globalObject, *impl) : JSC::jsNull(); }
+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestCustomNamedGetter&);
+inline JSC::JSValue toJSNewlyCreated(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestCustomNamedGetter* impl) { return impl ? toJSNewlyCreated(state, globalObject, *impl) : JSC::jsNull(); }
</ins><span class="cx">
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestEventConstructorcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventConstructor.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventConstructor.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventConstructor.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -101,8 +101,8 @@
</span><span class="cx"> return JSValue::encode(jsUndefined());
</span><span class="cx"> }
</span><span class="cx">
</span><del>- RefPtr<TestEventConstructor> event = TestEventConstructor::createForBindings(eventType, eventInit);
- return JSValue::encode(toJS(state, jsConstructor->globalObject(), event.get()));
</del><ins>+ Ref<TestEventConstructor> event = TestEventConstructor::createForBindings(eventType, eventInit);
+ return JSValue::encode(toJS(state, jsConstructor->globalObject(), event));
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> bool fillTestEventConstructorInit(TestEventConstructorInit& eventInit, JSDictionary& dictionary)
</span><span class="lines">@@ -271,22 +271,18 @@
</span><span class="cx"> #endif
</span><span class="cx"> #endif
</span><span class="cx">
</span><del>-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestEventConstructor* impl)
</del><ins>+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestEventConstructor& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- return createNewWrapper<JSTestEventConstructor>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestEventConstructor>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestEventConstructor* impl)
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestEventConstructor& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- if (JSValue result = getExistingWrapper<JSTestEventConstructor>(globalObject, impl))
</del><ins>+ if (JSValue result = getExistingWrapper<JSTestEventConstructor>(globalObject, &impl))
</ins><span class="cx"> return result;
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span><del>- void* actualVTablePointer = *(reinterpret_cast<void**>(impl));
</del><ins>+ void* actualVTablePointer = *(reinterpret_cast<void**>(&impl));
</ins><span class="cx"> #if PLATFORM(WIN)
</span><span class="cx"> void* expectedVTablePointer = reinterpret_cast<void*>(__identifier("??_7TestEventConstructor@WebCore@@6B@"));
</span><span class="cx"> #else
</span><span class="lines">@@ -303,7 +299,7 @@
</span><span class="cx"> // by adding the SkipVTableValidation attribute to the interface IDL definition
</span><span class="cx"> RELEASE_ASSERT(actualVTablePointer == expectedVTablePointer);
</span><span class="cx"> #endif
</span><del>- return createNewWrapper<JSTestEventConstructor>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestEventConstructor>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> TestEventConstructor* JSTestEventConstructor::toWrapped(JSC::JSValue value)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestEventConstructorh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventConstructor.h (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventConstructor.h        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventConstructor.h        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -81,9 +81,10 @@
</span><span class="cx"> return wrappableObject;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestEventConstructor*);
-inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestEventConstructor& impl) { return toJS(state, globalObject, &impl); }
-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestEventConstructor*);
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestEventConstructor&);
+inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestEventConstructor* impl) { return impl ? toJS(state, globalObject, *impl) : JSC::jsNull(); }
+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestEventConstructor&);
+inline JSC::JSValue toJSNewlyCreated(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestEventConstructor* impl) { return impl ? toJSNewlyCreated(state, globalObject, *impl) : JSC::jsNull(); }
</ins><span class="cx">
</span><span class="cx"> bool fillTestEventConstructorInit(TestEventConstructorInit&, JSDictionary&);
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestEventTargetcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventTarget.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventTarget.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventTarget.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -209,7 +209,7 @@
</span><span class="cx"> auto index = convert<uint32_t>(*state, state->argument(0), NormalConversion);
</span><span class="cx"> if (UNLIKELY(state->hadException()))
</span><span class="cx"> return JSValue::encode(jsUndefined());
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(impl.item(WTFMove(index))));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), impl.item(WTFMove(index)));
</ins><span class="cx"> return JSValue::encode(result);
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -230,22 +230,18 @@
</span><span class="cx"> #endif
</span><span class="cx"> #endif
</span><span class="cx">
</span><del>-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestEventTarget* impl)
</del><ins>+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestEventTarget& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- return createNewWrapper<JSTestEventTarget>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestEventTarget>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestEventTarget* impl)
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestEventTarget& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- if (JSValue result = getExistingWrapper<JSTestEventTarget>(globalObject, impl))
</del><ins>+ if (JSValue result = getExistingWrapper<JSTestEventTarget>(globalObject, &impl))
</ins><span class="cx"> return result;
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span><del>- void* actualVTablePointer = *(reinterpret_cast<void**>(impl));
</del><ins>+ void* actualVTablePointer = *(reinterpret_cast<void**>(&impl));
</ins><span class="cx"> #if PLATFORM(WIN)
</span><span class="cx"> void* expectedVTablePointer = reinterpret_cast<void*>(__identifier("??_7TestEventTarget@WebCore@@6B@"));
</span><span class="cx"> #else
</span><span class="lines">@@ -262,7 +258,7 @@
</span><span class="cx"> // by adding the SkipVTableValidation attribute to the interface IDL definition
</span><span class="cx"> RELEASE_ASSERT(actualVTablePointer == expectedVTablePointer);
</span><span class="cx"> #endif
</span><del>- return createNewWrapper<JSTestEventTarget>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestEventTarget>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> TestEventTarget* JSTestEventTarget::toWrapped(JSC::JSValue value)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestEventTargeth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventTarget.h (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventTarget.h        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventTarget.h        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -74,9 +74,10 @@
</span><span class="cx"> bool nameGetter(JSC::ExecState*, JSC::PropertyName, JSC::JSValue&);
</span><span class="cx"> };
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestEventTarget*);
-inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestEventTarget& impl) { return toJS(state, globalObject, &impl); }
-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestEventTarget*);
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestEventTarget&);
+inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestEventTarget* impl) { return impl ? toJS(state, globalObject, *impl) : JSC::jsNull(); }
+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestEventTarget&);
+inline JSC::JSValue toJSNewlyCreated(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestEventTarget* impl) { return impl ? toJSNewlyCreated(state, globalObject, *impl) : JSC::jsNull(); }
</ins><span class="cx">
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestExceptioncpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestException.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestException.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestException.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -204,22 +204,18 @@
</span><span class="cx"> #endif
</span><span class="cx"> #endif
</span><span class="cx">
</span><del>-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestException* impl)
</del><ins>+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestException& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- return createNewWrapper<JSTestException>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestException>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestException* impl)
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestException& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- if (JSValue result = getExistingWrapper<JSTestException>(globalObject, impl))
</del><ins>+ if (JSValue result = getExistingWrapper<JSTestException>(globalObject, &impl))
</ins><span class="cx"> return result;
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span><del>- void* actualVTablePointer = *(reinterpret_cast<void**>(impl));
</del><ins>+ void* actualVTablePointer = *(reinterpret_cast<void**>(&impl));
</ins><span class="cx"> #if PLATFORM(WIN)
</span><span class="cx"> void* expectedVTablePointer = reinterpret_cast<void*>(__identifier("??_7TestException@WebCore@@6B@"));
</span><span class="cx"> #else
</span><span class="lines">@@ -236,7 +232,7 @@
</span><span class="cx"> // by adding the SkipVTableValidation attribute to the interface IDL definition
</span><span class="cx"> RELEASE_ASSERT(actualVTablePointer == expectedVTablePointer);
</span><span class="cx"> #endif
</span><del>- return createNewWrapper<JSTestException>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestException>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> TestException* JSTestException::toWrapped(JSC::JSValue value)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestExceptionh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestException.h (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestException.h        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestException.h        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -83,9 +83,10 @@
</span><span class="cx"> return wrappableObject;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestException*);
-inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestException& impl) { return toJS(state, globalObject, &impl); }
-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestException*);
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestException&);
+inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestException* impl) { return impl ? toJS(state, globalObject, *impl) : JSC::jsNull(); }
+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestException&);
+inline JSC::JSValue toJSNewlyCreated(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestException* impl) { return impl ? toJSNewlyCreated(state, globalObject, *impl) : JSC::jsNull(); }
</ins><span class="cx">
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestGenerateIsReachablecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -163,22 +163,18 @@
</span><span class="cx"> #endif
</span><span class="cx"> #endif
</span><span class="cx">
</span><del>-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestGenerateIsReachable* impl)
</del><ins>+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestGenerateIsReachable& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- return createNewWrapper<JSTestGenerateIsReachable>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestGenerateIsReachable>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestGenerateIsReachable* impl)
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestGenerateIsReachable& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- if (JSValue result = getExistingWrapper<JSTestGenerateIsReachable>(globalObject, impl))
</del><ins>+ if (JSValue result = getExistingWrapper<JSTestGenerateIsReachable>(globalObject, &impl))
</ins><span class="cx"> return result;
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span><del>- void* actualVTablePointer = *(reinterpret_cast<void**>(impl));
</del><ins>+ void* actualVTablePointer = *(reinterpret_cast<void**>(&impl));
</ins><span class="cx"> #if PLATFORM(WIN)
</span><span class="cx"> void* expectedVTablePointer = reinterpret_cast<void*>(__identifier("??_7TestGenerateIsReachable@WebCore@@6B@"));
</span><span class="cx"> #else
</span><span class="lines">@@ -195,7 +191,7 @@
</span><span class="cx"> // by adding the SkipVTableValidation attribute to the interface IDL definition
</span><span class="cx"> RELEASE_ASSERT(actualVTablePointer == expectedVTablePointer);
</span><span class="cx"> #endif
</span><del>- return createNewWrapper<JSTestGenerateIsReachable>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestGenerateIsReachable>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> TestGenerateIsReachable* JSTestGenerateIsReachable::toWrapped(JSC::JSValue value)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestGenerateIsReachableh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestGenerateIsReachable.h (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestGenerateIsReachable.h        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestGenerateIsReachable.h        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -79,9 +79,10 @@
</span><span class="cx"> return wrappableObject;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestGenerateIsReachable*);
-inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestGenerateIsReachable& impl) { return toJS(state, globalObject, &impl); }
-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestGenerateIsReachable*);
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestGenerateIsReachable&);
+inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestGenerateIsReachable* impl) { return impl ? toJS(state, globalObject, *impl) : JSC::jsNull(); }
+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestGenerateIsReachable&);
+inline JSC::JSValue toJSNewlyCreated(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestGenerateIsReachable* impl) { return impl ? toJSNewlyCreated(state, globalObject, *impl) : JSC::jsNull(); }
</ins><span class="cx">
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestGlobalObjectcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestGlobalObject.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestGlobalObject.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestGlobalObject.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -345,22 +345,18 @@
</span><span class="cx"> #endif
</span><span class="cx"> #endif
</span><span class="cx">
</span><del>-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestGlobalObject* impl)
</del><ins>+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestGlobalObject& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- return createNewWrapper<JSTestGlobalObject>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestGlobalObject>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestGlobalObject* impl)
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestGlobalObject& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- if (JSValue result = getExistingWrapper<JSTestGlobalObject>(globalObject, impl))
</del><ins>+ if (JSValue result = getExistingWrapper<JSTestGlobalObject>(globalObject, &impl))
</ins><span class="cx"> return result;
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span><del>- void* actualVTablePointer = *(reinterpret_cast<void**>(impl));
</del><ins>+ void* actualVTablePointer = *(reinterpret_cast<void**>(&impl));
</ins><span class="cx"> #if PLATFORM(WIN)
</span><span class="cx"> void* expectedVTablePointer = reinterpret_cast<void*>(__identifier("??_7TestGlobalObject@WebCore@@6B@"));
</span><span class="cx"> #else
</span><span class="lines">@@ -377,7 +373,7 @@
</span><span class="cx"> // by adding the SkipVTableValidation attribute to the interface IDL definition
</span><span class="cx"> RELEASE_ASSERT(actualVTablePointer == expectedVTablePointer);
</span><span class="cx"> #endif
</span><del>- return createNewWrapper<JSTestGlobalObject>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestGlobalObject>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> TestGlobalObject* JSTestGlobalObject::toWrapped(JSC::JSValue value)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestGlobalObjecth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestGlobalObject.h (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestGlobalObject.h        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestGlobalObject.h        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -85,9 +85,10 @@
</span><span class="cx"> return wrappableObject;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestGlobalObject*);
-inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestGlobalObject& impl) { return toJS(state, globalObject, &impl); }
-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestGlobalObject*);
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestGlobalObject&);
+inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestGlobalObject* impl) { return impl ? toJS(state, globalObject, *impl) : JSC::jsNull(); }
+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestGlobalObject&);
+inline JSC::JSValue toJSNewlyCreated(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestGlobalObject* impl) { return impl ? toJSNewlyCreated(state, globalObject, *impl) : JSC::jsNull(); }
</ins><span class="cx">
</span><span class="cx"> class JSTestGlobalObjectPrototype : public JSC::JSNonFinalObject {
</span><span class="cx"> public:
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestInterfacecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestInterface.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestInterface.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestInterface.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -235,12 +235,12 @@
</span><span class="cx"> ScriptExecutionContext* context = castedThis->scriptExecutionContext();
</span><span class="cx"> if (UNLIKELY(!context))
</span><span class="cx"> return throwConstructorDocumentUnavailableError(*state, "TestInterface");
</span><del>- RefPtr<TestInterface> object = TestInterface::create(*context, str1, str2, ec);
</del><ins>+ auto object = TestInterface::create(*context, str1, str2, ec);
</ins><span class="cx"> if (UNLIKELY(ec)) {
</span><span class="cx"> setDOMException(state, ec);
</span><span class="cx"> return JSValue::encode(JSValue());
</span><span class="cx"> }
</span><del>- return JSValue::encode(asObject(toJS(state, castedThis->globalObject(), object.get())));
</del><ins>+ return JSValue::encode(asObject(toJS(state, castedThis->globalObject(), object)));
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> template<> JSValue JSTestInterfaceConstructor::prototypeForStructure(JSC::VM& vm, const JSDOMGlobalObject& globalObject)
</span><span class="lines">@@ -490,7 +490,7 @@
</span><span class="cx"> return throwGetterTypeError(*state, "TestInterface", "implementsNode");
</span><span class="cx"> }
</span><span class="cx"> auto& impl = castedThis->wrapped();
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(impl.implementsNode()));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), impl.implementsNode());
</ins><span class="cx"> return JSValue::encode(result);
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -578,7 +578,7 @@
</span><span class="cx"> return throwGetterTypeError(*state, "TestInterface", "supplementalNode");
</span><span class="cx"> }
</span><span class="cx"> auto& impl = castedThis->wrapped();
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(WebCore::TestSupplemental::supplementalNode(impl)));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), WebCore::TestSupplemental::supplementalNode(impl));
</ins><span class="cx"> return JSValue::encode(result);
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -803,7 +803,7 @@
</span><span class="cx"> auto objArg = JSTestObj::toWrapped(state->argument(1));
</span><span class="cx"> if (UNLIKELY(!objArg))
</span><span class="cx"> return throwArgumentTypeError(*state, 1, "objArg", "TestInterface", "implementsMethod2", "TestObj");
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(impl.implementsMethod2(*context, WTFMove(strArg), *objArg, ec)));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), impl.implementsMethod2(*context, WTFMove(strArg), *objArg, ec));
</ins><span class="cx">
</span><span class="cx"> setDOMException(state, ec);
</span><span class="cx"> return JSValue::encode(result);
</span><span class="lines">@@ -869,7 +869,7 @@
</span><span class="cx"> auto objArg = JSTestObj::toWrapped(state->argument(1));
</span><span class="cx"> if (UNLIKELY(!objArg))
</span><span class="cx"> return throwArgumentTypeError(*state, 1, "objArg", "TestInterface", "supplementalMethod2", "TestObj");
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(WebCore::TestSupplemental::supplementalMethod2(impl, *context, WTFMove(strArg), *objArg, ec)));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), WebCore::TestSupplemental::supplementalMethod2(impl, *context, WTFMove(strArg), *objArg, ec));
</ins><span class="cx">
</span><span class="cx"> setDOMException(state, ec);
</span><span class="cx"> return JSValue::encode(result);
</span><span class="lines">@@ -915,18 +915,14 @@
</span><span class="cx"> uncacheWrapper(world, &jsTestInterface->wrapped(), jsTestInterface);
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestInterface* impl)
</del><ins>+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestInterface& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- return createNewWrapper<JSTestInterface>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestInterface>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestInterface* impl)
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestInterface& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- if (JSValue result = getExistingWrapper<JSTestInterface>(globalObject, impl))
</del><ins>+ if (JSValue result = getExistingWrapper<JSTestInterface>(globalObject, &impl))
</ins><span class="cx"> return result;
</span><span class="cx"> #if COMPILER(CLANG)
</span><span class="cx"> // If you hit this failure the interface definition has the ImplementationLacksVTable
</span><span class="lines">@@ -935,7 +931,7 @@
</span><span class="cx"> // attribute to TestInterface.
</span><span class="cx"> static_assert(!__is_polymorphic(TestInterface), "TestInterface is polymorphic but the IDL claims it is not");
</span><span class="cx"> #endif
</span><del>- return createNewWrapper<JSTestInterface>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestInterface>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> TestInterface* JSTestInterface::toWrapped(JSC::JSValue value)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestInterfaceh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestInterface.h (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestInterface.h        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestInterface.h        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -106,9 +106,10 @@
</span><span class="cx"> return wrappableObject;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-WEBCORE_EXPORT JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestInterface*);
-inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestInterface& impl) { return toJS(state, globalObject, &impl); }
-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestInterface*);
</del><ins>+WEBCORE_EXPORT JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestInterface&);
+inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestInterface* impl) { return impl ? toJS(state, globalObject, *impl) : JSC::jsNull(); }
+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestInterface&);
+inline JSC::JSValue toJSNewlyCreated(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestInterface* impl) { return impl ? toJSNewlyCreated(state, globalObject, *impl) : JSC::jsNull(); }
</ins><span class="cx">
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestMediaQueryListListenercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -188,22 +188,18 @@
</span><span class="cx"> #endif
</span><span class="cx"> #endif
</span><span class="cx">
</span><del>-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestMediaQueryListListener* impl)
</del><ins>+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestMediaQueryListListener& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- return createNewWrapper<JSTestMediaQueryListListener>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestMediaQueryListListener>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestMediaQueryListListener* impl)
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestMediaQueryListListener& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- if (JSValue result = getExistingWrapper<JSTestMediaQueryListListener>(globalObject, impl))
</del><ins>+ if (JSValue result = getExistingWrapper<JSTestMediaQueryListListener>(globalObject, &impl))
</ins><span class="cx"> return result;
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span><del>- void* actualVTablePointer = *(reinterpret_cast<void**>(impl));
</del><ins>+ void* actualVTablePointer = *(reinterpret_cast<void**>(&impl));
</ins><span class="cx"> #if PLATFORM(WIN)
</span><span class="cx"> void* expectedVTablePointer = reinterpret_cast<void*>(__identifier("??_7TestMediaQueryListListener@WebCore@@6B@"));
</span><span class="cx"> #else
</span><span class="lines">@@ -220,7 +216,7 @@
</span><span class="cx"> // by adding the SkipVTableValidation attribute to the interface IDL definition
</span><span class="cx"> RELEASE_ASSERT(actualVTablePointer == expectedVTablePointer);
</span><span class="cx"> #endif
</span><del>- return createNewWrapper<JSTestMediaQueryListListener>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestMediaQueryListListener>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> TestMediaQueryListListener* JSTestMediaQueryListListener::toWrapped(JSC::JSValue value)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestMediaQueryListListenerh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestMediaQueryListListener.h (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestMediaQueryListListener.h        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestMediaQueryListListener.h        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -79,9 +79,10 @@
</span><span class="cx"> return wrappableObject;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestMediaQueryListListener*);
-inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestMediaQueryListListener& impl) { return toJS(state, globalObject, &impl); }
-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestMediaQueryListListener*);
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestMediaQueryListListener&);
+inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestMediaQueryListListener* impl) { return impl ? toJS(state, globalObject, *impl) : JSC::jsNull(); }
+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestMediaQueryListListener&);
+inline JSC::JSValue toJSNewlyCreated(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestMediaQueryListListener* impl) { return impl ? toJSNewlyCreated(state, globalObject, *impl) : JSC::jsNull(); }
</ins><span class="cx">
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestNamedConstructorcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedConstructor.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedConstructor.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedConstructor.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -95,12 +95,12 @@
</span><span class="cx"> auto str3 = state->argument(2).isUndefined() ? String() : state->uncheckedArgument(2).toWTFString(state);
</span><span class="cx"> if (UNLIKELY(state->hadException()))
</span><span class="cx"> return JSValue::encode(jsUndefined());
</span><del>- RefPtr<TestNamedConstructor> object = TestNamedConstructor::createForJSConstructor(*castedThis->document(), str1, str2, str3, ec);
</del><ins>+ auto object = TestNamedConstructor::createForJSConstructor(*castedThis->document(), str1, str2, str3, ec);
</ins><span class="cx"> if (UNLIKELY(ec)) {
</span><span class="cx"> setDOMException(state, ec);
</span><span class="cx"> return JSValue::encode(JSValue());
</span><span class="cx"> }
</span><del>- return JSValue::encode(asObject(toJS(state, castedThis->globalObject(), object.get())));
</del><ins>+ return JSValue::encode(asObject(toJS(state, castedThis->globalObject(), object)));
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> template<> JSValue JSTestNamedConstructorNamedConstructor::prototypeForStructure(JSC::VM& vm, const JSDOMGlobalObject& globalObject)
</span><span class="lines">@@ -211,22 +211,18 @@
</span><span class="cx"> #endif
</span><span class="cx"> #endif
</span><span class="cx">
</span><del>-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestNamedConstructor* impl)
</del><ins>+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestNamedConstructor& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- return createNewWrapper<JSTestNamedConstructor>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestNamedConstructor>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestNamedConstructor* impl)
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestNamedConstructor& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- if (JSValue result = getExistingWrapper<JSTestNamedConstructor>(globalObject, impl))
</del><ins>+ if (JSValue result = getExistingWrapper<JSTestNamedConstructor>(globalObject, &impl))
</ins><span class="cx"> return result;
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span><del>- void* actualVTablePointer = *(reinterpret_cast<void**>(impl));
</del><ins>+ void* actualVTablePointer = *(reinterpret_cast<void**>(&impl));
</ins><span class="cx"> #if PLATFORM(WIN)
</span><span class="cx"> void* expectedVTablePointer = reinterpret_cast<void*>(__identifier("??_7TestNamedConstructor@WebCore@@6B@"));
</span><span class="cx"> #else
</span><span class="lines">@@ -243,7 +239,7 @@
</span><span class="cx"> // by adding the SkipVTableValidation attribute to the interface IDL definition
</span><span class="cx"> RELEASE_ASSERT(actualVTablePointer == expectedVTablePointer);
</span><span class="cx"> #endif
</span><del>- return createNewWrapper<JSTestNamedConstructor>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestNamedConstructor>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> TestNamedConstructor* JSTestNamedConstructor::toWrapped(JSC::JSValue value)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestNamedConstructorh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedConstructor.h (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedConstructor.h        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedConstructor.h        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -80,9 +80,10 @@
</span><span class="cx"> return wrappableObject;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestNamedConstructor*);
-inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestNamedConstructor& impl) { return toJS(state, globalObject, &impl); }
-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestNamedConstructor*);
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestNamedConstructor&);
+inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestNamedConstructor* impl) { return impl ? toJS(state, globalObject, *impl) : JSC::jsNull(); }
+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestNamedConstructor&);
+inline JSC::JSValue toJSNewlyCreated(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestNamedConstructor* impl) { return impl ? toJSNewlyCreated(state, globalObject, *impl) : JSC::jsNull(); }
</ins><span class="cx">
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestNodecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNode.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNode.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNode.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -79,8 +79,8 @@
</span><span class="cx"> template<> EncodedJSValue JSC_HOST_CALL JSTestNodeConstructor::construct(ExecState* state)
</span><span class="cx"> {
</span><span class="cx"> auto* castedThis = jsCast<JSTestNodeConstructor*>(state->callee());
</span><del>- RefPtr<TestNode> object = TestNode::create();
- return JSValue::encode(asObject(toJS(state, castedThis->globalObject(), object.get())));
</del><ins>+ auto object = TestNode::create();
+ return JSValue::encode(asObject(toJS(state, castedThis->globalObject(), object)));
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> template<> JSValue JSTestNodeConstructor::prototypeForStructure(JSC::VM& vm, const JSDOMGlobalObject& globalObject)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestNondeterministiccpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNondeterministic.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNondeterministic.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNondeterministic.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -472,22 +472,18 @@
</span><span class="cx"> #endif
</span><span class="cx"> #endif
</span><span class="cx">
</span><del>-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestNondeterministic* impl)
</del><ins>+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestNondeterministic& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- return createNewWrapper<JSTestNondeterministic>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestNondeterministic>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestNondeterministic* impl)
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestNondeterministic& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- if (JSValue result = getExistingWrapper<JSTestNondeterministic>(globalObject, impl))
</del><ins>+ if (JSValue result = getExistingWrapper<JSTestNondeterministic>(globalObject, &impl))
</ins><span class="cx"> return result;
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span><del>- void* actualVTablePointer = *(reinterpret_cast<void**>(impl));
</del><ins>+ void* actualVTablePointer = *(reinterpret_cast<void**>(&impl));
</ins><span class="cx"> #if PLATFORM(WIN)
</span><span class="cx"> void* expectedVTablePointer = reinterpret_cast<void*>(__identifier("??_7TestNondeterministic@WebCore@@6B@"));
</span><span class="cx"> #else
</span><span class="lines">@@ -504,7 +500,7 @@
</span><span class="cx"> // by adding the SkipVTableValidation attribute to the interface IDL definition
</span><span class="cx"> RELEASE_ASSERT(actualVTablePointer == expectedVTablePointer);
</span><span class="cx"> #endif
</span><del>- return createNewWrapper<JSTestNondeterministic>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestNondeterministic>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> TestNondeterministic* JSTestNondeterministic::toWrapped(JSC::JSValue value)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestNondeterministich"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNondeterministic.h (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNondeterministic.h        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNondeterministic.h        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -79,9 +79,10 @@
</span><span class="cx"> return wrappableObject;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestNondeterministic*);
-inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestNondeterministic& impl) { return toJS(state, globalObject, &impl); }
-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestNondeterministic*);
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestNondeterministic&);
+inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestNondeterministic* impl) { return impl ? toJS(state, globalObject, *impl) : JSC::jsNull(); }
+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestNondeterministic&);
+inline JSC::JSValue toJSNewlyCreated(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestNondeterministic* impl) { return impl ? toJSNewlyCreated(state, globalObject, *impl) : JSC::jsNull(); }
</ins><span class="cx">
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestObjcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -963,8 +963,8 @@
</span><span class="cx"> if (UNLIKELY(!state->argument(1).isFunction()))
</span><span class="cx"> return throwArgumentMustBeFunctionError(*state, 1, "testCallbackFunction", "TestObj", nullptr);
</span><span class="cx"> RefPtr<TestCallbackFunction> testCallbackFunction = JSTestCallbackFunction::create(asObject(state->uncheckedArgument(1)), castedThis->globalObject());
</span><del>- RefPtr<TestObj> object = TestObj::create(*testCallback, *testCallbackFunction);
- return JSValue::encode(asObject(toJS(state, castedThis->globalObject(), object.get())));
</del><ins>+ auto object = TestObj::create(*testCallback, *testCallbackFunction);
+ return JSValue::encode(asObject(toJS(state, castedThis->globalObject(), object)));
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> template<> JSValue JSTestObjConstructor::prototypeForStructure(JSC::VM& vm, const JSDOMGlobalObject& globalObject)
</span><span class="lines">@@ -1361,7 +1361,7 @@
</span><span class="cx"> return throwGetterTypeError(*state, "TestObj", "readOnlyTestObjAttr");
</span><span class="cx"> }
</span><span class="cx"> auto& impl = castedThis->wrapped();
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(impl.readOnlyTestObjAttr()));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), impl.readOnlyTestObjAttr());
</ins><span class="cx"> return JSValue::encode(result);
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -1590,7 +1590,7 @@
</span><span class="cx"> return throwGetterTypeError(*state, "TestObj", "testObjAttr");
</span><span class="cx"> }
</span><span class="cx"> auto& impl = castedThis->wrapped();
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(impl.testObjAttr()));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), impl.testObjAttr());
</ins><span class="cx"> return JSValue::encode(result);
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -1605,7 +1605,7 @@
</span><span class="cx"> return throwGetterTypeError(*state, "TestObj", "testNullableObjAttr");
</span><span class="cx"> }
</span><span class="cx"> auto& impl = castedThis->wrapped();
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(impl.testNullableObjAttr()));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), impl.testNullableObjAttr());
</ins><span class="cx"> return JSValue::encode(result);
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -1620,7 +1620,7 @@
</span><span class="cx"> return JSValue::encode(jsUndefined());
</span><span class="cx"> }
</span><span class="cx"> auto& impl = castedThis->wrapped();
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(impl.lenientTestObjAttr()));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), impl.lenientTestObjAttr());
</ins><span class="cx"> return JSValue::encode(result);
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -1665,7 +1665,7 @@
</span><span class="cx"> return throwGetterTypeError(*state, "TestObj", "XMLObjAttr");
</span><span class="cx"> }
</span><span class="cx"> auto& impl = castedThis->wrapped();
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(impl.xmlObjAttr()));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), impl.xmlObjAttr());
</ins><span class="cx"> return JSValue::encode(result);
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -1847,7 +1847,7 @@
</span><span class="cx"> return throwGetterTypeError(*state, "TestObj", "typedArrayAttr");
</span><span class="cx"> }
</span><span class="cx"> auto& impl = castedThis->wrapped();
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(impl.typedArrayAttr()));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), impl.typedArrayAttr());
</ins><span class="cx"> return JSValue::encode(result);
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -1958,7 +1958,7 @@
</span><span class="cx"> return throwGetterTypeError(*state, "TestObj", "strictTypeCheckingAttribute");
</span><span class="cx"> }
</span><span class="cx"> auto& impl = castedThis->wrapped();
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(impl.strictTypeCheckingAttribute()));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), impl.strictTypeCheckingAttribute());
</ins><span class="cx"> return JSValue::encode(result);
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -2047,7 +2047,7 @@
</span><span class="cx"> if (!context)
</span><span class="cx"> return JSValue::encode(jsUndefined());
</span><span class="cx"> auto& impl = castedThis->wrapped();
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(impl.withScriptExecutionContextAttribute(*context)));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), impl.withScriptExecutionContextAttribute(*context));
</ins><span class="cx"> return JSValue::encode(result);
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -2063,7 +2063,7 @@
</span><span class="cx"> }
</span><span class="cx"> ExceptionCode ec = 0;
</span><span class="cx"> auto& impl = castedThis->wrapped();
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(impl.withScriptStateAttributeRaises(*state, ec)));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), impl.withScriptStateAttributeRaises(*state, ec));
</ins><span class="cx"> setDOMException(state, ec);
</span><span class="cx"> return JSValue::encode(result);
</span><span class="cx"> }
</span><span class="lines">@@ -2083,7 +2083,7 @@
</span><span class="cx"> if (!context)
</span><span class="cx"> return JSValue::encode(jsUndefined());
</span><span class="cx"> auto& impl = castedThis->wrapped();
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(impl.withScriptExecutionContextAttributeRaises(*context, ec)));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), impl.withScriptExecutionContextAttributeRaises(*context, ec));
</ins><span class="cx"> setDOMException(state, ec);
</span><span class="cx"> return JSValue::encode(result);
</span><span class="cx"> }
</span><span class="lines">@@ -2102,7 +2102,7 @@
</span><span class="cx"> if (!context)
</span><span class="cx"> return JSValue::encode(jsUndefined());
</span><span class="cx"> auto& impl = castedThis->wrapped();
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(impl.withScriptExecutionContextAndScriptStateAttribute(*state, *context)));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), impl.withScriptExecutionContextAndScriptStateAttribute(*state, *context));
</ins><span class="cx"> return JSValue::encode(result);
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -2121,7 +2121,7 @@
</span><span class="cx"> if (!context)
</span><span class="cx"> return JSValue::encode(jsUndefined());
</span><span class="cx"> auto& impl = castedThis->wrapped();
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(impl.withScriptExecutionContextAndScriptStateAttributeRaises(*state, *context, ec)));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), impl.withScriptExecutionContextAndScriptStateAttributeRaises(*state, *context, ec));
</ins><span class="cx"> setDOMException(state, ec);
</span><span class="cx"> return JSValue::encode(result);
</span><span class="cx"> }
</span><span class="lines">@@ -2140,7 +2140,7 @@
</span><span class="cx"> if (!context)
</span><span class="cx"> return JSValue::encode(jsUndefined());
</span><span class="cx"> auto& impl = castedThis->wrapped();
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(impl.withScriptExecutionContextAndScriptStateWithSpacesAttribute(*state, *context)));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), impl.withScriptExecutionContextAndScriptStateWithSpacesAttribute(*state, *context));
</ins><span class="cx"> return JSValue::encode(result);
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -2155,7 +2155,7 @@
</span><span class="cx"> return throwGetterTypeError(*state, "TestObj", "withScriptArgumentsAndCallStackAttribute");
</span><span class="cx"> }
</span><span class="cx"> auto& impl = castedThis->wrapped();
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(impl.withScriptArgumentsAndCallStackAttribute()));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), impl.withScriptArgumentsAndCallStackAttribute());
</ins><span class="cx"> return JSValue::encode(result);
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -2317,7 +2317,7 @@
</span><span class="cx"> return throwGetterTypeError(*state, "TestObj", "contentDocument");
</span><span class="cx"> }
</span><span class="cx"> auto& impl = castedThis->wrapped();
</span><del>- return JSValue::encode(shouldAllowAccessToNode(state, impl.contentDocument()) ? toJS(state, castedThis->globalObject(), WTF::getPtr(impl.contentDocument())) : jsNull());
</del><ins>+ return JSValue::encode(shouldAllowAccessToNode(state, impl.contentDocument()) ? toJS(state, castedThis->globalObject(), impl.contentDocument()) : jsNull());
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx">
</span><span class="lines">@@ -2331,7 +2331,7 @@
</span><span class="cx"> return throwGetterTypeError(*state, "TestObj", "mutablePoint");
</span><span class="cx"> }
</span><span class="cx"> auto& impl = castedThis->wrapped();
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(SVGStaticPropertyTearOff<TestObj, SVGPoint>::create(impl, impl.mutablePoint(), &TestObj::updateMutablePoint)));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), SVGStaticPropertyTearOff<TestObj, SVGPoint>::create(impl, impl.mutablePoint(), &TestObj::updateMutablePoint));
</ins><span class="cx"> return JSValue::encode(result);
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -2346,7 +2346,7 @@
</span><span class="cx"> return throwGetterTypeError(*state, "TestObj", "immutablePoint");
</span><span class="cx"> }
</span><span class="cx"> auto& impl = castedThis->wrapped();
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(SVGPropertyTearOff<SVGPoint>::create(impl.immutablePoint())));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), SVGPropertyTearOff<SVGPoint>::create(impl.immutablePoint()));
</ins><span class="cx"> return JSValue::encode(result);
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -2588,7 +2588,7 @@
</span><span class="cx"> return throwGetterTypeError(*state, "TestObj", "putForwardsAttribute");
</span><span class="cx"> }
</span><span class="cx"> auto& impl = castedThis->wrapped();
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(impl.putForwardsAttribute()));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), impl.putForwardsAttribute());
</ins><span class="cx"> return JSValue::encode(result);
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -2603,7 +2603,7 @@
</span><span class="cx"> return throwGetterTypeError(*state, "TestObj", "putForwardsNullableAttribute");
</span><span class="cx"> }
</span><span class="cx"> auto& impl = castedThis->wrapped();
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(impl.putForwardsNullableAttribute()));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), impl.putForwardsNullableAttribute());
</ins><span class="cx"> return JSValue::encode(result);
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -4030,7 +4030,7 @@
</span><span class="cx"> return throwThisTypeError(*state, "TestObj", "objMethod");
</span><span class="cx"> ASSERT_GC_OBJECT_INHERITS(castedThis, JSTestObj::info());
</span><span class="cx"> auto& impl = castedThis->wrapped();
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(impl.objMethod()));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), impl.objMethod());
</ins><span class="cx"> return JSValue::encode(result);
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -4053,7 +4053,7 @@
</span><span class="cx"> auto objArg = JSTestObj::toWrapped(state->argument(2));
</span><span class="cx"> if (UNLIKELY(!objArg))
</span><span class="cx"> return throwArgumentTypeError(*state, 2, "objArg", "TestObj", "objMethodWithArgs", "TestObj");
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(impl.objMethodWithArgs(WTFMove(longArg), WTFMove(strArg), *objArg)));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), impl.objMethodWithArgs(WTFMove(longArg), WTFMove(strArg), *objArg));
</ins><span class="cx"> return JSValue::encode(result);
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -4258,7 +4258,7 @@
</span><span class="cx"> auto objArg = JSTestObj::toWrapped(state->argument(1));
</span><span class="cx"> if (UNLIKELY(!objArg))
</span><span class="cx"> return throwArgumentTypeError(*state, 1, "objArg", "TestObj", "methodThatRequiresAllArgsAndThrows", "TestObj");
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(impl.methodThatRequiresAllArgsAndThrows(WTFMove(strArg), *objArg, ec)));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), impl.methodThatRequiresAllArgsAndThrows(WTFMove(strArg), *objArg, ec));
</ins><span class="cx">
</span><span class="cx"> setDOMException(state, ec);
</span><span class="cx"> return JSValue::encode(result);
</span><span class="lines">@@ -4412,7 +4412,7 @@
</span><span class="cx"> return throwThisTypeError(*state, "TestObj", "withScriptStateObj");
</span><span class="cx"> ASSERT_GC_OBJECT_INHERITS(castedThis, JSTestObj::info());
</span><span class="cx"> auto& impl = castedThis->wrapped();
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(impl.withScriptStateObj(*state)));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), impl.withScriptStateObj(*state));
</ins><span class="cx"> if (UNLIKELY(state->hadException()))
</span><span class="cx"> return JSValue::encode(jsUndefined());
</span><span class="cx"> return JSValue::encode(result);
</span><span class="lines">@@ -4441,7 +4441,7 @@
</span><span class="cx"> ASSERT_GC_OBJECT_INHERITS(castedThis, JSTestObj::info());
</span><span class="cx"> auto& impl = castedThis->wrapped();
</span><span class="cx"> ExceptionCode ec = 0;
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(impl.withScriptStateObjException(*state, ec)));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), impl.withScriptStateObjException(*state, ec));
</ins><span class="cx">
</span><span class="cx"> setDOMException(state, ec);
</span><span class="cx"> if (UNLIKELY(state->hadException()))
</span><span class="lines">@@ -4491,7 +4491,7 @@
</span><span class="cx"> auto* context = jsCast<JSDOMGlobalObject*>(state->lexicalGlobalObject())->scriptExecutionContext();
</span><span class="cx"> if (!context)
</span><span class="cx"> return JSValue::encode(jsUndefined());
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(impl.withScriptExecutionContextAndScriptStateObjException(*state, *context, ec)));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), impl.withScriptExecutionContextAndScriptStateObjException(*state, *context, ec));
</ins><span class="cx">
</span><span class="cx"> setDOMException(state, ec);
</span><span class="cx"> if (UNLIKELY(state->hadException()))
</span><span class="lines">@@ -4510,7 +4510,7 @@
</span><span class="cx"> auto* context = jsCast<JSDOMGlobalObject*>(state->lexicalGlobalObject())->scriptExecutionContext();
</span><span class="cx"> if (!context)
</span><span class="cx"> return JSValue::encode(jsUndefined());
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(impl.withScriptExecutionContextAndScriptStateWithSpaces(*state, *context)));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), impl.withScriptExecutionContextAndScriptStateWithSpaces(*state, *context));
</ins><span class="cx"> if (UNLIKELY(state->hadException()))
</span><span class="cx"> return JSValue::encode(jsUndefined());
</span><span class="cx"> return JSValue::encode(result);
</span><span class="lines">@@ -5602,7 +5602,7 @@
</span><span class="cx"> return JSValue::encode(jsUndefined());
</span><span class="cx"> if (UNLIKELY(!values))
</span><span class="cx"> return throwArgumentTypeError(*state, 0, "values", "TestObj", "domStringListFunction", "DOMStringList");
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(impl.domStringListFunction(*values, ec)));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), impl.domStringListFunction(*values, ec));
</ins><span class="cx">
</span><span class="cx"> setDOMException(state, ec);
</span><span class="cx"> return JSValue::encode(result);
</span><span class="lines">@@ -5661,7 +5661,7 @@
</span><span class="cx"> auto elementId = AtomicString(state->argument(0).toString(state)->toExistingAtomicString(state));
</span><span class="cx"> if (UNLIKELY(state->hadException()))
</span><span class="cx"> return JSValue::encode(jsUndefined());
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(impl.getElementById(WTFMove(elementId))));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), impl.getElementById(WTFMove(elementId)));
</ins><span class="cx"> return JSValue::encode(result);
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -5676,7 +5676,7 @@
</span><span class="cx"> ExceptionCode ec = 0;
</span><span class="cx"> if (!shouldAllowAccessToNode(state, impl.getSVGDocument(ec)))
</span><span class="cx"> return JSValue::encode(jsNull());
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(impl.getSVGDocument(ec)));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), impl.getSVGDocument(ec));
</ins><span class="cx">
</span><span class="cx"> setDOMException(state, ec);
</span><span class="cx"> return JSValue::encode(result);
</span><span class="lines">@@ -5756,7 +5756,7 @@
</span><span class="cx"> return throwThisTypeError(*state, "TestObj", "mutablePointFunction");
</span><span class="cx"> ASSERT_GC_OBJECT_INHERITS(castedThis, JSTestObj::info());
</span><span class="cx"> auto& impl = castedThis->wrapped();
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(SVGPropertyTearOff<SVGPoint>::create(impl.mutablePointFunction())));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), SVGPropertyTearOff<SVGPoint>::create(impl.mutablePointFunction()));
</ins><span class="cx"> return JSValue::encode(result);
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -5768,7 +5768,7 @@
</span><span class="cx"> return throwThisTypeError(*state, "TestObj", "immutablePointFunction");
</span><span class="cx"> ASSERT_GC_OBJECT_INHERITS(castedThis, JSTestObj::info());
</span><span class="cx"> auto& impl = castedThis->wrapped();
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(SVGPropertyTearOff<SVGPoint>::create(impl.immutablePointFunction())));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), SVGPropertyTearOff<SVGPoint>::create(impl.immutablePointFunction()));
</ins><span class="cx"> return JSValue::encode(result);
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -6207,22 +6207,18 @@
</span><span class="cx"> #endif
</span><span class="cx"> #endif
</span><span class="cx">
</span><del>-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestObj* impl)
</del><ins>+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestObj& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- return createNewWrapper<JSTestObj>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestObj>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestObj* impl)
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestObj& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- if (JSValue result = getExistingWrapper<JSTestObj>(globalObject, impl))
</del><ins>+ if (JSValue result = getExistingWrapper<JSTestObj>(globalObject, &impl))
</ins><span class="cx"> return result;
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span><del>- void* actualVTablePointer = *(reinterpret_cast<void**>(impl));
</del><ins>+ void* actualVTablePointer = *(reinterpret_cast<void**>(&impl));
</ins><span class="cx"> #if PLATFORM(WIN)
</span><span class="cx"> void* expectedVTablePointer = reinterpret_cast<void*>(__identifier("??_7TestObj@WebCore@@6B@"));
</span><span class="cx"> #else
</span><span class="lines">@@ -6239,7 +6235,7 @@
</span><span class="cx"> // by adding the SkipVTableValidation attribute to the interface IDL definition
</span><span class="cx"> RELEASE_ASSERT(actualVTablePointer == expectedVTablePointer);
</span><span class="cx"> #endif
</span><del>- return createNewWrapper<JSTestObj>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestObj>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> TestObj* JSTestObj::toWrapped(JSC::JSValue value)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestObjh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.h (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.h        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.h        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -97,9 +97,10 @@
</span><span class="cx"> return wrappableObject;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestObj*);
-inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestObj& impl) { return toJS(state, globalObject, &impl); }
-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestObj*);
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestObj&);
+inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestObj* impl) { return impl ? toJS(state, globalObject, *impl) : JSC::jsNull(); }
+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestObj&);
+inline JSC::JSValue toJSNewlyCreated(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestObj* impl) { return impl ? toJSNewlyCreated(state, globalObject, *impl) : JSC::jsNull(); }
</ins><span class="cx">
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestOverloadedConstructorscpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -75,8 +75,8 @@
</span><span class="cx"> return JSValue::encode(jsUndefined());
</span><span class="cx"> if (UNLIKELY(!arrayBuffer))
</span><span class="cx"> return throwArgumentTypeError(*state, 0, "arrayBuffer", "TestOverloadedConstructors", nullptr, "ArrayBuffer");
</span><del>- RefPtr<TestOverloadedConstructors> object = TestOverloadedConstructors::create(*arrayBuffer);
- return JSValue::encode(asObject(toJS(state, castedThis->globalObject(), object.get())));
</del><ins>+ auto object = TestOverloadedConstructors::create(*arrayBuffer);
+ return JSValue::encode(asObject(toJS(state, castedThis->globalObject(), object)));
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> static inline EncodedJSValue constructJSTestOverloadedConstructors2(ExecState* state)
</span><span class="lines">@@ -89,8 +89,8 @@
</span><span class="cx"> return JSValue::encode(jsUndefined());
</span><span class="cx"> if (UNLIKELY(!arrayBufferView))
</span><span class="cx"> return throwArgumentTypeError(*state, 0, "arrayBufferView", "TestOverloadedConstructors", nullptr, "ArrayBufferView");
</span><del>- RefPtr<TestOverloadedConstructors> object = TestOverloadedConstructors::create(*arrayBufferView);
- return JSValue::encode(asObject(toJS(state, castedThis->globalObject(), object.get())));
</del><ins>+ auto object = TestOverloadedConstructors::create(*arrayBufferView);
+ return JSValue::encode(asObject(toJS(state, castedThis->globalObject(), object)));
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> static inline EncodedJSValue constructJSTestOverloadedConstructors3(ExecState* state)
</span><span class="lines">@@ -101,8 +101,8 @@
</span><span class="cx"> auto blob = JSBlob::toWrapped(state->argument(0));
</span><span class="cx"> if (UNLIKELY(!blob))
</span><span class="cx"> return throwArgumentTypeError(*state, 0, "blob", "TestOverloadedConstructors", nullptr, "Blob");
</span><del>- RefPtr<TestOverloadedConstructors> object = TestOverloadedConstructors::create(*blob);
- return JSValue::encode(asObject(toJS(state, castedThis->globalObject(), object.get())));
</del><ins>+ auto object = TestOverloadedConstructors::create(*blob);
+ return JSValue::encode(asObject(toJS(state, castedThis->globalObject(), object)));
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> static inline EncodedJSValue constructJSTestOverloadedConstructors4(ExecState* state)
</span><span class="lines">@@ -113,8 +113,8 @@
</span><span class="cx"> auto string = state->argument(0).toWTFString(state);
</span><span class="cx"> if (UNLIKELY(state->hadException()))
</span><span class="cx"> return JSValue::encode(jsUndefined());
</span><del>- RefPtr<TestOverloadedConstructors> object = TestOverloadedConstructors::create(string);
- return JSValue::encode(asObject(toJS(state, castedThis->globalObject(), object.get())));
</del><ins>+ auto object = TestOverloadedConstructors::create(string);
+ return JSValue::encode(asObject(toJS(state, castedThis->globalObject(), object)));
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> static inline EncodedJSValue constructJSTestOverloadedConstructors5(ExecState* state)
</span><span class="lines">@@ -123,8 +123,8 @@
</span><span class="cx"> Vector<int32_t> longArgs = toNativeArguments<int32_t>(state, 0);
</span><span class="cx"> if (UNLIKELY(state->hadException()))
</span><span class="cx"> return JSValue::encode(jsUndefined());
</span><del>- RefPtr<TestOverloadedConstructors> object = TestOverloadedConstructors::create(longArgs);
- return JSValue::encode(asObject(toJS(state, castedThis->globalObject(), object.get())));
</del><ins>+ auto object = TestOverloadedConstructors::create(longArgs);
+ return JSValue::encode(asObject(toJS(state, castedThis->globalObject(), object)));
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> template<> EncodedJSValue JSC_HOST_CALL JSTestOverloadedConstructorsConstructor::construct(ExecState* state)
</span><span class="lines">@@ -247,22 +247,18 @@
</span><span class="cx"> #endif
</span><span class="cx"> #endif
</span><span class="cx">
</span><del>-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestOverloadedConstructors* impl)
</del><ins>+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestOverloadedConstructors& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- return createNewWrapper<JSTestOverloadedConstructors>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestOverloadedConstructors>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestOverloadedConstructors* impl)
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestOverloadedConstructors& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- if (JSValue result = getExistingWrapper<JSTestOverloadedConstructors>(globalObject, impl))
</del><ins>+ if (JSValue result = getExistingWrapper<JSTestOverloadedConstructors>(globalObject, &impl))
</ins><span class="cx"> return result;
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span><del>- void* actualVTablePointer = *(reinterpret_cast<void**>(impl));
</del><ins>+ void* actualVTablePointer = *(reinterpret_cast<void**>(&impl));
</ins><span class="cx"> #if PLATFORM(WIN)
</span><span class="cx"> void* expectedVTablePointer = reinterpret_cast<void*>(__identifier("??_7TestOverloadedConstructors@WebCore@@6B@"));
</span><span class="cx"> #else
</span><span class="lines">@@ -279,7 +275,7 @@
</span><span class="cx"> // by adding the SkipVTableValidation attribute to the interface IDL definition
</span><span class="cx"> RELEASE_ASSERT(actualVTablePointer == expectedVTablePointer);
</span><span class="cx"> #endif
</span><del>- return createNewWrapper<JSTestOverloadedConstructors>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestOverloadedConstructors>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> TestOverloadedConstructors* JSTestOverloadedConstructors::toWrapped(JSC::JSValue value)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestOverloadedConstructorsh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructors.h (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructors.h        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructors.h        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -79,9 +79,10 @@
</span><span class="cx"> return wrappableObject;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestOverloadedConstructors*);
-inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestOverloadedConstructors& impl) { return toJS(state, globalObject, &impl); }
-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestOverloadedConstructors*);
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestOverloadedConstructors&);
+inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestOverloadedConstructors* impl) { return impl ? toJS(state, globalObject, *impl) : JSC::jsNull(); }
+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestOverloadedConstructors&);
+inline JSC::JSValue toJSNewlyCreated(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestOverloadedConstructors* impl) { return impl ? toJSNewlyCreated(state, globalObject, *impl) : JSC::jsNull(); }
</ins><span class="cx">
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestOverrideBuiltinscpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverrideBuiltins.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverrideBuiltins.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverrideBuiltins.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -203,7 +203,7 @@
</span><span class="cx"> auto name = state->argument(0).isUndefined() ? ASCIILiteral("test") : state->uncheckedArgument(0).toWTFString(state);
</span><span class="cx"> if (UNLIKELY(state->hadException()))
</span><span class="cx"> return JSValue::encode(jsUndefined());
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(impl.namedItem(WTFMove(name))));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), impl.namedItem(WTFMove(name)));
</ins><span class="cx"> return JSValue::encode(result);
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -230,22 +230,18 @@
</span><span class="cx"> #endif
</span><span class="cx"> #endif
</span><span class="cx">
</span><del>-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestOverrideBuiltins* impl)
</del><ins>+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestOverrideBuiltins& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- return createNewWrapper<JSTestOverrideBuiltins>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestOverrideBuiltins>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestOverrideBuiltins* impl)
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestOverrideBuiltins& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- if (JSValue result = getExistingWrapper<JSTestOverrideBuiltins>(globalObject, impl))
</del><ins>+ if (JSValue result = getExistingWrapper<JSTestOverrideBuiltins>(globalObject, &impl))
</ins><span class="cx"> return result;
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span><del>- void* actualVTablePointer = *(reinterpret_cast<void**>(impl));
</del><ins>+ void* actualVTablePointer = *(reinterpret_cast<void**>(&impl));
</ins><span class="cx"> #if PLATFORM(WIN)
</span><span class="cx"> void* expectedVTablePointer = reinterpret_cast<void*>(__identifier("??_7TestOverrideBuiltins@WebCore@@6B@"));
</span><span class="cx"> #else
</span><span class="lines">@@ -262,7 +258,7 @@
</span><span class="cx"> // by adding the SkipVTableValidation attribute to the interface IDL definition
</span><span class="cx"> RELEASE_ASSERT(actualVTablePointer == expectedVTablePointer);
</span><span class="cx"> #endif
</span><del>- return createNewWrapper<JSTestOverrideBuiltins>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestOverrideBuiltins>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> TestOverrideBuiltins* JSTestOverrideBuiltins::toWrapped(JSC::JSValue value)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestOverrideBuiltinsh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverrideBuiltins.h (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverrideBuiltins.h        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverrideBuiltins.h        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -86,9 +86,10 @@
</span><span class="cx"> return wrappableObject;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestOverrideBuiltins*);
-inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestOverrideBuiltins& impl) { return toJS(state, globalObject, &impl); }
-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestOverrideBuiltins*);
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestOverrideBuiltins&);
+inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestOverrideBuiltins* impl) { return impl ? toJS(state, globalObject, *impl) : JSC::jsNull(); }
+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestOverrideBuiltins&);
+inline JSC::JSValue toJSNewlyCreated(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestOverrideBuiltins* impl) { return impl ? toJSNewlyCreated(state, globalObject, *impl) : JSC::jsNull(); }
</ins><span class="cx">
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestSerializedScriptValueInterfacecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -305,22 +305,18 @@
</span><span class="cx"> #endif
</span><span class="cx"> #endif
</span><span class="cx">
</span><del>-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestSerializedScriptValueInterface* impl)
</del><ins>+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestSerializedScriptValueInterface& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- return createNewWrapper<JSTestSerializedScriptValueInterface>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestSerializedScriptValueInterface>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestSerializedScriptValueInterface* impl)
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestSerializedScriptValueInterface& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- if (JSValue result = getExistingWrapper<JSTestSerializedScriptValueInterface>(globalObject, impl))
</del><ins>+ if (JSValue result = getExistingWrapper<JSTestSerializedScriptValueInterface>(globalObject, &impl))
</ins><span class="cx"> return result;
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span><del>- void* actualVTablePointer = *(reinterpret_cast<void**>(impl));
</del><ins>+ void* actualVTablePointer = *(reinterpret_cast<void**>(&impl));
</ins><span class="cx"> #if PLATFORM(WIN)
</span><span class="cx"> void* expectedVTablePointer = reinterpret_cast<void*>(__identifier("??_7TestSerializedScriptValueInterface@WebCore@@6B@"));
</span><span class="cx"> #else
</span><span class="lines">@@ -337,7 +333,7 @@
</span><span class="cx"> // by adding the SkipVTableValidation attribute to the interface IDL definition
</span><span class="cx"> RELEASE_ASSERT(actualVTablePointer == expectedVTablePointer);
</span><span class="cx"> #endif
</span><del>- return createNewWrapper<JSTestSerializedScriptValueInterface>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestSerializedScriptValueInterface>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> TestSerializedScriptValueInterface* JSTestSerializedScriptValueInterface::toWrapped(JSC::JSValue value)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestSerializedScriptValueInterfaceh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -85,9 +85,10 @@
</span><span class="cx"> return wrappableObject;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestSerializedScriptValueInterface*);
-inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestSerializedScriptValueInterface& impl) { return toJS(state, globalObject, &impl); }
-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestSerializedScriptValueInterface*);
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestSerializedScriptValueInterface&);
+inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestSerializedScriptValueInterface* impl) { return impl ? toJS(state, globalObject, *impl) : JSC::jsNull(); }
+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestSerializedScriptValueInterface&);
+inline JSC::JSValue toJSNewlyCreated(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestSerializedScriptValueInterface* impl) { return impl ? toJSNewlyCreated(state, globalObject, *impl) : JSC::jsNull(); }
</ins><span class="cx">
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestTypedefscpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -135,8 +135,8 @@
</span><span class="cx"> if (UNLIKELY(!state->argument(1).isObject()))
</span><span class="cx"> return throwArgumentMustBeFunctionError(*state, 1, "testCallback", "TestTypedefs", nullptr);
</span><span class="cx"> RefPtr<TestCallback> testCallback = JSTestCallback::create(asObject(state->uncheckedArgument(1)), castedThis->globalObject());
</span><del>- RefPtr<TestTypedefs> object = TestTypedefs::create(hello, *testCallback);
- return JSValue::encode(asObject(toJS(state, castedThis->globalObject(), object.get())));
</del><ins>+ auto object = TestTypedefs::create(hello, *testCallback);
+ return JSValue::encode(asObject(toJS(state, castedThis->globalObject(), object)));
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> template<> JSValue JSTestTypedefsConstructor::prototypeForStructure(JSC::VM& vm, const JSDOMGlobalObject& globalObject)
</span><span class="lines">@@ -562,7 +562,7 @@
</span><span class="cx"> return throwThisTypeError(*state, "TestTypedefs", "immutablePointFunction");
</span><span class="cx"> ASSERT_GC_OBJECT_INHERITS(castedThis, JSTestTypedefs::info());
</span><span class="cx"> auto& impl = castedThis->wrapped();
</span><del>- JSValue result = toJS(state, castedThis->globalObject(), WTF::getPtr(SVGPropertyTearOff<SVGPoint>::create(impl.immutablePointFunction())));
</del><ins>+ JSValue result = toJS(state, castedThis->globalObject(), SVGPropertyTearOff<SVGPoint>::create(impl.immutablePointFunction()));
</ins><span class="cx"> return JSValue::encode(result);
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -660,22 +660,18 @@
</span><span class="cx"> #endif
</span><span class="cx"> #endif
</span><span class="cx">
</span><del>-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestTypedefs* impl)
</del><ins>+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestTypedefs& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- return createNewWrapper<JSTestTypedefs>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestTypedefs>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestTypedefs* impl)
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestTypedefs& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- if (JSValue result = getExistingWrapper<JSTestTypedefs>(globalObject, impl))
</del><ins>+ if (JSValue result = getExistingWrapper<JSTestTypedefs>(globalObject, &impl))
</ins><span class="cx"> return result;
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span><del>- void* actualVTablePointer = *(reinterpret_cast<void**>(impl));
</del><ins>+ void* actualVTablePointer = *(reinterpret_cast<void**>(&impl));
</ins><span class="cx"> #if PLATFORM(WIN)
</span><span class="cx"> void* expectedVTablePointer = reinterpret_cast<void*>(__identifier("??_7TestTypedefs@WebCore@@6B@"));
</span><span class="cx"> #else
</span><span class="lines">@@ -692,7 +688,7 @@
</span><span class="cx"> // by adding the SkipVTableValidation attribute to the interface IDL definition
</span><span class="cx"> RELEASE_ASSERT(actualVTablePointer == expectedVTablePointer);
</span><span class="cx"> #endif
</span><del>- return createNewWrapper<JSTestTypedefs>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSTestTypedefs>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> TestTypedefs* JSTestTypedefs::toWrapped(JSC::JSValue value)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestTypedefsh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.h (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.h        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.h        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -82,9 +82,10 @@
</span><span class="cx"> return wrappableObject;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestTypedefs*);
-inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestTypedefs& impl) { return toJS(state, globalObject, &impl); }
-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestTypedefs*);
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, TestTypedefs&);
+inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestTypedefs* impl) { return impl ? toJS(state, globalObject, *impl) : JSC::jsNull(); }
+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, TestTypedefs&);
+inline JSC::JSValue toJSNewlyCreated(JSC::ExecState* state, JSDOMGlobalObject* globalObject, TestTypedefs* impl) { return impl ? toJSNewlyCreated(state, globalObject, *impl) : JSC::jsNull(); }
</ins><span class="cx">
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSattributecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSattribute.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSattribute.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSattribute.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -204,22 +204,18 @@
</span><span class="cx"> #endif
</span><span class="cx"> #endif
</span><span class="cx">
</span><del>-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, attribute* impl)
</del><ins>+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, attribute& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- return createNewWrapper<JSattribute>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSattribute>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, attribute* impl)
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, attribute& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- if (JSValue result = getExistingWrapper<JSattribute>(globalObject, impl))
</del><ins>+ if (JSValue result = getExistingWrapper<JSattribute>(globalObject, &impl))
</ins><span class="cx"> return result;
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span><del>- void* actualVTablePointer = *(reinterpret_cast<void**>(impl));
</del><ins>+ void* actualVTablePointer = *(reinterpret_cast<void**>(&impl));
</ins><span class="cx"> #if PLATFORM(WIN)
</span><span class="cx"> void* expectedVTablePointer = reinterpret_cast<void*>(__identifier("??_7attribute@WebCore@@6B@"));
</span><span class="cx"> #else
</span><span class="lines">@@ -236,7 +232,7 @@
</span><span class="cx"> // by adding the SkipVTableValidation attribute to the interface IDL definition
</span><span class="cx"> RELEASE_ASSERT(actualVTablePointer == expectedVTablePointer);
</span><span class="cx"> #endif
</span><del>- return createNewWrapper<JSattribute>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSattribute>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> attribute* JSattribute::toWrapped(JSC::JSValue value)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSattributeh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSattribute.h (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSattribute.h        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSattribute.h        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -83,9 +83,10 @@
</span><span class="cx"> return wrappableObject;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, attribute*);
-inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, attribute& impl) { return toJS(state, globalObject, &impl); }
-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, attribute*);
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, attribute&);
+inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, attribute* impl) { return impl ? toJS(state, globalObject, *impl) : JSC::jsNull(); }
+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, attribute&);
+inline JSC::JSValue toJSNewlyCreated(JSC::ExecState* state, JSDOMGlobalObject* globalObject, attribute* impl) { return impl ? toJSNewlyCreated(state, globalObject, *impl) : JSC::jsNull(); }
</ins><span class="cx">
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSreadonlycpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSreadonly.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSreadonly.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSreadonly.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -154,18 +154,14 @@
</span><span class="cx"> uncacheWrapper(world, &jsreadonly->wrapped(), jsreadonly);
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, readonly* impl)
</del><ins>+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject* globalObject, readonly& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- return createNewWrapper<JSreadonly>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSreadonly>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, readonly* impl)
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, readonly& impl)
</ins><span class="cx"> {
</span><del>- if (!impl)
- return jsNull();
- if (JSValue result = getExistingWrapper<JSreadonly>(globalObject, impl))
</del><ins>+ if (JSValue result = getExistingWrapper<JSreadonly>(globalObject, &impl))
</ins><span class="cx"> return result;
</span><span class="cx"> #if COMPILER(CLANG)
</span><span class="cx"> // If you hit this failure the interface definition has the ImplementationLacksVTable
</span><span class="lines">@@ -174,7 +170,7 @@
</span><span class="cx"> // attribute to readonly.
</span><span class="cx"> static_assert(!__is_polymorphic(readonly), "readonly is polymorphic but the IDL claims it is not");
</span><span class="cx"> #endif
</span><del>- return createNewWrapper<JSreadonly>(globalObject, impl);
</del><ins>+ return createNewWrapper<JSreadonly>(globalObject, &impl);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> readonly* JSreadonly::toWrapped(JSC::JSValue value)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSreadonlyh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSreadonly.h (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSreadonly.h        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSreadonly.h        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -79,9 +79,10 @@
</span><span class="cx"> return wrappableObject;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, readonly*);
-inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, readonly& impl) { return toJS(state, globalObject, &impl); }
-JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, readonly*);
</del><ins>+JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject*, readonly&);
+inline JSC::JSValue toJS(JSC::ExecState* state, JSDOMGlobalObject* globalObject, readonly* impl) { return impl ? toJS(state, globalObject, *impl) : JSC::jsNull(); }
+JSC::JSValue toJSNewlyCreated(JSC::ExecState*, JSDOMGlobalObject*, readonly&);
+inline JSC::JSValue toJSNewlyCreated(JSC::ExecState* state, JSDOMGlobalObject* globalObject, readonly* impl) { return impl ? toJSNewlyCreated(state, globalObject, *impl) : JSC::jsNull(); }
</ins><span class="cx">
</span><span class="cx">
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCorehtmlHTMLMediaElementcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/html/HTMLMediaElement.cpp (200774 => 200775)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/html/HTMLMediaElement.cpp        2016-05-12 15:47:45 UTC (rev 200774)
+++ trunk/Source/WebCore/html/HTMLMediaElement.cpp        2016-05-12 16:07:13 UTC (rev 200775)
</span><span class="lines">@@ -3896,7 +3896,7 @@
</span><span class="cx">
</span><span class="cx"> static JSC::JSValue controllerJSValue(JSC::ExecState& exec, JSDOMGlobalObject& globalObject, HTMLMediaElement& media)
</span><span class="cx"> {
</span><del>- auto mediaJSWrapper = toJS(&exec, &globalObject, &media);
</del><ins>+ auto mediaJSWrapper = toJS(&exec, &globalObject, media);
</ins><span class="cx">
</span><span class="cx"> // Retrieve the controller through the JS object graph
</span><span class="cx"> JSC::JSObject* mediaJSWrapperObject = JSC::jsDynamicCast<JSC::JSObject*>(mediaJSWrapper);
</span><span class="lines">@@ -6476,8 +6476,8 @@
</span><span class="cx"> if (!m_mediaControlsHost)
</span><span class="cx"> m_mediaControlsHost = MediaControlsHost::create(this);
</span><span class="cx">
</span><del>- auto mediaJSWrapper = toJS(exec, globalObject, this);
- auto mediaControlsHostJSWrapper = toJS(exec, globalObject, m_mediaControlsHost.get());
</del><ins>+ auto mediaJSWrapper = toJS(exec, globalObject, *this);
+ auto mediaControlsHostJSWrapper = toJS(exec, globalObject, m_mediaControlsHost);
</ins><span class="cx">
</span><span class="cx"> JSC::MarkedArgumentBuffer argList;
</span><span class="cx"> argList.append(toJS(exec, globalObject, root));
</span></span></pre>
</div>
</div>
</body>
</html>