Title: [104684] trunk/Source/WebCore
Revision
104684
Author
[email protected]
Date
2012-01-11 01:24:56 -0800 (Wed, 11 Jan 2012)

Log Message

REGRESSION(r101445): [V8] Generated code for custom getters and setters
with the [Supplemental] IDL is wrong
https://bugs.webkit.org/show_bug.cgi?id=76034

Reviewed by Adam Barth.

This patch fixes the class name of the implementation of custom getters
and setters, as follows.

Previous V8TestInterface.cpp:
    // Attribute 'supplementalStr3'
    {"supplementalStr3", V8TestSupplemental::supplementalStr3AccessorGetter, V8TestSupplemental::supplementalStr3AccessorSetter, ...},

New V8TestInterface.cpp:
    // Attribute 'supplementalStr3'
    {"supplementalStr3", V8TestInterface::supplementalStr3AccessorGetter, V8TestInterface::supplementalStr3AccessorSetter, ...},

Test: bindings/scripts/test/TestInterface.idl
      bindings/scripts/test/TestSupplemental.idl

* bindings/scripts/CodeGeneratorV8.pm:
(GenerateSingleBatchedAttribute):
* bindings/scripts/test/V8/V8TestInterface.cpp:

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (104683 => 104684)


--- trunk/Source/WebCore/ChangeLog	2012-01-11 09:16:16 UTC (rev 104683)
+++ trunk/Source/WebCore/ChangeLog	2012-01-11 09:24:56 UTC (rev 104684)
@@ -1,3 +1,29 @@
+2012-01-11  Kentaro Hara  <[email protected]>
+
+        REGRESSION(r101445): [V8] Generated code for custom getters and setters
+        with the [Supplemental] IDL is wrong
+        https://bugs.webkit.org/show_bug.cgi?id=76034
+
+        Reviewed by Adam Barth.
+
+        This patch fixes the class name of the implementation of custom getters
+        and setters, as follows.
+
+        Previous V8TestInterface.cpp:
+            // Attribute 'supplementalStr3'
+            {"supplementalStr3", V8TestSupplemental::supplementalStr3AccessorGetter, V8TestSupplemental::supplementalStr3AccessorSetter, ...},
+
+        New V8TestInterface.cpp:
+            // Attribute 'supplementalStr3'
+            {"supplementalStr3", V8TestInterface::supplementalStr3AccessorGetter, V8TestInterface::supplementalStr3AccessorSetter, ...},
+
+        Test: bindings/scripts/test/TestInterface.idl
+              bindings/scripts/test/TestSupplemental.idl
+
+        * bindings/scripts/CodeGeneratorV8.pm:
+        (GenerateSingleBatchedAttribute):
+        * bindings/scripts/test/V8/V8TestInterface.cpp:
+
 2012-01-10  Nikolas Zimmermann  <[email protected]>
 
         Large SVG text layout performance regression in r81168

Modified: trunk/Source/WebCore/bindings/scripts/CodeGeneratorV8.pm (104683 => 104684)


--- trunk/Source/WebCore/bindings/scripts/CodeGeneratorV8.pm	2012-01-11 09:16:16 UTC (rev 104683)
+++ trunk/Source/WebCore/bindings/scripts/CodeGeneratorV8.pm	2012-01-11 09:24:56 UTC (rev 104684)
@@ -1931,12 +1931,7 @@
         "";
     if ($customAccessor eq 1) {
         # use the naming convension, interface + (capitalize) attr name
-        if ($attribute->signature->extendedAttributes->{"ImplementedBy"}) {
-            $customAccessor = $attribute->signature->extendedAttributes->{"ImplementedBy"} . "::" . $attrName;
-            AddToImplIncludes("V8" . $attribute->signature->extendedAttributes->{"ImplementedBy"} . ".h");
-        } else {
-            $customAccessor = $interfaceName . "::" . $attrName;
-        }
+        $customAccessor = $interfaceName . "::" . $attrName;
     }
 
     my $getter;

Modified: trunk/Source/WebCore/bindings/scripts/test/V8/V8TestInterface.cpp (104683 => 104684)


--- trunk/Source/WebCore/bindings/scripts/test/V8/V8TestInterface.cpp	2012-01-11 09:16:16 UTC (rev 104683)
+++ trunk/Source/WebCore/bindings/scripts/test/V8/V8TestInterface.cpp	2012-01-11 09:24:56 UTC (rev 104684)
@@ -33,7 +33,6 @@
 #include "V8IsolatedContext.h"
 #include "V8Proxy.h"
 #include "V8TestObj.h"
-#include "V8TestSupplemental.h"
 #include <wtf/GetPtr.h>
 #include <wtf/RefCounted.h>
 #include <wtf/RefPtr.h>
@@ -134,7 +133,7 @@
 #endif // ENABLE(Condition11) || ENABLE(Condition12)
 #if ENABLE(Condition11) || ENABLE(Condition12)
     // Attribute 'supplementalStr3' (Type: 'attribute' ExtAttr: 'CustomSetter CustomGetter Conditional ImplementedBy')
-    {"supplementalStr3", V8TestSupplemental::supplementalStr3AccessorGetter, V8TestSupplemental::supplementalStr3AccessorSetter, 0 /* no data */, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), 0 /* on instance */},
+    {"supplementalStr3", V8TestInterface::supplementalStr3AccessorGetter, V8TestInterface::supplementalStr3AccessorSetter, 0 /* no data */, static_cast<v8::AccessControl>(v8::DEFAULT), static_cast<v8::PropertyAttribute>(v8::None), 0 /* on instance */},
 #endif // ENABLE(Condition11) || ENABLE(Condition12)
 };
 
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to