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

Change dictionary section to encourage Infra wording #524

Closed
annevk opened this issue Feb 19, 2018 · 0 comments · Fixed by #859
Closed

Change dictionary section to encourage Infra wording #524

annevk opened this issue Feb 19, 2018 · 0 comments · Fixed by #859

Comments

@annevk
Copy link
Member

annevk commented Feb 19, 2018

Per whatwg/dom#574 we no longer need to use

dict's member is present

and can instead use

dict["member"] exists

The dictionary section should probably encourage the latter style and only define "present" for as long as it takes everyone to migrate.

domenic added a commit that referenced this issue Mar 25, 2020
This rewrites some of the text around dictionaries to clear up the confusion in #852, as well as generally try to smooth out the reading experience and definitions. Concrete changes:

* Rewrote "dictionaries are always passed by value" to be more specific and clear.
* Moved "dictionaries must not be used as the type of an attribute or constant" near the top of the dictionary section, commensurate with its importance.
* Removed the terms "present" and "not present"; instead we can use Infra's "exists" for maps.
* Fixed several cases where the overload resolution algorithm discussed arguments being "not present", even though that was only defined for dictionaries. Instead it now correctly talks about "missing".
* Rewrote the discussion of required dictionary members and dictionary members with default values to make it clear how they contribute to the dictionary's entries.
* Added a note to the IDL-to-ES conversion algorithm for dictionaries explicitly pointing out that default-value dictionary members will always be present, and thus always show up in the output.

Closes #852. Closes #524.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging a pull request may close this issue.

1 participant