01:18
<bakkot>
so an instanceof check, you mean? that doesn't seem that useful; you can do that yourself
05:05
<ljharb>
no, not an instanceof check, those are forgeable and don't work across realms. a brand check.
16:00
<bakkot>
ljharb: what brand do you imagine checking? there are a bunch of different built-in iterators in the language and the web platform, and they don't have a common brand
16:00
<bakkot>
the whole point of iterator being an interface is that the interface is implemented by a bunch of different classes, including userland classes
16:02
<littledan>
IMO the appropriate level for a brand check here would be to revert the whole Symbol.toStringTag change in the first place... what a bad idea of a feature. Not clear if it makes sense to "chip away at it" as much as I'm sympathetic with the idea to try.
16:06
<littledan>
it's not unthinkable to add a brand just for this purpose in https://tc39.es/proposal-iterator-helpers/#sec-iterator but I don't see the point
16:06
<littledan>
(do we want to start telling people, they shouldn't be pasting iterator helpers onto a base class by messing with a prototype chain? that seems like a useful mode to me)