tc39 / proposal-joint-iteration

a TC39 proposal to synchronise the advancement of multiple iterators
https://tc39.es/proposal-joint-iteration
70 stars 2 forks source link

reject non-string primitives as well #34

Closed bakkot closed 4 weeks ago

bakkot commented 1 month ago

We check for strings explicitly, which allows putting Symbol.iterator on Number.prototype. We should reject that.

ljharb commented 1 month ago

s/reject-strings/reject-primitives perhaps

bakkot commented 4 weeks ago

It turns out I'd just misread the spec because of a stray line; we're already doing the right thing.