<!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>[191885] trunk/Source/WebCore</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/191885">191885</a></dd>
<dt>Author</dt> <dd>youenn.fablet@crf.canon.fr</dd>
<dt>Date</dt> <dd>2015-11-02 03:00:35 -0800 (Mon, 02 Nov 2015)</dd>
</dl>

<h3>Log Message</h3>
<pre>IDL functions and attributes should be JSBuiltin by default if interface is marked as JSBuiltinConstructor
https://bugs.webkit.org/show_bug.cgi?id=150438

Reviewed by Darin Adler.

Binding generator is now deducing that function/attribute is JSBuiltin if the interface is marked as JSBuiltin.
One exception is custom setters, getters or functions which remain C++ handled.
Updated streams API IDLs accordingly.

Binding generator knows whether class needs a DOM class by checking whether the interface is marked as JSBuiltin.
Binding generator knows that class uses a JS built-in constructor if marked as JSBuiltin+Constructor.
In particular, JSBuiltIn+CustomConstructor means that a DOM class is not needed and constructor is not JS built-in.

Applied JSBuiltin+CustomConstructor to ReadableStreamReader and ReadableStreamController.
Removing ReadableStreamReader and ReadableStreamController classes.

Removed unneeded &quot;Default&quot; keyword for cancel function in WebIDL.

Added a binding test case.
No change in behavior.

* Modules/streams/ByteLengthQueuingStrategy.idl: Marking interface as JSBuiltin and Constructable.
* Modules/streams/CountQueuingStrategy.idl: Ditto.
* Modules/streams/ReadableStream.idl: Ditto.
* Modules/streams/ReadableStreamController.h: Removed.
* Modules/streams/ReadableStreamController.idl: Marking interface as JSBuiltin and Constructable.
* Modules/streams/ReadableStreamReader.h: Removed.
* Modules/streams/ReadableStreamReader.idl: Marking interface as JSBuiltin and Constructable.
* Modules/streams/WritableStream.idl: Ditto.
* bindings/js/JSReadableStreamPrivateConstructors.cpp:
(WebCore::JSBuiltinReadableStreamReaderPrivateConstructor::createJSObject): Updated according new constructor.
(WebCore::JSBuiltinReadableStreamControllerPrivateConstructor::createJSObject): Ditto.
* bindings/scripts/CodeGeneratorJS.pm:
(NeedsImplementationClass):
(GetAttributeGetterName):
(GetAttributeSetterName):
(GetFunctionName):
(InstanceNeedsVisitChildren):
(GenerateHeader):
(GenerateAttributesHashTable):
(GenerateImplementation):
(GetConstructorTemplateClassName):
(GenerateConstructorDefinition):
(GenerateConstructorHelperMethods):
(IsConstructable):
(ComputeFunctionSpecial):
(IsJSBuiltin):
(IsJSBuiltinConstructor):
(AddJSBuiltinIncludesIfNeeded):
(GetJSBuiltinFunctionName): Deleted.
(GetJSBuiltinFunctionNameFromString): Deleted.
(GetJSBuiltinScopeName): Deleted.
* bindings/scripts/test/GObject/WebKitDOMTestJSBuiltinConstructor.cpp:
(webkit_dom_test_js_builtin_constructor_set_property):
(webkit_dom_test_js_builtin_constructor_get_property):
(webkit_dom_test_js_builtin_constructor_class_init):
(webkit_dom_test_js_builtin_constructor_test_function):
(webkit_dom_test_js_builtin_constructor_get_test_attribute):
(webkit_dom_test_js_builtin_constructor_set_test_attribute):
* bindings/scripts/test/GObject/WebKitDOMTestJSBuiltinConstructor.h:
* bindings/scripts/test/JS/JSTestJSBuiltinConstructor.cpp:
(WebCore::JSTestJSBuiltinConstructor::JSTestJSBuiltinConstructor):
(WebCore::JSTestJSBuiltinConstructor::getOwnPropertySlot):
(WebCore::jsTestJSBuiltinConstructorTestAttribute):
(WebCore::jsTestJSBuiltinConstructorTestAttributeCustom):
(WebCore::jsTestJSBuiltinConstructorTestAttributeRWCustom):
(WebCore::setJSTestJSBuiltinConstructorTestAttribute):
(WebCore::setJSTestJSBuiltinConstructorTestAttributeRWCustom):
(WebCore::jsTestJSBuiltinConstructorPrototypeFunctionTestFunction):
(WebCore::jsTestJSBuiltinConstructorPrototypeFunctionTestCustomFunction):
(WebCore::JSTestJSBuiltinConstructorOwner::isReachableFromOpaqueRoots):
(WebCore::JSTestJSBuiltinConstructorOwner::finalize):
(WebCore::toJSNewlyCreated):
(WebCore::toJS):
(WebCore::JSTestJSBuiltinConstructor::toWrapped):
(WebCore::JSTestJSBuiltinConstructorPrototype::createStructure): Deleted.
(WebCore::JSTestJSBuiltinConstructorConstructor::initializeProperties): Deleted.
(WebCore::JSTestJSBuiltinConstructor::createPrototype): Deleted.
(WebCore::JSTestJSBuiltinConstructor::getPrototype): Deleted.
* bindings/scripts/test/JS/JSTestJSBuiltinConstructor.h:
(WebCore::JSTestJSBuiltinConstructor::create):
(WebCore::JSTestJSBuiltinConstructor::finishCreation):
(WebCore::wrapperOwner):
(WebCore::toJS):
(WebCore::JSTestJSBuiltinConstructor::createStructure): Deleted.
* bindings/scripts/test/ObjC/DOMTestJSBuiltinConstructor.h:
* bindings/scripts/test/ObjC/DOMTestJSBuiltinConstructor.mm:
(-[DOMTestJSBuiltinConstructor testAttribute]):
(-[DOMTestJSBuiltinConstructor setTestAttribute:]):
(-[DOMTestJSBuiltinConstructor testAttributeCustom]):
(-[DOMTestJSBuiltinConstructor testAttributeRWCustom]):
(-[DOMTestJSBuiltinConstructor setTestAttributeRWCustom:]):
(-[DOMTestJSBuiltinConstructor testFunction]):
(-[DOMTestJSBuiltinConstructor testCustomFunction]):
* bindings/scripts/test/TestJSBuiltinConstructor.idl:</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCoreModulesstreamsByteLengthQueuingStrategyidl">trunk/Source/WebCore/Modules/streams/ByteLengthQueuingStrategy.idl</a></li>
<li><a href="#trunkSourceWebCoreModulesstreamsCountQueuingStrategyidl">trunk/Source/WebCore/Modules/streams/CountQueuingStrategy.idl</a></li>
<li><a href="#trunkSourceWebCoreModulesstreamsReadableStreamidl">trunk/Source/WebCore/Modules/streams/ReadableStream.idl</a></li>
<li><a href="#trunkSourceWebCoreModulesstreamsReadableStreamControlleridl">trunk/Source/WebCore/Modules/streams/ReadableStreamController.idl</a></li>
<li><a href="#trunkSourceWebCoreModulesstreamsReadableStreamReaderidl">trunk/Source/WebCore/Modules/streams/ReadableStreamReader.idl</a></li>
<li><a href="#trunkSourceWebCoreModulesstreamsWritableStreamidl">trunk/Source/WebCore/Modules/streams/WritableStream.idl</a></li>
<li><a href="#trunkSourceWebCorebindingsjsJSReadableStreamPrivateConstructorscpp">trunk/Source/WebCore/bindings/js/JSReadableStreamPrivateConstructors.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptsCodeGeneratorJSpm">trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestGObjectWebKitDOMTestJSBuiltinConstructorcpp">trunk/Source/WebCore/bindings/scripts/test/GObject/WebKitDOMTestJSBuiltinConstructor.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestGObjectWebKitDOMTestJSBuiltinConstructorh">trunk/Source/WebCore/bindings/scripts/test/GObject/WebKitDOMTestJSBuiltinConstructor.h</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestJSBuiltinConstructorcpp">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestJSBuiltinConstructor.cpp</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestJSJSTestJSBuiltinConstructorh">trunk/Source/WebCore/bindings/scripts/test/JS/JSTestJSBuiltinConstructor.h</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestObjCDOMTestJSBuiltinConstructorh">trunk/Source/WebCore/bindings/scripts/test/ObjC/DOMTestJSBuiltinConstructor.h</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestObjCDOMTestJSBuiltinConstructormm">trunk/Source/WebCore/bindings/scripts/test/ObjC/DOMTestJSBuiltinConstructor.mm</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestTestCustomConstructoridl">trunk/Source/WebCore/bindings/scripts/test/TestCustomConstructor.idl</a></li>
<li><a href="#trunkSourceWebCorebindingsscriptstestTestJSBuiltinConstructoridl">trunk/Source/WebCore/bindings/scripts/test/TestJSBuiltinConstructor.idl</a></li>
</ul>

<h3>Removed Paths</h3>
<ul>
<li><a href="#trunkSourceWebCoreModulesstreamsReadableStreamControllerh">trunk/Source/WebCore/Modules/streams/ReadableStreamController.h</a></li>
<li><a href="#trunkSourceWebCoreModulesstreamsReadableStreamReaderh">trunk/Source/WebCore/Modules/streams/ReadableStreamReader.h</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (191884 => 191885)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog        2015-11-02 10:33:44 UTC (rev 191884)
+++ trunk/Source/WebCore/ChangeLog        2015-11-02 11:00:35 UTC (rev 191885)
</span><span class="lines">@@ -1,3 +1,101 @@
</span><ins>+2015-11-02  Youenn Fablet  &lt;youenn.fablet@crf.canon.fr&gt;
+
+        IDL functions and attributes should be JSBuiltin by default if interface is marked as JSBuiltinConstructor
+        https://bugs.webkit.org/show_bug.cgi?id=150438
+
+        Reviewed by Darin Adler.
+
+        Binding generator is now deducing that function/attribute is JSBuiltin if the interface is marked as JSBuiltin.
+        One exception is custom setters, getters or functions which remain C++ handled.
+        Updated streams API IDLs accordingly.
+
+        Binding generator knows whether class needs a DOM class by checking whether the interface is marked as JSBuiltin.
+        Binding generator knows that class uses a JS built-in constructor if marked as JSBuiltin+Constructor.
+        In particular, JSBuiltIn+CustomConstructor means that a DOM class is not needed and constructor is not JS built-in.
+
+        Applied JSBuiltin+CustomConstructor to ReadableStreamReader and ReadableStreamController.
+        Removing ReadableStreamReader and ReadableStreamController classes.
+
+        Removed unneeded &quot;Default&quot; keyword for cancel function in WebIDL.
+
+        Added a binding test case.
+        No change in behavior.
+
+        * Modules/streams/ByteLengthQueuingStrategy.idl: Marking interface as JSBuiltin and Constructable.
+        * Modules/streams/CountQueuingStrategy.idl: Ditto.
+        * Modules/streams/ReadableStream.idl: Ditto.
+        * Modules/streams/ReadableStreamController.h: Removed.
+        * Modules/streams/ReadableStreamController.idl: Marking interface as JSBuiltin and Constructable.
+        * Modules/streams/ReadableStreamReader.h: Removed.
+        * Modules/streams/ReadableStreamReader.idl: Marking interface as JSBuiltin and Constructable.
+        * Modules/streams/WritableStream.idl: Ditto.
+        * bindings/js/JSReadableStreamPrivateConstructors.cpp:
+        (WebCore::JSBuiltinReadableStreamReaderPrivateConstructor::createJSObject): Updated according new constructor.
+        (WebCore::JSBuiltinReadableStreamControllerPrivateConstructor::createJSObject): Ditto.
+        * bindings/scripts/CodeGeneratorJS.pm:
+        (NeedsImplementationClass):
+        (GetAttributeGetterName):
+        (GetAttributeSetterName):
+        (GetFunctionName):
+        (InstanceNeedsVisitChildren):
+        (GenerateHeader):
+        (GenerateAttributesHashTable):
+        (GenerateImplementation):
+        (GetConstructorTemplateClassName):
+        (GenerateConstructorDefinition):
+        (GenerateConstructorHelperMethods):
+        (IsConstructable):
+        (ComputeFunctionSpecial):
+        (IsJSBuiltin):
+        (IsJSBuiltinConstructor):
+        (AddJSBuiltinIncludesIfNeeded):
+        (GetJSBuiltinFunctionName): Deleted.
+        (GetJSBuiltinFunctionNameFromString): Deleted.
+        (GetJSBuiltinScopeName): Deleted.
+        * bindings/scripts/test/GObject/WebKitDOMTestJSBuiltinConstructor.cpp:
+        (webkit_dom_test_js_builtin_constructor_set_property):
+        (webkit_dom_test_js_builtin_constructor_get_property):
+        (webkit_dom_test_js_builtin_constructor_class_init):
+        (webkit_dom_test_js_builtin_constructor_test_function):
+        (webkit_dom_test_js_builtin_constructor_get_test_attribute):
+        (webkit_dom_test_js_builtin_constructor_set_test_attribute):
+        * bindings/scripts/test/GObject/WebKitDOMTestJSBuiltinConstructor.h:
+        * bindings/scripts/test/JS/JSTestJSBuiltinConstructor.cpp:
+        (WebCore::JSTestJSBuiltinConstructor::JSTestJSBuiltinConstructor):
+        (WebCore::JSTestJSBuiltinConstructor::getOwnPropertySlot):
+        (WebCore::jsTestJSBuiltinConstructorTestAttribute):
+        (WebCore::jsTestJSBuiltinConstructorTestAttributeCustom):
+        (WebCore::jsTestJSBuiltinConstructorTestAttributeRWCustom):
+        (WebCore::setJSTestJSBuiltinConstructorTestAttribute):
+        (WebCore::setJSTestJSBuiltinConstructorTestAttributeRWCustom):
+        (WebCore::jsTestJSBuiltinConstructorPrototypeFunctionTestFunction):
+        (WebCore::jsTestJSBuiltinConstructorPrototypeFunctionTestCustomFunction):
+        (WebCore::JSTestJSBuiltinConstructorOwner::isReachableFromOpaqueRoots):
+        (WebCore::JSTestJSBuiltinConstructorOwner::finalize):
+        (WebCore::toJSNewlyCreated):
+        (WebCore::toJS):
+        (WebCore::JSTestJSBuiltinConstructor::toWrapped):
+        (WebCore::JSTestJSBuiltinConstructorPrototype::createStructure): Deleted.
+        (WebCore::JSTestJSBuiltinConstructorConstructor::initializeProperties): Deleted.
+        (WebCore::JSTestJSBuiltinConstructor::createPrototype): Deleted.
+        (WebCore::JSTestJSBuiltinConstructor::getPrototype): Deleted.
+        * bindings/scripts/test/JS/JSTestJSBuiltinConstructor.h:
+        (WebCore::JSTestJSBuiltinConstructor::create):
+        (WebCore::JSTestJSBuiltinConstructor::finishCreation):
+        (WebCore::wrapperOwner):
+        (WebCore::toJS):
+        (WebCore::JSTestJSBuiltinConstructor::createStructure): Deleted.
+        * bindings/scripts/test/ObjC/DOMTestJSBuiltinConstructor.h:
+        * bindings/scripts/test/ObjC/DOMTestJSBuiltinConstructor.mm:
+        (-[DOMTestJSBuiltinConstructor testAttribute]):
+        (-[DOMTestJSBuiltinConstructor setTestAttribute:]):
+        (-[DOMTestJSBuiltinConstructor testAttributeCustom]):
+        (-[DOMTestJSBuiltinConstructor testAttributeRWCustom]):
+        (-[DOMTestJSBuiltinConstructor setTestAttributeRWCustom:]):
+        (-[DOMTestJSBuiltinConstructor testFunction]):
+        (-[DOMTestJSBuiltinConstructor testCustomFunction]):
+        * bindings/scripts/test/TestJSBuiltinConstructor.idl:
+
</ins><span class="cx"> 2015-10-29  Sergio Villar Senin  &lt;svillar@igalia.com&gt;
</span><span class="cx"> 
</span><span class="cx">         [CSS Grid Layout] min-content row does not always shrink
</span></span></pre></div>
<a id="trunkSourceWebCoreModulesstreamsByteLengthQueuingStrategyidl"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/streams/ByteLengthQueuingStrategy.idl (191884 => 191885)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/streams/ByteLengthQueuingStrategy.idl        2015-11-02 10:33:44 UTC (rev 191884)
+++ trunk/Source/WebCore/Modules/streams/ByteLengthQueuingStrategy.idl        2015-11-02 11:00:35 UTC (rev 191885)
</span><span class="lines">@@ -28,8 +28,9 @@
</span><span class="cx">  */
</span><span class="cx"> 
</span><span class="cx"> [
</span><del>-    JSBuiltinConstructor,
</del><ins>+    JSBuiltin,
+    Constructor,
</ins><span class="cx">     Conditional=STREAMS_API,
</span><span class="cx"> ] interface ByteLengthQueuingStrategy {
</span><del>-    [JSBuiltin] double size();
</del><ins>+    double size();
</ins><span class="cx"> };
</span></span></pre></div>
<a id="trunkSourceWebCoreModulesstreamsCountQueuingStrategyidl"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/streams/CountQueuingStrategy.idl (191884 => 191885)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/streams/CountQueuingStrategy.idl        2015-11-02 10:33:44 UTC (rev 191884)
+++ trunk/Source/WebCore/Modules/streams/CountQueuingStrategy.idl        2015-11-02 11:00:35 UTC (rev 191885)
</span><span class="lines">@@ -28,8 +28,9 @@
</span><span class="cx">  */
</span><span class="cx"> 
</span><span class="cx"> [
</span><del>-    JSBuiltinConstructor,
</del><ins>+    JSBuiltin,
+    Constructor,
</ins><span class="cx">     Conditional=STREAMS_API,
</span><span class="cx"> ] interface CountQueuingStrategy {
</span><del>-    [JSBuiltin] double size();
</del><ins>+    double size();
</ins><span class="cx"> };
</span></span></pre></div>
<a id="trunkSourceWebCoreModulesstreamsReadableStreamidl"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/streams/ReadableStream.idl (191884 => 191885)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/streams/ReadableStream.idl        2015-11-02 10:33:44 UTC (rev 191884)
+++ trunk/Source/WebCore/Modules/streams/ReadableStream.idl        2015-11-02 11:00:35 UTC (rev 191885)
</span><span class="lines">@@ -29,13 +29,14 @@
</span><span class="cx"> 
</span><span class="cx"> [
</span><span class="cx">     Conditional=STREAMS_API,
</span><del>-    JSBuiltinConstructor
</del><ins>+    Constructor,
+    JSBuiltin
</ins><span class="cx"> ] interface ReadableStream {
</span><del>-    [JSBuiltin] Promise cancel([Default=Undefined] optional any reason);
-    [JSBuiltin] Object getReader();
-    [JSBuiltin] Promise pipeTo(any streams, any options);
-    [JSBuiltin] Object pipeThrough(any dest, any options);
-    [JSBuiltin] Object tee();
</del><ins>+    Promise cancel(optional any reason);
+    Object getReader();
+    Promise pipeTo(any streams, any options);
+    Object pipeThrough(any dest, any options);
+    Object tee();
</ins><span class="cx"> 
</span><del>-    [JSBuiltin] readonly attribute boolean locked;
</del><ins>+    readonly attribute boolean locked;
</ins><span class="cx"> };
</span></span></pre></div>
<a id="trunkSourceWebCoreModulesstreamsReadableStreamControllerh"></a>
<div class="delfile"><h4>Deleted: trunk/Source/WebCore/Modules/streams/ReadableStreamController.h (191884 => 191885)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/streams/ReadableStreamController.h        2015-11-02 10:33:44 UTC (rev 191884)
+++ trunk/Source/WebCore/Modules/streams/ReadableStreamController.h        2015-11-02 11:00:35 UTC (rev 191885)
</span><span class="lines">@@ -1,53 +0,0 @@
</span><del>-/*
- * Copyright (C) 2015 Canon Inc.
- * Copyright (C) 2015 Igalia S.L.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted, provided that the following conditions
- * are required to be met:
- *
- * 1.  Redistributions of source code must retain the above copyright
- *     notice, this list of conditions and the following disclaimer.
- * 2.  Redistributions in binary form must reproduce the above copyright
- *     notice, this list of conditions and the following disclaimer in the
- *     documentation and/or other materials provided with the distribution.
- * 3.  Neither the name of Canon Inc. nor the names of
- *     its contributors may be used to endorse or promote products derived
- *     from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY CANON INC. AND ITS CONTRIBUTORS &quot;AS IS&quot; AND ANY
- * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL CANON INC. AND ITS CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
- * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
- * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#ifndef ReadableStreamController_h
-#define ReadableStreamController_h
-
-#if ENABLE(STREAMS_API)
-
-#include &lt;wtf/RefCounted.h&gt;
-
-namespace WebCore {
-
-// This is a dummy class needed as we cannot yet use JSBuiltinConstructor with NoInterfaceObject.
-// Implementation of ReadableStreamController functionality is done in ReadableStreamController.js
-// FIXME: Find a way to remove that class.
-class ReadableStreamController final : public RefCounted&lt;ReadableStreamController&gt; {
-public:
-    static Ref&lt;ReadableStreamController&gt; create() { return adoptRef(* new ReadableStreamController); }
-private:
-    ReadableStreamController() { }
-};
-
-}
-
-#endif
-
-#endif // ReadableStream_h
</del></span></pre></div>
<a id="trunkSourceWebCoreModulesstreamsReadableStreamControlleridl"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/streams/ReadableStreamController.idl (191884 => 191885)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/streams/ReadableStreamController.idl        2015-11-02 10:33:44 UTC (rev 191884)
+++ trunk/Source/WebCore/Modules/streams/ReadableStreamController.idl        2015-11-02 11:00:35 UTC (rev 191885)
</span><span class="lines">@@ -30,12 +30,12 @@
</span><span class="cx"> [
</span><span class="cx">     Conditional=STREAMS_API,
</span><span class="cx">     CustomConstructor,
</span><del>-    ImplementationLacksVTable,
</del><ins>+    JSBuiltin,
</ins><span class="cx">     NoInterfaceObject
</span><span class="cx"> ] interface ReadableStreamController {
</span><del>-    [JSBuiltin] void enqueue([Default=Undefined] optional any chunk);
-    [JSBuiltin] void close();
-    [JSBuiltin] void error([Default=Undefined] optional any error);
</del><ins>+    void enqueue(optional any chunk);
+    void close();
+    void error(optional any error);
</ins><span class="cx"> 
</span><del>-    [JSBuiltin] readonly attribute double desiredSize;
</del><ins>+    readonly attribute double desiredSize;
</ins><span class="cx"> };
</span></span></pre></div>
<a id="trunkSourceWebCoreModulesstreamsReadableStreamReaderh"></a>
<div class="delfile"><h4>Deleted: trunk/Source/WebCore/Modules/streams/ReadableStreamReader.h (191884 => 191885)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/streams/ReadableStreamReader.h        2015-11-02 10:33:44 UTC (rev 191884)
+++ trunk/Source/WebCore/Modules/streams/ReadableStreamReader.h        2015-11-02 11:00:35 UTC (rev 191885)
</span><span class="lines">@@ -1,53 +0,0 @@
</span><del>-/*
- * Copyright (C) 2015 Canon Inc.
- * Copyright (C) 2015 Igalia S.L.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted, provided that the following conditions
- * are required to be met:
- *
- * 1.  Redistributions of source code must retain the above copyright
- *     notice, this list of conditions and the following disclaimer.
- * 2.  Redistributions in binary form must reproduce the above copyright
- *     notice, this list of conditions and the following disclaimer in the
- *     documentation and/or other materials provided with the distribution.
- * 3.  Neither the name of Canon Inc. nor the names of
- *     its contributors may be used to endorse or promote products derived
- *     from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY CANON INC. AND ITS CONTRIBUTORS &quot;AS IS&quot; AND ANY
- * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL CANON INC. AND ITS CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
- * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
- * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#ifndef ReadableStreamReader_h
-#define ReadableStreamReader_h
-
-#if ENABLE(STREAMS_API)
-
-#include &lt;wtf/RefCounted.h&gt;
-
-namespace WebCore {
-
-// This is a dummy class needed as we cannot yet use JSBuiltinConstructor with NoInterfaceObject.
-// Implementation of ReadableStreamReader functionality is done in ReadableStreamReader.js
-// FIXME: Find a way to remove that class.
-class ReadableStreamReader final : public RefCounted&lt;ReadableStreamReader&gt; {
-public:
-    static Ref&lt;ReadableStreamReader&gt; create() { return adoptRef(* new ReadableStreamReader); }
-private:
-    ReadableStreamReader() { }
-};
-
-}
-
-#endif
-
-#endif // ReadableStream_h
</del></span></pre></div>
<a id="trunkSourceWebCoreModulesstreamsReadableStreamReaderidl"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/streams/ReadableStreamReader.idl (191884 => 191885)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/streams/ReadableStreamReader.idl        2015-11-02 10:33:44 UTC (rev 191884)
+++ trunk/Source/WebCore/Modules/streams/ReadableStreamReader.idl        2015-11-02 11:00:35 UTC (rev 191885)
</span><span class="lines">@@ -30,12 +30,12 @@
</span><span class="cx"> [
</span><span class="cx">     Conditional=STREAMS_API,
</span><span class="cx">     CustomConstructor,
</span><del>-    ImplementationLacksVTable,
</del><ins>+    JSBuiltin,
</ins><span class="cx">     NoInterfaceObject
</span><span class="cx"> ] interface ReadableStreamReader {
</span><del>-    [JSBuiltin] Promise read();
-    [JSBuiltin] Promise cancel([Default=Undefined] optional any reason);
-    [JSBuiltin] void releaseLock();
</del><ins>+    Promise read();
+    Promise cancel(optional any reason);
+    void releaseLock();
</ins><span class="cx"> 
</span><del>-    [JSBuiltin] readonly attribute Promise closed;
</del><ins>+    readonly attribute Promise closed;
</ins><span class="cx"> };
</span></span></pre></div>
<a id="trunkSourceWebCoreModulesstreamsWritableStreamidl"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/Modules/streams/WritableStream.idl (191884 => 191885)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/Modules/streams/WritableStream.idl        2015-11-02 10:33:44 UTC (rev 191884)
+++ trunk/Source/WebCore/Modules/streams/WritableStream.idl        2015-11-02 11:00:35 UTC (rev 191885)
</span><span class="lines">@@ -29,13 +29,14 @@
</span><span class="cx"> 
</span><span class="cx"> [
</span><span class="cx">     Conditional=STREAMS_API,
</span><del>-    JSBuiltinConstructor
</del><ins>+    Constructor,
+    JSBuiltin
</ins><span class="cx"> ] interface WritableStream { 
</span><del>-    [JSBuiltin] Promise abort([Default=Undefined] optional any reason);
-    [JSBuiltin] Promise close();
-    [JSBuiltin] Promise write(any chunk);
</del><ins>+    Promise abort(optional any reason);
+    Promise close();
+    Promise write(any chunk);
</ins><span class="cx"> 
</span><del>-    [JSBuiltin] readonly attribute Promise closed;
-    [JSBuiltin] readonly attribute Promise ready;
-    [JSBuiltin] readonly attribute DOMString state;
</del><ins>+    readonly attribute Promise closed;
+    readonly attribute Promise ready;
+    readonly attribute DOMString state;
</ins><span class="cx"> };
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsjsJSReadableStreamPrivateConstructorscpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/js/JSReadableStreamPrivateConstructors.cpp (191884 => 191885)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/js/JSReadableStreamPrivateConstructors.cpp        2015-11-02 10:33:44 UTC (rev 191884)
+++ trunk/Source/WebCore/bindings/js/JSReadableStreamPrivateConstructors.cpp        2015-11-02 11:00:35 UTC (rev 191885)
</span><span class="lines">@@ -65,12 +65,12 @@
</span><span class="cx"> 
</span><span class="cx"> template&lt;&gt; JSObject* JSBuiltinReadableStreamReaderPrivateConstructor::createJSObject()
</span><span class="cx"> {
</span><del>-    return JSReadableStreamReader::create(getDOMStructure&lt;JSReadableStreamReader&gt;(globalObject()-&gt;vm(), *globalObject()), globalObject(), ReadableStreamReader::create());
</del><ins>+    return JSReadableStreamReader::create(getDOMStructure&lt;JSReadableStreamReader&gt;(globalObject()-&gt;vm(), *globalObject()), globalObject());
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> template&lt;&gt; JSObject* JSBuiltinReadableStreamControllerPrivateConstructor::createJSObject()
</span><span class="cx"> {
</span><del>-    return JSReadableStreamController::create(getDOMStructure&lt;JSReadableStreamController&gt;(globalObject()-&gt;vm(), *globalObject()), globalObject(), ReadableStreamController::create());
</del><ins>+    return JSReadableStreamController::create(getDOMStructure&lt;JSReadableStreamController&gt;(globalObject()-&gt;vm(), *globalObject()), globalObject());
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> template&lt;&gt; FunctionExecutable* JSBuiltinReadableStreamReaderPrivateConstructor::initializeExecutable(JSC::VM&amp; vm)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptsCodeGeneratorJSpm"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm (191884 => 191885)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm        2015-11-02 10:33:44 UTC (rev 191884)
+++ trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm        2015-11-02 11:00:35 UTC (rev 191885)
</span><span class="lines">@@ -522,7 +522,7 @@
</span><span class="cx"> {
</span><span class="cx">     my ($interface) = @_;
</span><span class="cx"> 
</span><del>-    return 0 if ($interface-&gt;extendedAttributes-&gt;{&quot;JSBuiltinConstructor&quot;});
</del><ins>+    return 0 if ($interface-&gt;extendedAttributes-&gt;{&quot;JSBuiltin&quot;});
</ins><span class="cx">     return 1;
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="lines">@@ -574,11 +574,11 @@
</span><span class="cx"> 
</span><span class="cx"> sub GetAttributeGetterName
</span><span class="cx"> {
</span><del>-    my ($interfaceName, $className, $attribute) = @_;
</del><ins>+    my ($interfaceName, $className, $interface, $attribute) = @_;
</ins><span class="cx">     if ($attribute-&gt;isStatic) {
</span><span class="cx">         return $codeGenerator-&gt;WK_lcfirst($className) . &quot;Constructor&quot; . $codeGenerator-&gt;WK_ucfirst($attribute-&gt;signature-&gt;name);
</span><span class="cx">     }
</span><del>-    if ($attribute-&gt;signature-&gt;extendedAttributes-&gt;{&quot;JSBuiltin&quot;}) {
</del><ins>+    if (IsJSBuiltin($interface, $attribute)) {
</ins><span class="cx">         return GetJSBuiltinFunctionName($className, $attribute);
</span><span class="cx">     }
</span><span class="cx">     return &quot;js&quot; . $interfaceName . $codeGenerator-&gt;WK_ucfirst($attribute-&gt;signature-&gt;name) . ($attribute-&gt;signature-&gt;type =~ /Constructor$/ ? &quot;Constructor&quot; : &quot;&quot;);
</span><span class="lines">@@ -586,11 +586,11 @@
</span><span class="cx"> 
</span><span class="cx"> sub GetAttributeSetterName
</span><span class="cx"> {
</span><del>-    my ($interfaceName, $className, $attribute) = @_;
</del><ins>+    my ($interfaceName, $className, $interface, $attribute) = @_;
</ins><span class="cx">     if ($attribute-&gt;isStatic) {
</span><span class="cx">         return &quot;set&quot; . $codeGenerator-&gt;WK_ucfirst($className) . &quot;Constructor&quot; . $codeGenerator-&gt;WK_ucfirst($attribute-&gt;signature-&gt;name);
</span><span class="cx">     }
</span><del>-    if ($attribute-&gt;signature-&gt;extendedAttributes-&gt;{&quot;JSBuiltin&quot;}) {
</del><ins>+    if (IsJSBuiltin($interface, $attribute)) {
</ins><span class="cx">         return &quot;set&quot; . $codeGenerator-&gt;WK_ucfirst(GetJSBuiltinFunctionName($className, $attribute));
</span><span class="cx">     }
</span><span class="cx">     return &quot;setJS&quot; . $interfaceName . $codeGenerator-&gt;WK_ucfirst($attribute-&gt;signature-&gt;name) . ($attribute-&gt;signature-&gt;type =~ /Constructor$/ ? &quot;Constructor&quot; : &quot;&quot;);
</span><span class="lines">@@ -598,9 +598,9 @@
</span><span class="cx"> 
</span><span class="cx"> sub GetFunctionName
</span><span class="cx"> {
</span><del>-    my ($className, $function) = @_;
</del><ins>+    my ($interface, $className, $function) = @_;
</ins><span class="cx"> 
</span><del>-    if ($function-&gt;signature-&gt;extendedAttributes-&gt;{&quot;JSBuiltin&quot;}) {
</del><ins>+    if (IsJSBuiltin($interface, $function)) {
</ins><span class="cx">         return GetJSBuiltinFunctionName($className, $function);
</span><span class="cx">     }
</span><span class="cx"> 
</span><span class="lines">@@ -830,7 +830,7 @@
</span><span class="cx">         || $interface-&gt;extendedAttributes-&gt;{&quot;EventTarget&quot;}
</span><span class="cx">         || $interface-&gt;name eq &quot;EventTarget&quot;
</span><span class="cx">         || $interface-&gt;extendedAttributes-&gt;{&quot;ReportExtraMemoryCost&quot;}
</span><del>-        || $interface-&gt;extendedAttributes-&gt;{&quot;JSBuiltinConstructor&quot;};
</del><ins>+        || IsJSBuiltinConstructor($interface)
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> sub GetImplClassName
</span><span class="lines">@@ -1295,7 +1295,7 @@
</span><span class="cx"> 
</span><span class="cx">             my $conditionalString = $codeGenerator-&gt;GenerateConditionalString($function-&gt;signature);
</span><span class="cx">             push(@headerContent, &quot;#if ${conditionalString}\n&quot;) if $conditionalString;
</span><del>-            my $functionName = GetFunctionName($className, $function);
</del><ins>+            my $functionName = GetFunctionName($interface, $className, $function);
</ins><span class="cx">             push(@headerContent, &quot;JSC::EncodedJSValue JSC_HOST_CALL ${functionName}(JSC::ExecState*);\n&quot;);
</span><span class="cx">             push(@headerContent, &quot;#endif\n&quot;) if $conditionalString;
</span><span class="cx">         }
</span><span class="lines">@@ -1311,10 +1311,10 @@
</span><span class="cx"> 
</span><span class="cx">             my $conditionalString = $codeGenerator-&gt;GenerateConditionalString($attribute-&gt;signature);
</span><span class="cx">             push(@headerContent, &quot;#if ${conditionalString}\n&quot;) if $conditionalString;
</span><del>-            my $getter = GetAttributeGetterName($interfaceName, $className, $attribute);
</del><ins>+            my $getter = GetAttributeGetterName($interfaceName, $className, $interface, $attribute);
</ins><span class="cx">             push(@headerContent, &quot;JSC::EncodedJSValue ${getter}(JSC::ExecState*, JSC::JSObject*, JSC::EncodedJSValue, JSC::PropertyName);\n&quot;);
</span><span class="cx">             if (!IsReadonly($attribute)) {
</span><del>-                my $setter = GetAttributeSetterName($interfaceName, $className, $attribute);
</del><ins>+                my $setter = GetAttributeSetterName($interfaceName, $className, $interface, $attribute);
</ins><span class="cx">                 push(@headerContent, &quot;void ${setter}(JSC::ExecState*, JSC::JSObject*, JSC::EncodedJSValue, JSC::EncodedJSValue);\n&quot;);
</span><span class="cx">             }
</span><span class="cx">             push(@headerContent, &quot;#endif\n&quot;) if $conditionalString;
</span><span class="lines">@@ -1393,18 +1393,18 @@
</span><span class="cx"> 
</span><span class="cx">         push(@specials, &quot;DontEnum&quot;) if ($attribute-&gt;signature-&gt;extendedAttributes-&gt;{&quot;NotEnumerable&quot;} || $is_global_constructor);
</span><span class="cx">         push(@specials, &quot;ReadOnly&quot;) if IsReadonly($attribute);
</span><del>-        push(@specials, &quot;CustomAccessor&quot;) unless $is_global_constructor or $attribute-&gt;signature-&gt;extendedAttributes-&gt;{&quot;JSBuiltin&quot;};
-        push(@specials, &quot;Accessor | Builtin&quot;) if  $attribute-&gt;signature-&gt;extendedAttributes-&gt;{&quot;JSBuiltin&quot;};
</del><ins>+        push(@specials, &quot;CustomAccessor&quot;) unless $is_global_constructor or IsJSBuiltin($interface, $attribute);
+        push(@specials, &quot;Accessor | Builtin&quot;) if  IsJSBuiltin($interface, $attribute);
</ins><span class="cx">         my $special = (@specials &gt; 0) ? join(&quot; | &quot;, @specials) : &quot;0&quot;;
</span><span class="cx">         push(@$hashSpecials, $special);
</span><span class="cx"> 
</span><del>-        my $getter = GetAttributeGetterName($interfaceName, $className, $attribute);
</del><ins>+        my $getter = GetAttributeGetterName($interfaceName, $className, $interface, $attribute);
</ins><span class="cx">         push(@$hashValue1, $getter);
</span><span class="cx"> 
</span><span class="cx">         if (IsReadonly($attribute)) {
</span><span class="cx">             push(@$hashValue2, &quot;0&quot;);
</span><span class="cx">         } else {
</span><del>-            my $setter = GetAttributeSetterName($interfaceName, $className, $attribute);
</del><ins>+            my $setter = GetAttributeSetterName($interfaceName, $className, $interface, $attribute);
</ins><span class="cx">             push(@$hashValue2, $setter);
</span><span class="cx">         }
</span><span class="cx"> 
</span><span class="lines">@@ -1809,7 +1809,7 @@
</span><span class="cx">             next if $function-&gt;{overloadIndex} &amp;&amp; $function-&gt;{overloadIndex} &gt; 1;
</span><span class="cx">             next if $function-&gt;signature-&gt;extendedAttributes-&gt;{&quot;ForwardDeclareInHeader&quot;};
</span><span class="cx">             next if $function-&gt;signature-&gt;extendedAttributes-&gt;{&quot;CustomBinding&quot;};
</span><del>-            next if $function-&gt;signature-&gt;extendedAttributes-&gt;{&quot;JSBuiltin&quot;};
</del><ins>+            next if IsJSBuiltin($interface, $function);
</ins><span class="cx"> 
</span><span class="cx">             my $needsAppleCopyright = $function-&gt;signature-&gt;extendedAttributes-&gt;{&quot;AppleCopyright&quot;};
</span><span class="cx">             if ($needsAppleCopyright) {
</span><span class="lines">@@ -1824,7 +1824,7 @@
</span><span class="cx"> 
</span><span class="cx">             my $conditionalString = $codeGenerator-&gt;GenerateConditionalString($function-&gt;signature);
</span><span class="cx">             push(@implContent, &quot;#if ${conditionalString}\n&quot;) if $conditionalString;
</span><del>-            my $functionName = GetFunctionName($className, $function);
</del><ins>+            my $functionName = GetFunctionName($interface, $className, $function);
</ins><span class="cx">             push(@implContent, &quot;JSC::EncodedJSValue JSC_HOST_CALL ${functionName}(JSC::ExecState*);\n&quot;);
</span><span class="cx">             push(@implContent, &quot;#endif\n&quot;) if $conditionalString;
</span><span class="cx">         }
</span><span class="lines">@@ -1838,14 +1838,14 @@
</span><span class="cx">         push(@implContent, &quot;// Attributes\n\n&quot;);
</span><span class="cx">         foreach my $attribute (@{$interface-&gt;attributes}) {
</span><span class="cx">             next if $attribute-&gt;signature-&gt;extendedAttributes-&gt;{&quot;ForwardDeclareInHeader&quot;};
</span><del>-            next if $attribute-&gt;signature-&gt;extendedAttributes-&gt;{&quot;JSBuiltin&quot;};
</del><ins>+            next if IsJSBuiltin($interface, $attribute);
</ins><span class="cx"> 
</span><span class="cx">             my $conditionalString = $codeGenerator-&gt;GenerateConditionalString($attribute-&gt;signature);
</span><span class="cx">             push(@implContent, &quot;#if ${conditionalString}\n&quot;) if $conditionalString;
</span><del>-            my $getter = GetAttributeGetterName($interfaceName, $className, $attribute);
</del><ins>+            my $getter = GetAttributeGetterName($interfaceName, $className, $interface, $attribute);
</ins><span class="cx">             push(@implContent, &quot;JSC::EncodedJSValue ${getter}(JSC::ExecState*, JSC::JSObject*, JSC::EncodedJSValue, JSC::PropertyName);\n&quot;);
</span><span class="cx">             if (!IsReadonly($attribute)) {
</span><del>-                my $setter = GetAttributeSetterName($interfaceName, $className, $attribute);
</del><ins>+                my $setter = GetAttributeSetterName($interfaceName, $className, $interface, $attribute);
</ins><span class="cx">                 push(@implContent, &quot;void ${setter}(JSC::ExecState*, JSC::JSObject*, JSC::EncodedJSValue, JSC::EncodedJSValue);\n&quot;);
</span><span class="cx">             }
</span><span class="cx">             push(@implContent, &quot;#endif\n&quot;) if $conditionalString;
</span><span class="lines">@@ -1935,13 +1935,13 @@
</span><span class="cx">             my $special = (@specials &gt; 0) ? join(&quot; | &quot;, @specials) : &quot;0&quot;;
</span><span class="cx">             push(@hashSpecials, $special);
</span><span class="cx"> 
</span><del>-            my $getter = GetAttributeGetterName($interfaceName, $className, $attribute);
</del><ins>+            my $getter = GetAttributeGetterName($interfaceName, $className, $interface, $attribute);
</ins><span class="cx">             push(@hashValue1, $getter);
</span><span class="cx"> 
</span><span class="cx">             if (IsReadonly($attribute)) {
</span><span class="cx">                 push(@hashValue2, &quot;0&quot;);
</span><span class="cx">             } else {
</span><del>-                my $setter = GetAttributeSetterName($interfaceName, $className, $attribute);
</del><ins>+                my $setter = GetAttributeSetterName($interfaceName, $className, $interface, $attribute);
</ins><span class="cx">                 push(@hashValue2, $setter);
</span><span class="cx">             }
</span><span class="cx"> 
</span><span class="lines">@@ -1959,7 +1959,7 @@
</span><span class="cx">             my $name = $function-&gt;signature-&gt;name;
</span><span class="cx">             push(@hashKeys, $name);
</span><span class="cx"> 
</span><del>-            my $functionName = GetFunctionName($className, $function);
</del><ins>+            my $functionName = GetFunctionName($interface, $className, $function);
</ins><span class="cx">             push(@hashValue1, $functionName);
</span><span class="cx"> 
</span><span class="cx">             my $functionLength = GetFunctionLength($function);
</span><span class="lines">@@ -2031,7 +2031,7 @@
</span><span class="cx">         my $name = $function-&gt;signature-&gt;name;
</span><span class="cx">         push(@hashKeys, $name);
</span><span class="cx"> 
</span><del>-        my $functionName = GetFunctionName($className, $function);
</del><ins>+        my $functionName = GetFunctionName($interface, $className, $function);
</ins><span class="cx">         push(@hashValue1, $functionName);
</span><span class="cx"> 
</span><span class="cx">         my $functionLength = GetFunctionLength($function);
</span><span class="lines">@@ -2107,7 +2107,7 @@
</span><span class="cx">                 AddToImplIncludes(&quot;WebCoreJSClientData.h&quot;);
</span><span class="cx">                 push(@implContent, &quot;    JSVMClientData&amp; clientData = *static_cast&lt;JSVMClientData*&gt;(vm.clientData);\n&quot;) if $firstPrivateFunction;
</span><span class="cx">                 $firstPrivateFunction = 0;
</span><del>-                push(@implContent, &quot;    putDirect(vm, clientData.builtinNames().&quot; . $function-&gt;signature-&gt;name . &quot;PrivateName(), JSFunction::create(vm, globalObject(), 0, String(), &quot; . GetFunctionName($className, $function) . &quot;), ReadOnly | DontEnum);\n&quot;);
</del><ins>+                push(@implContent, &quot;    putDirect(vm, clientData.builtinNames().&quot; . $function-&gt;signature-&gt;name . &quot;PrivateName(), JSFunction::create(vm, globalObject(), 0, String(), &quot; . GetFunctionName($interface, $className, $function) . &quot;), ReadOnly | DontEnum);\n&quot;);
</ins><span class="cx">             }
</span><span class="cx"> 
</span><span class="cx">             push(@implContent, &quot;}\n\n&quot;);
</span><span class="lines">@@ -2271,14 +2271,14 @@
</span><span class="cx">     $numAttributes = $numAttributes + 1 if NeedsConstructorProperty($interface);
</span><span class="cx">     if ($numAttributes &gt; 0) {
</span><span class="cx">         foreach my $attribute (@{$interface-&gt;attributes}) {
</span><del>-            next if $attribute-&gt;signature-&gt;extendedAttributes-&gt;{&quot;JSBuiltin&quot;};
</del><ins>+            next if IsJSBuiltin($interface, $attribute);
</ins><span class="cx"> 
</span><span class="cx">             my $name = $attribute-&gt;signature-&gt;name;
</span><span class="cx">             my $type = $attribute-&gt;signature-&gt;type;
</span><span class="cx">             # Nullable wrapper types do not need any special handling as the implementation can return a null pointer.
</span><span class="cx">             my $isNullable = $attribute-&gt;signature-&gt;isNullable &amp;&amp; !$codeGenerator-&gt;IsWrapperType($type);
</span><span class="cx">             $codeGenerator-&gt;AssertNotSequenceType($type);
</span><del>-            my $getFunctionName = GetAttributeGetterName($interfaceName, $className, $attribute);
</del><ins>+            my $getFunctionName = GetAttributeGetterName($interfaceName, $className, $interface, $attribute);
</ins><span class="cx">             my $implGetterFunctionName = $codeGenerator-&gt;WK_lcfirst($attribute-&gt;signature-&gt;extendedAttributes-&gt;{&quot;ImplementedAs&quot;} || $name);
</span><span class="cx">             my $getterExceptions = $attribute-&gt;signature-&gt;extendedAttributes-&gt;{&quot;GetterRaisesException&quot;};
</span><span class="cx"> 
</span><span class="lines">@@ -2617,11 +2617,11 @@
</span><span class="cx"> 
</span><span class="cx">     foreach my $attribute (@{$interface-&gt;attributes}) {
</span><span class="cx">         if (!IsReadonly($attribute)) {
</span><del>-            next if $attribute-&gt;signature-&gt;extendedAttributes-&gt;{&quot;JSBuiltin&quot;};
</del><ins>+            next if IsJSBuiltin($interface, $attribute);
</ins><span class="cx"> 
</span><span class="cx">             my $name = $attribute-&gt;signature-&gt;name;
</span><span class="cx">             my $type = $attribute-&gt;signature-&gt;type;
</span><del>-            my $putFunctionName = GetAttributeSetterName($interfaceName, $className, $attribute);
</del><ins>+            my $putFunctionName = GetAttributeSetterName($interfaceName, $className, $interface, $attribute);
</ins><span class="cx">             my $implSetterFunctionName = $codeGenerator-&gt;WK_ucfirst($name);
</span><span class="cx">             my $setterRaisesException = $attribute-&gt;signature-&gt;extendedAttributes-&gt;{&quot;SetterRaisesException&quot;};
</span><span class="cx"> 
</span><span class="lines">@@ -2853,7 +2853,7 @@
</span><span class="cx">         my $inAppleCopyright = 0;
</span><span class="cx">         foreach my $function (@{$interface-&gt;functions}) {
</span><span class="cx">             next if $function-&gt;signature-&gt;extendedAttributes-&gt;{&quot;CustomBinding&quot;};
</span><del>-            next if $function-&gt;signature-&gt;extendedAttributes-&gt;{&quot;JSBuiltin&quot;};
</del><ins>+            next if IsJSBuiltin($interface, $function);
</ins><span class="cx">             my $needsAppleCopyright = $function-&gt;signature-&gt;extendedAttributes-&gt;{&quot;AppleCopyright&quot;};
</span><span class="cx">             if ($needsAppleCopyright) {
</span><span class="cx">                 if (!$inAppleCopyright) {
</span><span class="lines">@@ -2873,7 +2873,7 @@
</span><span class="cx"> 
</span><span class="cx">             AddIncludesForTypeInImpl($function-&gt;signature-&gt;type) unless $isCustom or IsReturningPromise($function);
</span><span class="cx"> 
</span><del>-            my $functionName = GetFunctionName($className, $function);
</del><ins>+            my $functionName = GetFunctionName($interface, $className, $function);
</ins><span class="cx"> 
</span><span class="cx">             my $conditional = $function-&gt;signature-&gt;extendedAttributes-&gt;{&quot;Conditional&quot;};
</span><span class="cx">             if ($conditional) {
</span><span class="lines">@@ -4599,9 +4599,9 @@
</span><span class="cx"> sub GetConstructorTemplateClassName
</span><span class="cx"> {
</span><span class="cx">     my $interface = shift;
</span><del>-    return &quot;JSBuiltinConstructor&quot; if ($interface-&gt;extendedAttributes-&gt;{&quot;JSBuiltinConstructor&quot;});
</del><span class="cx">     return &quot;JSDOMConstructorNotConstructable&quot; if ($interface-&gt;extendedAttributes-&gt;{&quot;NamedConstructor&quot;});
</span><span class="cx">     return &quot;JSDOMConstructorNotConstructable&quot; unless IsConstructable($interface);
</span><ins>+    return &quot;JSBuiltinConstructor&quot; if IsJSBuiltinConstructor($interface);
</ins><span class="cx">     return &quot;JSDOMConstructor&quot;;
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="lines">@@ -4705,7 +4705,7 @@
</span><span class="cx">     my $generatingNamedConstructor = shift;
</span><span class="cx">     my $function = shift;
</span><span class="cx"> 
</span><del>-    return if ($interface-&gt;extendedAttributes-&gt;{&quot;JSBuiltinConstructor&quot;});
</del><ins>+    return if IsJSBuiltinConstructor($interface);
</ins><span class="cx"> 
</span><span class="cx">     my $constructorClassName = $generatingNamedConstructor ? &quot;${className}NamedConstructor&quot; : &quot;${className}Constructor&quot;;
</span><span class="cx"> 
</span><span class="lines">@@ -4955,7 +4955,7 @@
</span><span class="cx">         push(@$outputArray, &quot;\n&quot;);
</span><span class="cx">     }
</span><span class="cx"> 
</span><del>-    if ($interface-&gt;extendedAttributes-&gt;{&quot;JSBuiltinConstructor&quot;}) {
</del><ins>+    if (IsJSBuiltinConstructor($interface)) {
</ins><span class="cx">         push(@$outputArray, &quot;template&lt;&gt; FunctionExecutable* ${constructorClassName}::initializeExecutable(VM&amp; vm)\n&quot;);
</span><span class="cx">         push(@$outputArray, &quot;{\n&quot;);
</span><span class="cx">         push(@$outputArray, &quot;    return &quot; . GetJSBuiltinFunctionNameFromString($interfaceName, &quot;initialize&quot; . $interfaceName) . &quot;(vm);\n&quot;);
</span><span class="lines">@@ -5009,7 +5009,7 @@
</span><span class="cx"> {
</span><span class="cx">     my $interface = shift;
</span><span class="cx"> 
</span><del>-    return HasCustomConstructor($interface) || $interface-&gt;extendedAttributes-&gt;{&quot;Constructor&quot;} || $interface-&gt;extendedAttributes-&gt;{&quot;NamedConstructor&quot;} || $interface-&gt;extendedAttributes-&gt;{&quot;ConstructorTemplate&quot;} || $interface-&gt;extendedAttributes-&gt;{&quot;JSBuiltinConstructor&quot;};
</del><ins>+    return HasCustomConstructor($interface) || $interface-&gt;extendedAttributes-&gt;{&quot;Constructor&quot;} || $interface-&gt;extendedAttributes-&gt;{&quot;NamedConstructor&quot;} || $interface-&gt;extendedAttributes-&gt;{&quot;ConstructorTemplate&quot;};
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> sub HeaderNeedsPrototypeDeclaration
</span><span class="lines">@@ -5028,7 +5028,7 @@
</span><span class="cx">     push(@specials, &quot;DontDelete&quot;) if $function-&gt;signature-&gt;extendedAttributes-&gt;{&quot;Unforgeable&quot;}
</span><span class="cx">        || $interface-&gt;extendedAttributes-&gt;{&quot;Unforgeable&quot;};
</span><span class="cx">     push(@specials, &quot;DontEnum&quot;) if $function-&gt;signature-&gt;extendedAttributes-&gt;{&quot;NotEnumerable&quot;};
</span><del>-    if ($function-&gt;signature-&gt;extendedAttributes-&gt;{&quot;JSBuiltin&quot;}) {
</del><ins>+    if (IsJSBuiltin($interface, $function)) {
</ins><span class="cx">         push(@specials, &quot;JSC::Builtin&quot;);
</span><span class="cx">     }
</span><span class="cx">     else {
</span><span class="lines">@@ -5037,6 +5037,29 @@
</span><span class="cx">     return (@specials &gt; 0) ? join(&quot; | &quot;, @specials) : &quot;0&quot;;
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+sub IsJSBuiltin
+{
+    my ($interface, $object) = @_;
+
+    return 0 if $object-&gt;signature-&gt;extendedAttributes-&gt;{&quot;Custom&quot;};
+    return 0 if $object-&gt;signature-&gt;extendedAttributes-&gt;{&quot;CustomGetter&quot;};
+    return 0 if $object-&gt;signature-&gt;extendedAttributes-&gt;{&quot;CustomSetter&quot;};
+
+    return 1 if $object-&gt;signature-&gt;extendedAttributes-&gt;{&quot;JSBuiltin&quot;};
+    return 1 if $interface-&gt;extendedAttributes-&gt;{&quot;JSBuiltin&quot;};
+
+    return 0;
+}
+
+sub IsJSBuiltinConstructor
+{
+    my ($interface) = @_;
+
+    return 0 if $interface-&gt;extendedAttributes-&gt;{&quot;CustomConstructor&quot;};
+    return 1 if $interface-&gt;extendedAttributes-&gt;{&quot;JSBuiltin&quot;};
+    return 0;
+}
+
</ins><span class="cx"> sub GetJSBuiltinFunctionName
</span><span class="cx"> {
</span><span class="cx">     my ($className, $function) = @_;
</span><span class="lines">@@ -5064,17 +5087,17 @@
</span><span class="cx"> {
</span><span class="cx">     my $interface = shift;
</span><span class="cx"> 
</span><del>-    if ($interface-&gt;extendedAttributes-&gt;{&quot;JSBuiltinConstructor&quot;}) {
</del><ins>+    if ($interface-&gt;extendedAttributes-&gt;{&quot;JSBuiltin&quot;}) {
</ins><span class="cx">         AddToImplIncludes($interface-&gt;name . &quot;Builtins.h&quot;);
</span><span class="cx">         return;
</span><span class="cx">     }
</span><span class="cx"> 
</span><span class="cx">     foreach my $function (@{$interface-&gt;functions}) {
</span><del>-        AddToImplIncludes(GetJSBuiltinScopeName($interface, $function) . &quot;Builtins.h&quot;, $function-&gt;signature-&gt;extendedAttributes-&gt;{&quot;Conditional&quot;}) if $function-&gt;signature-&gt;extendedAttributes-&gt;{&quot;JSBuiltin&quot;};
</del><ins>+        AddToImplIncludes(GetJSBuiltinScopeName($interface, $function) . &quot;Builtins.h&quot;, $function-&gt;signature-&gt;extendedAttributes-&gt;{&quot;Conditional&quot;}) if IsJSBuiltin($interface, $function);
</ins><span class="cx">     }
</span><span class="cx"> 
</span><span class="cx">     foreach my $attribute (@{$interface-&gt;attributes}) {
</span><del>-        AddToImplIncludes(GetJSBuiltinScopeName($interface, $attribute) . &quot;Builtins.h&quot;, $attribute-&gt;signature-&gt;extendedAttributes-&gt;{&quot;Conditional&quot;}) if $attribute-&gt;signature-&gt;extendedAttributes-&gt;{&quot;JSBuiltin&quot;};
</del><ins>+        AddToImplIncludes(GetJSBuiltinScopeName($interface, $attribute) . &quot;Builtins.h&quot;, $attribute-&gt;signature-&gt;extendedAttributes-&gt;{&quot;Conditional&quot;}) if IsJSBuiltin($interface, $attribute);
</ins><span class="cx">     }
</span><span class="cx"> }
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestGObjectWebKitDOMTestJSBuiltinConstructorcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/GObject/WebKitDOMTestJSBuiltinConstructor.cpp (191884 => 191885)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/GObject/WebKitDOMTestJSBuiltinConstructor.cpp        2015-11-02 10:33:44 UTC (rev 191884)
+++ trunk/Source/WebCore/bindings/scripts/test/GObject/WebKitDOMTestJSBuiltinConstructor.cpp        2015-11-02 11:00:35 UTC (rev 191885)
</span><span class="lines">@@ -67,6 +67,11 @@
</span><span class="cx"> 
</span><span class="cx"> G_DEFINE_TYPE(WebKitDOMTestJSBuiltinConstructor, webkit_dom_test_js_builtin_constructor, WEBKIT_DOM_TYPE_OBJECT)
</span><span class="cx"> 
</span><ins>+enum {
+    PROP_0,
+    PROP_TEST_ATTRIBUTE,
+};
+
</ins><span class="cx"> static void webkit_dom_test_js_builtin_constructor_finalize(GObject* object)
</span><span class="cx"> {
</span><span class="cx">     WebKitDOMTestJSBuiltinConstructorPrivate* priv = WEBKIT_DOM_TEST_JS_BUILTIN_CONSTRUCTOR_GET_PRIVATE(object);
</span><span class="lines">@@ -77,6 +82,34 @@
</span><span class="cx">     G_OBJECT_CLASS(webkit_dom_test_js_builtin_constructor_parent_class)-&gt;finalize(object);
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+static void webkit_dom_test_js_builtin_constructor_set_property(GObject* object, guint propertyId, const GValue* value, GParamSpec* pspec)
+{
+    WebKitDOMTestJSBuiltinConstructor* self = WEBKIT_DOM_TEST_JS_BUILTIN_CONSTRUCTOR(object);
+
+    switch (propertyId) {
+    case PROP_TEST_ATTRIBUTE:
+        webkit_dom_test_js_builtin_constructor_set_test_attribute(self, g_value_get_boolean(value));
+        break;
+    default:
+        G_OBJECT_WARN_INVALID_PROPERTY_ID(object, propertyId, pspec);
+        break;
+    }
+}
+
+static void webkit_dom_test_js_builtin_constructor_get_property(GObject* object, guint propertyId, GValue* value, GParamSpec* pspec)
+{
+    WebKitDOMTestJSBuiltinConstructor* self = WEBKIT_DOM_TEST_JS_BUILTIN_CONSTRUCTOR(object);
+
+    switch (propertyId) {
+    case PROP_TEST_ATTRIBUTE:
+        g_value_set_boolean(value, webkit_dom_test_js_builtin_constructor_get_test_attribute(self));
+        break;
+    default:
+        G_OBJECT_WARN_INVALID_PROPERTY_ID(object, propertyId, pspec);
+        break;
+    }
+}
+
</ins><span class="cx"> static GObject* webkit_dom_test_js_builtin_constructor_constructor(GType type, guint constructPropertiesCount, GObjectConstructParam* constructProperties)
</span><span class="cx"> {
</span><span class="cx">     GObject* object = G_OBJECT_CLASS(webkit_dom_test_js_builtin_constructor_parent_class)-&gt;constructor(type, constructPropertiesCount, constructProperties);
</span><span class="lines">@@ -94,6 +127,19 @@
</span><span class="cx">     g_type_class_add_private(gobjectClass, sizeof(WebKitDOMTestJSBuiltinConstructorPrivate));
</span><span class="cx">     gobjectClass-&gt;constructor = webkit_dom_test_js_builtin_constructor_constructor;
</span><span class="cx">     gobjectClass-&gt;finalize = webkit_dom_test_js_builtin_constructor_finalize;
</span><ins>+    gobjectClass-&gt;set_property = webkit_dom_test_js_builtin_constructor_set_property;
+    gobjectClass-&gt;get_property = webkit_dom_test_js_builtin_constructor_get_property;
+
+    g_object_class_install_property(
+        gobjectClass,
+        PROP_TEST_ATTRIBUTE,
+        g_param_spec_boolean(
+            &quot;test-attribute&quot;,
+            &quot;TestJSBuiltinConstructor:test-attribute&quot;,
+            &quot;read-write gboolean TestJSBuiltinConstructor:test-attribute&quot;,
+            FALSE,
+            WEBKIT_PARAM_READWRITE));
+
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> static void webkit_dom_test_js_builtin_constructor_init(WebKitDOMTestJSBuiltinConstructor* request)
</span><span class="lines">@@ -102,3 +148,28 @@
</span><span class="cx">     new (priv) WebKitDOMTestJSBuiltinConstructorPrivate();
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+void webkit_dom_test_js_builtin_constructor_test_function(WebKitDOMTestJSBuiltinConstructor* self)
+{
+    WebCore::JSMainThreadNullState state;
+    g_return_if_fail(WEBKIT_DOM_IS_TEST_JS_BUILTIN_CONSTRUCTOR(self));
+    WebCore::TestJSBuiltinConstructor* item = WebKit::core(self);
+    item-&gt;testFunction();
+}
+
+gboolean webkit_dom_test_js_builtin_constructor_get_test_attribute(WebKitDOMTestJSBuiltinConstructor* self)
+{
+    WebCore::JSMainThreadNullState state;
+    g_return_val_if_fail(WEBKIT_DOM_IS_TEST_JS_BUILTIN_CONSTRUCTOR(self), FALSE);
+    WebCore::TestJSBuiltinConstructor* item = WebKit::core(self);
+    gboolean result = item-&gt;testAttribute();
+    return result;
+}
+
+void webkit_dom_test_js_builtin_constructor_set_test_attribute(WebKitDOMTestJSBuiltinConstructor* self, gboolean value)
+{
+    WebCore::JSMainThreadNullState state;
+    g_return_if_fail(WEBKIT_DOM_IS_TEST_JS_BUILTIN_CONSTRUCTOR(self));
+    WebCore::TestJSBuiltinConstructor* item = WebKit::core(self);
+    item-&gt;setTestAttribute(value);
+}
+
</ins></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestGObjectWebKitDOMTestJSBuiltinConstructorh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/GObject/WebKitDOMTestJSBuiltinConstructor.h (191884 => 191885)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/GObject/WebKitDOMTestJSBuiltinConstructor.h        2015-11-02 10:33:44 UTC (rev 191884)
+++ trunk/Source/WebCore/bindings/scripts/test/GObject/WebKitDOMTestJSBuiltinConstructor.h        2015-11-02 11:00:35 UTC (rev 191885)
</span><span class="lines">@@ -47,6 +47,36 @@
</span><span class="cx"> WEBKIT_API GType
</span><span class="cx"> webkit_dom_test_js_builtin_constructor_get_type(void);
</span><span class="cx"> 
</span><ins>+/**
+ * webkit_dom_test_js_builtin_constructor_test_function:
+ * @self: A #WebKitDOMTestJSBuiltinConstructor
+ *
+ * Stability: Unstable
+**/
+WEBKIT_API void
+webkit_dom_test_js_builtin_constructor_test_function(WebKitDOMTestJSBuiltinConstructor* self);
+
+/**
+ * webkit_dom_test_js_builtin_constructor_get_test_attribute:
+ * @self: A #WebKitDOMTestJSBuiltinConstructor
+ *
+ * Returns: A #gboolean
+ *
+ * Stability: Unstable
+**/
+WEBKIT_API gboolean
+webkit_dom_test_js_builtin_constructor_get_test_attribute(WebKitDOMTestJSBuiltinConstructor* self);
+
+/**
+ * webkit_dom_test_js_builtin_constructor_set_test_attribute:
+ * @self: A #WebKitDOMTestJSBuiltinConstructor
+ * @value: A #gboolean
+ *
+ * Stability: Unstable
+**/
+WEBKIT_API void
+webkit_dom_test_js_builtin_constructor_set_test_attribute(WebKitDOMTestJSBuiltinConstructor* self, gboolean value);
+
</ins><span class="cx"> G_END_DECLS
</span><span class="cx"> 
</span><span class="cx"> #endif /* WEBKIT_DOM_USE_UNSTABLE_API */
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestJSBuiltinConstructorcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestJSBuiltinConstructor.cpp (191884 => 191885)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestJSBuiltinConstructor.cpp        2015-11-02 10:33:44 UTC (rev 191884)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestJSBuiltinConstructor.cpp        2015-11-02 11:00:35 UTC (rev 191885)
</span><span class="lines">@@ -24,14 +24,22 @@
</span><span class="cx"> #include &quot;JSDOMBinding.h&quot;
</span><span class="cx"> #include &quot;JSDOMConstructor.h&quot;
</span><span class="cx"> #include &quot;TestJSBuiltinConstructorBuiltins.h&quot;
</span><ins>+#include &lt;runtime/Error.h&gt;
</ins><span class="cx"> #include &lt;wtf/GetPtr.h&gt;
</span><span class="cx"> 
</span><span class="cx"> using namespace JSC;
</span><span class="cx"> 
</span><span class="cx"> namespace WebCore {
</span><span class="cx"> 
</span><ins>+// Functions
+
+JSC::EncodedJSValue JSC_HOST_CALL jsTestJSBuiltinConstructorPrototypeFunctionTestCustomFunction(JSC::ExecState*);
+
</ins><span class="cx"> // Attributes
</span><span class="cx"> 
</span><ins>+JSC::EncodedJSValue jsTestJSBuiltinConstructorTestAttributeCustom(JSC::ExecState*, JSC::JSObject*, JSC::EncodedJSValue, JSC::PropertyName);
+JSC::EncodedJSValue jsTestJSBuiltinConstructorTestAttributeRWCustom(JSC::ExecState*, JSC::JSObject*, JSC::EncodedJSValue, JSC::PropertyName);
+void setJSTestJSBuiltinConstructorTestAttributeRWCustom(JSC::ExecState*, JSC::JSObject*, JSC::EncodedJSValue, JSC::EncodedJSValue);
</ins><span class="cx"> JSC::EncodedJSValue jsTestJSBuiltinConstructorConstructor(JSC::ExecState*, JSC::JSObject*, JSC::EncodedJSValue, JSC::PropertyName);
</span><span class="cx"> 
</span><span class="cx"> class JSTestJSBuiltinConstructorPrototype : public JSC::JSNonFinalObject {
</span><span class="lines">@@ -61,6 +69,23 @@
</span><span class="cx"> 
</span><span class="cx"> typedef JSBuiltinConstructor&lt;JSTestJSBuiltinConstructor&gt; JSTestJSBuiltinConstructorConstructor;
</span><span class="cx"> 
</span><ins>+/* Hash table for constructor */
+
+static const struct CompactHashIndex JSTestJSBuiltinConstructorTableIndex[4] = {
+    { 0, -1 },
+    { -1, -1 },
+    { 1, -1 },
+    { -1, -1 },
+};
+
+
+static const HashTableValue JSTestJSBuiltinConstructorTableValues[] =
+{
+    { &quot;testAttributeCustom&quot;, DontDelete | ReadOnly | CustomAccessor, NoIntrinsic, { (intptr_t)static_cast&lt;PropertySlot::GetValueFunc&gt;(jsTestJSBuiltinConstructorTestAttributeCustom), (intptr_t) static_cast&lt;PutPropertySlot::PutValueFunc&gt;(0) } },
+    { &quot;testAttributeRWCustom&quot;, DontDelete | CustomAccessor, NoIntrinsic, { (intptr_t)static_cast&lt;PropertySlot::GetValueFunc&gt;(jsTestJSBuiltinConstructorTestAttributeRWCustom), (intptr_t) static_cast&lt;PutPropertySlot::PutValueFunc&gt;(setJSTestJSBuiltinConstructorTestAttributeRWCustom) } },
+};
+
+static const HashTable JSTestJSBuiltinConstructorTable = { 2, 3, true, JSTestJSBuiltinConstructorTableValues, JSTestJSBuiltinConstructorTableIndex };
</ins><span class="cx"> template&lt;&gt; void JSTestJSBuiltinConstructorConstructor::initializeProperties(VM&amp; vm, JSDOMGlobalObject&amp; globalObject)
</span><span class="cx"> {
</span><span class="cx">     putDirect(vm, vm.propertyNames-&gt;prototype, JSTestJSBuiltinConstructor::getPrototype(vm, &amp;globalObject), DontDelete | ReadOnly | DontEnum);
</span><span class="lines">@@ -80,6 +105,9 @@
</span><span class="cx"> static const HashTableValue JSTestJSBuiltinConstructorPrototypeTableValues[] =
</span><span class="cx"> {
</span><span class="cx">     { &quot;constructor&quot;, DontEnum | ReadOnly, NoIntrinsic, { (intptr_t)static_cast&lt;PropertySlot::GetValueFunc&gt;(jsTestJSBuiltinConstructorConstructor), (intptr_t) static_cast&lt;PutPropertySlot::PutValueFunc&gt;(0) } },
</span><ins>+    { &quot;testAttribute&quot;, Accessor | Builtin, NoIntrinsic, { (intptr_t)static_cast&lt;BuiltinGenerator&gt;(testJSBuiltinConstructorTestAttributeCodeGenerator), (intptr_t) (setTestJSBuiltinConstructorTestAttributeCodeGenerator) } },
+    { &quot;testFunction&quot;, JSC::Builtin, NoIntrinsic, { (intptr_t)static_cast&lt;BuiltinGenerator&gt;(testJSBuiltinConstructorTestFunctionCodeGenerator), (intptr_t) (0) } },
+    { &quot;testCustomFunction&quot;, JSC::Function, NoIntrinsic, { (intptr_t)static_cast&lt;NativeFunction&gt;(jsTestJSBuiltinConstructorPrototypeFunctionTestCustomFunction), (intptr_t) (0) } },
</ins><span class="cx"> };
</span><span class="cx"> 
</span><span class="cx"> const ClassInfo JSTestJSBuiltinConstructorPrototype::s_info = { &quot;TestJSBuiltinConstructorPrototype&quot;, &amp;Base::s_info, 0, CREATE_METHOD_TABLE(JSTestJSBuiltinConstructorPrototype) };
</span><span class="lines">@@ -90,7 +118,7 @@
</span><span class="cx">     reifyStaticProperties(vm, JSTestJSBuiltinConstructorPrototypeTableValues, *this);
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-const ClassInfo JSTestJSBuiltinConstructor::s_info = { &quot;TestJSBuiltinConstructor&quot;, &amp;Base::s_info, 0, CREATE_METHOD_TABLE(JSTestJSBuiltinConstructor) };
</del><ins>+const ClassInfo JSTestJSBuiltinConstructor::s_info = { &quot;TestJSBuiltinConstructor&quot;, &amp;Base::s_info, &amp;JSTestJSBuiltinConstructorTable, CREATE_METHOD_TABLE(JSTestJSBuiltinConstructor) };
</ins><span class="cx"> 
</span><span class="cx"> JSTestJSBuiltinConstructor::JSTestJSBuiltinConstructor(Structure* structure, JSDOMGlobalObject&amp; globalObject)
</span><span class="cx">     : JSDOMObject(structure, globalObject) { }
</span><span class="lines">@@ -111,6 +139,35 @@
</span><span class="cx">     thisObject-&gt;JSTestJSBuiltinConstructor::~JSTestJSBuiltinConstructor();
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+bool JSTestJSBuiltinConstructor::getOwnPropertySlot(JSObject* object, ExecState* state, PropertyName propertyName, PropertySlot&amp; slot)
+{
+    auto* thisObject = jsCast&lt;JSTestJSBuiltinConstructor*&gt;(object);
+    ASSERT_GC_OBJECT_INHERITS(thisObject, info());
+    if (getStaticValueSlot&lt;JSTestJSBuiltinConstructor, Base&gt;(state, JSTestJSBuiltinConstructorTable, thisObject, propertyName, slot))
+        return true;
+    return false;
+}
+
+EncodedJSValue jsTestJSBuiltinConstructorTestAttributeCustom(ExecState* state, JSObject* slotBase, EncodedJSValue thisValue, PropertyName)
+{
+    UNUSED_PARAM(state);
+    UNUSED_PARAM(slotBase);
+    UNUSED_PARAM(thisValue);
+    auto* castedThis = jsCast&lt;JSTestJSBuiltinConstructor*&gt;(slotBase);
+    return JSValue::encode(castedThis-&gt;testAttributeCustom(*state));
+}
+
+
+EncodedJSValue jsTestJSBuiltinConstructorTestAttributeRWCustom(ExecState* state, JSObject* slotBase, EncodedJSValue thisValue, PropertyName)
+{
+    UNUSED_PARAM(state);
+    UNUSED_PARAM(slotBase);
+    UNUSED_PARAM(thisValue);
+    auto* castedThis = jsCast&lt;JSTestJSBuiltinConstructor*&gt;(slotBase);
+    return JSValue::encode(castedThis-&gt;testAttributeRWCustom(*state));
+}
+
+
</ins><span class="cx"> EncodedJSValue jsTestJSBuiltinConstructorConstructor(ExecState* state, JSObject* baseValue, EncodedJSValue, PropertyName)
</span><span class="cx"> {
</span><span class="cx">     JSTestJSBuiltinConstructorPrototype* domObject = jsDynamicCast&lt;JSTestJSBuiltinConstructorPrototype*&gt;(baseValue);
</span><span class="lines">@@ -119,11 +176,33 @@
</span><span class="cx">     return JSValue::encode(JSTestJSBuiltinConstructor::getConstructor(state-&gt;vm(), domObject-&gt;globalObject()));
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+void setJSTestJSBuiltinConstructorTestAttributeRWCustom(ExecState* state, JSObject* baseObject, EncodedJSValue thisValue, EncodedJSValue encodedValue)
+{
+    JSValue value = JSValue::decode(encodedValue);
+    UNUSED_PARAM(baseObject);
+    UNUSED_PARAM(thisValue);
+    auto* castedThis = jsCast&lt;JSTestJSBuiltinConstructor*&gt;(baseObject);
+    UNUSED_PARAM(thisValue);
+    UNUSED_PARAM(state);
+    castedThis-&gt;setTestAttributeRWCustom(*state, value);
+}
+
+
</ins><span class="cx"> JSValue JSTestJSBuiltinConstructor::getConstructor(VM&amp; vm, JSGlobalObject* globalObject)
</span><span class="cx"> {
</span><span class="cx">     return getDOMConstructor&lt;JSTestJSBuiltinConstructorConstructor&gt;(vm, *jsCast&lt;JSDOMGlobalObject*&gt;(globalObject));
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+EncodedJSValue JSC_HOST_CALL jsTestJSBuiltinConstructorPrototypeFunctionTestCustomFunction(ExecState* state)
+{
+    JSValue thisValue = state-&gt;thisValue();
+    JSTestJSBuiltinConstructor* castedThis = jsDynamicCast&lt;JSTestJSBuiltinConstructor*&gt;(thisValue);
+    if (UNLIKELY(!castedThis))
+        return throwThisTypeError(*state, &quot;TestJSBuiltinConstructor&quot;, &quot;testCustomFunction&quot;);
+    ASSERT_GC_OBJECT_INHERITS(castedThis, JSTestJSBuiltinConstructor::info());
+    return JSValue::encode(castedThis-&gt;testCustomFunction(*state));
+}
+
</ins><span class="cx"> void JSTestJSBuiltinConstructor::visitChildren(JSCell* cell, SlotVisitor&amp; visitor)
</span><span class="cx"> {
</span><span class="cx">     auto* thisObject = jsCast&lt;JSTestJSBuiltinConstructor*&gt;(cell);
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestJSJSTestJSBuiltinConstructorh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestJSBuiltinConstructor.h (191884 => 191885)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestJSBuiltinConstructor.h        2015-11-02 10:33:44 UTC (rev 191884)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestJSBuiltinConstructor.h        2015-11-02 11:00:35 UTC (rev 191885)
</span><span class="lines">@@ -37,6 +37,7 @@
</span><span class="cx"> 
</span><span class="cx">     static JSC::JSObject* createPrototype(JSC::VM&amp;, JSC::JSGlobalObject*);
</span><span class="cx">     static JSC::JSObject* getPrototype(JSC::VM&amp;, JSC::JSGlobalObject*);
</span><ins>+    static bool getOwnPropertySlot(JSC::JSObject*, JSC::ExecState*, JSC::PropertyName, JSC::PropertySlot&amp;);
</ins><span class="cx">     static void destroy(JSC::JSCell*);
</span><span class="cx"> 
</span><span class="cx">     DECLARE_INFO;
</span><span class="lines">@@ -49,6 +50,16 @@
</span><span class="cx">     static JSC::JSValue getConstructor(JSC::VM&amp;, JSC::JSGlobalObject*);
</span><span class="cx">     static void visitChildren(JSCell*, JSC::SlotVisitor&amp;);
</span><span class="cx"> 
</span><ins>+
+    // Custom attributes
+    JSC::JSValue testAttributeCustom(JSC::ExecState&amp;) const;
+    JSC::JSValue testAttributeRWCustom(JSC::ExecState&amp;) const;
+    void setTestAttributeRWCustom(JSC::ExecState&amp;, JSC::JSValue);
+
+    // Custom functions
+    JSC::JSValue testCustomFunction(JSC::ExecState&amp;);
+public:
+    static const unsigned StructureFlags = JSC::OverridesGetOwnPropertySlot | Base::StructureFlags;
</ins><span class="cx"> protected:
</span><span class="cx">     JSTestJSBuiltinConstructor(JSC::Structure*, JSDOMGlobalObject&amp;);
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestObjCDOMTestJSBuiltinConstructorh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/ObjC/DOMTestJSBuiltinConstructor.h (191884 => 191885)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/ObjC/DOMTestJSBuiltinConstructor.h        2015-11-02 10:33:44 UTC (rev 191884)
+++ trunk/Source/WebCore/bindings/scripts/test/ObjC/DOMTestJSBuiltinConstructor.h        2015-11-02 11:00:35 UTC (rev 191885)
</span><span class="lines">@@ -28,4 +28,10 @@
</span><span class="cx"> 
</span><span class="cx"> WEBKIT_CLASS_AVAILABLE_MAC(9876_5)
</span><span class="cx"> WEBCORE_EXPORT @interface DOMTestJSBuiltinConstructor : DOMObject
</span><ins>+@property BOOL testAttribute;
+@property (readonly) BOOL testAttributeCustom;
+@property BOOL testAttributeRWCustom;
+
+- (void)testFunction;
+- (void)testCustomFunction;
</ins><span class="cx"> @end
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestObjCDOMTestJSBuiltinConstructormm"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/ObjC/DOMTestJSBuiltinConstructor.mm (191884 => 191885)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/ObjC/DOMTestJSBuiltinConstructor.mm        2015-11-02 10:33:44 UTC (rev 191884)
+++ trunk/Source/WebCore/bindings/scripts/test/ObjC/DOMTestJSBuiltinConstructor.mm        2015-11-02 11:00:35 UTC (rev 191885)
</span><span class="lines">@@ -60,6 +60,48 @@
</span><span class="cx">     [super finalize];
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+- (BOOL)testAttribute
+{
+    WebCore::JSMainThreadNullState state;
+    return IMPL-&gt;testAttribute();
+}
+
+- (void)setTestAttribute:(BOOL)newTestAttribute
+{
+    WebCore::JSMainThreadNullState state;
+    IMPL-&gt;setTestAttribute(newTestAttribute);
+}
+
+- (BOOL)testAttributeCustom
+{
+    WebCore::JSMainThreadNullState state;
+    return IMPL-&gt;testAttributeCustom();
+}
+
+- (BOOL)testAttributeRWCustom
+{
+    WebCore::JSMainThreadNullState state;
+    return IMPL-&gt;testAttributeRWCustom();
+}
+
+- (void)setTestAttributeRWCustom:(BOOL)newTestAttributeRWCustom
+{
+    WebCore::JSMainThreadNullState state;
+    IMPL-&gt;setTestAttributeRWCustom(newTestAttributeRWCustom);
+}
+
+- (void)testFunction
+{
+    WebCore::JSMainThreadNullState state;
+    IMPL-&gt;testFunction();
+}
+
+- (void)testCustomFunction
+{
+    WebCore::JSMainThreadNullState state;
+    IMPL-&gt;testCustomFunction();
+}
+
</ins><span class="cx"> @end
</span><span class="cx"> 
</span><span class="cx"> WebCore::TestJSBuiltinConstructor* core(DOMTestJSBuiltinConstructor *wrapper)
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestTestCustomConstructoridl"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/TestCustomConstructor.idl (191884 => 191885)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/TestCustomConstructor.idl        2015-11-02 10:33:44 UTC (rev 191884)
+++ trunk/Source/WebCore/bindings/scripts/test/TestCustomConstructor.idl        2015-11-02 11:00:35 UTC (rev 191885)
</span><span class="lines">@@ -28,6 +28,7 @@
</span><span class="cx"> 
</span><span class="cx"> [
</span><span class="cx">     CustomConstructor,
</span><ins>+    JSBuiltIn,
</ins><span class="cx">     NoInterfaceObject
</span><span class="cx"> ] interface TestCustomConstructorWithNoInterfaceObject {
</span><span class="cx"> };
</span></span></pre></div>
<a id="trunkSourceWebCorebindingsscriptstestTestJSBuiltinConstructoridl"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/bindings/scripts/test/TestJSBuiltinConstructor.idl (191884 => 191885)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/bindings/scripts/test/TestJSBuiltinConstructor.idl        2015-11-02 10:33:44 UTC (rev 191884)
+++ trunk/Source/WebCore/bindings/scripts/test/TestJSBuiltinConstructor.idl        2015-11-02 11:00:35 UTC (rev 191885)
</span><span class="lines">@@ -27,7 +27,15 @@
</span><span class="cx">  */
</span><span class="cx"> 
</span><span class="cx"> [
</span><del>-    JSBuiltinConstructor
</del><ins>+    JSBuiltin,
+    Constructor
</ins><span class="cx"> ] interface TestJSBuiltinConstructor {
</span><ins>+
+    void testFunction();
+    attribute boolean testAttribute;
+
+    [ Custom ] void testCustomFunction();
+    [ CustomGetter ] readonly attribute boolean testAttributeCustom;
+    [ CustomGetter, CustomSetter ] attribute boolean testAttributeRWCustom;
+
</ins><span class="cx"> };
</span><del>-
</del></span></pre>
</div>
</div>

</body>
</html>