diff options
Diffstat (limited to 'tools/node_modules/eslint/node_modules/js-sdsl/dist/cjs/container/HashContainer/HashSet.js')
-rw-r--r-- | tools/node_modules/eslint/node_modules/js-sdsl/dist/cjs/container/HashContainer/HashSet.js | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/tools/node_modules/eslint/node_modules/js-sdsl/dist/cjs/container/HashContainer/HashSet.js b/tools/node_modules/eslint/node_modules/js-sdsl/dist/cjs/container/HashContainer/HashSet.js index 89290ae685..6c75f33865 100644 --- a/tools/node_modules/eslint/node_modules/js-sdsl/dist/cjs/container/HashContainer/HashSet.js +++ b/tools/node_modules/eslint/node_modules/js-sdsl/dist/cjs/container/HashContainer/HashSet.js @@ -11,6 +11,10 @@ var _Base = require("./Base"); var _throwError = require("../../utils/throwError"); class HashSetIterator extends _Base.HashContainerIterator { + constructor(t, e, r, s) { + super(t, e, s); + this.container = r; + } get pointer() { if (this.o === this.h) { (0, _throwError.throwIteratorAccessError)(); @@ -18,7 +22,7 @@ class HashSetIterator extends _Base.HashContainerIterator { return this.o.u; } copy() { - return new HashSetIterator(this.o, this.h, this.iteratorType); + return new HashSetIterator(this.o, this.h, this.container, this.iteratorType); } } @@ -31,16 +35,16 @@ class HashSet extends _Base.HashContainer { })); } begin() { - return new HashSetIterator(this.p, this.h); + return new HashSetIterator(this.p, this.h, this); } end() { - return new HashSetIterator(this.h, this.h); + return new HashSetIterator(this.h, this.h, this); } rBegin() { - return new HashSetIterator(this._, this.h, 1); + return new HashSetIterator(this._, this.h, this, 1); } rEnd() { - return new HashSetIterator(this.h, this.h, 1); + return new HashSetIterator(this.h, this.h, this, 1); } front() { return this.p.u; @@ -63,7 +67,7 @@ class HashSet extends _Base.HashContainer { } find(t, e) { const r = this.I(t, e); - return new HashSetIterator(r, this.h); + return new HashSetIterator(r, this.h, this); } forEach(t) { let e = 0; |