Diff
Modified: trunk/Source/WebCore/ChangeLog (171955 => 171956)
--- trunk/Source/WebCore/ChangeLog 2014-08-01 23:14:30 UTC (rev 171955)
+++ trunk/Source/WebCore/ChangeLog 2014-08-01 23:20:45 UTC (rev 171956)
@@ -1,3 +1,21 @@
+2014-08-01 Andreas Kling <akl...@apple.com>
+
+ Many DOM objects have InterceptsGetOwnPropertySlotByIndexEvenWhenLengthIsNotZero for no reason.
+ <https://webkit.org/b/135519>
+
+ Don't set this structure flag unless the object actually has an override
+ for getOwnPropertySlotByIndex().
+
+ Reviewed by Geoffrey Garen.
+
+ * bindings/scripts/CodeGeneratorJS.pm:
+ (GenerateHeader):
+ * bindings/scripts/test/JS/JSTestActiveDOMObject.h:
+ * bindings/scripts/test/JS/JSTestException.h:
+ * bindings/scripts/test/JS/JSTestInterface.h:
+ * bindings/scripts/test/JS/JSTestObj.h:
+ * bindings/scripts/test/JS/JSTestTypedefs.h:
+
2014-08-01 Myles C. Maxfield <mmaxfi...@apple.com>
SVG Font kerning can take an early out if the font has no kerning information
Modified: trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm (171955 => 171956)
--- trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm 2014-08-01 23:14:30 UTC (rev 171955)
+++ trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm 2014-08-01 23:20:45 UTC (rev 171956)
@@ -890,10 +890,13 @@
# Getters
if ($hasGetter) {
push(@headerContent, " static bool getOwnPropertySlot(JSC::JSObject*, JSC::ExecState*, JSC::PropertyName, JSC::PropertySlot&);\n");
- push(@headerContent, " static bool getOwnPropertySlotByIndex(JSC::JSObject*, JSC::ExecState*, unsigned propertyName, JSC::PropertySlot&);\n") if ($hasComplexGetter);
push(@headerContent, " bool getOwnPropertySlotDelegate(JSC::ExecState*, JSC::PropertyName, JSC::PropertySlot&);\n") if $interface->extendedAttributes->{"JSCustomGetOwnPropertySlotAndDescriptor"};
$structureFlags{"JSC::OverridesGetOwnPropertySlot"} = 1;
- $structureFlags{"JSC::InterceptsGetOwnPropertySlotByIndexEvenWhenLengthIsNotZero"} = 1;
+
+ if ($hasComplexGetter) {
+ push(@headerContent, " static bool getOwnPropertySlotByIndex(JSC::JSObject*, JSC::ExecState*, unsigned propertyName, JSC::PropertySlot&);\n");
+ $structureFlags{"JSC::InterceptsGetOwnPropertySlotByIndexEvenWhenLengthIsNotZero"} = 1;
+ }
}
my $overridesPut = InstanceOverridesPutDeclaration($interface);
Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestActiveDOMObject.h (171955 => 171956)
--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestActiveDOMObject.h 2014-08-01 23:14:30 UTC (rev 171955)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestActiveDOMObject.h 2014-08-01 23:20:45 UTC (rev 171956)
@@ -72,7 +72,7 @@
ASSERT(inherits(info()));
}
- static const unsigned StructureFlags = JSC::InterceptsGetOwnPropertySlotByIndexEvenWhenLengthIsNotZero | JSC::OverridesGetOwnPropertySlot | Base::StructureFlags;
+ static const unsigned StructureFlags = JSC::OverridesGetOwnPropertySlot | Base::StructureFlags;
};
class JSTestActiveDOMObjectOwner : public JSC::WeakHandleOwner {
Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestException.h (171955 => 171956)
--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestException.h 2014-08-01 23:14:30 UTC (rev 171955)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestException.h 2014-08-01 23:20:45 UTC (rev 171956)
@@ -73,7 +73,7 @@
ASSERT(inherits(info()));
}
- static const unsigned StructureFlags = JSC::InterceptsGetOwnPropertySlotByIndexEvenWhenLengthIsNotZero | JSC::OverridesGetOwnPropertySlot | Base::StructureFlags;
+ static const unsigned StructureFlags = JSC::OverridesGetOwnPropertySlot | Base::StructureFlags;
};
class JSTestExceptionOwner : public JSC::WeakHandleOwner {
Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestInterface.h (171955 => 171956)
--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestInterface.h 2014-08-01 23:14:30 UTC (rev 171955)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestInterface.h 2014-08-01 23:20:45 UTC (rev 171956)
@@ -99,7 +99,7 @@
ASSERT(inherits(info()));
}
- static const unsigned StructureFlags = JSC::InterceptsGetOwnPropertySlotByIndexEvenWhenLengthIsNotZero | JSC::OverridesGetOwnPropertySlot | Base::StructureFlags;
+ static const unsigned StructureFlags = JSC::OverridesGetOwnPropertySlot | Base::StructureFlags;
};
class JSTestInterfaceOwner : public JSC::WeakHandleOwner {
Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.h (171955 => 171956)
--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.h 2014-08-01 23:14:30 UTC (rev 171955)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.h 2014-08-01 23:20:45 UTC (rev 171956)
@@ -85,7 +85,7 @@
ASSERT(inherits(info()));
}
- static const unsigned StructureFlags = JSC::InterceptsGetOwnPropertySlotByIndexEvenWhenLengthIsNotZero | JSC::OverridesGetOwnPropertySlot | Base::StructureFlags;
+ static const unsigned StructureFlags = JSC::OverridesGetOwnPropertySlot | Base::StructureFlags;
};
class JSTestObjOwner : public JSC::WeakHandleOwner {
Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.h (171955 => 171956)
--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.h 2014-08-01 23:14:30 UTC (rev 171955)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.h 2014-08-01 23:20:45 UTC (rev 171956)
@@ -72,7 +72,7 @@
ASSERT(inherits(info()));
}
- static const unsigned StructureFlags = JSC::InterceptsGetOwnPropertySlotByIndexEvenWhenLengthIsNotZero | JSC::OverridesGetOwnPropertySlot | Base::StructureFlags;
+ static const unsigned StructureFlags = JSC::OverridesGetOwnPropertySlot | Base::StructureFlags;
};
class JSTestTypedefsOwner : public JSC::WeakHandleOwner {