Diff
Modified: trunk/LayoutTests/ChangeLog (207518 => 207519)
--- trunk/LayoutTests/ChangeLog 2016-10-19 03:52:29 UTC (rev 207518)
+++ trunk/LayoutTests/ChangeLog 2016-10-19 04:46:39 UTC (rev 207519)
@@ -1,3 +1,15 @@
+2016-10-18 Chris Dumez <cdu...@apple.com>
+
+ [Web IDL] Drop webkit-specific extended attributes that are no longer useful
+ https://bugs.webkit.org/show_bug.cgi?id=163643
+
+ Reviewed by Ryosuke Niwa.
+
+ Add layout test to check that Notification.permission is now deletable.
+
+ * fast/notifications/notification-permisssion-deletable-expected.txt: Added.
+ * fast/notifications/notification-permisssion-deletable.html: Added.
+
2016-10-18 Mark Lam <mark....@apple.com>
Invoking Object.prototype.__proto__ accessors directly should throw a TypeError.
Added: trunk/LayoutTests/fast/notifications/notification-permisssion-deletable-expected.txt (0 => 207519)
--- trunk/LayoutTests/fast/notifications/notification-permisssion-deletable-expected.txt (rev 0)
+++ trunk/LayoutTests/fast/notifications/notification-permisssion-deletable-expected.txt 2016-10-19 04:46:39 UTC (rev 207519)
@@ -0,0 +1,12 @@
+Tests that Notification.permission is deletable.
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
+PASS Notification.permission is "default"
+PASS delete Notification.permission is true
+PASS Notification.permission is undefined.
+PASS successfullyParsed is true
+
+TEST COMPLETE
+
Added: trunk/LayoutTests/fast/notifications/notification-permisssion-deletable.html (0 => 207519)
--- trunk/LayoutTests/fast/notifications/notification-permisssion-deletable.html (rev 0)
+++ trunk/LayoutTests/fast/notifications/notification-permisssion-deletable.html 2016-10-19 04:46:39 UTC (rev 207519)
@@ -0,0 +1,14 @@
+<!DOCTYPE html>
+<html>
+<body>
+<script src=""
+<script>
+description("Tests that Notification.permission is deletable.");
+
+shouldBeEqualToString("Notification.permission", "default");
+shouldBeTrue("delete Notification.permission");
+shouldBeUndefined("Notification.permission");
+</script>
+<script src=""
+</body>
+</html>
Modified: trunk/Source/WebCore/ChangeLog (207518 => 207519)
--- trunk/Source/WebCore/ChangeLog 2016-10-19 03:52:29 UTC (rev 207518)
+++ trunk/Source/WebCore/ChangeLog 2016-10-19 04:46:39 UTC (rev 207519)
@@ -1,3 +1,38 @@
+2016-10-18 Chris Dumez <cdu...@apple.com>
+
+ [Web IDL] Drop webkit-specific extended attributes that are no longer useful
+ https://bugs.webkit.org/show_bug.cgi?id=163643
+
+ Reviewed by Ryosuke Niwa.
+
+ Drop webkit-specific IDL extended attributes that are no longer useful:
+ - [CustomReturn]: I believe this used to be for ObjC bindings. It has
+ no impact in JS bindings.
+ - [Deletable]: It only had an impact on static attributes and was only
+ used on HTMLAllCollection.all, which is not static. I updated the
+ bindings generator to so that static attributes are now configurable
+ by default (unless marked as [Unforgeable], as per Web IDL [1]. This
+ causes Notification.permission (This only static attribute we have)
+ to become deletable. This behavior is consistent with the specification
+ and with Chrome. I added test coverage for this.
+ - [ImplementationNamespace]: Implemented but unused.
+ - [PassContext]: Not implemented and unused.
+ - [TypedArray=*]: Not implemented and unused.
+
+ [1] https://heycam.github.io/webidl/#es-attributes
+
+ Test: fast/notifications/notification-permisssion-deletable.html
+
+ * bindings/scripts/CodeGeneratorJS.pm:
+ (GetNamespaceForInterface):
+ (GenerateImplementation):
+ * bindings/scripts/IDLAttributes.txt:
+ * bindings/scripts/test/JS/JSTestInterface.cpp:
+ * bindings/scripts/test/JS/JSTestObj.cpp:
+ * bindings/scripts/test/JS/JSTestTypedefs.cpp:
+ * dom/Node.idl:
+ * html/HTMLDocument.idl:
+
2016-10-18 Sam Weinig <s...@webkit.org>
Replace std::experimental::variant with WTF::Variant (or similar)
Modified: trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm (207518 => 207519)
--- trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm 2016-10-19 03:52:29 UTC (rev 207518)
+++ trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm 2016-10-19 04:46:39 UTC (rev 207519)
@@ -2343,7 +2343,7 @@
sub GetNamespaceForInterface
{
my $interface = shift;
- return $interface->extendedAttributes->{ImplementationNamespace} || "WebCore";
+ return "WebCore";
}
sub GetImplementationLacksVTableForInterface
@@ -2592,7 +2592,7 @@
push(@hashKeys, $name);
my @specials = ();
- push(@specials, "DontDelete") unless $attribute->signature->extendedAttributes->{Deletable};
+ push(@specials, "DontDelete") if IsUnforgeable($interface, $attribute);
push(@specials, "ReadOnly") if IsReadonly($attribute);
push(@specials, "DOMJITAttribute") if $attribute->signature->extendedAttributes->{"DOMJIT"};
my $special = (@specials > 0) ? join(" | ", @specials) : "0";
Modified: trunk/Source/WebCore/bindings/scripts/IDLAttributes.txt (207518 => 207519)
--- trunk/Source/WebCore/bindings/scripts/IDLAttributes.txt 2016-10-19 03:52:29 UTC (rev 207518)
+++ trunk/Source/WebCore/bindings/scripts/IDLAttributes.txt 2016-10-19 04:46:39 UTC (rev 207519)
@@ -49,12 +49,10 @@
CustomPreventExtensions
CustomProxyToJSObject
CustomPutFunction
-CustomReturn
CustomSetPrototype
CustomSetter
CustomToJSObject
DOMJIT
-Deletable
DoNotCheckConstants
DoNotCheckSecurity
DoNotCheckSecurityOnGetter
@@ -73,7 +71,6 @@
Immutable
ImplementedAs=*
ImplementationLacksVTable
-ImplementationNamespace=*
ImplementationReturnType=*
ImplicitThis
InterfaceName=*
@@ -103,7 +100,6 @@
Nondeterministic
NotEnumerable
OverrideBuiltins
-PassContext
PrivateIdentifier
PublicIdentifier
PutForwards=*
@@ -118,7 +114,6 @@
SkipVTableValidation
SuppressToJSObject
TreatNullAs=EmptyString
-TypedArray=*
URL
Unforgeable
Unscopable
Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestInterface.cpp (207518 => 207519)
--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestInterface.cpp 2016-10-19 03:52:29 UTC (rev 207518)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestInterface.cpp 2016-10-19 04:46:39 UTC (rev 207519)
@@ -176,22 +176,22 @@
{ 0, 0, NoIntrinsic, { 0, 0 } },
#endif
#if ENABLE(Condition22) || ENABLE(Condition23)
- { "implementsStaticReadOnlyAttr", DontDelete | ReadOnly, NoIntrinsic, { (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsTestInterfaceConstructorImplementsStaticReadOnlyAttr), (intptr_t) static_cast<PutPropertySlot::PutValueFunc>(0) } },
+ { "implementsStaticReadOnlyAttr", ReadOnly, NoIntrinsic, { (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsTestInterfaceConstructorImplementsStaticReadOnlyAttr), (intptr_t) static_cast<PutPropertySlot::PutValueFunc>(0) } },
#else
{ 0, 0, NoIntrinsic, { 0, 0 } },
#endif
#if ENABLE(Condition22) || ENABLE(Condition23)
- { "implementsStaticAttr", DontDelete, NoIntrinsic, { (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsTestInterfaceConstructorImplementsStaticAttr), (intptr_t) static_cast<PutPropertySlot::PutValueFunc>(setJSTestInterfaceConstructorImplementsStaticAttr) } },
+ { "implementsStaticAttr", 0, NoIntrinsic, { (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsTestInterfaceConstructorImplementsStaticAttr), (intptr_t) static_cast<PutPropertySlot::PutValueFunc>(setJSTestInterfaceConstructorImplementsStaticAttr) } },
#else
{ 0, 0, NoIntrinsic, { 0, 0 } },
#endif
#if ENABLE(Condition11) || ENABLE(Condition12)
- { "supplementalStaticReadOnlyAttr", DontDelete | ReadOnly, NoIntrinsic, { (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsTestInterfaceConstructorSupplementalStaticReadOnlyAttr), (intptr_t) static_cast<PutPropertySlot::PutValueFunc>(0) } },
+ { "supplementalStaticReadOnlyAttr", ReadOnly, NoIntrinsic, { (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsTestInterfaceConstructorSupplementalStaticReadOnlyAttr), (intptr_t) static_cast<PutPropertySlot::PutValueFunc>(0) } },
#else
{ 0, 0, NoIntrinsic, { 0, 0 } },
#endif
#if ENABLE(Condition11) || ENABLE(Condition12)
- { "supplementalStaticAttr", DontDelete, NoIntrinsic, { (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsTestInterfaceConstructorSupplementalStaticAttr), (intptr_t) static_cast<PutPropertySlot::PutValueFunc>(setJSTestInterfaceConstructorSupplementalStaticAttr) } },
+ { "supplementalStaticAttr", 0, NoIntrinsic, { (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsTestInterfaceConstructorSupplementalStaticAttr), (intptr_t) static_cast<PutPropertySlot::PutValueFunc>(setJSTestInterfaceConstructorSupplementalStaticAttr) } },
#else
{ 0, 0, NoIntrinsic, { 0, 0 } },
#endif
Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.cpp (207518 => 207519)
--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.cpp 2016-10-19 03:52:29 UTC (rev 207518)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.cpp 2016-10-19 04:46:39 UTC (rev 207519)
@@ -1276,9 +1276,9 @@
{ "CONST_VALUE_14", DontDelete | ReadOnly | ConstantInteger, NoIntrinsic, { (long long)(0x1abc) } },
{ "CONST_JAVASCRIPT", DontDelete | ReadOnly | ConstantInteger, NoIntrinsic, { (long long)(15) } },
{ "readonly", DontDelete | ReadOnly | ConstantInteger, NoIntrinsic, { (long long)(0) } },
- { "staticReadOnlyLongAttr", DontDelete | ReadOnly, NoIntrinsic, { (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsTestObjConstructorStaticReadOnlyLongAttr), (intptr_t) static_cast<PutPropertySlot::PutValueFunc>(0) } },
- { "staticStringAttr", DontDelete, NoIntrinsic, { (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsTestObjConstructorStaticStringAttr), (intptr_t) static_cast<PutPropertySlot::PutValueFunc>(setJSTestObjConstructorStaticStringAttr) } },
- { "TestSubObj", DontDelete | ReadOnly, NoIntrinsic, { (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsTestObjConstructorTestSubObj), (intptr_t) static_cast<PutPropertySlot::PutValueFunc>(0) } },
+ { "staticReadOnlyLongAttr", ReadOnly, NoIntrinsic, { (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsTestObjConstructorStaticReadOnlyLongAttr), (intptr_t) static_cast<PutPropertySlot::PutValueFunc>(0) } },
+ { "staticStringAttr", 0, NoIntrinsic, { (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsTestObjConstructorStaticStringAttr), (intptr_t) static_cast<PutPropertySlot::PutValueFunc>(setJSTestObjConstructorStaticStringAttr) } },
+ { "TestSubObj", ReadOnly, NoIntrinsic, { (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsTestObjConstructorTestSubObj), (intptr_t) static_cast<PutPropertySlot::PutValueFunc>(0) } },
{ "nullableStringStaticMethod", JSC::Function, NoIntrinsic, { (intptr_t)static_cast<NativeFunction>(jsTestObjConstructorFunctionNullableStringStaticMethod), (intptr_t) (0) } },
{ "staticMethodWithCallbackAndOptionalArg", JSC::Function, NoIntrinsic, { (intptr_t)static_cast<NativeFunction>(jsTestObjConstructorFunctionStaticMethodWithCallbackAndOptionalArg), (intptr_t) (0) } },
{ "staticMethodWithCallbackArg", JSC::Function, NoIntrinsic, { (intptr_t)static_cast<NativeFunction>(jsTestObjConstructorFunctionStaticMethodWithCallbackArg), (intptr_t) (1) } },
Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.cpp (207518 => 207519)
--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.cpp 2016-10-19 03:52:29 UTC (rev 207518)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.cpp 2016-10-19 04:46:39 UTC (rev 207519)
@@ -122,7 +122,7 @@
static const HashTableValue JSTestTypedefsConstructorTableValues[] =
{
- { "TestSubObj", DontDelete | ReadOnly, NoIntrinsic, { (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsTestTypedefsConstructorTestSubObj), (intptr_t) static_cast<PutPropertySlot::PutValueFunc>(0) } },
+ { "TestSubObj", ReadOnly, NoIntrinsic, { (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsTestTypedefsConstructorTestSubObj), (intptr_t) static_cast<PutPropertySlot::PutValueFunc>(0) } },
};
template<> EncodedJSValue JSC_HOST_CALL JSTestTypedefsConstructor::construct(ExecState* state)
Modified: trunk/Source/WebCore/dom/Node.idl (207518 => 207519)
--- trunk/Source/WebCore/dom/Node.idl 2016-10-19 03:52:29 UTC (rev 207518)
+++ trunk/Source/WebCore/dom/Node.idl 2016-10-19 04:46:39 UTC (rev 207519)
@@ -55,10 +55,10 @@
[DOMJIT] readonly attribute Node? nextSibling;
readonly attribute Document? ownerDocument;
- [CEReactions, Custom, MayThrowLegacyException] Node insertBefore([CustomReturn] Node newChild, Node? refChild);
- [CEReactions, Custom, MayThrowLegacyException] Node replaceChild(Node newChild, [CustomReturn] Node oldChild);
- [CEReactions, Custom, MayThrowLegacyException] Node removeChild([CustomReturn] Node oldChild);
- [CEReactions, Custom, MayThrowLegacyException] Node appendChild([CustomReturn] Node newChild);
+ [CEReactions, Custom, MayThrowLegacyException] Node insertBefore(Node newChild, Node? refChild);
+ [CEReactions, Custom, MayThrowLegacyException] Node replaceChild(Node newChild, Node oldChild);
+ [CEReactions, Custom, MayThrowLegacyException] Node removeChild(Node oldChild);
+ [CEReactions, Custom, MayThrowLegacyException] Node appendChild(Node newChild);
boolean hasChildNodes();
Modified: trunk/Source/WebCore/html/HTMLDocument.idl (207518 => 207519)
--- trunk/Source/WebCore/html/HTMLDocument.idl 2016-10-19 03:52:29 UTC (rev 207518)
+++ trunk/Source/WebCore/html/HTMLDocument.idl 2016-10-19 04:46:39 UTC (rev 207519)
@@ -30,7 +30,7 @@
[Custom] void write(optional DOMString text);
[Custom] void writeln(optional DOMString text);
- [Custom, Replaceable, Deletable] readonly attribute HTMLAllCollection all;
+ [Custom, Replaceable] readonly attribute HTMLAllCollection all;
void clear();