This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 28592 - Conflicting @@iterator symbols between indexed attributes/getters and maplike/setlike
Summary: Conflicting @@iterator symbols between indexed attributes/getters and maplike...
Status: RESOLVED FIXED
Alias: None
Product: WebAppsWG
Classification: Unclassified
Component: WebIDL (show other bugs)
Version: unspecified
Hardware: PC Windows NT
: P2 normal
Target Milestone: ---
Assignee: Cameron McCormack
QA Contact: public-webapps-bugzilla
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-05-01 19:49 UTC by Kyle Machulis
Modified: 2019-03-07 15:21 UTC (History)
5 users (show)

See Also:


Attachments

Description Kyle Machulis 2015-05-01 19:49:28 UTC
Assuming an interface is both maplike/setlike and an indexed attribute/getter, both cases will require an @@iterator symbol, but the spec does not make clear whether there should be a tiebreak or whether this case should not be permitted at all.
Comment 1 Domenic Denicola 2015-05-01 19:53:54 UTC
Given that we do not want to encouraged further indexed attributes or getters, I think we should just disallow maplike/setlike from being used on interfaces that use those features.
Comment 2 Boris Zbarsky 2015-05-01 20:18:56 UTC
It's worth thinking about how you'd spec HTMLCollection today.  That's the one case I can think of that's more or less something maplike with an indexed getter.
Comment 3 Domenic Denicola 2015-05-01 20:21:54 UTC
Probably like https://dom.spec.whatwg.org/#element-collections :). (To get named access use `.query("#x, [name='x']")`)