Bug 963382, part 1 - Split out MethodDefiner's JS implemented case into its own thing. r=bz
authorAndrew McCreight <continuation@gmail.com>
Thu, 21 Aug 2014 13:56:11 -0700
changeset 201075 c9ce133b845e6ea0973d9a65349e4ef9a1b3b47a
parent 201074 585a440843210eed1e1db9fd4762d5f32038b380
child 201076 019faa34f1948b0f8f5ba18a3a82b056177e58ee
push id27362
push userkwierso@gmail.com
push dateFri, 22 Aug 2014 23:47:54 +0000
treeherdermozilla-central@64c4ec2df3d4 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbz
bugs963382
milestone34.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 963382, part 1 - Split out MethodDefiner's JS implemented case into its own thing. r=bz
dom/bindings/Codegen.py
--- a/dom/bindings/Codegen.py
+++ b/dom/bindings/Codegen.py
@@ -2160,26 +2160,28 @@ class MethodDefiner(PropertyDefiner):
                     "name": 'valueOf',
                     "nativeName": "UnforgeableValueOf",
                     "methodInfo": False,
                     "length": 0,
                     "flags": "JSPROP_ENUMERATE", # readonly/permanent added
                                                  # automatically.
                     "condition": MemberCondition(None, None)
                 })
-        elif (descriptor.interface.isJSImplemented() and
-              descriptor.interface.hasInterfaceObject()):
-            self.chrome.append({
-                "name": '_create',
-                "nativeName": ("%s::_Create" % descriptor.name),
-                "methodInfo": False,
-                "length": 2,
-                "flags": "0",
-                "condition": MemberCondition(None, None)
-            })
+
+        if (descriptor.interface.isJSImplemented() and
+            descriptor.interface.hasInterfaceObject()):
+            if static:
+                self.chrome.append({
+                    "name": '_create',
+                    "nativeName": ("%s::_Create" % descriptor.name),
+                    "methodInfo": False,
+                    "length": 2,
+                    "flags": "0",
+                    "condition": MemberCondition(None, None)
+                })
 
         self.unforgeable = unforgeable
 
         if static:
             if not descriptor.interface.hasInterfaceObject():
                 # static methods go on the interface object
                 assert not self.hasChromeOnly() and not self.hasNonChromeOnly()
         else: