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

supportedSources should not have [SameObject] #269

Open
rakuco opened this issue Apr 26, 2024 · 7 comments
Open

supportedSources should not have [SameObject] #269

rakuco opened this issue Apr 26, 2024 · 7 comments
Labels
external-issue Depending on changes in other spec's

Comments

@rakuco
Copy link
Member

rakuco commented Apr 26, 2024

https://webidl.spec.whatwg.org/#SameObject says

The [SameObject] extended attribute must not be used on anything other than a read only attribute whose type is an interface type or object.

supportedSources is a read-only attribute, but its type is not an interface type or object.

@kenchris
Copy link
Contributor

FrozenArray is an object

@rakuco
Copy link
Member Author

rakuco commented Apr 26, 2024

object in this case is https://webidl.spec.whatwg.org/#idl-object specifically. I don't think FrozenArray counts, but we could double check.

@kenchris
Copy link
Contributor

Not really sure where to double check that, but that would also explain why it has to be associated a global object (JavaScript realm)

@kenchris
Copy link
Contributor

@foolip do you know?

@rakuco
Copy link
Member Author

rakuco commented Apr 26, 2024

Not really sure where to double check that

It'd be good to file an issue in the Web IDL repository to ask about this. I can do that later if you don't beat me to it.

@foolip
Copy link
Member

foolip commented Apr 26, 2024

I think that as written the spec doesn't allow [SameObject] for FrozenArray but that seems unlikely to be intentional. A spec issue sounds good.

@rakuco
Copy link
Member Author

rakuco commented Apr 26, 2024

I've filed whatwg/webidl#1402.

@arskama arskama added the external-issue Depending on changes in other spec's label Sep 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
external-issue Depending on changes in other spec's
Projects
None yet
Development

No branches or pull requests

4 participants