Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make setlike/maplike generated properties enumerable #1166

Merged
merged 1 commit into from
Oct 3, 2022

Conversation

domenic
Copy link
Member

@domenic domenic commented Jul 13, 2022

This makes the properties generated by the maplike/setlike declarations consistent with properties generated by other IDL constructs such as operation and attribute declarations. (That includes, e.g., explicitly-specified has/get/set/delete operations!) This is also consistent with the generated properties for iterable declarations.

The @@iterator symbol property remains non-enumerable, like it is for iterable declarations, and like all other symbol-named properties are.

Closes #738.

(See WHATWG Working Mode: Changes for more details.)


Preview | Diff

This makes the properties generated by the maplike/setlike declarations consistent with properties generated by other IDL constructs such as operation and attribute declarations. (That includes, e.g., explicitly-specified has/get/set/delete operations!) This is also consistent with the generated properties for iterable declarations.

The @@iterator symbol property remains non-enumerable, like it is for iterable declarations, and like all other symbol-named properties are.

Closes #738.
Copy link

@petervanderbeken petervanderbeken left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@domenic domenic merged commit bf88a5a into main Oct 3, 2022
@domenic domenic deleted the iterable-maplike-setlike branch October 3, 2022 07:02
domenic added a commit to web-platform-tests/wpt that referenced this pull request Oct 6, 2022
domenic added a commit to web-platform-tests/wpt that referenced this pull request Oct 11, 2022
foolip pushed a commit to web-platform-tests/wpt that referenced this pull request Oct 11, 2022
moz-v2v-gh pushed a commit to mozilla/gecko-dev that referenced this pull request Oct 21, 2022
…thod enumerability, a=testonly

Automatic update from web-platform-tests
Flip expectations for maplike/setlike method enumerability (#36123)

Follows whatwg/webidl#1166.
--

wpt-commits: ea58f5fc30d8cfff977a930eecc4a55b22c8bb46
wpt-pr: 36123
jamienicol pushed a commit to jamienicol/gecko that referenced this pull request Oct 26, 2022
…thod enumerability, a=testonly

Automatic update from web-platform-tests
Flip expectations for maplike/setlike method enumerability (#36123)

Follows whatwg/webidl#1166.
--

wpt-commits: ea58f5fc30d8cfff977a930eecc4a55b22c8bb46
wpt-pr: 36123
webkit-early-warning-system pushed a commit to shvaikalesh/WebKit that referenced this pull request Nov 18, 2022
https://bugs.webkit.org/show_bug.cgi?id=245771
<rdar://100798576>

Reviewed by Sam Weinig and Yusuke Suzuki.

This change makes maplike<> and setlike<> generated method enumerable per latest spec change [1],
aligning WebKit with Blink and Gecko.

Since the methods are being tested via wpt/resources/idlharness.js, it was synced along with
a few other changes, causing some expectations to be adjusted.

Also, syncs CSS Custom Highlight API's idlharness.js test to ensure that setlike<> declarations
are tested as well.

[1] whatwg/webidl#1166

* LayoutTests/imported/w3c/web-platform-tests/css/css-highlight-api/idlharness.window-expected.txt:
HighlightRegistry's maplike<DOMString, Highlight> tests are failing because the interface was renamed in the spec, but not yet in our codebase.

* LayoutTests/imported/w3c/web-platform-tests/css/css-highlight-api/idlharness.window.html:
* LayoutTests/imported/w3c/web-platform-tests/css/css-highlight-api/idlharness.window.js: Sync from upstream, commit 2ecf81b.
* LayoutTests/imported/w3c/web-platform-tests/interfaces/css-highlight-api.idl: Sync from upstream, commit 11ec24d.
* LayoutTests/imported/w3c/web-platform-tests/resources/idlharness.js: Sync from upstream, commit 56ec9be.
* LayoutTests/imported/w3c/web-platform-tests/*-expected.txt: Adjust expectations.
* LayoutTests/platform/glib/imported/w3c/web-platform-tests/css/css-font-loading/idlharness.https-expected.txt: Adjust expectations.
* Source/WebCore/bindings/scripts/CodeGeneratorJS.pm:
(AddMapLikeAttributesAndOperationIfNeeded):
(AddSetLikeAttributesAndOperationIfNeeded):
* Source/WebCore/bindings/scripts/test/JS/*: Updated.

Canonical link: https://commits.webkit.org/256838@main
mnutt pushed a commit to movableink/webkit that referenced this pull request Dec 6, 2022
https://bugs.webkit.org/show_bug.cgi?id=245771
<rdar://100798576>

Reviewed by Sam Weinig and Yusuke Suzuki.

This change makes maplike<> and setlike<> generated method enumerable per latest spec change [1],
aligning WebKit with Blink and Gecko.

Since the methods are being tested via wpt/resources/idlharness.js, it was synced along with
a few other changes, causing some expectations to be adjusted.

Also, syncs CSS Custom Highlight API's idlharness.js test to ensure that setlike<> declarations
are tested as well.

[1] whatwg/webidl#1166

* LayoutTests/imported/w3c/web-platform-tests/css/css-highlight-api/idlharness.window-expected.txt:
HighlightRegistry's maplike<DOMString, Highlight> tests are failing because the interface was renamed in the spec, but not yet in our codebase.

* LayoutTests/imported/w3c/web-platform-tests/css/css-highlight-api/idlharness.window.html:
* LayoutTests/imported/w3c/web-platform-tests/css/css-highlight-api/idlharness.window.js: Sync from upstream, commit 2ecf81b0ea0b6c45035038d8d381c6d2962d2347.
* LayoutTests/imported/w3c/web-platform-tests/interfaces/css-highlight-api.idl: Sync from upstream, commit 11ec24d28e86b8809d7f17833b7306bb5c8401ec.
* LayoutTests/imported/w3c/web-platform-tests/resources/idlharness.js: Sync from upstream, commit 56ec9beaab4ecd393f99d256a2ac2a4e66a09f9c.
* LayoutTests/imported/w3c/web-platform-tests/*-expected.txt: Adjust expectations.
* LayoutTests/platform/glib/imported/w3c/web-platform-tests/css/css-font-loading/idlharness.https-expected.txt: Adjust expectations.
* Source/WebCore/bindings/scripts/CodeGeneratorJS.pm:
(AddMapLikeAttributesAndOperationIfNeeded):
(AddSetLikeAttributesAndOperationIfNeeded):
* Source/WebCore/bindings/scripts/test/JS/*: Updated.

Canonical link: https://commits.webkit.org/256838@main
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

Inconsistent enumerability on keys/values/entries and friends
3 participants