<!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>[189616] trunk/Source</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/189616">189616</a></dd>
<dt>Author</dt> <dd>akling@apple.com</dd>
<dt>Date</dt> <dd>2015-09-11 02:16:37 -0700 (Fri, 11 Sep 2015)</dd>
</dl>
<h3>Log Message</h3>
<pre>[JSC] Weak should only accept cell pointees.
<https://webkit.org/b/148955>
Reviewed by Geoffrey Garen.
Source/JavaScriptCore:
Since WeakImpls only support pointing to JSCell derived objects,
enforce that at compile time by having the API use JSCell* instead of JSValue.
WeakHandleOwner callbacks now get JSCell& and JSCell*& respectively instead
of wrapping the cell pointer in a Handle<Unknown>.
Also added a static_assert so Weak<T> can't be instantiated with a T that's
not convertible to JSCell.
* API/JSAPIWrapperObject.mm:
(JSAPIWrapperObjectHandleOwner::finalize):
(JSAPIWrapperObjectHandleOwner::isReachableFromOpaqueRoots):
(JSC::JSAPIWrapperObject::finishCreation):
* API/JSManagedValue.mm:
(JSManagedValueHandleOwner::isReachableFromOpaqueRoots):
(JSManagedValueHandleOwner::finalize):
* builtins/BuiltinExecutables.cpp:
(JSC::BuiltinExecutables::finalize):
* builtins/BuiltinExecutables.h:
* heap/Heap.cpp:
(JSC::Heap::addFinalizer):
(JSC::Heap::FinalizerOwner::finalize):
* heap/Heap.h:
* heap/WeakBlock.cpp:
(JSC::WeakBlock::visit):
(JSC::WeakBlock::reap):
* heap/WeakHandleOwner.cpp:
(JSC::WeakHandleOwner::isReachableFromOpaqueRoots):
(JSC::WeakHandleOwner::finalize):
* heap/WeakHandleOwner.h:
* heap/WeakImpl.h:
(JSC::WeakImpl::WeakImpl):
(JSC::WeakImpl::state):
(JSC::WeakImpl::cell):
(JSC::WeakImpl::asWeakImpl):
(JSC::WeakImpl::jsValue): Deleted.
* heap/WeakInlines.h:
(JSC::Weak<T>::Weak):
(JSC::>):
(JSC::Weak<T>::operator):
(JSC::Weak<T>::get):
(JSC::Weak<T>::was):
* heap/WeakSet.h:
* heap/WeakSetInlines.h:
(JSC::WeakSet::allocate):
(JSC::WeakBlock::finalize):
* jit/JITThunks.cpp:
(JSC::JITThunks::finalize):
* jit/JITThunks.h:
* jsc.cpp:
(WTF::ElementHandleOwner::isReachableFromOpaqueRoots): Deleted.
* runtime/JSCell.h:
(JSC::jsCast):
* runtime/RegExpCache.cpp:
(JSC::RegExpCache::finalize):
* runtime/RegExpCache.h:
* runtime/Structure.cpp:
(JSC::StructureTransitionTable::singleTransition):
(JSC::StructureTransitionTable::setSingleTransition):
Source/WebCore:
Update WebCore bindings for the new Weak and Weak-related signatures.
* bindings/js/JSCSSRuleListCustom.cpp:
(WebCore::JSCSSRuleListOwner::isReachableFromOpaqueRoots):
* bindings/js/JSCSSValueCustom.cpp:
(WebCore::JSCSSValueOwner::isReachableFromOpaqueRoots):
(WebCore::JSCSSValueOwner::finalize):
* bindings/js/JSCallbackData.cpp:
(WebCore::JSCallbackDataWeak::WeakOwner::isReachableFromOpaqueRoots):
* bindings/js/JSCallbackData.h:
* bindings/js/JSMutationObserverCustom.cpp:
(WebCore::JSMutationObserverOwner::isReachableFromOpaqueRoots):
* bindings/js/JSNodeCustom.cpp:
(WebCore::isReachableFromDOM):
(WebCore::JSNodeOwner::isReachableFromOpaqueRoots):
* bindings/js/JSNodeListCustom.cpp:
(WebCore::JSNodeListOwner::isReachableFromOpaqueRoots):
* bindings/js/JSTextTrackCueCustom.cpp:
(WebCore::JSTextTrackCueOwner::isReachableFromOpaqueRoots):
* bindings/js/WebCoreTypedArrayController.cpp:
(WebCore::WebCoreTypedArrayController::JSArrayBufferOwner::isReachableFromOpaqueRoots):
(WebCore::WebCoreTypedArrayController::JSArrayBufferOwner::finalize):
* bindings/js/WebCoreTypedArrayController.h:
* bindings/scripts/CodeGeneratorJS.pm:
(GenerateHeader):
(GenerateImplementation):
* bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
(WebCore::JSTestActiveDOMObjectOwner::isReachableFromOpaqueRoots):
(WebCore::JSTestActiveDOMObjectOwner::finalize):
* bindings/scripts/test/JS/JSTestActiveDOMObject.h:
* bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.cpp:
(WebCore::JSTestCustomConstructorWithNoInterfaceObjectOwner::isReachableFromOpaqueRoots):
(WebCore::JSTestCustomConstructorWithNoInterfaceObjectOwner::finalize):
* bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.h:
* bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
(WebCore::JSTestCustomNamedGetterOwner::isReachableFromOpaqueRoots):
(WebCore::JSTestCustomNamedGetterOwner::finalize):
* bindings/scripts/test/JS/JSTestCustomNamedGetter.h:
* bindings/scripts/test/JS/JSTestEventConstructor.cpp:
(WebCore::JSTestEventConstructorOwner::isReachableFromOpaqueRoots):
(WebCore::JSTestEventConstructorOwner::finalize):
* bindings/scripts/test/JS/JSTestEventConstructor.h:
* bindings/scripts/test/JS/JSTestEventTarget.cpp:
(WebCore::JSTestEventTargetOwner::isReachableFromOpaqueRoots):
(WebCore::JSTestEventTargetOwner::finalize):
* bindings/scripts/test/JS/JSTestEventTarget.h:
* bindings/scripts/test/JS/JSTestException.cpp:
(WebCore::JSTestExceptionOwner::isReachableFromOpaqueRoots):
(WebCore::JSTestExceptionOwner::finalize):
* bindings/scripts/test/JS/JSTestException.h:
* bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
(WebCore::JSTestGenerateIsReachableOwner::isReachableFromOpaqueRoots):
(WebCore::JSTestGenerateIsReachableOwner::finalize):
* bindings/scripts/test/JS/JSTestGenerateIsReachable.h:
* bindings/scripts/test/JS/JSTestInterface.cpp:
(WebCore::JSTestInterfaceOwner::isReachableFromOpaqueRoots):
(WebCore::JSTestInterfaceOwner::finalize):
* bindings/scripts/test/JS/JSTestInterface.h:
* bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
(WebCore::JSTestMediaQueryListListenerOwner::isReachableFromOpaqueRoots):
(WebCore::JSTestMediaQueryListListenerOwner::finalize):
* bindings/scripts/test/JS/JSTestMediaQueryListListener.h:
* bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
(WebCore::JSTestNamedConstructorOwner::isReachableFromOpaqueRoots):
(WebCore::JSTestNamedConstructorOwner::finalize):
* bindings/scripts/test/JS/JSTestNamedConstructor.h:
* bindings/scripts/test/JS/JSTestNondeterministic.cpp:
(WebCore::JSTestNondeterministicOwner::isReachableFromOpaqueRoots):
(WebCore::JSTestNondeterministicOwner::finalize):
* bindings/scripts/test/JS/JSTestNondeterministic.h:
* bindings/scripts/test/JS/JSTestObj.cpp:
(WebCore::JSTestObjOwner::isReachableFromOpaqueRoots):
(WebCore::JSTestObjOwner::finalize):
* bindings/scripts/test/JS/JSTestObj.h:
* bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
(WebCore::JSTestOverloadedConstructorsOwner::isReachableFromOpaqueRoots):
(WebCore::JSTestOverloadedConstructorsOwner::finalize):
* bindings/scripts/test/JS/JSTestOverloadedConstructors.h:
* bindings/scripts/test/JS/JSTestOverrideBuiltins.cpp:
(WebCore::JSTestOverrideBuiltinsOwner::isReachableFromOpaqueRoots):
(WebCore::JSTestOverrideBuiltinsOwner::finalize):
* bindings/scripts/test/JS/JSTestOverrideBuiltins.h:
* bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
(WebCore::JSTestSerializedScriptValueInterfaceOwner::isReachableFromOpaqueRoots):
(WebCore::JSTestSerializedScriptValueInterfaceOwner::finalize):
* bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h:
* bindings/scripts/test/JS/JSTestTypedefs.cpp:
(WebCore::JSTestTypedefsOwner::isReachableFromOpaqueRoots):
(WebCore::JSTestTypedefsOwner::finalize):
* bindings/scripts/test/JS/JSTestTypedefs.h:
* bindings/scripts/test/JS/JSattribute.cpp:
(WebCore::JSattributeOwner::isReachableFromOpaqueRoots):
(WebCore::JSattributeOwner::finalize):
* bindings/scripts/test/JS/JSattribute.h:
* bindings/scripts/test/JS/JSreadonly.cpp:
(WebCore::JSreadonlyOwner::isReachableFromOpaqueRoots):
(WebCore::JSreadonlyOwner::finalize):
* bindings/scripts/test/JS/JSreadonly.h:
* bridge/runtime_root.cpp:
(JSC::Bindings::RootObject::finalize):
* bridge/runtime_root.h:
Source/WebKit2:
* WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp:
(WebKit::NPRuntimeObjectMap::finalize):
* WebProcess/Plugins/Netscape/NPRuntimeObjectMap.h:</pre>
<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkSourceJavaScriptCoreAPIJSAPIWrapperObjectmm">trunk/Source/JavaScriptCore/API/JSAPIWrapperObject.mm</a></li>
<li><a href="#trunkSourceJavaScriptCoreAPIJSManagedValuemm">trunk/Source/JavaScriptCore/API/JSManagedValue.mm</a></li>
<li><a href="#trunkSourceJavaScriptCoreChangeLog">trunk/Source/JavaScriptCore/ChangeLog</a></li>
<li><a href="#trunkSourceJavaScriptCorebuiltinsBuiltinExecutablescpp">trunk/Source/JavaScriptCore/builtins/BuiltinExecutables.cpp</a></li>
<li><a href="#trunkSourceJavaScriptCorebuiltinsBuiltinExecutablesh">trunk/Source/JavaScriptCore/builtins/BuiltinExecutables.h</a></li>
<li><a href="#trunkSourceJavaScriptCoreheapHeapcpp">trunk/Source/JavaScriptCore/heap/Heap.cpp</a></li>
<li><a href="#trunkSourceJavaScriptCoreheapHeaph">trunk/Source/JavaScriptCore/heap/Heap.h</a></li>
<li><a href="#trunkSourceJavaScriptCoreheapWeakBlockcpp">trunk/Source/JavaScriptCore/heap/WeakBlock.cpp</a></li>
<li><a href="#trunkSourceJavaScriptCoreheapWeakHandleOwnercpp">trunk/Source/JavaScriptCore/heap/WeakHandleOwner.cpp</a></li>
<li><a href="#trunkSourceJavaScriptCoreheapWeakHandleOwnerh">trunk/Source/JavaScriptCore/heap/WeakHandleOwner.h</a></li>
<li><a href="#trunkSourceJavaScriptCoreheapWeakImplh">trunk/Source/JavaScriptCore/heap/WeakImpl.h</a></li>
<li><a href="#trunkSourceJavaScriptCoreheapWeakInlinesh">trunk/Source/JavaScriptCore/heap/WeakInlines.h</a></li>
<li><a href="#trunkSourceJavaScriptCoreheapWeakSeth">trunk/Source/JavaScriptCore/heap/WeakSet.h</a></li>
<li><a href="#trunkSourceJavaScriptCoreheapWeakSetInlinesh">trunk/Source/JavaScriptCore/heap/WeakSetInlines.h</a></li>
<li><a href="#trunkSourceJavaScriptCorejitJITThunkscpp">trunk/Source/JavaScriptCore/jit/JITThunks.cpp</a></li>
<li><a href="#trunkSourceJavaScriptCorejitJITThunksh">trunk/Source/JavaScriptCore/jit/JITThunks.h</a></li>
<li><a href="#trunkSourceJavaScriptCorejsccpp">trunk/Source/JavaScriptCore/jsc.cpp</a></li>
<li><a href="#trunkSourceJavaScriptCoreruntimeJSCellh">trunk/Source/JavaScriptCore/runtime/JSCell.h</a></li>
<li><a href="#trunkSourceJavaScriptCoreruntimeRegExpCachecpp">trunk/Source/JavaScriptCore/runtime/RegExpCache.cpp</a></li>
<li><a href="#trunkSourceJavaScriptCoreruntimeRegExpCacheh">trunk/Source/JavaScriptCore/runtime/RegExpCache.h</a></li>
<li><a href="#trunkSourceJavaScriptCoreruntimeStructurecpp">trunk/Source/JavaScriptCore/runtime/Structure.cpp</a></li>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSCSSRuleListCustomcpp">trunk/Source/WebCore/bindings/js/JSCSSRuleListCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSCSSValueCustomcpp">trunk/Source/WebCore/bindings/js/JSCSSValueCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSCallbackDatacpp">trunk/Source/WebCore/bindings/js/JSCallbackData.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSCallbackDatah">trunk/Source/WebCore/bindings/js/JSCallbackData.h</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSMutationObserverCustomcpp">trunk/Source/WebCore/bindings/js/JSMutationObserverCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSNodeCustomcpp">trunk/Source/WebCore/bindings/js/JSNodeCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSNodeListCustomcpp">trunk/Source/WebCore/bindings/js/JSNodeListCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSTextTrackCueCustomcpp">trunk/Source/WebCore/bindings/js/JSTextTrackCueCustom.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsWebCoreTypedArrayControllercpp">trunk/Source/WebCore/bindings/js/WebCoreTypedArrayController.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsjsWebCoreTypedArrayControllerh">trunk/Source/WebCore/bindings/js/WebCoreTypedArrayController.h</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="#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="#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="#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="#trunkSourceWebCorebridgeruntime_rootcpp">trunk/Source/WebCore/bridge/runtime_root.cpp</a></li>
<li><a href="#trunkSourceWebCorebridgeruntime_rooth">trunk/Source/WebCore/bridge/runtime_root.h</a></li>
<li><a href="#trunkSourceWebKit2ChangeLog">trunk/Source/WebKit2/ChangeLog</a></li>
<li><a href="#trunkSourceWebKit2WebProcessPluginsNetscapeNPRuntimeObjectMapcpp">trunk/Source/WebKit2/WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp</a></li>
<li><a href="#trunkSourceWebKit2WebProcessPluginsNetscapeNPRuntimeObjectMaph">trunk/Source/WebKit2/WebProcess/Plugins/Netscape/NPRuntimeObjectMap.h</a></li>
</ul>
</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkSourceJavaScriptCoreAPIJSAPIWrapperObjectmm"></a>
<div class="modfile"><h4>Modified: trunk/Source/JavaScriptCore/API/JSAPIWrapperObject.mm (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/JavaScriptCore/API/JSAPIWrapperObject.mm        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/JavaScriptCore/API/JSAPIWrapperObject.mm        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -33,10 +33,10 @@
</span><span class="cx">
</span><span class="cx"> #if JSC_OBJC_API_ENABLED
</span><span class="cx">
</span><del>-class JSAPIWrapperObjectHandleOwner : public JSC::WeakHandleOwner {
</del><ins>+class JSAPIWrapperObjectHandleOwner final : public JSC::WeakHandleOwner {
</ins><span class="cx"> public:
</span><del>- virtual void finalize(JSC::Handle<JSC::Unknown>, void*) override;
- virtual bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&) override;
</del><ins>+ void finalize(JSC::JSCell*&, void*) override;
+ bool isReachableFromOpaqueRoots(JSC::JSCell&, void* context, JSC::SlotVisitor&) override;
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> static JSAPIWrapperObjectHandleOwner* jsAPIWrapperObjectHandleOwner()
</span><span class="lines">@@ -45,24 +45,24 @@
</span><span class="cx"> return &jsWrapperObjectHandleOwner;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void JSAPIWrapperObjectHandleOwner::finalize(JSC::Handle<JSC::Unknown> handle, void*)
</del><ins>+void JSAPIWrapperObjectHandleOwner::finalize(JSC::JSCell*& cell, void*)
</ins><span class="cx"> {
</span><del>- JSC::JSAPIWrapperObject* wrapperObject = JSC::jsCast<JSC::JSAPIWrapperObject*>(handle.get().asCell());
- if (!wrapperObject->wrappedObject())
</del><ins>+ auto& wrapperObject = JSC::jsCast<JSC::JSAPIWrapperObject&>(*cell);
+ if (!wrapperObject.wrappedObject())
</ins><span class="cx"> return;
</span><span class="cx">
</span><del>- JSC::Heap::heap(wrapperObject)->releaseSoon(adoptNS(static_cast<id>(wrapperObject->wrappedObject())));
- JSC::WeakSet::deallocate(JSC::WeakImpl::asWeakImpl(handle.slot()));
</del><ins>+ JSC::Heap::heap(&wrapperObject)->releaseSoon(adoptNS(static_cast<id>(wrapperObject.wrappedObject())));
+ JSC::WeakSet::deallocate(JSC::WeakImpl::asWeakImpl(&cell));
</ins><span class="cx"> }
</span><span class="cx">
</span><del>-bool JSAPIWrapperObjectHandleOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, JSC::SlotVisitor& visitor)
</del><ins>+bool JSAPIWrapperObjectHandleOwner::isReachableFromOpaqueRoots(JSC::JSCell& cell, void*, JSC::SlotVisitor& visitor)
</ins><span class="cx"> {
</span><del>- JSC::JSAPIWrapperObject* wrapperObject = JSC::jsCast<JSC::JSAPIWrapperObject*>(handle.get().asCell());
</del><ins>+ JSC::JSAPIWrapperObject& wrapperObject = JSC::jsCast<JSC::JSAPIWrapperObject&>(cell);
</ins><span class="cx"> // We use the JSGlobalObject when processing weak handles to prevent the situation where using
</span><span class="cx"> // the same Objective-C object in multiple global objects keeps all of the global objects alive.
</span><del>- if (!wrapperObject->wrappedObject())
</del><ins>+ if (!wrapperObject.wrappedObject())
</ins><span class="cx"> return false;
</span><del>- return JSC::Heap::isMarked(wrapperObject->structure()->globalObject()) && visitor.containsOpaqueRoot(wrapperObject->wrappedObject());
</del><ins>+ return JSC::Heap::isMarked(wrapperObject.globalObject()) && visitor.containsOpaqueRoot(wrapperObject.wrappedObject());
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> namespace JSC {
</span><span class="lines">@@ -86,7 +86,7 @@
</span><span class="cx"> void JSAPIWrapperObject::finishCreation(VM& vm)
</span><span class="cx"> {
</span><span class="cx"> Base::finishCreation(vm);
</span><del>- WeakSet::allocate(this, jsAPIWrapperObjectHandleOwner(), 0); // Balanced in JSAPIWrapperObjectHandleOwner::finalize.
</del><ins>+ WeakSet::allocate(*this, jsAPIWrapperObjectHandleOwner(), 0); // Balanced in JSAPIWrapperObjectHandleOwner::finalize.
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> void JSAPIWrapperObject::setWrappedObject(void* wrappedObject)
</span></span></pre></div>
<a id="trunkSourceJavaScriptCoreAPIJSManagedValuemm"></a>
<div class="modfile"><h4>Modified: trunk/Source/JavaScriptCore/API/JSManagedValue.mm (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/JavaScriptCore/API/JSManagedValue.mm        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/JavaScriptCore/API/JSManagedValue.mm        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -39,10 +39,10 @@
</span><span class="cx"> #import "JSCInlines.h"
</span><span class="cx"> #import <wtf/spi/cocoa/NSMapTableSPI.h>
</span><span class="cx">
</span><del>-class JSManagedValueHandleOwner : public JSC::WeakHandleOwner {
</del><ins>+class JSManagedValueHandleOwner final : public JSC::WeakHandleOwner {
</ins><span class="cx"> public:
</span><del>- virtual void finalize(JSC::Handle<JSC::Unknown>, void* context) override;
- virtual bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&) override;
</del><ins>+ void finalize(JSC::JSCell*&, void* context) override;
+ bool isReachableFromOpaqueRoots(JSC::JSCell&, void* context, JSC::SlotVisitor&) override;
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> static JSManagedValueHandleOwner* managedValueHandleOwner()
</span><span class="lines">@@ -295,13 +295,13 @@
</span><span class="cx"> - (void)disconnectValue;
</span><span class="cx"> @end
</span><span class="cx">
</span><del>-bool JSManagedValueHandleOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor& visitor)
</del><ins>+bool JSManagedValueHandleOwner::isReachableFromOpaqueRoots(JSC::JSCell&, void* context, JSC::SlotVisitor& visitor)
</ins><span class="cx"> {
</span><span class="cx"> JSManagedValue *managedValue = static_cast<JSManagedValue *>(context);
</span><span class="cx"> return visitor.containsOpaqueRoot(managedValue);
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void JSManagedValueHandleOwner::finalize(JSC::Handle<JSC::Unknown>, void* context)
</del><ins>+void JSManagedValueHandleOwner::finalize(JSC::JSCell*&, void* context)
</ins><span class="cx"> {
</span><span class="cx"> JSManagedValue *managedValue = static_cast<JSManagedValue *>(context);
</span><span class="cx"> [managedValue disconnectValue];
</span></span></pre></div>
<a id="trunkSourceJavaScriptCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/JavaScriptCore/ChangeLog (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/JavaScriptCore/ChangeLog        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/JavaScriptCore/ChangeLog        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -1,3 +1,70 @@
</span><ins>+2015-09-11 Andreas Kling <akling@apple.com>
+
+ [JSC] Weak should only accept cell pointees.
+ <https://webkit.org/b/148955>
+
+ Reviewed by Geoffrey Garen.
+
+ Since WeakImpls only support pointing to JSCell derived objects,
+ enforce that at compile time by having the API use JSCell* instead of JSValue.
+
+ WeakHandleOwner callbacks now get JSCell& and JSCell*& respectively instead
+ of wrapping the cell pointer in a Handle<Unknown>.
+
+ Also added a static_assert so Weak<T> can't be instantiated with a T that's
+ not convertible to JSCell.
+
+ * API/JSAPIWrapperObject.mm:
+ (JSAPIWrapperObjectHandleOwner::finalize):
+ (JSAPIWrapperObjectHandleOwner::isReachableFromOpaqueRoots):
+ (JSC::JSAPIWrapperObject::finishCreation):
+ * API/JSManagedValue.mm:
+ (JSManagedValueHandleOwner::isReachableFromOpaqueRoots):
+ (JSManagedValueHandleOwner::finalize):
+ * builtins/BuiltinExecutables.cpp:
+ (JSC::BuiltinExecutables::finalize):
+ * builtins/BuiltinExecutables.h:
+ * heap/Heap.cpp:
+ (JSC::Heap::addFinalizer):
+ (JSC::Heap::FinalizerOwner::finalize):
+ * heap/Heap.h:
+ * heap/WeakBlock.cpp:
+ (JSC::WeakBlock::visit):
+ (JSC::WeakBlock::reap):
+ * heap/WeakHandleOwner.cpp:
+ (JSC::WeakHandleOwner::isReachableFromOpaqueRoots):
+ (JSC::WeakHandleOwner::finalize):
+ * heap/WeakHandleOwner.h:
+ * heap/WeakImpl.h:
+ (JSC::WeakImpl::WeakImpl):
+ (JSC::WeakImpl::state):
+ (JSC::WeakImpl::cell):
+ (JSC::WeakImpl::asWeakImpl):
+ (JSC::WeakImpl::jsValue): Deleted.
+ * heap/WeakInlines.h:
+ (JSC::Weak<T>::Weak):
+ (JSC::>):
+ (JSC::Weak<T>::operator):
+ (JSC::Weak<T>::get):
+ (JSC::Weak<T>::was):
+ * heap/WeakSet.h:
+ * heap/WeakSetInlines.h:
+ (JSC::WeakSet::allocate):
+ (JSC::WeakBlock::finalize):
+ * jit/JITThunks.cpp:
+ (JSC::JITThunks::finalize):
+ * jit/JITThunks.h:
+ * jsc.cpp:
+ (WTF::ElementHandleOwner::isReachableFromOpaqueRoots): Deleted.
+ * runtime/JSCell.h:
+ (JSC::jsCast):
+ * runtime/RegExpCache.cpp:
+ (JSC::RegExpCache::finalize):
+ * runtime/RegExpCache.h:
+ * runtime/Structure.cpp:
+ (JSC::StructureTransitionTable::singleTransition):
+ (JSC::StructureTransitionTable::setSingleTransition):
+
</ins><span class="cx"> 2015-09-10 Sukolsak Sakshuwong <sukolsak@gmail.com>
</span><span class="cx">
</span><span class="cx"> Implement switch statements in WebAssembly
</span></span></pre></div>
<a id="trunkSourceJavaScriptCorebuiltinsBuiltinExecutablescpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/JavaScriptCore/builtins/BuiltinExecutables.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/JavaScriptCore/builtins/BuiltinExecutables.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/JavaScriptCore/builtins/BuiltinExecutables.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -108,7 +108,7 @@
</span><span class="cx"> return functionExecutable;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void BuiltinExecutables::finalize(Handle<Unknown>, void* context)
</del><ins>+void BuiltinExecutables::finalize(JSCell*&, void* context)
</ins><span class="cx"> {
</span><span class="cx"> static_cast<Weak<UnlinkedFunctionExecutable>*>(context)->clear();
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceJavaScriptCorebuiltinsBuiltinExecutablesh"></a>
<div class="modfile"><h4>Modified: trunk/Source/JavaScriptCore/builtins/BuiltinExecutables.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/JavaScriptCore/builtins/BuiltinExecutables.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/JavaScriptCore/builtins/BuiltinExecutables.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -53,7 +53,7 @@
</span><span class="cx"> UnlinkedFunctionExecutable* createDefaultConstructor(ConstructorKind, const Identifier& name);
</span><span class="cx">
</span><span class="cx"> private:
</span><del>- void finalize(Handle<Unknown>, void* context) override;
</del><ins>+ void finalize(JSCell*&, void* context) override;
</ins><span class="cx">
</span><span class="cx"> VM& m_vm;
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceJavaScriptCoreheapHeapcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/JavaScriptCore/heap/Heap.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/JavaScriptCore/heap/Heap.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/JavaScriptCore/heap/Heap.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -1383,15 +1383,14 @@
</span><span class="cx">
</span><span class="cx"> void Heap::addFinalizer(JSCell* cell, Finalizer finalizer)
</span><span class="cx"> {
</span><del>- WeakSet::allocate(cell, &m_finalizerOwner, reinterpret_cast<void*>(finalizer)); // Balanced by FinalizerOwner::finalize().
</del><ins>+ WeakSet::allocate(*cell, &m_finalizerOwner, reinterpret_cast<void*>(finalizer)); // Balanced by FinalizerOwner::finalize().
</ins><span class="cx"> }
</span><span class="cx">
</span><del>-void Heap::FinalizerOwner::finalize(Handle<Unknown> handle, void* context)
</del><ins>+void Heap::FinalizerOwner::finalize(JSCell*& cell, void* context)
</ins><span class="cx"> {
</span><del>- HandleSlot slot = handle.slot();
</del><span class="cx"> Finalizer finalizer = reinterpret_cast<Finalizer>(context);
</span><del>- finalizer(slot->asCell());
- WeakSet::deallocate(WeakImpl::asWeakImpl(slot));
</del><ins>+ finalizer(cell);
+ WeakSet::deallocate(WeakImpl::asWeakImpl(&cell));
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> void Heap::addExecutable(ExecutableBase* executable)
</span></span></pre></div>
<a id="trunkSourceJavaScriptCoreheapHeaph"></a>
<div class="modfile"><h4>Modified: trunk/Source/JavaScriptCore/heap/Heap.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/JavaScriptCore/heap/Heap.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/JavaScriptCore/heap/Heap.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -268,8 +268,8 @@
</span><span class="cx">
</span><span class="cx"> static const size_t minExtraMemory = 256;
</span><span class="cx">
</span><del>- class FinalizerOwner : public WeakHandleOwner {
- virtual void finalize(Handle<Unknown>, void* context) override;
</del><ins>+ class FinalizerOwner final : public WeakHandleOwner {
+ void finalize(JSCell*&, void* context) override;
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> JS_EXPORT_PRIVATE bool isValidAllocation(size_t);
</span></span></pre></div>
<a id="trunkSourceJavaScriptCoreheapWeakBlockcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/JavaScriptCore/heap/WeakBlock.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/JavaScriptCore/heap/WeakBlock.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/JavaScriptCore/heap/WeakBlock.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -112,18 +112,17 @@
</span><span class="cx"> if (weakImpl->state() != WeakImpl::Live)
</span><span class="cx"> continue;
</span><span class="cx">
</span><del>- const JSValue& jsValue = weakImpl->jsValue();
- if (m_markedBlock->isMarkedOrNewlyAllocated(jsValue.asCell()))
</del><ins>+ if (m_markedBlock->isMarkedOrNewlyAllocated(weakImpl->m_cell))
</ins><span class="cx"> continue;
</span><span class="cx">
</span><span class="cx"> WeakHandleOwner* weakHandleOwner = weakImpl->weakHandleOwner();
</span><span class="cx"> if (!weakHandleOwner)
</span><span class="cx"> continue;
</span><span class="cx">
</span><del>- if (!weakHandleOwner->isReachableFromOpaqueRoots(Handle<Unknown>::wrapSlot(&const_cast<JSValue&>(jsValue)), weakImpl->context(), visitor))
</del><ins>+ if (!weakHandleOwner->isReachableFromOpaqueRoots(*weakImpl->m_cell, weakImpl->context(), visitor))
</ins><span class="cx"> continue;
</span><span class="cx">
</span><del>- heapRootVisitor.visit(&const_cast<JSValue&>(jsValue));
</del><ins>+ heapRootVisitor.visit(&weakImpl->m_cell);
</ins><span class="cx"> }
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -144,7 +143,7 @@
</span><span class="cx"> if (weakImpl->state() > WeakImpl::Dead)
</span><span class="cx"> continue;
</span><span class="cx">
</span><del>- if (m_markedBlock->isMarkedOrNewlyAllocated(weakImpl->jsValue().asCell())) {
</del><ins>+ if (m_markedBlock->isMarkedOrNewlyAllocated(weakImpl->cell())) {
</ins><span class="cx"> ASSERT(weakImpl->state() == WeakImpl::Live);
</span><span class="cx"> continue;
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceJavaScriptCoreheapWeakHandleOwnercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/JavaScriptCore/heap/WeakHandleOwner.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/JavaScriptCore/heap/WeakHandleOwner.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/JavaScriptCore/heap/WeakHandleOwner.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -37,12 +37,12 @@
</span><span class="cx"> {
</span><span class="cx"> }
</span><span class="cx">
</span><del>-bool WeakHandleOwner::isReachableFromOpaqueRoots(Handle<Unknown>, void*, SlotVisitor&)
</del><ins>+bool WeakHandleOwner::isReachableFromOpaqueRoots(JSCell&, void*, SlotVisitor&)
</ins><span class="cx"> {
</span><span class="cx"> return false;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void WeakHandleOwner::finalize(Handle<Unknown>, void*)
</del><ins>+void WeakHandleOwner::finalize(JSCell*&, void*)
</ins><span class="cx"> {
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceJavaScriptCoreheapWeakHandleOwnerh"></a>
<div class="modfile"><h4>Modified: trunk/Source/JavaScriptCore/heap/WeakHandleOwner.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/JavaScriptCore/heap/WeakHandleOwner.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/JavaScriptCore/heap/WeakHandleOwner.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -35,8 +35,8 @@
</span><span class="cx"> class JS_EXPORT_PRIVATE WeakHandleOwner {
</span><span class="cx"> public:
</span><span class="cx"> virtual ~WeakHandleOwner();
</span><del>- virtual bool isReachableFromOpaqueRoots(Handle<Unknown>, void* context, SlotVisitor&);
- virtual void finalize(Handle<Unknown>, void* context);
</del><ins>+ virtual bool isReachableFromOpaqueRoots(JSCell&, void* context, SlotVisitor&);
+ virtual void finalize(JSCell*&, void* context);
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> } // namespace JSC
</span></span></pre></div>
<a id="trunkSourceJavaScriptCoreheapWeakImplh"></a>
<div class="modfile"><h4>Modified: trunk/Source/JavaScriptCore/heap/WeakImpl.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/JavaScriptCore/heap/WeakImpl.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/JavaScriptCore/heap/WeakImpl.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -1,5 +1,5 @@
</span><span class="cx"> /*
</span><del>- * Copyright (C) 2012 Apple Inc. All rights reserved.
</del><ins>+ * Copyright (C) 2012-2015 Apple Inc. All rights reserved.
</ins><span class="cx"> *
</span><span class="cx"> * Redistribution and use in source and binary forms, with or without
</span><span class="cx"> * modification, are permitted provided that the following conditions
</span><span class="lines">@@ -46,40 +46,39 @@
</span><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> WeakImpl();
</span><del>- WeakImpl(JSValue, WeakHandleOwner*, void* context);
</del><ins>+ WeakImpl(JSCell&, WeakHandleOwner*, void* context);
</ins><span class="cx">
</span><del>- State state();
</del><ins>+ State state() const;
</ins><span class="cx"> void setState(State);
</span><span class="cx">
</span><del>- const JSValue& jsValue();
</del><ins>+ JSCell* cell();
</ins><span class="cx"> WeakHandleOwner* weakHandleOwner();
</span><span class="cx"> void* context();
</span><span class="cx">
</span><del>- static WeakImpl* asWeakImpl(JSValue*);
</del><ins>+ static WeakImpl* asWeakImpl(JSCell**);
</ins><span class="cx">
</span><span class="cx"> private:
</span><del>- const JSValue m_jsValue;
- WeakHandleOwner* m_weakHandleOwner;
- void* m_context;
</del><ins>+ friend class WeakBlock;
+
+ JSCell* m_cell { nullptr };
+ WeakHandleOwner* m_weakHandleOwner { nullptr };
+ void* m_context { nullptr };
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> inline WeakImpl::WeakImpl()
</span><del>- : m_weakHandleOwner(0)
- , m_context(0)
</del><span class="cx"> {
</span><span class="cx"> setState(Deallocated);
</span><span class="cx"> }
</span><span class="cx">
</span><del>-inline WeakImpl::WeakImpl(JSValue jsValue, WeakHandleOwner* weakHandleOwner, void* context)
- : m_jsValue(jsValue)
</del><ins>+inline WeakImpl::WeakImpl(JSCell& cell, WeakHandleOwner* weakHandleOwner, void* context)
+ : m_cell(&cell)
</ins><span class="cx"> , m_weakHandleOwner(weakHandleOwner)
</span><span class="cx"> , m_context(context)
</span><span class="cx"> {
</span><span class="cx"> ASSERT(state() == Live);
</span><del>- ASSERT(m_jsValue && m_jsValue.isCell());
</del><span class="cx"> }
</span><span class="cx">
</span><del>-inline WeakImpl::State WeakImpl::state()
</del><ins>+inline WeakImpl::State WeakImpl::state() const
</ins><span class="cx"> {
</span><span class="cx"> return static_cast<State>(reinterpret_cast<uintptr_t>(m_weakHandleOwner) & StateMask);
</span><span class="cx"> }
</span><span class="lines">@@ -90,9 +89,9 @@
</span><span class="cx"> m_weakHandleOwner = reinterpret_cast<WeakHandleOwner*>((reinterpret_cast<uintptr_t>(m_weakHandleOwner) & ~StateMask) | state);
</span><span class="cx"> }
</span><span class="cx">
</span><del>-inline const JSValue& WeakImpl::jsValue()
</del><ins>+inline JSCell* WeakImpl::cell()
</ins><span class="cx"> {
</span><del>- return m_jsValue;
</del><ins>+ return m_cell;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> inline WeakHandleOwner* WeakImpl::weakHandleOwner()
</span><span class="lines">@@ -105,9 +104,9 @@
</span><span class="cx"> return m_context;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-inline WeakImpl* WeakImpl::asWeakImpl(JSValue* slot)
</del><ins>+inline WeakImpl* WeakImpl::asWeakImpl(JSCell** slot)
</ins><span class="cx"> {
</span><del>- return reinterpret_cast_ptr<WeakImpl*>(reinterpret_cast_ptr<char*>(slot) + OBJECT_OFFSETOF(WeakImpl, m_jsValue));
</del><ins>+ return reinterpret_cast_ptr<WeakImpl*>(reinterpret_cast_ptr<char*>(slot));
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> } // namespace JSC
</span></span></pre></div>
<a id="trunkSourceJavaScriptCoreheapWeakInlinesh"></a>
<div class="modfile"><h4>Modified: trunk/Source/JavaScriptCore/heap/WeakInlines.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/JavaScriptCore/heap/WeakInlines.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/JavaScriptCore/heap/WeakInlines.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -34,8 +34,9 @@
</span><span class="cx"> namespace JSC {
</span><span class="cx">
</span><span class="cx"> template<typename T> inline Weak<T>::Weak(T* cell, WeakHandleOwner* weakOwner, void* context)
</span><del>- : m_impl(cell ? WeakSet::allocate(cell, weakOwner, context) : 0)
</del><ins>+ : m_impl(cell ? WeakSet::allocate(*cell, weakOwner, context) : 0)
</ins><span class="cx"> {
</span><ins>+ static_assert((std::is_convertible<T, JSCell>::value), "JSC::Weak can only be used with cell types.");
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> template<typename T> inline bool Weak<T>::isHashTableDeletedValue() const
</span><span class="lines">@@ -73,30 +74,30 @@
</span><span class="cx"> template<typename T> inline T* Weak<T>::operator->() const
</span><span class="cx"> {
</span><span class="cx"> ASSERT(m_impl && m_impl->state() == WeakImpl::Live);
</span><del>- return jsCast<T*>(m_impl->jsValue().asCell());
</del><ins>+ return jsCast<T*>(m_impl->cell());
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> template<typename T> inline T& Weak<T>::operator*() const
</span><span class="cx"> {
</span><span class="cx"> ASSERT(m_impl && m_impl->state() == WeakImpl::Live);
</span><del>- return *jsCast<T*>(m_impl->jsValue().asCell());
</del><ins>+ return *jsCast<T*>(m_impl->cell());
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> template<typename T> inline T* Weak<T>::get() const
</span><span class="cx"> {
</span><span class="cx"> if (!m_impl || m_impl->state() != WeakImpl::Live)
</span><span class="cx"> return 0;
</span><del>- return jsCast<T*>(m_impl->jsValue().asCell());
</del><ins>+ return jsCast<T*>(m_impl->cell());
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> template<typename T> inline bool Weak<T>::was(T* other) const
</span><span class="cx"> {
</span><del>- return static_cast<T*>(m_impl->jsValue().asCell()) == other;
</del><ins>+ return static_cast<T*>(m_impl->cell()) == other;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> template<typename T> inline bool Weak<T>::operator!() const
</span><span class="cx"> {
</span><del>- return !m_impl || !m_impl->jsValue() || m_impl->state() != WeakImpl::Live;
</del><ins>+ return !m_impl || !m_impl->cell() || m_impl->state() != WeakImpl::Live;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> template<typename T> inline Weak<T>::operator bool() const
</span></span></pre></div>
<a id="trunkSourceJavaScriptCoreheapWeakSeth"></a>
<div class="modfile"><h4>Modified: trunk/Source/JavaScriptCore/heap/WeakSet.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/JavaScriptCore/heap/WeakSet.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/JavaScriptCore/heap/WeakSet.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -38,7 +38,7 @@
</span><span class="cx"> friend class LLIntOffsetsExtractor;
</span><span class="cx">
</span><span class="cx"> public:
</span><del>- static WeakImpl* allocate(JSValue, WeakHandleOwner* = 0, void* context = 0);
</del><ins>+ static WeakImpl* allocate(JSCell&, WeakHandleOwner* = 0, void* context = 0);
</ins><span class="cx"> static void deallocate(WeakImpl*);
</span><span class="cx">
</span><span class="cx"> WeakSet(VM*, MarkedBlock&);
</span></span></pre></div>
<a id="trunkSourceJavaScriptCoreheapWeakSetInlinesh"></a>
<div class="modfile"><h4>Modified: trunk/Source/JavaScriptCore/heap/WeakSetInlines.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/JavaScriptCore/heap/WeakSetInlines.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/JavaScriptCore/heap/WeakSetInlines.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -30,16 +30,16 @@
</span><span class="cx">
</span><span class="cx"> namespace JSC {
</span><span class="cx">
</span><del>-inline WeakImpl* WeakSet::allocate(JSValue jsValue, WeakHandleOwner* weakHandleOwner, void* context)
</del><ins>+inline WeakImpl* WeakSet::allocate(JSCell& cell, WeakHandleOwner* weakHandleOwner, void* context)
</ins><span class="cx"> {
</span><del>- WeakSet& weakSet = MarkedBlock::blockFor(jsValue.asCell())->weakSet();
</del><ins>+ WeakSet& weakSet = MarkedBlock::blockFor(&cell)->weakSet();
</ins><span class="cx"> WeakBlock::FreeCell* allocator = weakSet.m_allocator;
</span><span class="cx"> if (UNLIKELY(!allocator))
</span><span class="cx"> allocator = weakSet.findAllocator();
</span><span class="cx"> weakSet.m_allocator = allocator->next;
</span><span class="cx">
</span><span class="cx"> WeakImpl* weakImpl = WeakBlock::asWeakImpl(allocator);
</span><del>- return new (NotNull, weakImpl) WeakImpl(jsValue, weakHandleOwner, context);
</del><ins>+ return new (NotNull, weakImpl) WeakImpl(cell, weakHandleOwner, context);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> inline void WeakBlock::finalize(WeakImpl* weakImpl)
</span><span class="lines">@@ -49,7 +49,7 @@
</span><span class="cx"> WeakHandleOwner* weakHandleOwner = weakImpl->weakHandleOwner();
</span><span class="cx"> if (!weakHandleOwner)
</span><span class="cx"> return;
</span><del>- weakHandleOwner->finalize(Handle<Unknown>::wrapSlot(&const_cast<JSValue&>(weakImpl->jsValue())), weakImpl->context());
</del><ins>+ weakHandleOwner->finalize(weakImpl->m_cell, weakImpl->context());
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> } // namespace JSC
</span></span></pre></div>
<a id="trunkSourceJavaScriptCorejitJITThunkscpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/JavaScriptCore/jit/JITThunks.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/JavaScriptCore/jit/JITThunks.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/JavaScriptCore/jit/JITThunks.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -76,9 +76,9 @@
</span><span class="cx"> return entry.iterator->value;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void JITThunks::finalize(Handle<Unknown> handle, void*)
</del><ins>+void JITThunks::finalize(JSCell*& cell, void*)
</ins><span class="cx"> {
</span><del>- auto* nativeExecutable = jsCast<NativeExecutable*>(handle.get().asCell());
</del><ins>+ auto* nativeExecutable = jsCast<NativeExecutable*>(cell);
</ins><span class="cx"> weakRemove(*m_hostFunctionStubMap, std::make_pair(nativeExecutable->function(), nativeExecutable->constructor()), nativeExecutable);
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceJavaScriptCorejitJITThunksh"></a>
<div class="modfile"><h4>Modified: trunk/Source/JavaScriptCore/jit/JITThunks.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/JavaScriptCore/jit/JITThunks.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/JavaScriptCore/jit/JITThunks.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -63,7 +63,7 @@
</span><span class="cx"> void clearHostFunctionStubs();
</span><span class="cx">
</span><span class="cx"> private:
</span><del>- void finalize(Handle<Unknown>, void* context) override;
</del><ins>+ void finalize(JSCell*&, void* context) override;
</ins><span class="cx">
</span><span class="cx"> typedef HashMap<ThunkGenerator, MacroAssemblerCodeRef> CTIStubMap;
</span><span class="cx"> CTIStubMap m_ctiStubMap;
</span></span></pre></div>
<a id="trunkSourceJavaScriptCorejsccpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/JavaScriptCore/jsc.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/JavaScriptCore/jsc.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/JavaScriptCore/jsc.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -176,12 +176,12 @@
</span><span class="cx"> WriteBarrier<Root> m_root;
</span><span class="cx"> };
</span><span class="cx">
</span><del>-class ElementHandleOwner : public WeakHandleOwner {
</del><ins>+class ElementHandleOwner final : public WeakHandleOwner {
</ins><span class="cx"> public:
</span><del>- virtual bool isReachableFromOpaqueRoots(Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor)
</del><ins>+ virtual bool isReachableFromOpaqueRoots(JSCell& cell, void*, SlotVisitor& visitor)
</ins><span class="cx"> {
</span><del>- Element* element = jsCast<Element*>(handle.slot()->asCell());
- return visitor.containsOpaqueRoot(element->root());
</del><ins>+ auto& element = jsCast<Element&>(cell);
+ return visitor.containsOpaqueRoot(element.root());
</ins><span class="cx"> }
</span><span class="cx"> };
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceJavaScriptCoreruntimeJSCellh"></a>
<div class="modfile"><h4>Modified: trunk/Source/JavaScriptCore/runtime/JSCell.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/JavaScriptCore/runtime/JSCell.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/JavaScriptCore/runtime/JSCell.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -245,6 +245,13 @@
</span><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> template<typename To, typename From>
</span><ins>+inline To& jsCast(From& from)
+{
+ ASSERT_WITH_SECURITY_IMPLICATION(from.JSCell::inherits(std::remove_reference<To>::type::info()));
+ return static_cast<To&>(from);
+}
+
+template<typename To, typename From>
</ins><span class="cx"> inline To jsCast(From* from)
</span><span class="cx"> {
</span><span class="cx"> ASSERT_WITH_SECURITY_IMPLICATION(!from || from->JSCell::inherits(std::remove_pointer<To>::type::info()));
</span></span></pre></div>
<a id="trunkSourceJavaScriptCoreruntimeRegExpCachecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/JavaScriptCore/runtime/RegExpCache.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/JavaScriptCore/runtime/RegExpCache.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/JavaScriptCore/runtime/RegExpCache.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -56,9 +56,9 @@
</span><span class="cx"> {
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void RegExpCache::finalize(Handle<Unknown> handle, void*)
</del><ins>+void RegExpCache::finalize(JSCell*& cell, void*)
</ins><span class="cx"> {
</span><del>- RegExp* regExp = static_cast<RegExp*>(handle.get().asCell());
</del><ins>+ RegExp* regExp = jsCast<RegExp*>(cell);
</ins><span class="cx"> weakRemove(m_weakCache, regExp->key(), regExp);
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceJavaScriptCoreruntimeRegExpCacheh"></a>
<div class="modfile"><h4>Modified: trunk/Source/JavaScriptCore/runtime/RegExpCache.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/JavaScriptCore/runtime/RegExpCache.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/JavaScriptCore/runtime/RegExpCache.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -54,7 +54,7 @@
</span><span class="cx">
</span><span class="cx"> static const int maxStrongCacheableEntries = 32;
</span><span class="cx">
</span><del>- virtual void finalize(Handle<Unknown>, void* context) override;
</del><ins>+ void finalize(JSCell*&, void* context) override;
</ins><span class="cx">
</span><span class="cx"> RegExp* lookupOrCreate(const WTF::String& patternString, RegExpFlags);
</span><span class="cx"> void addToStrongCache(RegExp*);
</span></span></pre></div>
<a id="trunkSourceJavaScriptCoreruntimeStructurecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/JavaScriptCore/runtime/Structure.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/JavaScriptCore/runtime/Structure.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/JavaScriptCore/runtime/Structure.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -62,7 +62,7 @@
</span><span class="cx"> #endif
</span><span class="cx">
</span><span class="cx"> class SingleSlotTransitionWeakOwner final : public WeakHandleOwner {
</span><del>- void finalize(Handle<Unknown>, void* context) override
</del><ins>+ void finalize(JSCell*&, void* context) override
</ins><span class="cx"> {
</span><span class="cx"> StructureTransitionTable* table = reinterpret_cast<StructureTransitionTable*>(context);
</span><span class="cx"> ASSERT(table->isUsingSingleSlot());
</span><span class="lines">@@ -82,7 +82,7 @@
</span><span class="cx"> ASSERT(isUsingSingleSlot());
</span><span class="cx"> if (WeakImpl* impl = this->weakImpl()) {
</span><span class="cx"> if (impl->state() == WeakImpl::Live)
</span><del>- return jsCast<Structure*>(impl->jsValue().asCell());
</del><ins>+ return jsCast<Structure*>(impl->cell());
</ins><span class="cx"> }
</span><span class="cx"> return nullptr;
</span><span class="cx"> }
</span><span class="lines">@@ -92,7 +92,7 @@
</span><span class="cx"> ASSERT(isUsingSingleSlot());
</span><span class="cx"> if (WeakImpl* impl = this->weakImpl())
</span><span class="cx"> WeakSet::deallocate(impl);
</span><del>- WeakImpl* impl = WeakSet::allocate(structure, &singleSlotTransitionWeakOwner(), this);
</del><ins>+ WeakImpl* impl = WeakSet::allocate(*structure, &singleSlotTransitionWeakOwner(), this);
</ins><span class="cx"> m_data = reinterpret_cast<intptr_t>(impl) | UsingSingleSlotFlag;
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/ChangeLog        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -1,3 +1,112 @@
</span><ins>+2015-09-11 Andreas Kling <akling@apple.com>
+
+ [JSC] Weak should only accept cell pointees.
+ <https://webkit.org/b/148955>
+
+ Reviewed by Geoffrey Garen.
+
+ Update WebCore bindings for the new Weak and Weak-related signatures.
+
+ * bindings/js/JSCSSRuleListCustom.cpp:
+ (WebCore::JSCSSRuleListOwner::isReachableFromOpaqueRoots):
+ * bindings/js/JSCSSValueCustom.cpp:
+ (WebCore::JSCSSValueOwner::isReachableFromOpaqueRoots):
+ (WebCore::JSCSSValueOwner::finalize):
+ * bindings/js/JSCallbackData.cpp:
+ (WebCore::JSCallbackDataWeak::WeakOwner::isReachableFromOpaqueRoots):
+ * bindings/js/JSCallbackData.h:
+ * bindings/js/JSMutationObserverCustom.cpp:
+ (WebCore::JSMutationObserverOwner::isReachableFromOpaqueRoots):
+ * bindings/js/JSNodeCustom.cpp:
+ (WebCore::isReachableFromDOM):
+ (WebCore::JSNodeOwner::isReachableFromOpaqueRoots):
+ * bindings/js/JSNodeListCustom.cpp:
+ (WebCore::JSNodeListOwner::isReachableFromOpaqueRoots):
+ * bindings/js/JSTextTrackCueCustom.cpp:
+ (WebCore::JSTextTrackCueOwner::isReachableFromOpaqueRoots):
+ * bindings/js/WebCoreTypedArrayController.cpp:
+ (WebCore::WebCoreTypedArrayController::JSArrayBufferOwner::isReachableFromOpaqueRoots):
+ (WebCore::WebCoreTypedArrayController::JSArrayBufferOwner::finalize):
+ * bindings/js/WebCoreTypedArrayController.h:
+ * bindings/scripts/CodeGeneratorJS.pm:
+ (GenerateHeader):
+ (GenerateImplementation):
+ * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
+ (WebCore::JSTestActiveDOMObjectOwner::isReachableFromOpaqueRoots):
+ (WebCore::JSTestActiveDOMObjectOwner::finalize):
+ * bindings/scripts/test/JS/JSTestActiveDOMObject.h:
+ * bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.cpp:
+ (WebCore::JSTestCustomConstructorWithNoInterfaceObjectOwner::isReachableFromOpaqueRoots):
+ (WebCore::JSTestCustomConstructorWithNoInterfaceObjectOwner::finalize):
+ * bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.h:
+ * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
+ (WebCore::JSTestCustomNamedGetterOwner::isReachableFromOpaqueRoots):
+ (WebCore::JSTestCustomNamedGetterOwner::finalize):
+ * bindings/scripts/test/JS/JSTestCustomNamedGetter.h:
+ * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
+ (WebCore::JSTestEventConstructorOwner::isReachableFromOpaqueRoots):
+ (WebCore::JSTestEventConstructorOwner::finalize):
+ * bindings/scripts/test/JS/JSTestEventConstructor.h:
+ * bindings/scripts/test/JS/JSTestEventTarget.cpp:
+ (WebCore::JSTestEventTargetOwner::isReachableFromOpaqueRoots):
+ (WebCore::JSTestEventTargetOwner::finalize):
+ * bindings/scripts/test/JS/JSTestEventTarget.h:
+ * bindings/scripts/test/JS/JSTestException.cpp:
+ (WebCore::JSTestExceptionOwner::isReachableFromOpaqueRoots):
+ (WebCore::JSTestExceptionOwner::finalize):
+ * bindings/scripts/test/JS/JSTestException.h:
+ * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
+ (WebCore::JSTestGenerateIsReachableOwner::isReachableFromOpaqueRoots):
+ (WebCore::JSTestGenerateIsReachableOwner::finalize):
+ * bindings/scripts/test/JS/JSTestGenerateIsReachable.h:
+ * bindings/scripts/test/JS/JSTestInterface.cpp:
+ (WebCore::JSTestInterfaceOwner::isReachableFromOpaqueRoots):
+ (WebCore::JSTestInterfaceOwner::finalize):
+ * bindings/scripts/test/JS/JSTestInterface.h:
+ * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
+ (WebCore::JSTestMediaQueryListListenerOwner::isReachableFromOpaqueRoots):
+ (WebCore::JSTestMediaQueryListListenerOwner::finalize):
+ * bindings/scripts/test/JS/JSTestMediaQueryListListener.h:
+ * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
+ (WebCore::JSTestNamedConstructorOwner::isReachableFromOpaqueRoots):
+ (WebCore::JSTestNamedConstructorOwner::finalize):
+ * bindings/scripts/test/JS/JSTestNamedConstructor.h:
+ * bindings/scripts/test/JS/JSTestNondeterministic.cpp:
+ (WebCore::JSTestNondeterministicOwner::isReachableFromOpaqueRoots):
+ (WebCore::JSTestNondeterministicOwner::finalize):
+ * bindings/scripts/test/JS/JSTestNondeterministic.h:
+ * bindings/scripts/test/JS/JSTestObj.cpp:
+ (WebCore::JSTestObjOwner::isReachableFromOpaqueRoots):
+ (WebCore::JSTestObjOwner::finalize):
+ * bindings/scripts/test/JS/JSTestObj.h:
+ * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
+ (WebCore::JSTestOverloadedConstructorsOwner::isReachableFromOpaqueRoots):
+ (WebCore::JSTestOverloadedConstructorsOwner::finalize):
+ * bindings/scripts/test/JS/JSTestOverloadedConstructors.h:
+ * bindings/scripts/test/JS/JSTestOverrideBuiltins.cpp:
+ (WebCore::JSTestOverrideBuiltinsOwner::isReachableFromOpaqueRoots):
+ (WebCore::JSTestOverrideBuiltinsOwner::finalize):
+ * bindings/scripts/test/JS/JSTestOverrideBuiltins.h:
+ * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
+ (WebCore::JSTestSerializedScriptValueInterfaceOwner::isReachableFromOpaqueRoots):
+ (WebCore::JSTestSerializedScriptValueInterfaceOwner::finalize):
+ * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h:
+ * bindings/scripts/test/JS/JSTestTypedefs.cpp:
+ (WebCore::JSTestTypedefsOwner::isReachableFromOpaqueRoots):
+ (WebCore::JSTestTypedefsOwner::finalize):
+ * bindings/scripts/test/JS/JSTestTypedefs.h:
+ * bindings/scripts/test/JS/JSattribute.cpp:
+ (WebCore::JSattributeOwner::isReachableFromOpaqueRoots):
+ (WebCore::JSattributeOwner::finalize):
+ * bindings/scripts/test/JS/JSattribute.h:
+ * bindings/scripts/test/JS/JSreadonly.cpp:
+ (WebCore::JSreadonlyOwner::isReachableFromOpaqueRoots):
+ (WebCore::JSreadonlyOwner::finalize):
+ * bindings/scripts/test/JS/JSreadonly.h:
+ * bridge/runtime_root.cpp:
+ (JSC::Bindings::RootObject::finalize):
+ * bridge/runtime_root.h:
+
</ins><span class="cx"> 2015-09-10 Chris Fleizach <cfleizach@apple.com>
</span><span class="cx">
</span><span class="cx"> AX: Mavericks: Text cursor does not move along with VoiceOver cursor for text fields
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSCSSRuleListCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSCSSRuleListCustom.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSCSSRuleListCustom.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/js/JSCSSRuleListCustom.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -36,14 +36,14 @@
</span><span class="cx">
</span><span class="cx"> namespace WebCore {
</span><span class="cx">
</span><del>-bool JSCSSRuleListOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor)
</del><ins>+bool JSCSSRuleListOwner::isReachableFromOpaqueRoots(JSC::JSCell& cell, void*, SlotVisitor& visitor)
</ins><span class="cx"> {
</span><del>- JSCSSRuleList* jsCSSRuleList = jsCast<JSCSSRuleList*>(handle.slot()->asCell());
- if (!jsCSSRuleList->hasCustomProperties())
</del><ins>+ auto& jsCSSRuleList = jsCast<JSCSSRuleList&>(cell);
+ if (!jsCSSRuleList.hasCustomProperties())
</ins><span class="cx"> return false;
</span><del>- if (CSSStyleSheet* styleSheet = jsCSSRuleList->impl().styleSheet())
</del><ins>+ if (CSSStyleSheet* styleSheet = jsCSSRuleList.impl().styleSheet())
</ins><span class="cx"> return visitor.containsOpaqueRoot(root(styleSheet));
</span><del>- if (CSSRule* cssRule = jsCSSRuleList->impl().item(0))
</del><ins>+ if (CSSRule* cssRule = jsCSSRuleList.impl().item(0))
</ins><span class="cx"> return visitor.containsOpaqueRoot(root(cssRule));
</span><span class="cx"> return false;
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSCSSValueCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSCSSValueCustom.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSCSSValueCustom.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/js/JSCSSValueCustom.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -44,24 +44,24 @@
</span><span class="cx">
</span><span class="cx"> namespace WebCore {
</span><span class="cx">
</span><del>-bool JSCSSValueOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void* context, SlotVisitor& visitor)
</del><ins>+bool JSCSSValueOwner::isReachableFromOpaqueRoots(JSC::JSCell& cell, void* context, SlotVisitor& visitor)
</ins><span class="cx"> {
</span><del>- JSCSSValue* jsCSSValue = jsCast<JSCSSValue*>(handle.slot()->asCell());
- if (!jsCSSValue->hasCustomProperties())
</del><ins>+ auto& jsCSSValue = jsCast<JSCSSValue&>(cell);
+ if (!jsCSSValue.hasCustomProperties())
</ins><span class="cx"> return false;
</span><del>- DOMWrapperWorld* world = static_cast<DOMWrapperWorld*>(context);
- void* root = world->m_cssValueRoots.get(&jsCSSValue->impl());
</del><ins>+ DOMWrapperWorld& world = *static_cast<DOMWrapperWorld*>(context);
+ void* root = world.m_cssValueRoots.get(&jsCSSValue.impl());
</ins><span class="cx"> if (!root)
</span><span class="cx"> return false;
</span><span class="cx"> return visitor.containsOpaqueRoot(root);
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void JSCSSValueOwner::finalize(JSC::Handle<JSC::Unknown> handle, void* context)
</del><ins>+void JSCSSValueOwner::finalize(JSC::JSCell*& cell, void* context)
</ins><span class="cx"> {
</span><del>- JSCSSValue* jsCSSValue = jsCast<JSCSSValue*>(handle.slot()->asCell());
</del><ins>+ auto& jsCSSValue = jsCast<JSCSSValue&>(*cell);
</ins><span class="cx"> DOMWrapperWorld& world = *static_cast<DOMWrapperWorld*>(context);
</span><del>- world.m_cssValueRoots.remove(&jsCSSValue->impl());
- uncacheWrapper(world, &jsCSSValue->impl(), jsCSSValue);
</del><ins>+ world.m_cssValueRoots.remove(&jsCSSValue.impl());
+ uncacheWrapper(world, &jsCSSValue.impl(), &jsCSSValue);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> JSValue toJS(ExecState*, JSDOMGlobalObject* globalObject, CSSValue* value)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSCallbackDatacpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSCallbackData.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSCallbackData.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/js/JSCallbackData.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -90,7 +90,7 @@
</span><span class="cx"> return result;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-bool JSCallbackDataWeak::WeakOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, SlotVisitor& visitor)
</del><ins>+bool JSCallbackDataWeak::WeakOwner::isReachableFromOpaqueRoots(JSC::JSCell&, void* context, SlotVisitor& visitor)
</ins><span class="cx"> {
</span><span class="cx"> return visitor.containsOpaqueRoot(context);
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSCallbackDatah"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSCallbackData.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSCallbackData.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/js/JSCallbackData.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -105,8 +105,8 @@
</span><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> private:
</span><del>- class WeakOwner : public JSC::WeakHandleOwner {
- virtual bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&);
</del><ins>+ class WeakOwner final : public JSC::WeakHandleOwner {
+ bool isReachableFromOpaqueRoots(JSC::JSCell&, void* context, JSC::SlotVisitor&) override;
</ins><span class="cx"> };
</span><span class="cx"> WeakOwner m_weakOwner;
</span><span class="cx"> JSC::Weak<JSC::JSObject> m_callback;
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSMutationObserverCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSMutationObserverCustom.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSMutationObserverCustom.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/js/JSMutationObserverCustom.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -61,9 +61,9 @@
</span><span class="cx"> return JSValue::encode(jsObserver);
</span><span class="cx"> }
</span><span class="cx">
</span><del>-bool JSMutationObserverOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor)
</del><ins>+bool JSMutationObserverOwner::isReachableFromOpaqueRoots(JSC::JSCell& cell, void*, SlotVisitor& visitor)
</ins><span class="cx"> {
</span><del>- MutationObserver& observer = jsCast<JSMutationObserver*>(handle.slot()->asCell())->impl();
</del><ins>+ MutationObserver& observer = jsCast<JSMutationObserver&>(cell).impl();
</ins><span class="cx"> auto observedNodes = observer.getObservedNodes();
</span><span class="cx"> for (auto it = observedNodes.begin(), end = observedNodes.end(); it != end; ++it) {
</span><span class="cx"> if (visitor.containsOpaqueRoot(root(*it)))
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSNodeCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSNodeCustom.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSNodeCustom.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/js/JSNodeCustom.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -75,11 +75,11 @@
</span><span class="cx">
</span><span class="cx"> using namespace HTMLNames;
</span><span class="cx">
</span><del>-static inline bool isReachableFromDOM(Node* node, SlotVisitor& visitor)
</del><ins>+static inline bool isReachableFromDOM(Node& node, SlotVisitor& visitor)
</ins><span class="cx"> {
</span><del>- if (!node->inDocument()) {
- if (is<Element>(*node)) {
- auto& element = downcast<Element>(*node);
</del><ins>+ if (!node.inDocument()) {
+ if (is<Element>(node)) {
+ auto& element = downcast<Element>(node);
</ins><span class="cx">
</span><span class="cx"> // If a wrapper is the last reference to an image element
</span><span class="cx"> // that is loading but not in the document, the wrapper is observable
</span><span class="lines">@@ -100,17 +100,17 @@
</span><span class="cx">
</span><span class="cx"> // If a node is firing event listeners, its wrapper is observable because
</span><span class="cx"> // its wrapper is responsible for marking those event listeners.
</span><del>- if (node->isFiringEventListeners())
</del><ins>+ if (node.isFiringEventListeners())
</ins><span class="cx"> return true;
</span><span class="cx"> }
</span><span class="cx">
</span><del>- return visitor.containsOpaqueRoot(root(node));
</del><ins>+ return visitor.containsOpaqueRoot(root(&node));
</ins><span class="cx"> }
</span><span class="cx">
</span><del>-bool JSNodeOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor)
</del><ins>+bool JSNodeOwner::isReachableFromOpaqueRoots(JSC::JSCell& cell, void*, SlotVisitor& visitor)
</ins><span class="cx"> {
</span><del>- JSNode* jsNode = jsCast<JSNode*>(handle.slot()->asCell());
- return isReachableFromDOM(&jsNode->impl(), visitor);
</del><ins>+ auto& jsNode = jsCast<JSNode&>(cell);
+ return isReachableFromDOM(jsNode.impl(), visitor);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> JSValue JSNode::insertBefore(ExecState* exec)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSNodeListCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSNodeListCustom.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSNodeListCustom.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/js/JSNodeListCustom.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -37,17 +37,17 @@
</span><span class="cx">
</span><span class="cx"> namespace WebCore {
</span><span class="cx">
</span><del>-bool JSNodeListOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor)
</del><ins>+bool JSNodeListOwner::isReachableFromOpaqueRoots(JSC::JSCell& cell, void*, SlotVisitor& visitor)
</ins><span class="cx"> {
</span><del>- JSNodeList* jsNodeList = jsCast<JSNodeList*>(handle.slot()->asCell());
- if (!jsNodeList->hasCustomProperties())
</del><ins>+ auto& jsNodeList = jsCast<JSNodeList&>(cell);
+ if (!jsNodeList.hasCustomProperties())
</ins><span class="cx"> return false;
</span><del>- if (jsNodeList->impl().isLiveNodeList())
- return visitor.containsOpaqueRoot(root(static_cast<LiveNodeList&>(jsNodeList->impl()).ownerNode()));
- if (jsNodeList->impl().isChildNodeList())
- return visitor.containsOpaqueRoot(root(static_cast<ChildNodeList&>(jsNodeList->impl()).ownerNode()));
- if (jsNodeList->impl().isEmptyNodeList())
- return visitor.containsOpaqueRoot(root(static_cast<EmptyNodeList&>(jsNodeList->impl()).ownerNode()));
</del><ins>+ if (jsNodeList.impl().isLiveNodeList())
+ return visitor.containsOpaqueRoot(root(static_cast<LiveNodeList&>(jsNodeList.impl()).ownerNode()));
+ if (jsNodeList.impl().isChildNodeList())
+ return visitor.containsOpaqueRoot(root(static_cast<ChildNodeList&>(jsNodeList.impl()).ownerNode()));
+ if (jsNodeList.impl().isEmptyNodeList())
+ return visitor.containsOpaqueRoot(root(static_cast<EmptyNodeList&>(jsNodeList.impl()).ownerNode()));
</ins><span class="cx"> return false;
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSTextTrackCueCustomcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSTextTrackCueCustom.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSTextTrackCueCustom.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/js/JSTextTrackCueCustom.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -38,10 +38,10 @@
</span><span class="cx">
</span><span class="cx"> namespace WebCore {
</span><span class="cx">
</span><del>-bool JSTextTrackCueOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor)
</del><ins>+bool JSTextTrackCueOwner::isReachableFromOpaqueRoots(JSC::JSCell& cell, void*, SlotVisitor& visitor)
</ins><span class="cx"> {
</span><del>- JSTextTrackCue* jsTextTrackCue = jsCast<JSTextTrackCue*>(handle.slot()->asCell());
- TextTrackCue& textTrackCue = jsTextTrackCue->impl();
</del><ins>+ auto& jsTextTrackCue = jsCast<JSTextTrackCue&>(cell);
+ TextTrackCue& textTrackCue = jsTextTrackCue.impl();
</ins><span class="cx">
</span><span class="cx"> // If the cue is firing event listeners, its wrapper is reachable because
</span><span class="cx"> // the wrapper is responsible for marking those event listeners.
</span><span class="lines">@@ -49,7 +49,7 @@
</span><span class="cx"> return true;
</span><span class="cx">
</span><span class="cx"> // If the cue has no event listeners and has no custom properties, it is not reachable.
</span><del>- if (!textTrackCue.hasEventListeners() && !jsTextTrackCue->hasCustomProperties())
</del><ins>+ if (!textTrackCue.hasEventListeners() && !jsTextTrackCue.hasCustomProperties())
</ins><span class="cx"> return false;
</span><span class="cx">
</span><span class="cx"> // If the cue is not associated with a track, it is not reachable.
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsWebCoreTypedArrayControllercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/WebCoreTypedArrayController.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/WebCoreTypedArrayController.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/js/WebCoreTypedArrayController.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -47,17 +47,17 @@
</span><span class="cx"> return JSC::jsCast<JSC::JSArrayBuffer*>(WebCore::toJS(state, JSC::jsCast<JSDOMGlobalObject*>(globalObject), buffer));
</span><span class="cx"> }
</span><span class="cx">
</span><del>-bool WebCoreTypedArrayController::JSArrayBufferOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, JSC::SlotVisitor& visitor)
</del><ins>+bool WebCoreTypedArrayController::JSArrayBufferOwner::isReachableFromOpaqueRoots(JSC::JSCell& cell, void*, JSC::SlotVisitor& visitor)
</ins><span class="cx"> {
</span><del>- auto& wrapper = *JSC::jsCast<JSC::JSArrayBuffer*>(handle.slot()->asCell());
</del><ins>+ auto& wrapper = JSC::jsCast<JSC::JSArrayBuffer&>(cell);
</ins><span class="cx"> if (!wrapper.hasCustomProperties())
</span><span class="cx"> return false;
</span><span class="cx"> return visitor.containsOpaqueRoot(wrapper.impl());
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void WebCoreTypedArrayController::JSArrayBufferOwner::finalize(JSC::Handle<JSC::Unknown> handle, void* context)
</del><ins>+void WebCoreTypedArrayController::JSArrayBufferOwner::finalize(JSC::JSCell*& cell, void* context)
</ins><span class="cx"> {
</span><del>- auto& wrapper = *static_cast<JSC::JSArrayBuffer*>(handle.slot()->asCell());
</del><ins>+ auto& wrapper = static_cast<JSC::JSArrayBuffer&>(*cell);
</ins><span class="cx"> auto& buffer = *wrapper.impl();
</span><span class="cx"> uncacheWrapper(*static_cast<DOMWrapperWorld*>(context), &buffer, &wrapper);
</span><span class="cx"> buffer.deref();
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsWebCoreTypedArrayControllerh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/WebCoreTypedArrayController.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/WebCoreTypedArrayController.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/js/WebCoreTypedArrayController.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -35,7 +35,7 @@
</span><span class="cx">
</span><span class="cx"> namespace WebCore {
</span><span class="cx">
</span><del>-class WebCoreTypedArrayController : public JSC::TypedArrayController {
</del><ins>+class WebCoreTypedArrayController final : public JSC::TypedArrayController {
</ins><span class="cx"> public:
</span><span class="cx"> WebCoreTypedArrayController();
</span><span class="cx"> virtual ~WebCoreTypedArrayController();
</span><span class="lines">@@ -45,10 +45,10 @@
</span><span class="cx"> JSC::WeakHandleOwner* wrapperOwner() { return &m_owner; }
</span><span class="cx">
</span><span class="cx"> private:
</span><del>- class JSArrayBufferOwner : public JSC::WeakHandleOwner {
</del><ins>+ class JSArrayBufferOwner final : public JSC::WeakHandleOwner {
</ins><span class="cx"> public:
</span><del>- virtual bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&) override;
- virtual void finalize(JSC::Handle<JSC::Unknown>, void* context) override;
</del><ins>+ bool isReachableFromOpaqueRoots(JSC::JSCell&, void* context, JSC::SlotVisitor&) override;
+ void finalize(JSC::JSCell*&, void* context) override;
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> JSArrayBufferOwner m_owner;
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptsCodeGeneratorJSpm"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -1191,8 +1191,8 @@
</span><span class="cx"> }
</span><span class="cx"> $headerIncludes{"<wtf/NeverDestroyed.h>"} = 1;
</span><span class="cx"> push(@headerContent, "public:\n");
</span><del>- push(@headerContent, " virtual bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&);\n");
- push(@headerContent, " virtual void finalize(JSC::Handle<JSC::Unknown>, void* context);\n");
</del><ins>+ push(@headerContent, " bool isReachableFromOpaqueRoots(JSC::JSCell&, void* context, JSC::SlotVisitor&) override;\n");
+ push(@headerContent, " void finalize(JSC::JSCell*&, void* context) override;\n");
</ins><span class="cx"> push(@headerContent, "};\n");
</span><span class="cx"> push(@headerContent, "\n");
</span><span class="cx"> push(@headerContent, "inline JSC::WeakHandleOwner* wrapperOwner(DOMWrapperWorld&, $implType*)\n");
</span><span class="lines">@@ -2945,7 +2945,7 @@
</span><span class="cx">
</span><span class="cx"> if ((!$hasParent && !GetCustomIsReachable($interface)) || GetGenerateIsReachable($interface) || $codeGenerator->InheritsExtendedAttribute($interface, "ActiveDOMObject")) {
</span><span class="cx">
</span><del>- push(@implContent, "bool JS${interfaceName}Owner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor)\n");
</del><ins>+ push(@implContent, "bool JS${interfaceName}Owner::isReachableFromOpaqueRoots(JSC::JSCell& cell, void*, SlotVisitor& visitor)\n");
</ins><span class="cx"> push(@implContent, "{\n");
</span><span class="cx"> # All ActiveDOMObjects implement hasPendingActivity(), but not all of them
</span><span class="cx"> # increment their C++ reference counts when hasPendingActivity() becomes
</span><span class="lines">@@ -2956,70 +2956,70 @@
</span><span class="cx"> # check just above the (GetGenerateIsReachable($interface) eq "Impl") check below.
</span><span class="cx"> my $emittedJSCast = 0;
</span><span class="cx"> if ($codeGenerator->InheritsExtendedAttribute($interface, "ActiveDOMObject")) {
</span><del>- push(@implContent, " auto* js${interfaceName} = jsCast<JS${interfaceName}*>(handle.slot()->asCell());\n");
</del><ins>+ push(@implContent, " auto& js${interfaceName} = jsCast<JS${interfaceName}&>(cell);\n");
</ins><span class="cx"> $emittedJSCast = 1;
</span><del>- push(@implContent, " if (js${interfaceName}->impl().hasPendingActivity())\n");
</del><ins>+ push(@implContent, " if (js${interfaceName}.impl().hasPendingActivity())\n");
</ins><span class="cx"> push(@implContent, " return true;\n");
</span><span class="cx"> }
</span><span class="cx"> if ($codeGenerator->InheritsExtendedAttribute($interface, "EventTarget")) {
</span><span class="cx"> if (!$emittedJSCast) {
</span><del>- push(@implContent, " auto* js${interfaceName} = jsCast<JS${interfaceName}*>(handle.slot()->asCell());\n");
</del><ins>+ push(@implContent, " auto& js${interfaceName} = jsCast<JS${interfaceName}&>(cell);\n");
</ins><span class="cx"> $emittedJSCast = 1;
</span><span class="cx"> }
</span><del>- push(@implContent, " if (js${interfaceName}->impl().isFiringEventListeners())\n");
</del><ins>+ push(@implContent, " if (js${interfaceName}.impl().isFiringEventListeners())\n");
</ins><span class="cx"> push(@implContent, " return true;\n");
</span><span class="cx"> }
</span><span class="cx"> if ($codeGenerator->InheritsInterface($interface, "Node")) {
</span><span class="cx"> if (!$emittedJSCast) {
</span><del>- push(@implContent, " auto* js${interfaceName} = jsCast<JS${interfaceName}*>(handle.slot()->asCell());\n");
</del><ins>+ push(@implContent, " auto& js${interfaceName} = jsCast<JS${interfaceName}&>(cell);\n");
</ins><span class="cx"> $emittedJSCast = 1;
</span><span class="cx"> }
</span><del>- push(@implContent, " if (JSNodeOwner::isReachableFromOpaqueRoots(handle, 0, visitor))\n");
</del><ins>+ push(@implContent, " if (JSNodeOwner::isReachableFromOpaqueRoots(cell, 0, visitor))\n");
</ins><span class="cx"> push(@implContent, " return true;\n");
</span><span class="cx"> }
</span><span class="cx"> if (GetGenerateIsReachable($interface)) {
</span><span class="cx"> if (!$emittedJSCast) {
</span><del>- push(@implContent, " auto* js${interfaceName} = jsCast<JS${interfaceName}*>(handle.slot()->asCell());\n");
</del><ins>+ push(@implContent, " auto& js${interfaceName} = jsCast<JS${interfaceName}&>(cell);\n");
</ins><span class="cx"> $emittedJSCast = 1;
</span><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> my $rootString;
</span><span class="cx"> if (GetGenerateIsReachable($interface) eq "Impl") {
</span><del>- $rootString = " ${implType}* root = &js${interfaceName}->impl();\n";
</del><ins>+ $rootString = " ${implType}* root = &js${interfaceName}.impl();\n";
</ins><span class="cx"> } elsif (GetGenerateIsReachable($interface) eq "ImplWebGLRenderingContext") {
</span><del>- $rootString = " WebGLRenderingContextBase* root = WTF::getPtr(js${interfaceName}->impl().context());\n";
</del><ins>+ $rootString = " WebGLRenderingContextBase* root = WTF::getPtr(js${interfaceName}.impl().context());\n";
</ins><span class="cx"> } elsif (GetGenerateIsReachable($interface) eq "ImplFrame") {
</span><del>- $rootString = " Frame* root = WTF::getPtr(js${interfaceName}->impl().frame());\n";
</del><ins>+ $rootString = " Frame* root = WTF::getPtr(js${interfaceName}.impl().frame());\n";
</ins><span class="cx"> $rootString .= " if (!root)\n";
</span><span class="cx"> $rootString .= " return false;\n";
</span><span class="cx"> } elsif (GetGenerateIsReachable($interface) eq "ImplDocument") {
</span><del>- $rootString = " Document* root = WTF::getPtr(js${interfaceName}->impl().document());\n";
</del><ins>+ $rootString = " Document* root = WTF::getPtr(js${interfaceName}.impl().document());\n";
</ins><span class="cx"> $rootString .= " if (!root)\n";
</span><span class="cx"> $rootString .= " return false;\n";
</span><span class="cx"> } elsif (GetGenerateIsReachable($interface) eq "ImplElementRoot") {
</span><span class="cx"> $implIncludes{"Element.h"} = 1;
</span><span class="cx"> $implIncludes{"JSNodeCustom.h"} = 1;
</span><del>- $rootString = " Element* element = WTF::getPtr(js${interfaceName}->impl().element());\n";
</del><ins>+ $rootString = " Element* element = WTF::getPtr(js${interfaceName}.impl().element());\n";
</ins><span class="cx"> $rootString .= " if (!element)\n";
</span><span class="cx"> $rootString .= " return false;\n";
</span><span class="cx"> $rootString .= " void* root = WebCore::root(element);\n";
</span><span class="cx"> } elsif ($interfaceName eq "CanvasRenderingContext") {
</span><span class="cx"> $implIncludes{"Element.h"} = 1;
</span><span class="cx"> $implIncludes{"JSNodeCustom.h"} = 1;
</span><del>- $rootString = " void* root = WebCore::root(js${interfaceName}->impl().canvas());\n";
</del><ins>+ $rootString = " void* root = WebCore::root(js${interfaceName}.impl().canvas());\n";
</ins><span class="cx"> } elsif (GetGenerateIsReachable($interface) eq "ImplOwnerNodeRoot") {
</span><span class="cx"> $implIncludes{"Element.h"} = 1;
</span><span class="cx"> $implIncludes{"JSNodeCustom.h"} = 1;
</span><del>- $rootString = " void* root = WebCore::root(js${interfaceName}->impl().ownerNode());\n";
</del><ins>+ $rootString = " void* root = WebCore::root(js${interfaceName}.impl().ownerNode());\n";
</ins><span class="cx"> } else {
</span><del>- $rootString = " void* root = WebCore::root(&js${interfaceName}->impl());\n";
</del><ins>+ $rootString = " void* root = WebCore::root(&js${interfaceName}.impl());\n";
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> push(@implContent, $rootString);
</span><span class="cx"> push(@implContent, " return visitor.containsOpaqueRoot(root);\n");
</span><span class="cx"> } else {
</span><span class="cx"> if (!$emittedJSCast) {
</span><del>- push(@implContent, " UNUSED_PARAM(handle);\n");
</del><ins>+ push(@implContent, " UNUSED_PARAM(cell);\n");
</ins><span class="cx"> }
</span><span class="cx"> push(@implContent, " UNUSED_PARAM(visitor);\n");
</span><span class="cx"> push(@implContent, " return false;\n");
</span><span class="lines">@@ -3032,11 +3032,11 @@
</span><span class="cx"> GetGenerateIsReachable($interface) ||
</span><span class="cx"> GetCustomIsReachable($interface) ||
</span><span class="cx"> $codeGenerator->InheritsExtendedAttribute($interface, "ActiveDOMObject"))) {
</span><del>- push(@implContent, "void JS${interfaceName}Owner::finalize(JSC::Handle<JSC::Unknown> handle, void* context)\n");
</del><ins>+ push(@implContent, "void JS${interfaceName}Owner::finalize(JSC::JSCell*& cell, void* context)\n");
</ins><span class="cx"> push(@implContent, "{\n");
</span><del>- push(@implContent, " auto* js${interfaceName} = jsCast<JS${interfaceName}*>(handle.slot()->asCell());\n");
</del><ins>+ push(@implContent, " auto& wrapper = jsCast<JS${interfaceName}&>(*cell);\n");
</ins><span class="cx"> push(@implContent, " auto& world = *static_cast<DOMWrapperWorld*>(context);\n");
</span><del>- push(@implContent, " uncacheWrapper(world, &js${interfaceName}->impl(), js${interfaceName});\n");
</del><ins>+ push(@implContent, " uncacheWrapper(world, &wrapper.impl(), &wrapper);\n");
</ins><span class="cx"> push(@implContent, "}\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 (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestActiveDOMObject.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestActiveDOMObject.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -240,18 +240,18 @@
</span><span class="cx"> return JSValue::encode(jsUndefined());
</span><span class="cx"> }
</span><span class="cx">
</span><del>-bool JSTestActiveDOMObjectOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor)
</del><ins>+bool JSTestActiveDOMObjectOwner::isReachableFromOpaqueRoots(JSC::JSCell& cell, void*, SlotVisitor& visitor)
</ins><span class="cx"> {
</span><del>- UNUSED_PARAM(handle);
</del><ins>+ UNUSED_PARAM(cell);
</ins><span class="cx"> UNUSED_PARAM(visitor);
</span><span class="cx"> return false;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void JSTestActiveDOMObjectOwner::finalize(JSC::Handle<JSC::Unknown> handle, void* context)
</del><ins>+void JSTestActiveDOMObjectOwner::finalize(JSC::JSCell*& cell, void* context)
</ins><span class="cx"> {
</span><del>- auto* jsTestActiveDOMObject = jsCast<JSTestActiveDOMObject*>(handle.slot()->asCell());
</del><ins>+ auto& wrapper = jsCast<JSTestActiveDOMObject&>(*cell);
</ins><span class="cx"> auto& world = *static_cast<DOMWrapperWorld*>(context);
</span><del>- uncacheWrapper(world, &jsTestActiveDOMObject->impl(), jsTestActiveDOMObject);
</del><ins>+ uncacheWrapper(world, &wrapper.impl(), &wrapper);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestActiveDOMObjecth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestActiveDOMObject.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestActiveDOMObject.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestActiveDOMObject.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -72,8 +72,8 @@
</span><span class="cx">
</span><span class="cx"> class JSTestActiveDOMObjectOwner : public JSC::WeakHandleOwner {
</span><span class="cx"> public:
</span><del>- virtual bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&);
- virtual void finalize(JSC::Handle<JSC::Unknown>, void* context);
</del><ins>+ bool isReachableFromOpaqueRoots(JSC::JSCell&, void* context, JSC::SlotVisitor&) override;
+ void finalize(JSC::JSCell*&, void* context) override;
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> inline JSC::WeakHandleOwner* wrapperOwner(DOMWrapperWorld&, TestActiveDOMObject*)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestCustomConstructorWithNoInterfaceObjectcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -157,18 +157,18 @@
</span><span class="cx"> return JSValue::encode(constructor);
</span><span class="cx"> }
</span><span class="cx">
</span><del>-bool JSTestCustomConstructorWithNoInterfaceObjectOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor)
</del><ins>+bool JSTestCustomConstructorWithNoInterfaceObjectOwner::isReachableFromOpaqueRoots(JSC::JSCell& cell, void*, SlotVisitor& visitor)
</ins><span class="cx"> {
</span><del>- UNUSED_PARAM(handle);
</del><ins>+ UNUSED_PARAM(cell);
</ins><span class="cx"> UNUSED_PARAM(visitor);
</span><span class="cx"> return false;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void JSTestCustomConstructorWithNoInterfaceObjectOwner::finalize(JSC::Handle<JSC::Unknown> handle, void* context)
</del><ins>+void JSTestCustomConstructorWithNoInterfaceObjectOwner::finalize(JSC::JSCell*& cell, void* context)
</ins><span class="cx"> {
</span><del>- auto* jsTestCustomConstructorWithNoInterfaceObject = jsCast<JSTestCustomConstructorWithNoInterfaceObject*>(handle.slot()->asCell());
</del><ins>+ auto& wrapper = jsCast<JSTestCustomConstructorWithNoInterfaceObject&>(*cell);
</ins><span class="cx"> auto& world = *static_cast<DOMWrapperWorld*>(context);
</span><del>- uncacheWrapper(world, &jsTestCustomConstructorWithNoInterfaceObject->impl(), jsTestCustomConstructorWithNoInterfaceObject);
</del><ins>+ uncacheWrapper(world, &wrapper.impl(), &wrapper);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestCustomConstructorWithNoInterfaceObjecth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -68,8 +68,8 @@
</span><span class="cx">
</span><span class="cx"> class JSTestCustomConstructorWithNoInterfaceObjectOwner : public JSC::WeakHandleOwner {
</span><span class="cx"> public:
</span><del>- virtual bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&);
- virtual void finalize(JSC::Handle<JSC::Unknown>, void* context);
</del><ins>+ bool isReachableFromOpaqueRoots(JSC::JSCell&, void* context, JSC::SlotVisitor&) override;
+ void finalize(JSC::JSCell*&, void* context) override;
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> inline JSC::WeakHandleOwner* wrapperOwner(DOMWrapperWorld&, TestCustomConstructorWithNoInterfaceObject*)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestCustomNamedGettercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -225,18 +225,18 @@
</span><span class="cx"> return JSValue::encode(jsUndefined());
</span><span class="cx"> }
</span><span class="cx">
</span><del>-bool JSTestCustomNamedGetterOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor)
</del><ins>+bool JSTestCustomNamedGetterOwner::isReachableFromOpaqueRoots(JSC::JSCell& cell, void*, SlotVisitor& visitor)
</ins><span class="cx"> {
</span><del>- UNUSED_PARAM(handle);
</del><ins>+ UNUSED_PARAM(cell);
</ins><span class="cx"> UNUSED_PARAM(visitor);
</span><span class="cx"> return false;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void JSTestCustomNamedGetterOwner::finalize(JSC::Handle<JSC::Unknown> handle, void* context)
</del><ins>+void JSTestCustomNamedGetterOwner::finalize(JSC::JSCell*& cell, void* context)
</ins><span class="cx"> {
</span><del>- auto* jsTestCustomNamedGetter = jsCast<JSTestCustomNamedGetter*>(handle.slot()->asCell());
</del><ins>+ auto& wrapper = jsCast<JSTestCustomNamedGetter&>(*cell);
</ins><span class="cx"> auto& world = *static_cast<DOMWrapperWorld*>(context);
</span><del>- uncacheWrapper(world, &jsTestCustomNamedGetter->impl(), jsTestCustomNamedGetter);
</del><ins>+ uncacheWrapper(world, &wrapper.impl(), &wrapper);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestCustomNamedGetterh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCustomNamedGetter.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCustomNamedGetter.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCustomNamedGetter.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -75,8 +75,8 @@
</span><span class="cx">
</span><span class="cx"> class JSTestCustomNamedGetterOwner : public JSC::WeakHandleOwner {
</span><span class="cx"> public:
</span><del>- virtual bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&);
- virtual void finalize(JSC::Handle<JSC::Unknown>, void* context);
</del><ins>+ bool isReachableFromOpaqueRoots(JSC::JSCell&, void* context, JSC::SlotVisitor&) override;
+ void finalize(JSC::JSCell*&, void* context) override;
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> inline JSC::WeakHandleOwner* wrapperOwner(DOMWrapperWorld&, TestCustomNamedGetter*)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestEventConstructorcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventConstructor.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventConstructor.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventConstructor.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -241,18 +241,18 @@
</span><span class="cx"> return getDOMConstructor<JSTestEventConstructorConstructor>(vm, jsCast<JSDOMGlobalObject*>(globalObject));
</span><span class="cx"> }
</span><span class="cx">
</span><del>-bool JSTestEventConstructorOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor)
</del><ins>+bool JSTestEventConstructorOwner::isReachableFromOpaqueRoots(JSC::JSCell& cell, void*, SlotVisitor& visitor)
</ins><span class="cx"> {
</span><del>- UNUSED_PARAM(handle);
</del><ins>+ UNUSED_PARAM(cell);
</ins><span class="cx"> UNUSED_PARAM(visitor);
</span><span class="cx"> return false;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void JSTestEventConstructorOwner::finalize(JSC::Handle<JSC::Unknown> handle, void* context)
</del><ins>+void JSTestEventConstructorOwner::finalize(JSC::JSCell*& cell, void* context)
</ins><span class="cx"> {
</span><del>- auto* jsTestEventConstructor = jsCast<JSTestEventConstructor*>(handle.slot()->asCell());
</del><ins>+ auto& wrapper = jsCast<JSTestEventConstructor&>(*cell);
</ins><span class="cx"> auto& world = *static_cast<DOMWrapperWorld*>(context);
</span><del>- uncacheWrapper(world, &jsTestEventConstructor->impl(), jsTestEventConstructor);
</del><ins>+ uncacheWrapper(world, &wrapper.impl(), &wrapper);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestEventConstructorh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventConstructor.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventConstructor.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventConstructor.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -71,8 +71,8 @@
</span><span class="cx">
</span><span class="cx"> class JSTestEventConstructorOwner : public JSC::WeakHandleOwner {
</span><span class="cx"> public:
</span><del>- virtual bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&);
- virtual void finalize(JSC::Handle<JSC::Unknown>, void* context);
</del><ins>+ bool isReachableFromOpaqueRoots(JSC::JSCell&, void* context, JSC::SlotVisitor&) override;
+ void finalize(JSC::JSCell*&, void* context) override;
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> inline JSC::WeakHandleOwner* wrapperOwner(DOMWrapperWorld&, TestEventConstructor*)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestEventTargetcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventTarget.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventTarget.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventTarget.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -320,20 +320,20 @@
</span><span class="cx"> thisObject->impl().visitJSEventListeners(visitor);
</span><span class="cx"> }
</span><span class="cx">
</span><del>-bool JSTestEventTargetOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor)
</del><ins>+bool JSTestEventTargetOwner::isReachableFromOpaqueRoots(JSC::JSCell& cell, void*, SlotVisitor& visitor)
</ins><span class="cx"> {
</span><del>- auto* jsTestEventTarget = jsCast<JSTestEventTarget*>(handle.slot()->asCell());
- if (jsTestEventTarget->impl().isFiringEventListeners())
</del><ins>+ auto& jsTestEventTarget = jsCast<JSTestEventTarget&>(cell);
+ if (jsTestEventTarget.impl().isFiringEventListeners())
</ins><span class="cx"> return true;
</span><span class="cx"> UNUSED_PARAM(visitor);
</span><span class="cx"> return false;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void JSTestEventTargetOwner::finalize(JSC::Handle<JSC::Unknown> handle, void* context)
</del><ins>+void JSTestEventTargetOwner::finalize(JSC::JSCell*& cell, void* context)
</ins><span class="cx"> {
</span><del>- auto* jsTestEventTarget = jsCast<JSTestEventTarget*>(handle.slot()->asCell());
</del><ins>+ auto& wrapper = jsCast<JSTestEventTarget&>(*cell);
</ins><span class="cx"> auto& world = *static_cast<DOMWrapperWorld*>(context);
</span><del>- uncacheWrapper(world, &jsTestEventTarget->impl(), jsTestEventTarget);
</del><ins>+ uncacheWrapper(world, &wrapper.impl(), &wrapper);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestEventTargeth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventTarget.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventTarget.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventTarget.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -79,8 +79,8 @@
</span><span class="cx">
</span><span class="cx"> class JSTestEventTargetOwner : public JSC::WeakHandleOwner {
</span><span class="cx"> public:
</span><del>- virtual bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&);
- virtual void finalize(JSC::Handle<JSC::Unknown>, void* context);
</del><ins>+ bool isReachableFromOpaqueRoots(JSC::JSCell&, void* context, JSC::SlotVisitor&) override;
+ void finalize(JSC::JSCell*&, void* context) override;
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> inline JSC::WeakHandleOwner* wrapperOwner(DOMWrapperWorld&, TestEventTarget*)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestExceptioncpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestException.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestException.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestException.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -190,18 +190,18 @@
</span><span class="cx"> return getDOMConstructor<JSTestExceptionConstructor>(vm, jsCast<JSDOMGlobalObject*>(globalObject));
</span><span class="cx"> }
</span><span class="cx">
</span><del>-bool JSTestExceptionOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor)
</del><ins>+bool JSTestExceptionOwner::isReachableFromOpaqueRoots(JSC::JSCell& cell, void*, SlotVisitor& visitor)
</ins><span class="cx"> {
</span><del>- UNUSED_PARAM(handle);
</del><ins>+ UNUSED_PARAM(cell);
</ins><span class="cx"> UNUSED_PARAM(visitor);
</span><span class="cx"> return false;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void JSTestExceptionOwner::finalize(JSC::Handle<JSC::Unknown> handle, void* context)
</del><ins>+void JSTestExceptionOwner::finalize(JSC::JSCell*& cell, void* context)
</ins><span class="cx"> {
</span><del>- auto* jsTestException = jsCast<JSTestException*>(handle.slot()->asCell());
</del><ins>+ auto& wrapper = jsCast<JSTestException&>(*cell);
</ins><span class="cx"> auto& world = *static_cast<DOMWrapperWorld*>(context);
</span><del>- uncacheWrapper(world, &jsTestException->impl(), jsTestException);
</del><ins>+ uncacheWrapper(world, &wrapper.impl(), &wrapper);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestExceptionh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestException.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestException.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestException.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -73,8 +73,8 @@
</span><span class="cx">
</span><span class="cx"> class JSTestExceptionOwner : public JSC::WeakHandleOwner {
</span><span class="cx"> public:
</span><del>- virtual bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&);
- virtual void finalize(JSC::Handle<JSC::Unknown>, void* context);
</del><ins>+ bool isReachableFromOpaqueRoots(JSC::JSCell&, void* context, JSC::SlotVisitor&) override;
+ void finalize(JSC::JSCell*&, void* context) override;
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> inline JSC::WeakHandleOwner* wrapperOwner(DOMWrapperWorld&, TestException*)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestGenerateIsReachablecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -152,18 +152,18 @@
</span><span class="cx"> return getDOMConstructor<JSTestGenerateIsReachableConstructor>(vm, jsCast<JSDOMGlobalObject*>(globalObject));
</span><span class="cx"> }
</span><span class="cx">
</span><del>-bool JSTestGenerateIsReachableOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor)
</del><ins>+bool JSTestGenerateIsReachableOwner::isReachableFromOpaqueRoots(JSC::JSCell& cell, void*, SlotVisitor& visitor)
</ins><span class="cx"> {
</span><del>- auto* jsTestGenerateIsReachable = jsCast<JSTestGenerateIsReachable*>(handle.slot()->asCell());
- TestGenerateIsReachable* root = &jsTestGenerateIsReachable->impl();
</del><ins>+ auto& jsTestGenerateIsReachable = jsCast<JSTestGenerateIsReachable&>(cell);
+ TestGenerateIsReachable* root = &jsTestGenerateIsReachable.impl();
</ins><span class="cx"> return visitor.containsOpaqueRoot(root);
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void JSTestGenerateIsReachableOwner::finalize(JSC::Handle<JSC::Unknown> handle, void* context)
</del><ins>+void JSTestGenerateIsReachableOwner::finalize(JSC::JSCell*& cell, void* context)
</ins><span class="cx"> {
</span><del>- auto* jsTestGenerateIsReachable = jsCast<JSTestGenerateIsReachable*>(handle.slot()->asCell());
</del><ins>+ auto& wrapper = jsCast<JSTestGenerateIsReachable&>(*cell);
</ins><span class="cx"> auto& world = *static_cast<DOMWrapperWorld*>(context);
</span><del>- uncacheWrapper(world, &jsTestGenerateIsReachable->impl(), jsTestGenerateIsReachable);
</del><ins>+ uncacheWrapper(world, &wrapper.impl(), &wrapper);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestGenerateIsReachableh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestGenerateIsReachable.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestGenerateIsReachable.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestGenerateIsReachable.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -69,8 +69,8 @@
</span><span class="cx">
</span><span class="cx"> class JSTestGenerateIsReachableOwner : public JSC::WeakHandleOwner {
</span><span class="cx"> public:
</span><del>- virtual bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&);
- virtual void finalize(JSC::Handle<JSC::Unknown>, void* context);
</del><ins>+ bool isReachableFromOpaqueRoots(JSC::JSCell&, void* context, JSC::SlotVisitor&) override;
+ void finalize(JSC::JSCell*&, void* context) override;
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> inline JSC::WeakHandleOwner* wrapperOwner(DOMWrapperWorld&, TestGenerateIsReachable*)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestInterfacecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestInterface.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestInterface.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestInterface.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -939,20 +939,20 @@
</span><span class="cx">
</span><span class="cx"> #endif
</span><span class="cx">
</span><del>-bool JSTestInterfaceOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor)
</del><ins>+bool JSTestInterfaceOwner::isReachableFromOpaqueRoots(JSC::JSCell& cell, void*, SlotVisitor& visitor)
</ins><span class="cx"> {
</span><del>- auto* jsTestInterface = jsCast<JSTestInterface*>(handle.slot()->asCell());
- if (jsTestInterface->impl().hasPendingActivity())
</del><ins>+ auto& jsTestInterface = jsCast<JSTestInterface&>(cell);
+ if (jsTestInterface.impl().hasPendingActivity())
</ins><span class="cx"> return true;
</span><span class="cx"> UNUSED_PARAM(visitor);
</span><span class="cx"> return false;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void JSTestInterfaceOwner::finalize(JSC::Handle<JSC::Unknown> handle, void* context)
</del><ins>+void JSTestInterfaceOwner::finalize(JSC::JSCell*& cell, void* context)
</ins><span class="cx"> {
</span><del>- auto* jsTestInterface = jsCast<JSTestInterface*>(handle.slot()->asCell());
</del><ins>+ auto& wrapper = jsCast<JSTestInterface&>(*cell);
</ins><span class="cx"> auto& world = *static_cast<DOMWrapperWorld*>(context);
</span><del>- uncacheWrapper(world, &jsTestInterface->impl(), jsTestInterface);
</del><ins>+ uncacheWrapper(world, &wrapper.impl(), &wrapper);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, TestInterface* impl)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestInterfaceh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestInterface.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestInterface.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestInterface.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -99,8 +99,8 @@
</span><span class="cx">
</span><span class="cx"> class JSTestInterfaceOwner : public JSC::WeakHandleOwner {
</span><span class="cx"> public:
</span><del>- virtual bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&);
- virtual void finalize(JSC::Handle<JSC::Unknown>, void* context);
</del><ins>+ bool isReachableFromOpaqueRoots(JSC::JSCell&, void* context, JSC::SlotVisitor&) override;
+ void finalize(JSC::JSCell*&, void* context) override;
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> inline JSC::WeakHandleOwner* wrapperOwner(DOMWrapperWorld&, TestInterface*)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestMediaQueryListListenercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -177,18 +177,18 @@
</span><span class="cx"> return JSValue::encode(jsUndefined());
</span><span class="cx"> }
</span><span class="cx">
</span><del>-bool JSTestMediaQueryListListenerOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor)
</del><ins>+bool JSTestMediaQueryListListenerOwner::isReachableFromOpaqueRoots(JSC::JSCell& cell, void*, SlotVisitor& visitor)
</ins><span class="cx"> {
</span><del>- UNUSED_PARAM(handle);
</del><ins>+ UNUSED_PARAM(cell);
</ins><span class="cx"> UNUSED_PARAM(visitor);
</span><span class="cx"> return false;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void JSTestMediaQueryListListenerOwner::finalize(JSC::Handle<JSC::Unknown> handle, void* context)
</del><ins>+void JSTestMediaQueryListListenerOwner::finalize(JSC::JSCell*& cell, void* context)
</ins><span class="cx"> {
</span><del>- auto* jsTestMediaQueryListListener = jsCast<JSTestMediaQueryListListener*>(handle.slot()->asCell());
</del><ins>+ auto& wrapper = jsCast<JSTestMediaQueryListListener&>(*cell);
</ins><span class="cx"> auto& world = *static_cast<DOMWrapperWorld*>(context);
</span><del>- uncacheWrapper(world, &jsTestMediaQueryListListener->impl(), jsTestMediaQueryListListener);
</del><ins>+ uncacheWrapper(world, &wrapper.impl(), &wrapper);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestMediaQueryListListenerh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestMediaQueryListListener.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestMediaQueryListListener.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestMediaQueryListListener.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -69,8 +69,8 @@
</span><span class="cx">
</span><span class="cx"> class JSTestMediaQueryListListenerOwner : public JSC::WeakHandleOwner {
</span><span class="cx"> public:
</span><del>- virtual bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&);
- virtual void finalize(JSC::Handle<JSC::Unknown>, void* context);
</del><ins>+ bool isReachableFromOpaqueRoots(JSC::JSCell&, void* context, JSC::SlotVisitor&) override;
+ void finalize(JSC::JSCell*&, void* context) override;
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> inline JSC::WeakHandleOwner* wrapperOwner(DOMWrapperWorld&, TestMediaQueryListListener*)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestNamedConstructorcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedConstructor.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedConstructor.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedConstructor.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -230,20 +230,20 @@
</span><span class="cx"> return getDOMConstructor<JSTestNamedConstructorNamedConstructor>(vm, jsCast<JSDOMGlobalObject*>(globalObject));
</span><span class="cx"> }
</span><span class="cx">
</span><del>-bool JSTestNamedConstructorOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor)
</del><ins>+bool JSTestNamedConstructorOwner::isReachableFromOpaqueRoots(JSC::JSCell& cell, void*, SlotVisitor& visitor)
</ins><span class="cx"> {
</span><del>- auto* jsTestNamedConstructor = jsCast<JSTestNamedConstructor*>(handle.slot()->asCell());
- if (jsTestNamedConstructor->impl().hasPendingActivity())
</del><ins>+ auto& jsTestNamedConstructor = jsCast<JSTestNamedConstructor&>(cell);
+ if (jsTestNamedConstructor.impl().hasPendingActivity())
</ins><span class="cx"> return true;
</span><span class="cx"> UNUSED_PARAM(visitor);
</span><span class="cx"> return false;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void JSTestNamedConstructorOwner::finalize(JSC::Handle<JSC::Unknown> handle, void* context)
</del><ins>+void JSTestNamedConstructorOwner::finalize(JSC::JSCell*& cell, void* context)
</ins><span class="cx"> {
</span><del>- auto* jsTestNamedConstructor = jsCast<JSTestNamedConstructor*>(handle.slot()->asCell());
</del><ins>+ auto& wrapper = jsCast<JSTestNamedConstructor&>(*cell);
</ins><span class="cx"> auto& world = *static_cast<DOMWrapperWorld*>(context);
</span><del>- uncacheWrapper(world, &jsTestNamedConstructor->impl(), jsTestNamedConstructor);
</del><ins>+ uncacheWrapper(world, &wrapper.impl(), &wrapper);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestNamedConstructorh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedConstructor.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedConstructor.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNamedConstructor.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -70,8 +70,8 @@
</span><span class="cx">
</span><span class="cx"> class JSTestNamedConstructorOwner : public JSC::WeakHandleOwner {
</span><span class="cx"> public:
</span><del>- virtual bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&);
- virtual void finalize(JSC::Handle<JSC::Unknown>, void* context);
</del><ins>+ bool isReachableFromOpaqueRoots(JSC::JSCell&, void* context, JSC::SlotVisitor&) override;
+ void finalize(JSC::JSCell*&, void* context) override;
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> inline JSC::WeakHandleOwner* wrapperOwner(DOMWrapperWorld&, TestNamedConstructor*)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestNondeterministiccpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNondeterministic.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNondeterministic.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNondeterministic.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -483,18 +483,18 @@
</span><span class="cx"> return JSValue::encode(result);
</span><span class="cx"> }
</span><span class="cx">
</span><del>-bool JSTestNondeterministicOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor)
</del><ins>+bool JSTestNondeterministicOwner::isReachableFromOpaqueRoots(JSC::JSCell& cell, void*, SlotVisitor& visitor)
</ins><span class="cx"> {
</span><del>- UNUSED_PARAM(handle);
</del><ins>+ UNUSED_PARAM(cell);
</ins><span class="cx"> UNUSED_PARAM(visitor);
</span><span class="cx"> return false;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void JSTestNondeterministicOwner::finalize(JSC::Handle<JSC::Unknown> handle, void* context)
</del><ins>+void JSTestNondeterministicOwner::finalize(JSC::JSCell*& cell, void* context)
</ins><span class="cx"> {
</span><del>- auto* jsTestNondeterministic = jsCast<JSTestNondeterministic*>(handle.slot()->asCell());
</del><ins>+ auto& wrapper = jsCast<JSTestNondeterministic&>(*cell);
</ins><span class="cx"> auto& world = *static_cast<DOMWrapperWorld*>(context);
</span><del>- uncacheWrapper(world, &jsTestNondeterministic->impl(), jsTestNondeterministic);
</del><ins>+ uncacheWrapper(world, &wrapper.impl(), &wrapper);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestNondeterministich"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNondeterministic.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNondeterministic.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestNondeterministic.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -69,8 +69,8 @@
</span><span class="cx">
</span><span class="cx"> class JSTestNondeterministicOwner : public JSC::WeakHandleOwner {
</span><span class="cx"> public:
</span><del>- virtual bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&);
- virtual void finalize(JSC::Handle<JSC::Unknown>, void* context);
</del><ins>+ bool isReachableFromOpaqueRoots(JSC::JSCell&, void* context, JSC::SlotVisitor&) override;
+ void finalize(JSC::JSCell*&, void* context) override;
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> inline JSC::WeakHandleOwner* wrapperOwner(DOMWrapperWorld&, TestNondeterministic*)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestObjcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -4682,18 +4682,18 @@
</span><span class="cx"> visitor.append(&thisObject->m_cachedAttribute2);
</span><span class="cx"> }
</span><span class="cx">
</span><del>-bool JSTestObjOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor)
</del><ins>+bool JSTestObjOwner::isReachableFromOpaqueRoots(JSC::JSCell& cell, void*, SlotVisitor& visitor)
</ins><span class="cx"> {
</span><del>- UNUSED_PARAM(handle);
</del><ins>+ UNUSED_PARAM(cell);
</ins><span class="cx"> UNUSED_PARAM(visitor);
</span><span class="cx"> return false;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void JSTestObjOwner::finalize(JSC::Handle<JSC::Unknown> handle, void* context)
</del><ins>+void JSTestObjOwner::finalize(JSC::JSCell*& cell, void* context)
</ins><span class="cx"> {
</span><del>- auto* jsTestObj = jsCast<JSTestObj*>(handle.slot()->asCell());
</del><ins>+ auto& wrapper = jsCast<JSTestObj&>(*cell);
</ins><span class="cx"> auto& world = *static_cast<DOMWrapperWorld*>(context);
</span><del>- uncacheWrapper(world, &jsTestObj->impl(), jsTestObj);
</del><ins>+ uncacheWrapper(world, &wrapper.impl(), &wrapper);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestObjh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -85,8 +85,8 @@
</span><span class="cx">
</span><span class="cx"> class JSTestObjOwner : public JSC::WeakHandleOwner {
</span><span class="cx"> public:
</span><del>- virtual bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&);
- virtual void finalize(JSC::Handle<JSC::Unknown>, void* context);
</del><ins>+ bool isReachableFromOpaqueRoots(JSC::JSCell&, void* context, JSC::SlotVisitor&) override;
+ void finalize(JSC::JSCell*&, void* context) override;
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> inline JSC::WeakHandleOwner* wrapperOwner(DOMWrapperWorld&, TestObj*)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestOverloadedConstructorscpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -246,18 +246,18 @@
</span><span class="cx"> return getDOMConstructor<JSTestOverloadedConstructorsConstructor>(vm, jsCast<JSDOMGlobalObject*>(globalObject));
</span><span class="cx"> }
</span><span class="cx">
</span><del>-bool JSTestOverloadedConstructorsOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor)
</del><ins>+bool JSTestOverloadedConstructorsOwner::isReachableFromOpaqueRoots(JSC::JSCell& cell, void*, SlotVisitor& visitor)
</ins><span class="cx"> {
</span><del>- UNUSED_PARAM(handle);
</del><ins>+ UNUSED_PARAM(cell);
</ins><span class="cx"> UNUSED_PARAM(visitor);
</span><span class="cx"> return false;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void JSTestOverloadedConstructorsOwner::finalize(JSC::Handle<JSC::Unknown> handle, void* context)
</del><ins>+void JSTestOverloadedConstructorsOwner::finalize(JSC::JSCell*& cell, void* context)
</ins><span class="cx"> {
</span><del>- auto* jsTestOverloadedConstructors = jsCast<JSTestOverloadedConstructors*>(handle.slot()->asCell());
</del><ins>+ auto& wrapper = jsCast<JSTestOverloadedConstructors&>(*cell);
</ins><span class="cx"> auto& world = *static_cast<DOMWrapperWorld*>(context);
</span><del>- uncacheWrapper(world, &jsTestOverloadedConstructors->impl(), jsTestOverloadedConstructors);
</del><ins>+ uncacheWrapper(world, &wrapper.impl(), &wrapper);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestOverloadedConstructorsh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructors.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructors.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructors.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -69,8 +69,8 @@
</span><span class="cx">
</span><span class="cx"> class JSTestOverloadedConstructorsOwner : public JSC::WeakHandleOwner {
</span><span class="cx"> public:
</span><del>- virtual bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&);
- virtual void finalize(JSC::Handle<JSC::Unknown>, void* context);
</del><ins>+ bool isReachableFromOpaqueRoots(JSC::JSCell&, void* context, JSC::SlotVisitor&) override;
+ void finalize(JSC::JSCell*&, void* context) override;
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> inline JSC::WeakHandleOwner* wrapperOwner(DOMWrapperWorld&, TestOverloadedConstructors*)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestOverrideBuiltinscpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverrideBuiltins.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverrideBuiltins.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverrideBuiltins.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -221,18 +221,18 @@
</span><span class="cx"> return JSValue::encode(result);
</span><span class="cx"> }
</span><span class="cx">
</span><del>-bool JSTestOverrideBuiltinsOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor)
</del><ins>+bool JSTestOverrideBuiltinsOwner::isReachableFromOpaqueRoots(JSC::JSCell& cell, void*, SlotVisitor& visitor)
</ins><span class="cx"> {
</span><del>- UNUSED_PARAM(handle);
</del><ins>+ UNUSED_PARAM(cell);
</ins><span class="cx"> UNUSED_PARAM(visitor);
</span><span class="cx"> return false;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void JSTestOverrideBuiltinsOwner::finalize(JSC::Handle<JSC::Unknown> handle, void* context)
</del><ins>+void JSTestOverrideBuiltinsOwner::finalize(JSC::JSCell*& cell, void* context)
</ins><span class="cx"> {
</span><del>- auto* jsTestOverrideBuiltins = jsCast<JSTestOverrideBuiltins*>(handle.slot()->asCell());
</del><ins>+ auto& wrapper = jsCast<JSTestOverrideBuiltins&>(*cell);
</ins><span class="cx"> auto& world = *static_cast<DOMWrapperWorld*>(context);
</span><del>- uncacheWrapper(world, &jsTestOverrideBuiltins->impl(), jsTestOverrideBuiltins);
</del><ins>+ uncacheWrapper(world, &wrapper.impl(), &wrapper);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestOverrideBuiltinsh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverrideBuiltins.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverrideBuiltins.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestOverrideBuiltins.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -75,8 +75,8 @@
</span><span class="cx">
</span><span class="cx"> class JSTestOverrideBuiltinsOwner : public JSC::WeakHandleOwner {
</span><span class="cx"> public:
</span><del>- virtual bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&);
- virtual void finalize(JSC::Handle<JSC::Unknown>, void* context);
</del><ins>+ bool isReachableFromOpaqueRoots(JSC::JSCell&, void* context, JSC::SlotVisitor&) override;
+ void finalize(JSC::JSCell*&, void* context) override;
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> inline JSC::WeakHandleOwner* wrapperOwner(DOMWrapperWorld&, TestOverrideBuiltins*)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestSerializedScriptValueInterfacecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -311,18 +311,18 @@
</span><span class="cx"> visitor.append(&thisObject->m_cachedReadonlyValue);
</span><span class="cx"> }
</span><span class="cx">
</span><del>-bool JSTestSerializedScriptValueInterfaceOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor)
</del><ins>+bool JSTestSerializedScriptValueInterfaceOwner::isReachableFromOpaqueRoots(JSC::JSCell& cell, void*, SlotVisitor& visitor)
</ins><span class="cx"> {
</span><del>- UNUSED_PARAM(handle);
</del><ins>+ UNUSED_PARAM(cell);
</ins><span class="cx"> UNUSED_PARAM(visitor);
</span><span class="cx"> return false;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void JSTestSerializedScriptValueInterfaceOwner::finalize(JSC::Handle<JSC::Unknown> handle, void* context)
</del><ins>+void JSTestSerializedScriptValueInterfaceOwner::finalize(JSC::JSCell*& cell, void* context)
</ins><span class="cx"> {
</span><del>- auto* jsTestSerializedScriptValueInterface = jsCast<JSTestSerializedScriptValueInterface*>(handle.slot()->asCell());
</del><ins>+ auto& wrapper = jsCast<JSTestSerializedScriptValueInterface&>(*cell);
</ins><span class="cx"> auto& world = *static_cast<DOMWrapperWorld*>(context);
</span><del>- uncacheWrapper(world, &jsTestSerializedScriptValueInterface->impl(), jsTestSerializedScriptValueInterface);
</del><ins>+ uncacheWrapper(world, &wrapper.impl(), &wrapper);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestSerializedScriptValueInterfaceh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -75,8 +75,8 @@
</span><span class="cx">
</span><span class="cx"> class JSTestSerializedScriptValueInterfaceOwner : public JSC::WeakHandleOwner {
</span><span class="cx"> public:
</span><del>- virtual bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&);
- virtual void finalize(JSC::Handle<JSC::Unknown>, void* context);
</del><ins>+ bool isReachableFromOpaqueRoots(JSC::JSCell&, void* context, JSC::SlotVisitor&) override;
+ void finalize(JSC::JSCell*&, void* context) override;
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> inline JSC::WeakHandleOwner* wrapperOwner(DOMWrapperWorld&, TestSerializedScriptValueInterface*)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestTypedefscpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -720,18 +720,18 @@
</span><span class="cx"> return JSValue::encode(jsUndefined());
</span><span class="cx"> }
</span><span class="cx">
</span><del>-bool JSTestTypedefsOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor)
</del><ins>+bool JSTestTypedefsOwner::isReachableFromOpaqueRoots(JSC::JSCell& cell, void*, SlotVisitor& visitor)
</ins><span class="cx"> {
</span><del>- UNUSED_PARAM(handle);
</del><ins>+ UNUSED_PARAM(cell);
</ins><span class="cx"> UNUSED_PARAM(visitor);
</span><span class="cx"> return false;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void JSTestTypedefsOwner::finalize(JSC::Handle<JSC::Unknown> handle, void* context)
</del><ins>+void JSTestTypedefsOwner::finalize(JSC::JSCell*& cell, void* context)
</ins><span class="cx"> {
</span><del>- auto* jsTestTypedefs = jsCast<JSTestTypedefs*>(handle.slot()->asCell());
</del><ins>+ auto& wrapper = jsCast<JSTestTypedefs&>(*cell);
</ins><span class="cx"> auto& world = *static_cast<DOMWrapperWorld*>(context);
</span><del>- uncacheWrapper(world, &jsTestTypedefs->impl(), jsTestTypedefs);
</del><ins>+ uncacheWrapper(world, &wrapper.impl(), &wrapper);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestTypedefsh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -72,8 +72,8 @@
</span><span class="cx">
</span><span class="cx"> class JSTestTypedefsOwner : public JSC::WeakHandleOwner {
</span><span class="cx"> public:
</span><del>- virtual bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&);
- virtual void finalize(JSC::Handle<JSC::Unknown>, void* context);
</del><ins>+ bool isReachableFromOpaqueRoots(JSC::JSCell&, void* context, JSC::SlotVisitor&) override;
+ void finalize(JSC::JSCell*&, void* context) override;
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> inline JSC::WeakHandleOwner* wrapperOwner(DOMWrapperWorld&, TestTypedefs*)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSattributecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSattribute.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSattribute.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSattribute.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -173,18 +173,18 @@
</span><span class="cx"> return getDOMConstructor<JSattributeConstructor>(vm, jsCast<JSDOMGlobalObject*>(globalObject));
</span><span class="cx"> }
</span><span class="cx">
</span><del>-bool JSattributeOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor)
</del><ins>+bool JSattributeOwner::isReachableFromOpaqueRoots(JSC::JSCell& cell, void*, SlotVisitor& visitor)
</ins><span class="cx"> {
</span><del>- UNUSED_PARAM(handle);
</del><ins>+ UNUSED_PARAM(cell);
</ins><span class="cx"> UNUSED_PARAM(visitor);
</span><span class="cx"> return false;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void JSattributeOwner::finalize(JSC::Handle<JSC::Unknown> handle, void* context)
</del><ins>+void JSattributeOwner::finalize(JSC::JSCell*& cell, void* context)
</ins><span class="cx"> {
</span><del>- auto* jsattribute = jsCast<JSattribute*>(handle.slot()->asCell());
</del><ins>+ auto& wrapper = jsCast<JSattribute&>(*cell);
</ins><span class="cx"> auto& world = *static_cast<DOMWrapperWorld*>(context);
</span><del>- uncacheWrapper(world, &jsattribute->impl(), jsattribute);
</del><ins>+ uncacheWrapper(world, &wrapper.impl(), &wrapper);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> #if ENABLE(BINDING_INTEGRITY)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSattributeh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSattribute.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSattribute.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSattribute.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -70,8 +70,8 @@
</span><span class="cx">
</span><span class="cx"> class JSattributeOwner : public JSC::WeakHandleOwner {
</span><span class="cx"> public:
</span><del>- virtual bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&);
- virtual void finalize(JSC::Handle<JSC::Unknown>, void* context);
</del><ins>+ bool isReachableFromOpaqueRoots(JSC::JSCell&, void* context, JSC::SlotVisitor&) override;
+ void finalize(JSC::JSCell*&, void* context) override;
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> inline JSC::WeakHandleOwner* wrapperOwner(DOMWrapperWorld&, attribute*)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSreadonlycpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSreadonly.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSreadonly.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSreadonly.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -152,18 +152,18 @@
</span><span class="cx"> return getDOMConstructor<JSreadonlyConstructor>(vm, jsCast<JSDOMGlobalObject*>(globalObject));
</span><span class="cx"> }
</span><span class="cx">
</span><del>-bool JSreadonlyOwner::isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown> handle, void*, SlotVisitor& visitor)
</del><ins>+bool JSreadonlyOwner::isReachableFromOpaqueRoots(JSC::JSCell& cell, void*, SlotVisitor& visitor)
</ins><span class="cx"> {
</span><del>- UNUSED_PARAM(handle);
</del><ins>+ UNUSED_PARAM(cell);
</ins><span class="cx"> UNUSED_PARAM(visitor);
</span><span class="cx"> return false;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void JSreadonlyOwner::finalize(JSC::Handle<JSC::Unknown> handle, void* context)
</del><ins>+void JSreadonlyOwner::finalize(JSC::JSCell*& cell, void* context)
</ins><span class="cx"> {
</span><del>- auto* jsreadonly = jsCast<JSreadonly*>(handle.slot()->asCell());
</del><ins>+ auto& wrapper = jsCast<JSreadonly&>(*cell);
</ins><span class="cx"> auto& world = *static_cast<DOMWrapperWorld*>(context);
</span><del>- uncacheWrapper(world, &jsreadonly->impl(), jsreadonly);
</del><ins>+ uncacheWrapper(world, &wrapper.impl(), &wrapper);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> JSC::JSValue toJS(JSC::ExecState*, JSDOMGlobalObject* globalObject, readonly* impl)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSreadonlyh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSreadonly.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSreadonly.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSreadonly.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -69,8 +69,8 @@
</span><span class="cx">
</span><span class="cx"> class JSreadonlyOwner : public JSC::WeakHandleOwner {
</span><span class="cx"> public:
</span><del>- virtual bool isReachableFromOpaqueRoots(JSC::Handle<JSC::Unknown>, void* context, JSC::SlotVisitor&);
- virtual void finalize(JSC::Handle<JSC::Unknown>, void* context);
</del><ins>+ bool isReachableFromOpaqueRoots(JSC::JSCell&, void* context, JSC::SlotVisitor&) override;
+ void finalize(JSC::JSCell*&, void* context) override;
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> inline JSC::WeakHandleOwner* wrapperOwner(DOMWrapperWorld&, readonly*)
</span></span></pre></div>
<a id="trunkSourceWebCorebridgeruntime_rootcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bridge/runtime_root.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bridge/runtime_root.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bridge/runtime_root.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -196,9 +196,9 @@
</span><span class="cx"> weakRemove(m_runtimeObjects, object, object);
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void RootObject::finalize(JSC::Handle<JSC::Unknown> handle, void*)
</del><ins>+void RootObject::finalize(JSC::JSCell*& cell, void*)
</ins><span class="cx"> {
</span><del>- RuntimeObject* object = static_cast<RuntimeObject*>(handle.slot()->asCell());
</del><ins>+ RuntimeObject* object = jsCast<RuntimeObject*>(cell);
</ins><span class="cx">
</span><span class="cx"> Ref<RootObject> protect(*this);
</span><span class="cx"> object->invalidate();
</span></span></pre></div>
<a id="trunkSourceWebCorebridgeruntime_rooth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bridge/runtime_root.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bridge/runtime_root.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebCore/bridge/runtime_root.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -83,7 +83,7 @@
</span><span class="cx"> RootObject(const void* nativeHandle, JSGlobalObject*);
</span><span class="cx">
</span><span class="cx"> // WeakHandleOwner
</span><del>- virtual void finalize(JSC::Handle<JSC::Unknown>, void* context) override;
</del><ins>+ void finalize(JSC::JSCell*&, void* context) override;
</ins><span class="cx">
</span><span class="cx"> bool m_isValid;
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebKit2ChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/ChangeLog (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/ChangeLog        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebKit2/ChangeLog        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -1,3 +1,14 @@
</span><ins>+2015-09-11 Andreas Kling <akling@apple.com>
+
+ [JSC] Weak should only accept cell pointees.
+ <https://webkit.org/b/148955>
+
+ Reviewed by Geoffrey Garen.
+
+ * WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp:
+ (WebKit::NPRuntimeObjectMap::finalize):
+ * WebProcess/Plugins/Netscape/NPRuntimeObjectMap.h:
+
</ins><span class="cx"> 2015-09-10 Joseph Pecoraro <pecoraro@apple.com>
</span><span class="cx">
</span><span class="cx"> Web Inspector: Remove unused files
</span></span></pre></div>
<a id="trunkSourceWebKit2WebProcessPluginsNetscapeNPRuntimeObjectMapcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebKit2/WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -305,11 +305,11 @@
</span><span class="cx"> m_npObjectsToFinalize.append(npObject);
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void NPRuntimeObjectMap::finalize(JSC::Handle<JSC::Unknown> handle, void* context)
</del><ins>+void NPRuntimeObjectMap::finalize(JSC::JSCell*& cell, void* context)
</ins><span class="cx"> {
</span><del>- JSNPObject* object = jsCast<JSNPObject*>(handle.get().asCell());
- weakRemove(m_jsNPObjects, static_cast<NPObject*>(context), object);
- addToInvalidationQueue(object->leakNPObject());
</del><ins>+ JSNPObject& object = jsCast<JSNPObject&>(*cell);
+ weakRemove(m_jsNPObjects, static_cast<NPObject*>(context), &object);
+ addToInvalidationQueue(object.leakNPObject());
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> } // namespace WebKit
</span></span></pre></div>
<a id="trunkSourceWebKit2WebProcessPluginsNetscapeNPRuntimeObjectMaph"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/WebProcess/Plugins/Netscape/NPRuntimeObjectMap.h (189615 => 189616)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/WebProcess/Plugins/Netscape/NPRuntimeObjectMap.h        2015-09-11 07:17:21 UTC (rev 189615)
+++ trunk/Source/WebKit2/WebProcess/Plugins/Netscape/NPRuntimeObjectMap.h        2015-09-11 09:16:37 UTC (rev 189616)
</span><span class="lines">@@ -52,7 +52,7 @@
</span><span class="cx"> class PluginView;
</span><span class="cx">
</span><span class="cx"> // A per plug-in map of NPObjects that wrap JavaScript objects.
</span><del>-class NPRuntimeObjectMap : private JSC::WeakHandleOwner {
</del><ins>+class NPRuntimeObjectMap final : private JSC::WeakHandleOwner {
</ins><span class="cx"> public:
</span><span class="cx"> explicit NPRuntimeObjectMap(PluginView*);
</span><span class="cx">
</span><span class="lines">@@ -90,7 +90,8 @@
</span><span class="cx">
</span><span class="cx"> private:
</span><span class="cx"> // WeakHandleOwner
</span><del>- virtual void finalize(JSC::Handle<JSC::Unknown>, void* context);
</del><ins>+ void finalize(JSC::JSCell*&, void* context) override;
+
</ins><span class="cx"> void addToInvalidationQueue(NPObject*);
</span><span class="cx"> void invalidateQueuedObjects();
</span><span class="cx">
</span></span></pre>
</div>
</div>
</body>
</html>