| Index: src/collection-iterator.js
|
| diff --git a/src/collection-iterator.js b/src/collection-iterator.js
|
| index 7aa5208cea5bfc0a9b679cae37d0accdc335bc09..b48b85c1dca7eafa98d90269e6a31b46770b884f 100644
|
| --- a/src/collection-iterator.js
|
| +++ b/src/collection-iterator.js
|
| @@ -14,7 +14,6 @@ var $setValues;
|
| %CheckIsBootstrapping();
|
|
|
| var GlobalMap = global.Map;
|
| -var GlobalObject = global.Object;
|
| var GlobalSet = global.Set;
|
|
|
| // -------------------------------------------------------------------
|
| @@ -49,11 +48,6 @@ function SetIteratorNextJS() {
|
| }
|
|
|
|
|
| -function SetIteratorSymbolIterator() {
|
| - return this;
|
| -}
|
| -
|
| -
|
| function SetEntries() {
|
| if (!IS_SET(this)) {
|
| throw MakeTypeError(kIncompatibleMethodReceiver,
|
| @@ -74,15 +68,12 @@ function SetValues() {
|
| // -------------------------------------------------------------------
|
|
|
| %SetCode(SetIterator, SetIteratorConstructor);
|
| -%FunctionSetPrototype(SetIterator, new GlobalObject());
|
| +%FunctionSetPrototype(SetIterator, {__proto__: $iteratorPrototype});
|
| %FunctionSetInstanceClassName(SetIterator, 'Set Iterator');
|
| $installFunctions(SetIterator.prototype, DONT_ENUM, [
|
| 'next', SetIteratorNextJS
|
| ]);
|
|
|
| -$setFunctionName(SetIteratorSymbolIterator, symbolIterator);
|
| -%AddNamedProperty(SetIterator.prototype, symbolIterator,
|
| - SetIteratorSymbolIterator, DONT_ENUM);
|
| %AddNamedProperty(SetIterator.prototype, symbolToStringTag,
|
| "Set Iterator", READ_ONLY | DONT_ENUM);
|
|
|
| @@ -104,11 +95,6 @@ function MapIteratorConstructor(map, kind) {
|
| }
|
|
|
|
|
| -function MapIteratorSymbolIterator() {
|
| - return this;
|
| -}
|
| -
|
| -
|
| function MapIteratorNextJS() {
|
| if (!IS_MAP_ITERATOR(this)) {
|
| throw MakeTypeError(kIncompatibleMethodReceiver,
|
| @@ -164,15 +150,12 @@ function MapValues() {
|
| // -------------------------------------------------------------------
|
|
|
| %SetCode(MapIterator, MapIteratorConstructor);
|
| -%FunctionSetPrototype(MapIterator, new GlobalObject());
|
| +%FunctionSetPrototype(MapIterator, {__proto__: $iteratorPrototype});
|
| %FunctionSetInstanceClassName(MapIterator, 'Map Iterator');
|
| $installFunctions(MapIterator.prototype, DONT_ENUM, [
|
| 'next', MapIteratorNextJS
|
| ]);
|
|
|
| -$setFunctionName(MapIteratorSymbolIterator, symbolIterator);
|
| -%AddNamedProperty(MapIterator.prototype, symbolIterator,
|
| - MapIteratorSymbolIterator, DONT_ENUM);
|
| %AddNamedProperty(MapIterator.prototype, symbolToStringTag,
|
| "Map Iterator", READ_ONLY | DONT_ENUM);
|
|
|
|
|