paulmillr / es6-shim

ECMAScript 6 compatibility shims for legacy JS engines
http://paulmillr.com
MIT License
3.11k stars 388 forks source link

Distinguish Set and Map iterators. #391

Closed cscott closed 7 years ago

cscott commented 8 years ago

Closes: #387

ljharb commented 8 years ago

This seems fine, but we should probably have a test to prevent a regression

Xotic750 commented 7 years ago

What kind of tests would be needed for this?

ljharb commented 7 years ago

@Xotic750 i'd assume something from your report in #387.

Although, I'd expect Object.getPrototypeOf(new Map().entries()) !== Object.getPrototypeOf(new Set().entries()) to be true, and I'm not sure that's the case with the shims.

Xotic750 commented 7 years ago

https://github.com/paulmillr/es6-shim/pull/437