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

Define equality for sets #660

Merged
merged 1 commit into from
Jan 10, 2025
Merged

Define equality for sets #660

merged 1 commit into from
Jan 10, 2025

Conversation

OrKoN
Copy link
Contributor

@OrKoN OrKoN commented Jan 10, 2025

A definition of what it means for two sets to be equal. This definition re-uses the subset/superset definitions but we could also define it as an iteration over elements and size equality.


Preview | Diff

@OrKoN OrKoN force-pushed the orkon/set-equality branch from 29ab22a to 1aca0e5 Compare January 10, 2025 09:30
@OrKoN OrKoN marked this pull request as ready for review January 10, 2025 09:35
Copy link

@sadym-chromium sadym-chromium left a comment

Choose a reason for hiding this comment

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

SGTM

@annevk
Copy link
Member

annevk commented Jan 10, 2025

I guess this works, but we're also running into #643 with these.

@domenic you okay with generally using "equal(s)" for structural equality and "is" for identity equality?

Copy link
Member

@domenic domenic left a comment

Choose a reason for hiding this comment

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

Yeah, this seems reasonable to me. Although it's a bit silly that we haven't defined what it means for two strings to be equal, or two numbers, or similar, so this is all on slightly shaky foundations.

@annevk annevk merged commit 2c3dbce into whatwg:main Jan 10, 2025
2 checks passed
@OrKoN OrKoN deleted the orkon/set-equality branch January 10, 2025 10:23
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.

4 participants