From 86f3f37950b41d4aa0dff557b1a5c9261ea26443 Mon Sep 17 00:00:00 2001 From: Anthony Ramine Date: Fri, 25 Dec 2015 05:04:00 +0100 Subject: Always implement getOwnEnumerablePropertyKeys According to JSProxy.h, without this the default implementation calls ownPropertyKeys and filters out the unenumerable properties. We know when such things exist so we don't need to do that. --- components/script/dom/bindings/codegen/CodegenRust.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'components/script/dom/bindings/codegen/CodegenRust.py') diff --git a/components/script/dom/bindings/codegen/CodegenRust.py b/components/script/dom/bindings/codegen/CodegenRust.py index 6d626bea0ca..27272370cc1 100644 --- a/components/script/dom/bindings/codegen/CodegenRust.py +++ b/components/script/dom/bindings/codegen/CodegenRust.py @@ -2602,9 +2602,9 @@ class CGDefineProxyHandler(CGAbstractMethod): if self.descriptor.operations['NamedDeleter']: customDelete = 'delete' - getOwnEnumerablePropertyKeys = "None" + getOwnEnumerablePropertyKeys = "own_property_keys" if self.descriptor.interface.getExtendedAttribute("LegacyUnenumerableNamedProperties"): - getOwnEnumerablePropertyKeys = "Some(getOwnEnumerablePropertyKeys)" + getOwnEnumerablePropertyKeys = "getOwnEnumerablePropertyKeys" args = { "defineProperty": customDefineProperty, @@ -2631,7 +2631,7 @@ let traps = ProxyTraps { construct: None, getPropertyDescriptor: Some(get_property_descriptor), hasOwn: Some(hasOwn), - getOwnEnumerablePropertyKeys: %(getOwnEnumerablePropertyKeys)s, + getOwnEnumerablePropertyKeys: Some(%(getOwnEnumerablePropertyKeys)s), nativeCall: None, hasInstance: None, objectClassIs: None, -- cgit v1.2.3