pixel-react 1.15.14 → 1.15.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/ThirdPartyPackages/JanusGateway.js +5 -2
 - package/lib/ThirdPartyPackages/JanusGateway.js.map +1 -1
 - package/lib/_virtual/_commonjsHelpers.js +1 -30
 - package/lib/_virtual/_commonjsHelpers.js.map +1 -1
 - package/lib/_virtual/index10.js +2 -2
 - package/lib/_virtual/index11.js +2 -2
 - package/lib/_virtual/index9.js +2 -2
 - package/lib/assets/icons/quit.svg.js +6 -0
 - package/lib/assets/icons/quit.svg.js.map +1 -0
 - package/lib/components/Icon/iconList.js +2 -0
 - package/lib/components/Icon/iconList.js.map +1 -1
 - package/lib/index.cjs +5104 -6804
 - package/lib/index.cjs.map +1 -1
 - package/lib/index.js +1 -1
 - package/lib/node_modules/draft-js/lib/AtomicBlockUtils.js +1 -1
 - package/lib/node_modules/draft-js/lib/BlockMapBuilder.js +1 -1
 - package/lib/node_modules/draft-js/lib/BlockTree.js +1 -1
 - package/lib/node_modules/draft-js/lib/CharacterMetadata.js +1 -1
 - package/lib/node_modules/draft-js/lib/CompositeDraftDecorator.js +1 -1
 - package/lib/node_modules/draft-js/lib/ContentBlock.js +1 -1
 - package/lib/node_modules/draft-js/lib/ContentBlockNode.js +1 -1
 - package/lib/node_modules/draft-js/lib/ContentState.js +1 -1
 - package/lib/node_modules/draft-js/lib/ContentStateInlineStyle.js +1 -1
 - package/lib/node_modules/draft-js/lib/DOMObserver.js +1 -1
 - package/lib/node_modules/draft-js/lib/DefaultDraftBlockRenderMap.js +1 -1
 - package/lib/node_modules/draft-js/lib/DraftEditorBlockNode.react.js +1 -1
 - package/lib/node_modules/draft-js/lib/DraftEditorNode.react.js +1 -1
 - package/lib/node_modules/draft-js/lib/DraftEntity.js +1 -1
 - package/lib/node_modules/draft-js/lib/DraftEntityInstance.js +1 -1
 - package/lib/node_modules/draft-js/lib/DraftModifier.js +1 -1
 - package/lib/node_modules/draft-js/lib/DraftPasteProcessor.js +1 -1
 - package/lib/node_modules/draft-js/lib/EditorBidiService.js +1 -1
 - package/lib/node_modules/draft-js/lib/EditorState.js +1 -1
 - package/lib/node_modules/draft-js/lib/SelectionState.js +1 -1
 - package/lib/node_modules/draft-js/lib/applyEntityToContentState.js +1 -1
 - package/lib/node_modules/draft-js/lib/convertFromHTMLToContentBlocks.js +1 -1
 - package/lib/node_modules/draft-js/lib/convertFromRawToDraftState.js +1 -1
 - package/lib/node_modules/draft-js/lib/createCharacterList.js +1 -1
 - package/lib/node_modules/draft-js/lib/decodeInlineStyleRanges.js +1 -1
 - package/lib/node_modules/draft-js/lib/insertFragmentIntoContentState.js +1 -1
 - package/lib/node_modules/draft-js/lib/insertTextIntoContentState.js +1 -1
 - package/lib/node_modules/draft-js/lib/modifyBlockForContentState.js +1 -1
 - package/lib/node_modules/draft-js/lib/moveBlockInContentState.js +1 -1
 - package/lib/node_modules/draft-js/lib/randomizeBlockMapKeys.js +1 -1
 - package/lib/node_modules/draft-js/lib/removeRangeFromContentState.js +1 -1
 - package/lib/node_modules/draft-js/lib/splitBlockInContentState.js +1 -1
 - package/lib/node_modules/{draft-js/node_modules/immutable → immutable}/dist/immutable.js +1 -1
 - package/lib/node_modules/immutable/dist/immutable.js.map +1 -0
 - package/lib/node_modules/janus-gateway/npm/dist/janus.es.js +3210 -0
 - package/lib/node_modules/janus-gateway/npm/dist/janus.es.js.map +1 -0
 - package/lib/node_modules/js-beautify/js/src/css/beautifier.js +1 -1
 - package/lib/node_modules/js-beautify/js/src/css/index.js +1 -1
 - package/lib/node_modules/js-beautify/js/src/html/index.js +1 -1
 - package/lib/node_modules/js-beautify/js/src/javascript/beautifier.js +1 -1
 - package/lib/node_modules/js-beautify/js/src/javascript/index.js +1 -1
 - package/lib/node_modules/react-draft-wysiwyg/dist/react-draft-wysiwyg.js +2 -2
 - package/lib/node_modules/react-draft-wysiwyg/dist/react-draft-wysiwyg.js.map +1 -1
 - package/package.json +1 -1
 - package/lib/_virtual/immutable.es.js +0 -7
 - package/lib/_virtual/immutable.es.js.map +0 -1
 - package/lib/node_modules/draft-js/node_modules/immutable/dist/immutable.js.map +0 -1
 - package/lib/node_modules/immutable/dist/immutable.es.js +0 -4829
 - package/lib/node_modules/immutable/dist/immutable.es.js.map +0 -1
 
| 
         @@ -1,4829 +0,0 @@ 
     | 
|
| 
       1 
     | 
    
         
            -
            /**
         
     | 
| 
       2 
     | 
    
         
            -
             * MIT License
         
     | 
| 
       3 
     | 
    
         
            -
             * 
         
     | 
| 
       4 
     | 
    
         
            -
             * Copyright (c) 2014-present, Lee Byron and other contributors.
         
     | 
| 
       5 
     | 
    
         
            -
             * 
         
     | 
| 
       6 
     | 
    
         
            -
             * Permission is hereby granted, free of charge, to any person obtaining a copy
         
     | 
| 
       7 
     | 
    
         
            -
             * of this software and associated documentation files (the "Software"), to deal
         
     | 
| 
       8 
     | 
    
         
            -
             * in the Software without restriction, including without limitation the rights
         
     | 
| 
       9 
     | 
    
         
            -
             * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
         
     | 
| 
       10 
     | 
    
         
            -
             * copies of the Software, and to permit persons to whom the Software is
         
     | 
| 
       11 
     | 
    
         
            -
             * furnished to do so, subject to the following conditions:
         
     | 
| 
       12 
     | 
    
         
            -
             * 
         
     | 
| 
       13 
     | 
    
         
            -
             * The above copyright notice and this permission notice shall be included in all
         
     | 
| 
       14 
     | 
    
         
            -
             * copies or substantial portions of the Software.
         
     | 
| 
       15 
     | 
    
         
            -
             * 
         
     | 
| 
       16 
     | 
    
         
            -
             * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
         
     | 
| 
       17 
     | 
    
         
            -
             * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
         
     | 
| 
       18 
     | 
    
         
            -
             * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
         
     | 
| 
       19 
     | 
    
         
            -
             * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
         
     | 
| 
       20 
     | 
    
         
            -
             * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
         
     | 
| 
       21 
     | 
    
         
            -
             * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
         
     | 
| 
       22 
     | 
    
         
            -
             * SOFTWARE.
         
     | 
| 
       23 
     | 
    
         
            -
             */
         
     | 
| 
       24 
     | 
    
         
            -
            var DELETE = 'delete';
         
     | 
| 
       25 
     | 
    
         
            -
             
     | 
| 
       26 
     | 
    
         
            -
            // Constants describing the size of trie nodes.
         
     | 
| 
       27 
     | 
    
         
            -
            var SHIFT = 5; // Resulted in best performance after ______?
         
     | 
| 
       28 
     | 
    
         
            -
            var SIZE = 1 << SHIFT;
         
     | 
| 
       29 
     | 
    
         
            -
            var MASK = SIZE - 1;
         
     | 
| 
       30 
     | 
    
         
            -
             
     | 
| 
       31 
     | 
    
         
            -
            // A consistent shared value representing "not set" which equals nothing other
         
     | 
| 
       32 
     | 
    
         
            -
            // than itself, and nothing that could be provided externally.
         
     | 
| 
       33 
     | 
    
         
            -
            var NOT_SET = {};
         
     | 
| 
       34 
     | 
    
         
            -
             
     | 
| 
       35 
     | 
    
         
            -
            // Boolean references, Rough equivalent of `bool &`.
         
     | 
| 
       36 
     | 
    
         
            -
            function MakeRef() {
         
     | 
| 
       37 
     | 
    
         
            -
              return {
         
     | 
| 
       38 
     | 
    
         
            -
                value: false
         
     | 
| 
       39 
     | 
    
         
            -
              };
         
     | 
| 
       40 
     | 
    
         
            -
            }
         
     | 
| 
       41 
     | 
    
         
            -
            function SetRef(ref) {
         
     | 
| 
       42 
     | 
    
         
            -
              if (ref) {
         
     | 
| 
       43 
     | 
    
         
            -
                ref.value = true;
         
     | 
| 
       44 
     | 
    
         
            -
              }
         
     | 
| 
       45 
     | 
    
         
            -
            }
         
     | 
| 
       46 
     | 
    
         
            -
             
     | 
| 
       47 
     | 
    
         
            -
            // A function which returns a value representing an "owner" for transient writes
         
     | 
| 
       48 
     | 
    
         
            -
            // to tries. The return value will only ever equal itself, and will not equal
         
     | 
| 
       49 
     | 
    
         
            -
            // the return of any subsequent call of this function.
         
     | 
| 
       50 
     | 
    
         
            -
            function OwnerID() {}
         
     | 
| 
       51 
     | 
    
         
            -
            function ensureSize(iter) {
         
     | 
| 
       52 
     | 
    
         
            -
              if (iter.size === undefined) {
         
     | 
| 
       53 
     | 
    
         
            -
                iter.size = iter.__iterate(returnTrue);
         
     | 
| 
       54 
     | 
    
         
            -
              }
         
     | 
| 
       55 
     | 
    
         
            -
              return iter.size;
         
     | 
| 
       56 
     | 
    
         
            -
            }
         
     | 
| 
       57 
     | 
    
         
            -
            function wrapIndex(iter, index) {
         
     | 
| 
       58 
     | 
    
         
            -
              // This implements "is array index" which the ECMAString spec defines as:
         
     | 
| 
       59 
     | 
    
         
            -
              //
         
     | 
| 
       60 
     | 
    
         
            -
              //     A String property name P is an array index if and only if
         
     | 
| 
       61 
     | 
    
         
            -
              //     ToString(ToUint32(P)) is equal to P and ToUint32(P) is not equal
         
     | 
| 
       62 
     | 
    
         
            -
              //     to 2^32−1.
         
     | 
| 
       63 
     | 
    
         
            -
              //
         
     | 
| 
       64 
     | 
    
         
            -
              // http://www.ecma-international.org/ecma-262/6.0/#sec-array-exotic-objects
         
     | 
| 
       65 
     | 
    
         
            -
              if (typeof index !== 'number') {
         
     | 
| 
       66 
     | 
    
         
            -
                var uint32Index = index >>> 0; // N >>> 0 is shorthand for ToUint32
         
     | 
| 
       67 
     | 
    
         
            -
                if ('' + uint32Index !== index || uint32Index === 4294967295) {
         
     | 
| 
       68 
     | 
    
         
            -
                  return NaN;
         
     | 
| 
       69 
     | 
    
         
            -
                }
         
     | 
| 
       70 
     | 
    
         
            -
                index = uint32Index;
         
     | 
| 
       71 
     | 
    
         
            -
              }
         
     | 
| 
       72 
     | 
    
         
            -
              return index < 0 ? ensureSize(iter) + index : index;
         
     | 
| 
       73 
     | 
    
         
            -
            }
         
     | 
| 
       74 
     | 
    
         
            -
            function returnTrue() {
         
     | 
| 
       75 
     | 
    
         
            -
              return true;
         
     | 
| 
       76 
     | 
    
         
            -
            }
         
     | 
| 
       77 
     | 
    
         
            -
            function wholeSlice(begin, end, size) {
         
     | 
| 
       78 
     | 
    
         
            -
              return (begin === 0 && !isNeg(begin) || size !== undefined && begin <= -size) && (end === undefined || size !== undefined && end >= size);
         
     | 
| 
       79 
     | 
    
         
            -
            }
         
     | 
| 
       80 
     | 
    
         
            -
            function resolveBegin(begin, size) {
         
     | 
| 
       81 
     | 
    
         
            -
              return resolveIndex(begin, size, 0);
         
     | 
| 
       82 
     | 
    
         
            -
            }
         
     | 
| 
       83 
     | 
    
         
            -
            function resolveEnd(end, size) {
         
     | 
| 
       84 
     | 
    
         
            -
              return resolveIndex(end, size, size);
         
     | 
| 
       85 
     | 
    
         
            -
            }
         
     | 
| 
       86 
     | 
    
         
            -
            function resolveIndex(index, size, defaultIndex) {
         
     | 
| 
       87 
     | 
    
         
            -
              // Sanitize indices using this shorthand for ToInt32(argument)
         
     | 
| 
       88 
     | 
    
         
            -
              // http://www.ecma-international.org/ecma-262/6.0/#sec-toint32
         
     | 
| 
       89 
     | 
    
         
            -
              return index === undefined ? defaultIndex : isNeg(index) ? size === Infinity ? size : Math.max(0, size + index) | 0 : size === undefined || size === index ? index : Math.min(size, index) | 0;
         
     | 
| 
       90 
     | 
    
         
            -
            }
         
     | 
| 
       91 
     | 
    
         
            -
            function isNeg(value) {
         
     | 
| 
       92 
     | 
    
         
            -
              // Account for -0 which is negative, but not less than 0.
         
     | 
| 
       93 
     | 
    
         
            -
              return value < 0 || value === 0 && 1 / value === -Infinity;
         
     | 
| 
       94 
     | 
    
         
            -
            }
         
     | 
| 
       95 
     | 
    
         
            -
            var IS_COLLECTION_SYMBOL = '@@__IMMUTABLE_ITERABLE__@@';
         
     | 
| 
       96 
     | 
    
         
            -
            function isCollection(maybeCollection) {
         
     | 
| 
       97 
     | 
    
         
            -
              return Boolean(maybeCollection && maybeCollection[IS_COLLECTION_SYMBOL]);
         
     | 
| 
       98 
     | 
    
         
            -
            }
         
     | 
| 
       99 
     | 
    
         
            -
            var IS_KEYED_SYMBOL = '@@__IMMUTABLE_KEYED__@@';
         
     | 
| 
       100 
     | 
    
         
            -
            function isKeyed(maybeKeyed) {
         
     | 
| 
       101 
     | 
    
         
            -
              return Boolean(maybeKeyed && maybeKeyed[IS_KEYED_SYMBOL]);
         
     | 
| 
       102 
     | 
    
         
            -
            }
         
     | 
| 
       103 
     | 
    
         
            -
            var IS_INDEXED_SYMBOL = '@@__IMMUTABLE_INDEXED__@@';
         
     | 
| 
       104 
     | 
    
         
            -
            function isIndexed(maybeIndexed) {
         
     | 
| 
       105 
     | 
    
         
            -
              return Boolean(maybeIndexed && maybeIndexed[IS_INDEXED_SYMBOL]);
         
     | 
| 
       106 
     | 
    
         
            -
            }
         
     | 
| 
       107 
     | 
    
         
            -
            function isAssociative(maybeAssociative) {
         
     | 
| 
       108 
     | 
    
         
            -
              return isKeyed(maybeAssociative) || isIndexed(maybeAssociative);
         
     | 
| 
       109 
     | 
    
         
            -
            }
         
     | 
| 
       110 
     | 
    
         
            -
            var Collection = function Collection(value) {
         
     | 
| 
       111 
     | 
    
         
            -
              // eslint-disable-next-line no-constructor-return
         
     | 
| 
       112 
     | 
    
         
            -
              return isCollection(value) ? value : Seq(value);
         
     | 
| 
       113 
     | 
    
         
            -
            };
         
     | 
| 
       114 
     | 
    
         
            -
            var KeyedCollection = /*@__PURE__*/function (Collection) {
         
     | 
| 
       115 
     | 
    
         
            -
              function KeyedCollection(value) {
         
     | 
| 
       116 
     | 
    
         
            -
                // eslint-disable-next-line no-constructor-return
         
     | 
| 
       117 
     | 
    
         
            -
                return isKeyed(value) ? value : KeyedSeq(value);
         
     | 
| 
       118 
     | 
    
         
            -
              }
         
     | 
| 
       119 
     | 
    
         
            -
              if (Collection) KeyedCollection.__proto__ = Collection;
         
     | 
| 
       120 
     | 
    
         
            -
              KeyedCollection.prototype = Object.create(Collection && Collection.prototype);
         
     | 
| 
       121 
     | 
    
         
            -
              KeyedCollection.prototype.constructor = KeyedCollection;
         
     | 
| 
       122 
     | 
    
         
            -
              return KeyedCollection;
         
     | 
| 
       123 
     | 
    
         
            -
            }(Collection);
         
     | 
| 
       124 
     | 
    
         
            -
            var IndexedCollection = /*@__PURE__*/function (Collection) {
         
     | 
| 
       125 
     | 
    
         
            -
              function IndexedCollection(value) {
         
     | 
| 
       126 
     | 
    
         
            -
                // eslint-disable-next-line no-constructor-return
         
     | 
| 
       127 
     | 
    
         
            -
                return isIndexed(value) ? value : IndexedSeq(value);
         
     | 
| 
       128 
     | 
    
         
            -
              }
         
     | 
| 
       129 
     | 
    
         
            -
              if (Collection) IndexedCollection.__proto__ = Collection;
         
     | 
| 
       130 
     | 
    
         
            -
              IndexedCollection.prototype = Object.create(Collection && Collection.prototype);
         
     | 
| 
       131 
     | 
    
         
            -
              IndexedCollection.prototype.constructor = IndexedCollection;
         
     | 
| 
       132 
     | 
    
         
            -
              return IndexedCollection;
         
     | 
| 
       133 
     | 
    
         
            -
            }(Collection);
         
     | 
| 
       134 
     | 
    
         
            -
            var SetCollection = /*@__PURE__*/function (Collection) {
         
     | 
| 
       135 
     | 
    
         
            -
              function SetCollection(value) {
         
     | 
| 
       136 
     | 
    
         
            -
                // eslint-disable-next-line no-constructor-return
         
     | 
| 
       137 
     | 
    
         
            -
                return isCollection(value) && !isAssociative(value) ? value : SetSeq(value);
         
     | 
| 
       138 
     | 
    
         
            -
              }
         
     | 
| 
       139 
     | 
    
         
            -
              if (Collection) SetCollection.__proto__ = Collection;
         
     | 
| 
       140 
     | 
    
         
            -
              SetCollection.prototype = Object.create(Collection && Collection.prototype);
         
     | 
| 
       141 
     | 
    
         
            -
              SetCollection.prototype.constructor = SetCollection;
         
     | 
| 
       142 
     | 
    
         
            -
              return SetCollection;
         
     | 
| 
       143 
     | 
    
         
            -
            }(Collection);
         
     | 
| 
       144 
     | 
    
         
            -
            Collection.Keyed = KeyedCollection;
         
     | 
| 
       145 
     | 
    
         
            -
            Collection.Indexed = IndexedCollection;
         
     | 
| 
       146 
     | 
    
         
            -
            Collection.Set = SetCollection;
         
     | 
| 
       147 
     | 
    
         
            -
            var IS_SEQ_SYMBOL = '@@__IMMUTABLE_SEQ__@@';
         
     | 
| 
       148 
     | 
    
         
            -
            function isSeq(maybeSeq) {
         
     | 
| 
       149 
     | 
    
         
            -
              return Boolean(maybeSeq && maybeSeq[IS_SEQ_SYMBOL]);
         
     | 
| 
       150 
     | 
    
         
            -
            }
         
     | 
| 
       151 
     | 
    
         
            -
            var IS_RECORD_SYMBOL = '@@__IMMUTABLE_RECORD__@@';
         
     | 
| 
       152 
     | 
    
         
            -
            function isRecord(maybeRecord) {
         
     | 
| 
       153 
     | 
    
         
            -
              return Boolean(maybeRecord && maybeRecord[IS_RECORD_SYMBOL]);
         
     | 
| 
       154 
     | 
    
         
            -
            }
         
     | 
| 
       155 
     | 
    
         
            -
            function isImmutable(maybeImmutable) {
         
     | 
| 
       156 
     | 
    
         
            -
              return isCollection(maybeImmutable) || isRecord(maybeImmutable);
         
     | 
| 
       157 
     | 
    
         
            -
            }
         
     | 
| 
       158 
     | 
    
         
            -
            var IS_ORDERED_SYMBOL = '@@__IMMUTABLE_ORDERED__@@';
         
     | 
| 
       159 
     | 
    
         
            -
            function isOrdered(maybeOrdered) {
         
     | 
| 
       160 
     | 
    
         
            -
              return Boolean(maybeOrdered && maybeOrdered[IS_ORDERED_SYMBOL]);
         
     | 
| 
       161 
     | 
    
         
            -
            }
         
     | 
| 
       162 
     | 
    
         
            -
            var ITERATE_KEYS = 0;
         
     | 
| 
       163 
     | 
    
         
            -
            var ITERATE_VALUES = 1;
         
     | 
| 
       164 
     | 
    
         
            -
            var ITERATE_ENTRIES = 2;
         
     | 
| 
       165 
     | 
    
         
            -
            var REAL_ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;
         
     | 
| 
       166 
     | 
    
         
            -
            var FAUX_ITERATOR_SYMBOL = '@@iterator';
         
     | 
| 
       167 
     | 
    
         
            -
            var ITERATOR_SYMBOL = REAL_ITERATOR_SYMBOL || FAUX_ITERATOR_SYMBOL;
         
     | 
| 
       168 
     | 
    
         
            -
            var Iterator = function Iterator(next) {
         
     | 
| 
       169 
     | 
    
         
            -
              this.next = next;
         
     | 
| 
       170 
     | 
    
         
            -
            };
         
     | 
| 
       171 
     | 
    
         
            -
            Iterator.prototype.toString = function toString() {
         
     | 
| 
       172 
     | 
    
         
            -
              return '[Iterator]';
         
     | 
| 
       173 
     | 
    
         
            -
            };
         
     | 
| 
       174 
     | 
    
         
            -
            Iterator.KEYS = ITERATE_KEYS;
         
     | 
| 
       175 
     | 
    
         
            -
            Iterator.VALUES = ITERATE_VALUES;
         
     | 
| 
       176 
     | 
    
         
            -
            Iterator.ENTRIES = ITERATE_ENTRIES;
         
     | 
| 
       177 
     | 
    
         
            -
            Iterator.prototype.inspect = Iterator.prototype.toSource = function () {
         
     | 
| 
       178 
     | 
    
         
            -
              return this.toString();
         
     | 
| 
       179 
     | 
    
         
            -
            };
         
     | 
| 
       180 
     | 
    
         
            -
            Iterator.prototype[ITERATOR_SYMBOL] = function () {
         
     | 
| 
       181 
     | 
    
         
            -
              return this;
         
     | 
| 
       182 
     | 
    
         
            -
            };
         
     | 
| 
       183 
     | 
    
         
            -
            function iteratorValue(type, k, v, iteratorResult) {
         
     | 
| 
       184 
     | 
    
         
            -
              var value = type === 0 ? k : type === 1 ? v : [k, v];
         
     | 
| 
       185 
     | 
    
         
            -
              iteratorResult ? iteratorResult.value = value : iteratorResult = {
         
     | 
| 
       186 
     | 
    
         
            -
                value: value,
         
     | 
| 
       187 
     | 
    
         
            -
                done: false
         
     | 
| 
       188 
     | 
    
         
            -
              };
         
     | 
| 
       189 
     | 
    
         
            -
              return iteratorResult;
         
     | 
| 
       190 
     | 
    
         
            -
            }
         
     | 
| 
       191 
     | 
    
         
            -
            function iteratorDone() {
         
     | 
| 
       192 
     | 
    
         
            -
              return {
         
     | 
| 
       193 
     | 
    
         
            -
                value: undefined,
         
     | 
| 
       194 
     | 
    
         
            -
                done: true
         
     | 
| 
       195 
     | 
    
         
            -
              };
         
     | 
| 
       196 
     | 
    
         
            -
            }
         
     | 
| 
       197 
     | 
    
         
            -
            function hasIterator(maybeIterable) {
         
     | 
| 
       198 
     | 
    
         
            -
              if (Array.isArray(maybeIterable)) {
         
     | 
| 
       199 
     | 
    
         
            -
                // IE11 trick as it does not support `Symbol.iterator`
         
     | 
| 
       200 
     | 
    
         
            -
                return true;
         
     | 
| 
       201 
     | 
    
         
            -
              }
         
     | 
| 
       202 
     | 
    
         
            -
              return !!getIteratorFn(maybeIterable);
         
     | 
| 
       203 
     | 
    
         
            -
            }
         
     | 
| 
       204 
     | 
    
         
            -
            function isIterator(maybeIterator) {
         
     | 
| 
       205 
     | 
    
         
            -
              return maybeIterator && typeof maybeIterator.next === 'function';
         
     | 
| 
       206 
     | 
    
         
            -
            }
         
     | 
| 
       207 
     | 
    
         
            -
            function getIterator(iterable) {
         
     | 
| 
       208 
     | 
    
         
            -
              var iteratorFn = getIteratorFn(iterable);
         
     | 
| 
       209 
     | 
    
         
            -
              return iteratorFn && iteratorFn.call(iterable);
         
     | 
| 
       210 
     | 
    
         
            -
            }
         
     | 
| 
       211 
     | 
    
         
            -
            function getIteratorFn(iterable) {
         
     | 
| 
       212 
     | 
    
         
            -
              var iteratorFn = iterable && (REAL_ITERATOR_SYMBOL && iterable[REAL_ITERATOR_SYMBOL] || iterable[FAUX_ITERATOR_SYMBOL]);
         
     | 
| 
       213 
     | 
    
         
            -
              if (typeof iteratorFn === 'function') {
         
     | 
| 
       214 
     | 
    
         
            -
                return iteratorFn;
         
     | 
| 
       215 
     | 
    
         
            -
              }
         
     | 
| 
       216 
     | 
    
         
            -
            }
         
     | 
| 
       217 
     | 
    
         
            -
            function isEntriesIterable(maybeIterable) {
         
     | 
| 
       218 
     | 
    
         
            -
              var iteratorFn = getIteratorFn(maybeIterable);
         
     | 
| 
       219 
     | 
    
         
            -
              return iteratorFn && iteratorFn === maybeIterable.entries;
         
     | 
| 
       220 
     | 
    
         
            -
            }
         
     | 
| 
       221 
     | 
    
         
            -
            function isKeysIterable(maybeIterable) {
         
     | 
| 
       222 
     | 
    
         
            -
              var iteratorFn = getIteratorFn(maybeIterable);
         
     | 
| 
       223 
     | 
    
         
            -
              return iteratorFn && iteratorFn === maybeIterable.keys;
         
     | 
| 
       224 
     | 
    
         
            -
            }
         
     | 
| 
       225 
     | 
    
         
            -
            var hasOwnProperty = Object.prototype.hasOwnProperty;
         
     | 
| 
       226 
     | 
    
         
            -
            function isArrayLike(value) {
         
     | 
| 
       227 
     | 
    
         
            -
              if (Array.isArray(value) || typeof value === 'string') {
         
     | 
| 
       228 
     | 
    
         
            -
                return true;
         
     | 
| 
       229 
     | 
    
         
            -
              }
         
     | 
| 
       230 
     | 
    
         
            -
              return value && typeof value === 'object' && Number.isInteger(value.length) && value.length >= 0 && (value.length === 0 ?
         
     | 
| 
       231 
     | 
    
         
            -
              // Only {length: 0} is considered Array-like.
         
     | 
| 
       232 
     | 
    
         
            -
              Object.keys(value).length === 1 :
         
     | 
| 
       233 
     | 
    
         
            -
              // An object is only Array-like if it has a property where the last value
         
     | 
| 
       234 
     | 
    
         
            -
              // in the array-like may be found (which could be undefined).
         
     | 
| 
       235 
     | 
    
         
            -
              value.hasOwnProperty(value.length - 1));
         
     | 
| 
       236 
     | 
    
         
            -
            }
         
     | 
| 
       237 
     | 
    
         
            -
            var Seq = /*@__PURE__*/function (Collection) {
         
     | 
| 
       238 
     | 
    
         
            -
              function Seq(value) {
         
     | 
| 
       239 
     | 
    
         
            -
                // eslint-disable-next-line no-constructor-return
         
     | 
| 
       240 
     | 
    
         
            -
                return value === undefined || value === null ? emptySequence() : isImmutable(value) ? value.toSeq() : seqFromValue(value);
         
     | 
| 
       241 
     | 
    
         
            -
              }
         
     | 
| 
       242 
     | 
    
         
            -
              if (Collection) Seq.__proto__ = Collection;
         
     | 
| 
       243 
     | 
    
         
            -
              Seq.prototype = Object.create(Collection && Collection.prototype);
         
     | 
| 
       244 
     | 
    
         
            -
              Seq.prototype.constructor = Seq;
         
     | 
| 
       245 
     | 
    
         
            -
              Seq.prototype.toSeq = function toSeq() {
         
     | 
| 
       246 
     | 
    
         
            -
                return this;
         
     | 
| 
       247 
     | 
    
         
            -
              };
         
     | 
| 
       248 
     | 
    
         
            -
              Seq.prototype.toString = function toString() {
         
     | 
| 
       249 
     | 
    
         
            -
                return this.__toString('Seq {', '}');
         
     | 
| 
       250 
     | 
    
         
            -
              };
         
     | 
| 
       251 
     | 
    
         
            -
              Seq.prototype.cacheResult = function cacheResult() {
         
     | 
| 
       252 
     | 
    
         
            -
                if (!this._cache && this.__iterateUncached) {
         
     | 
| 
       253 
     | 
    
         
            -
                  this._cache = this.entrySeq().toArray();
         
     | 
| 
       254 
     | 
    
         
            -
                  this.size = this._cache.length;
         
     | 
| 
       255 
     | 
    
         
            -
                }
         
     | 
| 
       256 
     | 
    
         
            -
                return this;
         
     | 
| 
       257 
     | 
    
         
            -
              };
         
     | 
| 
       258 
     | 
    
         
            -
             
     | 
| 
       259 
     | 
    
         
            -
              // abstract __iterateUncached(fn, reverse)
         
     | 
| 
       260 
     | 
    
         
            -
             
     | 
| 
       261 
     | 
    
         
            -
              Seq.prototype.__iterate = function __iterate(fn, reverse) {
         
     | 
| 
       262 
     | 
    
         
            -
                var cache = this._cache;
         
     | 
| 
       263 
     | 
    
         
            -
                if (cache) {
         
     | 
| 
       264 
     | 
    
         
            -
                  var size = cache.length;
         
     | 
| 
       265 
     | 
    
         
            -
                  var i = 0;
         
     | 
| 
       266 
     | 
    
         
            -
                  while (i !== size) {
         
     | 
| 
       267 
     | 
    
         
            -
                    var entry = cache[reverse ? size - ++i : i++];
         
     | 
| 
       268 
     | 
    
         
            -
                    if (fn(entry[1], entry[0], this) === false) {
         
     | 
| 
       269 
     | 
    
         
            -
                      break;
         
     | 
| 
       270 
     | 
    
         
            -
                    }
         
     | 
| 
       271 
     | 
    
         
            -
                  }
         
     | 
| 
       272 
     | 
    
         
            -
                  return i;
         
     | 
| 
       273 
     | 
    
         
            -
                }
         
     | 
| 
       274 
     | 
    
         
            -
                return this.__iterateUncached(fn, reverse);
         
     | 
| 
       275 
     | 
    
         
            -
              };
         
     | 
| 
       276 
     | 
    
         
            -
             
     | 
| 
       277 
     | 
    
         
            -
              // abstract __iteratorUncached(type, reverse)
         
     | 
| 
       278 
     | 
    
         
            -
             
     | 
| 
       279 
     | 
    
         
            -
              Seq.prototype.__iterator = function __iterator(type, reverse) {
         
     | 
| 
       280 
     | 
    
         
            -
                var cache = this._cache;
         
     | 
| 
       281 
     | 
    
         
            -
                if (cache) {
         
     | 
| 
       282 
     | 
    
         
            -
                  var size = cache.length;
         
     | 
| 
       283 
     | 
    
         
            -
                  var i = 0;
         
     | 
| 
       284 
     | 
    
         
            -
                  return new Iterator(function () {
         
     | 
| 
       285 
     | 
    
         
            -
                    if (i === size) {
         
     | 
| 
       286 
     | 
    
         
            -
                      return iteratorDone();
         
     | 
| 
       287 
     | 
    
         
            -
                    }
         
     | 
| 
       288 
     | 
    
         
            -
                    var entry = cache[reverse ? size - ++i : i++];
         
     | 
| 
       289 
     | 
    
         
            -
                    return iteratorValue(type, entry[0], entry[1]);
         
     | 
| 
       290 
     | 
    
         
            -
                  });
         
     | 
| 
       291 
     | 
    
         
            -
                }
         
     | 
| 
       292 
     | 
    
         
            -
                return this.__iteratorUncached(type, reverse);
         
     | 
| 
       293 
     | 
    
         
            -
              };
         
     | 
| 
       294 
     | 
    
         
            -
              return Seq;
         
     | 
| 
       295 
     | 
    
         
            -
            }(Collection);
         
     | 
| 
       296 
     | 
    
         
            -
            var KeyedSeq = /*@__PURE__*/function (Seq) {
         
     | 
| 
       297 
     | 
    
         
            -
              function KeyedSeq(value) {
         
     | 
| 
       298 
     | 
    
         
            -
                // eslint-disable-next-line no-constructor-return
         
     | 
| 
       299 
     | 
    
         
            -
                return value === undefined || value === null ? emptySequence().toKeyedSeq() : isCollection(value) ? isKeyed(value) ? value.toSeq() : value.fromEntrySeq() : isRecord(value) ? value.toSeq() : keyedSeqFromValue(value);
         
     | 
| 
       300 
     | 
    
         
            -
              }
         
     | 
| 
       301 
     | 
    
         
            -
              if (Seq) KeyedSeq.__proto__ = Seq;
         
     | 
| 
       302 
     | 
    
         
            -
              KeyedSeq.prototype = Object.create(Seq && Seq.prototype);
         
     | 
| 
       303 
     | 
    
         
            -
              KeyedSeq.prototype.constructor = KeyedSeq;
         
     | 
| 
       304 
     | 
    
         
            -
              KeyedSeq.prototype.toKeyedSeq = function toKeyedSeq() {
         
     | 
| 
       305 
     | 
    
         
            -
                return this;
         
     | 
| 
       306 
     | 
    
         
            -
              };
         
     | 
| 
       307 
     | 
    
         
            -
              return KeyedSeq;
         
     | 
| 
       308 
     | 
    
         
            -
            }(Seq);
         
     | 
| 
       309 
     | 
    
         
            -
            var IndexedSeq = /*@__PURE__*/function (Seq) {
         
     | 
| 
       310 
     | 
    
         
            -
              function IndexedSeq(value) {
         
     | 
| 
       311 
     | 
    
         
            -
                // eslint-disable-next-line no-constructor-return
         
     | 
| 
       312 
     | 
    
         
            -
                return value === undefined || value === null ? emptySequence() : isCollection(value) ? isKeyed(value) ? value.entrySeq() : value.toIndexedSeq() : isRecord(value) ? value.toSeq().entrySeq() : indexedSeqFromValue(value);
         
     | 
| 
       313 
     | 
    
         
            -
              }
         
     | 
| 
       314 
     | 
    
         
            -
              if (Seq) IndexedSeq.__proto__ = Seq;
         
     | 
| 
       315 
     | 
    
         
            -
              IndexedSeq.prototype = Object.create(Seq && Seq.prototype);
         
     | 
| 
       316 
     | 
    
         
            -
              IndexedSeq.prototype.constructor = IndexedSeq;
         
     | 
| 
       317 
     | 
    
         
            -
              IndexedSeq.of = function of(/*...values*/
         
     | 
| 
       318 
     | 
    
         
            -
              ) {
         
     | 
| 
       319 
     | 
    
         
            -
                return IndexedSeq(arguments);
         
     | 
| 
       320 
     | 
    
         
            -
              };
         
     | 
| 
       321 
     | 
    
         
            -
              IndexedSeq.prototype.toIndexedSeq = function toIndexedSeq() {
         
     | 
| 
       322 
     | 
    
         
            -
                return this;
         
     | 
| 
       323 
     | 
    
         
            -
              };
         
     | 
| 
       324 
     | 
    
         
            -
              IndexedSeq.prototype.toString = function toString() {
         
     | 
| 
       325 
     | 
    
         
            -
                return this.__toString('Seq [', ']');
         
     | 
| 
       326 
     | 
    
         
            -
              };
         
     | 
| 
       327 
     | 
    
         
            -
              return IndexedSeq;
         
     | 
| 
       328 
     | 
    
         
            -
            }(Seq);
         
     | 
| 
       329 
     | 
    
         
            -
            var SetSeq = /*@__PURE__*/function (Seq) {
         
     | 
| 
       330 
     | 
    
         
            -
              function SetSeq(value) {
         
     | 
| 
       331 
     | 
    
         
            -
                // eslint-disable-next-line no-constructor-return
         
     | 
| 
       332 
     | 
    
         
            -
                return (isCollection(value) && !isAssociative(value) ? value : IndexedSeq(value)).toSetSeq();
         
     | 
| 
       333 
     | 
    
         
            -
              }
         
     | 
| 
       334 
     | 
    
         
            -
              if (Seq) SetSeq.__proto__ = Seq;
         
     | 
| 
       335 
     | 
    
         
            -
              SetSeq.prototype = Object.create(Seq && Seq.prototype);
         
     | 
| 
       336 
     | 
    
         
            -
              SetSeq.prototype.constructor = SetSeq;
         
     | 
| 
       337 
     | 
    
         
            -
              SetSeq.of = function of(/*...values*/
         
     | 
| 
       338 
     | 
    
         
            -
              ) {
         
     | 
| 
       339 
     | 
    
         
            -
                return SetSeq(arguments);
         
     | 
| 
       340 
     | 
    
         
            -
              };
         
     | 
| 
       341 
     | 
    
         
            -
              SetSeq.prototype.toSetSeq = function toSetSeq() {
         
     | 
| 
       342 
     | 
    
         
            -
                return this;
         
     | 
| 
       343 
     | 
    
         
            -
              };
         
     | 
| 
       344 
     | 
    
         
            -
              return SetSeq;
         
     | 
| 
       345 
     | 
    
         
            -
            }(Seq);
         
     | 
| 
       346 
     | 
    
         
            -
            Seq.isSeq = isSeq;
         
     | 
| 
       347 
     | 
    
         
            -
            Seq.Keyed = KeyedSeq;
         
     | 
| 
       348 
     | 
    
         
            -
            Seq.Set = SetSeq;
         
     | 
| 
       349 
     | 
    
         
            -
            Seq.Indexed = IndexedSeq;
         
     | 
| 
       350 
     | 
    
         
            -
            Seq.prototype[IS_SEQ_SYMBOL] = true;
         
     | 
| 
       351 
     | 
    
         
            -
             
     | 
| 
       352 
     | 
    
         
            -
            // #pragma Root Sequences
         
     | 
| 
       353 
     | 
    
         
            -
             
     | 
| 
       354 
     | 
    
         
            -
            var ArraySeq = /*@__PURE__*/function (IndexedSeq) {
         
     | 
| 
       355 
     | 
    
         
            -
              function ArraySeq(array) {
         
     | 
| 
       356 
     | 
    
         
            -
                this._array = array;
         
     | 
| 
       357 
     | 
    
         
            -
                this.size = array.length;
         
     | 
| 
       358 
     | 
    
         
            -
              }
         
     | 
| 
       359 
     | 
    
         
            -
              if (IndexedSeq) ArraySeq.__proto__ = IndexedSeq;
         
     | 
| 
       360 
     | 
    
         
            -
              ArraySeq.prototype = Object.create(IndexedSeq && IndexedSeq.prototype);
         
     | 
| 
       361 
     | 
    
         
            -
              ArraySeq.prototype.constructor = ArraySeq;
         
     | 
| 
       362 
     | 
    
         
            -
              ArraySeq.prototype.get = function get(index, notSetValue) {
         
     | 
| 
       363 
     | 
    
         
            -
                return this.has(index) ? this._array[wrapIndex(this, index)] : notSetValue;
         
     | 
| 
       364 
     | 
    
         
            -
              };
         
     | 
| 
       365 
     | 
    
         
            -
              ArraySeq.prototype.__iterate = function __iterate(fn, reverse) {
         
     | 
| 
       366 
     | 
    
         
            -
                var array = this._array;
         
     | 
| 
       367 
     | 
    
         
            -
                var size = array.length;
         
     | 
| 
       368 
     | 
    
         
            -
                var i = 0;
         
     | 
| 
       369 
     | 
    
         
            -
                while (i !== size) {
         
     | 
| 
       370 
     | 
    
         
            -
                  var ii = reverse ? size - ++i : i++;
         
     | 
| 
       371 
     | 
    
         
            -
                  if (fn(array[ii], ii, this) === false) {
         
     | 
| 
       372 
     | 
    
         
            -
                    break;
         
     | 
| 
       373 
     | 
    
         
            -
                  }
         
     | 
| 
       374 
     | 
    
         
            -
                }
         
     | 
| 
       375 
     | 
    
         
            -
                return i;
         
     | 
| 
       376 
     | 
    
         
            -
              };
         
     | 
| 
       377 
     | 
    
         
            -
              ArraySeq.prototype.__iterator = function __iterator(type, reverse) {
         
     | 
| 
       378 
     | 
    
         
            -
                var array = this._array;
         
     | 
| 
       379 
     | 
    
         
            -
                var size = array.length;
         
     | 
| 
       380 
     | 
    
         
            -
                var i = 0;
         
     | 
| 
       381 
     | 
    
         
            -
                return new Iterator(function () {
         
     | 
| 
       382 
     | 
    
         
            -
                  if (i === size) {
         
     | 
| 
       383 
     | 
    
         
            -
                    return iteratorDone();
         
     | 
| 
       384 
     | 
    
         
            -
                  }
         
     | 
| 
       385 
     | 
    
         
            -
                  var ii = reverse ? size - ++i : i++;
         
     | 
| 
       386 
     | 
    
         
            -
                  return iteratorValue(type, ii, array[ii]);
         
     | 
| 
       387 
     | 
    
         
            -
                });
         
     | 
| 
       388 
     | 
    
         
            -
              };
         
     | 
| 
       389 
     | 
    
         
            -
              return ArraySeq;
         
     | 
| 
       390 
     | 
    
         
            -
            }(IndexedSeq);
         
     | 
| 
       391 
     | 
    
         
            -
            var ObjectSeq = /*@__PURE__*/function (KeyedSeq) {
         
     | 
| 
       392 
     | 
    
         
            -
              function ObjectSeq(object) {
         
     | 
| 
       393 
     | 
    
         
            -
                var keys = Object.keys(object).concat(Object.getOwnPropertySymbols ? Object.getOwnPropertySymbols(object) : []);
         
     | 
| 
       394 
     | 
    
         
            -
                this._object = object;
         
     | 
| 
       395 
     | 
    
         
            -
                this._keys = keys;
         
     | 
| 
       396 
     | 
    
         
            -
                this.size = keys.length;
         
     | 
| 
       397 
     | 
    
         
            -
              }
         
     | 
| 
       398 
     | 
    
         
            -
              if (KeyedSeq) ObjectSeq.__proto__ = KeyedSeq;
         
     | 
| 
       399 
     | 
    
         
            -
              ObjectSeq.prototype = Object.create(KeyedSeq && KeyedSeq.prototype);
         
     | 
| 
       400 
     | 
    
         
            -
              ObjectSeq.prototype.constructor = ObjectSeq;
         
     | 
| 
       401 
     | 
    
         
            -
              ObjectSeq.prototype.get = function get(key, notSetValue) {
         
     | 
| 
       402 
     | 
    
         
            -
                if (notSetValue !== undefined && !this.has(key)) {
         
     | 
| 
       403 
     | 
    
         
            -
                  return notSetValue;
         
     | 
| 
       404 
     | 
    
         
            -
                }
         
     | 
| 
       405 
     | 
    
         
            -
                return this._object[key];
         
     | 
| 
       406 
     | 
    
         
            -
              };
         
     | 
| 
       407 
     | 
    
         
            -
              ObjectSeq.prototype.has = function has(key) {
         
     | 
| 
       408 
     | 
    
         
            -
                return hasOwnProperty.call(this._object, key);
         
     | 
| 
       409 
     | 
    
         
            -
              };
         
     | 
| 
       410 
     | 
    
         
            -
              ObjectSeq.prototype.__iterate = function __iterate(fn, reverse) {
         
     | 
| 
       411 
     | 
    
         
            -
                var object = this._object;
         
     | 
| 
       412 
     | 
    
         
            -
                var keys = this._keys;
         
     | 
| 
       413 
     | 
    
         
            -
                var size = keys.length;
         
     | 
| 
       414 
     | 
    
         
            -
                var i = 0;
         
     | 
| 
       415 
     | 
    
         
            -
                while (i !== size) {
         
     | 
| 
       416 
     | 
    
         
            -
                  var key = keys[reverse ? size - ++i : i++];
         
     | 
| 
       417 
     | 
    
         
            -
                  if (fn(object[key], key, this) === false) {
         
     | 
| 
       418 
     | 
    
         
            -
                    break;
         
     | 
| 
       419 
     | 
    
         
            -
                  }
         
     | 
| 
       420 
     | 
    
         
            -
                }
         
     | 
| 
       421 
     | 
    
         
            -
                return i;
         
     | 
| 
       422 
     | 
    
         
            -
              };
         
     | 
| 
       423 
     | 
    
         
            -
              ObjectSeq.prototype.__iterator = function __iterator(type, reverse) {
         
     | 
| 
       424 
     | 
    
         
            -
                var object = this._object;
         
     | 
| 
       425 
     | 
    
         
            -
                var keys = this._keys;
         
     | 
| 
       426 
     | 
    
         
            -
                var size = keys.length;
         
     | 
| 
       427 
     | 
    
         
            -
                var i = 0;
         
     | 
| 
       428 
     | 
    
         
            -
                return new Iterator(function () {
         
     | 
| 
       429 
     | 
    
         
            -
                  if (i === size) {
         
     | 
| 
       430 
     | 
    
         
            -
                    return iteratorDone();
         
     | 
| 
       431 
     | 
    
         
            -
                  }
         
     | 
| 
       432 
     | 
    
         
            -
                  var key = keys[reverse ? size - ++i : i++];
         
     | 
| 
       433 
     | 
    
         
            -
                  return iteratorValue(type, key, object[key]);
         
     | 
| 
       434 
     | 
    
         
            -
                });
         
     | 
| 
       435 
     | 
    
         
            -
              };
         
     | 
| 
       436 
     | 
    
         
            -
              return ObjectSeq;
         
     | 
| 
       437 
     | 
    
         
            -
            }(KeyedSeq);
         
     | 
| 
       438 
     | 
    
         
            -
            ObjectSeq.prototype[IS_ORDERED_SYMBOL] = true;
         
     | 
| 
       439 
     | 
    
         
            -
            var CollectionSeq = /*@__PURE__*/function (IndexedSeq) {
         
     | 
| 
       440 
     | 
    
         
            -
              function CollectionSeq(collection) {
         
     | 
| 
       441 
     | 
    
         
            -
                this._collection = collection;
         
     | 
| 
       442 
     | 
    
         
            -
                this.size = collection.length || collection.size;
         
     | 
| 
       443 
     | 
    
         
            -
              }
         
     | 
| 
       444 
     | 
    
         
            -
              if (IndexedSeq) CollectionSeq.__proto__ = IndexedSeq;
         
     | 
| 
       445 
     | 
    
         
            -
              CollectionSeq.prototype = Object.create(IndexedSeq && IndexedSeq.prototype);
         
     | 
| 
       446 
     | 
    
         
            -
              CollectionSeq.prototype.constructor = CollectionSeq;
         
     | 
| 
       447 
     | 
    
         
            -
              CollectionSeq.prototype.__iterateUncached = function __iterateUncached(fn, reverse) {
         
     | 
| 
       448 
     | 
    
         
            -
                if (reverse) {
         
     | 
| 
       449 
     | 
    
         
            -
                  return this.cacheResult().__iterate(fn, reverse);
         
     | 
| 
       450 
     | 
    
         
            -
                }
         
     | 
| 
       451 
     | 
    
         
            -
                var collection = this._collection;
         
     | 
| 
       452 
     | 
    
         
            -
                var iterator = getIterator(collection);
         
     | 
| 
       453 
     | 
    
         
            -
                var iterations = 0;
         
     | 
| 
       454 
     | 
    
         
            -
                if (isIterator(iterator)) {
         
     | 
| 
       455 
     | 
    
         
            -
                  var step;
         
     | 
| 
       456 
     | 
    
         
            -
                  while (!(step = iterator.next()).done) {
         
     | 
| 
       457 
     | 
    
         
            -
                    if (fn(step.value, iterations++, this) === false) {
         
     | 
| 
       458 
     | 
    
         
            -
                      break;
         
     | 
| 
       459 
     | 
    
         
            -
                    }
         
     | 
| 
       460 
     | 
    
         
            -
                  }
         
     | 
| 
       461 
     | 
    
         
            -
                }
         
     | 
| 
       462 
     | 
    
         
            -
                return iterations;
         
     | 
| 
       463 
     | 
    
         
            -
              };
         
     | 
| 
       464 
     | 
    
         
            -
              CollectionSeq.prototype.__iteratorUncached = function __iteratorUncached(type, reverse) {
         
     | 
| 
       465 
     | 
    
         
            -
                if (reverse) {
         
     | 
| 
       466 
     | 
    
         
            -
                  return this.cacheResult().__iterator(type, reverse);
         
     | 
| 
       467 
     | 
    
         
            -
                }
         
     | 
| 
       468 
     | 
    
         
            -
                var collection = this._collection;
         
     | 
| 
       469 
     | 
    
         
            -
                var iterator = getIterator(collection);
         
     | 
| 
       470 
     | 
    
         
            -
                if (!isIterator(iterator)) {
         
     | 
| 
       471 
     | 
    
         
            -
                  return new Iterator(iteratorDone);
         
     | 
| 
       472 
     | 
    
         
            -
                }
         
     | 
| 
       473 
     | 
    
         
            -
                var iterations = 0;
         
     | 
| 
       474 
     | 
    
         
            -
                return new Iterator(function () {
         
     | 
| 
       475 
     | 
    
         
            -
                  var step = iterator.next();
         
     | 
| 
       476 
     | 
    
         
            -
                  return step.done ? step : iteratorValue(type, iterations++, step.value);
         
     | 
| 
       477 
     | 
    
         
            -
                });
         
     | 
| 
       478 
     | 
    
         
            -
              };
         
     | 
| 
       479 
     | 
    
         
            -
              return CollectionSeq;
         
     | 
| 
       480 
     | 
    
         
            -
            }(IndexedSeq);
         
     | 
| 
       481 
     | 
    
         
            -
             
     | 
| 
       482 
     | 
    
         
            -
            // # pragma Helper functions
         
     | 
| 
       483 
     | 
    
         
            -
             
     | 
| 
       484 
     | 
    
         
            -
            var EMPTY_SEQ;
         
     | 
| 
       485 
     | 
    
         
            -
            function emptySequence() {
         
     | 
| 
       486 
     | 
    
         
            -
              return EMPTY_SEQ || (EMPTY_SEQ = new ArraySeq([]));
         
     | 
| 
       487 
     | 
    
         
            -
            }
         
     | 
| 
       488 
     | 
    
         
            -
            function keyedSeqFromValue(value) {
         
     | 
| 
       489 
     | 
    
         
            -
              var seq = maybeIndexedSeqFromValue(value);
         
     | 
| 
       490 
     | 
    
         
            -
              if (seq) {
         
     | 
| 
       491 
     | 
    
         
            -
                return seq.fromEntrySeq();
         
     | 
| 
       492 
     | 
    
         
            -
              }
         
     | 
| 
       493 
     | 
    
         
            -
              if (typeof value === 'object') {
         
     | 
| 
       494 
     | 
    
         
            -
                return new ObjectSeq(value);
         
     | 
| 
       495 
     | 
    
         
            -
              }
         
     | 
| 
       496 
     | 
    
         
            -
              throw new TypeError('Expected Array or collection object of [k, v] entries, or keyed object: ' + value);
         
     | 
| 
       497 
     | 
    
         
            -
            }
         
     | 
| 
       498 
     | 
    
         
            -
            function indexedSeqFromValue(value) {
         
     | 
| 
       499 
     | 
    
         
            -
              var seq = maybeIndexedSeqFromValue(value);
         
     | 
| 
       500 
     | 
    
         
            -
              if (seq) {
         
     | 
| 
       501 
     | 
    
         
            -
                return seq;
         
     | 
| 
       502 
     | 
    
         
            -
              }
         
     | 
| 
       503 
     | 
    
         
            -
              throw new TypeError('Expected Array or collection object of values: ' + value);
         
     | 
| 
       504 
     | 
    
         
            -
            }
         
     | 
| 
       505 
     | 
    
         
            -
            function seqFromValue(value) {
         
     | 
| 
       506 
     | 
    
         
            -
              var seq = maybeIndexedSeqFromValue(value);
         
     | 
| 
       507 
     | 
    
         
            -
              if (seq) {
         
     | 
| 
       508 
     | 
    
         
            -
                return isEntriesIterable(value) ? seq.fromEntrySeq() : isKeysIterable(value) ? seq.toSetSeq() : seq;
         
     | 
| 
       509 
     | 
    
         
            -
              }
         
     | 
| 
       510 
     | 
    
         
            -
              if (typeof value === 'object') {
         
     | 
| 
       511 
     | 
    
         
            -
                return new ObjectSeq(value);
         
     | 
| 
       512 
     | 
    
         
            -
              }
         
     | 
| 
       513 
     | 
    
         
            -
              throw new TypeError('Expected Array or collection object of values, or keyed object: ' + value);
         
     | 
| 
       514 
     | 
    
         
            -
            }
         
     | 
| 
       515 
     | 
    
         
            -
            function maybeIndexedSeqFromValue(value) {
         
     | 
| 
       516 
     | 
    
         
            -
              return isArrayLike(value) ? new ArraySeq(value) : hasIterator(value) ? new CollectionSeq(value) : undefined;
         
     | 
| 
       517 
     | 
    
         
            -
            }
         
     | 
| 
       518 
     | 
    
         
            -
            var IS_MAP_SYMBOL = '@@__IMMUTABLE_MAP__@@';
         
     | 
| 
       519 
     | 
    
         
            -
            function isMap(maybeMap) {
         
     | 
| 
       520 
     | 
    
         
            -
              return Boolean(maybeMap && maybeMap[IS_MAP_SYMBOL]);
         
     | 
| 
       521 
     | 
    
         
            -
            }
         
     | 
| 
       522 
     | 
    
         
            -
            function isOrderedMap(maybeOrderedMap) {
         
     | 
| 
       523 
     | 
    
         
            -
              return isMap(maybeOrderedMap) && isOrdered(maybeOrderedMap);
         
     | 
| 
       524 
     | 
    
         
            -
            }
         
     | 
| 
       525 
     | 
    
         
            -
            function isValueObject(maybeValue) {
         
     | 
| 
       526 
     | 
    
         
            -
              return Boolean(maybeValue && typeof maybeValue.equals === 'function' && typeof maybeValue.hashCode === 'function');
         
     | 
| 
       527 
     | 
    
         
            -
            }
         
     | 
| 
       528 
     | 
    
         
            -
             
     | 
| 
       529 
     | 
    
         
            -
            /**
         
     | 
| 
       530 
     | 
    
         
            -
             * An extension of the "same-value" algorithm as [described for use by ES6 Map
         
     | 
| 
       531 
     | 
    
         
            -
             * and Set](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map#Key_equality)
         
     | 
| 
       532 
     | 
    
         
            -
             *
         
     | 
| 
       533 
     | 
    
         
            -
             * NaN is considered the same as NaN, however -0 and 0 are considered the same
         
     | 
| 
       534 
     | 
    
         
            -
             * value, which is different from the algorithm described by
         
     | 
| 
       535 
     | 
    
         
            -
             * [`Object.is`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is).
         
     | 
| 
       536 
     | 
    
         
            -
             *
         
     | 
| 
       537 
     | 
    
         
            -
             * This is extended further to allow Objects to describe the values they
         
     | 
| 
       538 
     | 
    
         
            -
             * represent, by way of `valueOf` or `equals` (and `hashCode`).
         
     | 
| 
       539 
     | 
    
         
            -
             *
         
     | 
| 
       540 
     | 
    
         
            -
             * Note: because of this extension, the key equality of Immutable.Map and the
         
     | 
| 
       541 
     | 
    
         
            -
             * value equality of Immutable.Set will differ from ES6 Map and Set.
         
     | 
| 
       542 
     | 
    
         
            -
             *
         
     | 
| 
       543 
     | 
    
         
            -
             * ### Defining custom values
         
     | 
| 
       544 
     | 
    
         
            -
             *
         
     | 
| 
       545 
     | 
    
         
            -
             * The easiest way to describe the value an object represents is by implementing
         
     | 
| 
       546 
     | 
    
         
            -
             * `valueOf`. For example, `Date` represents a value by returning a unix
         
     | 
| 
       547 
     | 
    
         
            -
             * timestamp for `valueOf`:
         
     | 
| 
       548 
     | 
    
         
            -
             *
         
     | 
| 
       549 
     | 
    
         
            -
             *     var date1 = new Date(1234567890000); // Fri Feb 13 2009 ...
         
     | 
| 
       550 
     | 
    
         
            -
             *     var date2 = new Date(1234567890000);
         
     | 
| 
       551 
     | 
    
         
            -
             *     date1.valueOf(); // 1234567890000
         
     | 
| 
       552 
     | 
    
         
            -
             *     assert( date1 !== date2 );
         
     | 
| 
       553 
     | 
    
         
            -
             *     assert( Immutable.is( date1, date2 ) );
         
     | 
| 
       554 
     | 
    
         
            -
             *
         
     | 
| 
       555 
     | 
    
         
            -
             * Note: overriding `valueOf` may have other implications if you use this object
         
     | 
| 
       556 
     | 
    
         
            -
             * where JavaScript expects a primitive, such as implicit string coercion.
         
     | 
| 
       557 
     | 
    
         
            -
             *
         
     | 
| 
       558 
     | 
    
         
            -
             * For more complex types, especially collections, implementing `valueOf` may
         
     | 
| 
       559 
     | 
    
         
            -
             * not be performant. An alternative is to implement `equals` and `hashCode`.
         
     | 
| 
       560 
     | 
    
         
            -
             *
         
     | 
| 
       561 
     | 
    
         
            -
             * `equals` takes another object, presumably of similar type, and returns true
         
     | 
| 
       562 
     | 
    
         
            -
             * if it is equal. Equality is symmetrical, so the same result should be
         
     | 
| 
       563 
     | 
    
         
            -
             * returned if this and the argument are flipped.
         
     | 
| 
       564 
     | 
    
         
            -
             *
         
     | 
| 
       565 
     | 
    
         
            -
             *     assert( a.equals(b) === b.equals(a) );
         
     | 
| 
       566 
     | 
    
         
            -
             *
         
     | 
| 
       567 
     | 
    
         
            -
             * `hashCode` returns a 32bit integer number representing the object which will
         
     | 
| 
       568 
     | 
    
         
            -
             * be used to determine how to store the value object in a Map or Set. You must
         
     | 
| 
       569 
     | 
    
         
            -
             * provide both or neither methods, one must not exist without the other.
         
     | 
| 
       570 
     | 
    
         
            -
             *
         
     | 
| 
       571 
     | 
    
         
            -
             * Also, an important relationship between these methods must be upheld: if two
         
     | 
| 
       572 
     | 
    
         
            -
             * values are equal, they *must* return the same hashCode. If the values are not
         
     | 
| 
       573 
     | 
    
         
            -
             * equal, they might have the same hashCode; this is called a hash collision,
         
     | 
| 
       574 
     | 
    
         
            -
             * and while undesirable for performance reasons, it is acceptable.
         
     | 
| 
       575 
     | 
    
         
            -
             *
         
     | 
| 
       576 
     | 
    
         
            -
             *     if (a.equals(b)) {
         
     | 
| 
       577 
     | 
    
         
            -
             *       assert( a.hashCode() === b.hashCode() );
         
     | 
| 
       578 
     | 
    
         
            -
             *     }
         
     | 
| 
       579 
     | 
    
         
            -
             *
         
     | 
| 
       580 
     | 
    
         
            -
             * All Immutable collections are Value Objects: they implement `equals()`
         
     | 
| 
       581 
     | 
    
         
            -
             * and `hashCode()`.
         
     | 
| 
       582 
     | 
    
         
            -
             */
         
     | 
| 
       583 
     | 
    
         
            -
            function is(valueA, valueB) {
         
     | 
| 
       584 
     | 
    
         
            -
              if (valueA === valueB || valueA !== valueA && valueB !== valueB) {
         
     | 
| 
       585 
     | 
    
         
            -
                return true;
         
     | 
| 
       586 
     | 
    
         
            -
              }
         
     | 
| 
       587 
     | 
    
         
            -
              if (!valueA || !valueB) {
         
     | 
| 
       588 
     | 
    
         
            -
                return false;
         
     | 
| 
       589 
     | 
    
         
            -
              }
         
     | 
| 
       590 
     | 
    
         
            -
              if (typeof valueA.valueOf === 'function' && typeof valueB.valueOf === 'function') {
         
     | 
| 
       591 
     | 
    
         
            -
                valueA = valueA.valueOf();
         
     | 
| 
       592 
     | 
    
         
            -
                valueB = valueB.valueOf();
         
     | 
| 
       593 
     | 
    
         
            -
                if (valueA === valueB || valueA !== valueA && valueB !== valueB) {
         
     | 
| 
       594 
     | 
    
         
            -
                  return true;
         
     | 
| 
       595 
     | 
    
         
            -
                }
         
     | 
| 
       596 
     | 
    
         
            -
                if (!valueA || !valueB) {
         
     | 
| 
       597 
     | 
    
         
            -
                  return false;
         
     | 
| 
       598 
     | 
    
         
            -
                }
         
     | 
| 
       599 
     | 
    
         
            -
              }
         
     | 
| 
       600 
     | 
    
         
            -
              return !!(isValueObject(valueA) && isValueObject(valueB) && valueA.equals(valueB));
         
     | 
| 
       601 
     | 
    
         
            -
            }
         
     | 
| 
       602 
     | 
    
         
            -
            var imul = typeof Math.imul === 'function' && Math.imul(0xffffffff, 2) === -2 ? Math.imul : function imul(a, b) {
         
     | 
| 
       603 
     | 
    
         
            -
              a |= 0; // int
         
     | 
| 
       604 
     | 
    
         
            -
              b |= 0; // int
         
     | 
| 
       605 
     | 
    
         
            -
              var c = a & 0xffff;
         
     | 
| 
       606 
     | 
    
         
            -
              var d = b & 0xffff;
         
     | 
| 
       607 
     | 
    
         
            -
              // Shift by 0 fixes the sign on the high part.
         
     | 
| 
       608 
     | 
    
         
            -
              return c * d + ((a >>> 16) * d + c * (b >>> 16) << 16 >>> 0) | 0; // int
         
     | 
| 
       609 
     | 
    
         
            -
            };
         
     | 
| 
       610 
     | 
    
         
            -
             
     | 
| 
       611 
     | 
    
         
            -
            // v8 has an optimization for storing 31-bit signed numbers.
         
     | 
| 
       612 
     | 
    
         
            -
            // Values which have either 00 or 11 as the high order bits qualify.
         
     | 
| 
       613 
     | 
    
         
            -
            // This function drops the highest order bit in a signed number, maintaining
         
     | 
| 
       614 
     | 
    
         
            -
            // the sign bit.
         
     | 
| 
       615 
     | 
    
         
            -
            function smi(i32) {
         
     | 
| 
       616 
     | 
    
         
            -
              return i32 >>> 1 & 0x40000000 | i32 & 0xbfffffff;
         
     | 
| 
       617 
     | 
    
         
            -
            }
         
     | 
| 
       618 
     | 
    
         
            -
            var defaultValueOf = Object.prototype.valueOf;
         
     | 
| 
       619 
     | 
    
         
            -
            function hash(o) {
         
     | 
| 
       620 
     | 
    
         
            -
              if (o == null) {
         
     | 
| 
       621 
     | 
    
         
            -
                return hashNullish(o);
         
     | 
| 
       622 
     | 
    
         
            -
              }
         
     | 
| 
       623 
     | 
    
         
            -
              if (typeof o.hashCode === 'function') {
         
     | 
| 
       624 
     | 
    
         
            -
                // Drop any high bits from accidentally long hash codes.
         
     | 
| 
       625 
     | 
    
         
            -
                return smi(o.hashCode(o));
         
     | 
| 
       626 
     | 
    
         
            -
              }
         
     | 
| 
       627 
     | 
    
         
            -
              var v = valueOf(o);
         
     | 
| 
       628 
     | 
    
         
            -
              if (v == null) {
         
     | 
| 
       629 
     | 
    
         
            -
                return hashNullish(v);
         
     | 
| 
       630 
     | 
    
         
            -
              }
         
     | 
| 
       631 
     | 
    
         
            -
              switch (typeof v) {
         
     | 
| 
       632 
     | 
    
         
            -
                case 'boolean':
         
     | 
| 
       633 
     | 
    
         
            -
                  // The hash values for built-in constants are a 1 value for each 5-byte
         
     | 
| 
       634 
     | 
    
         
            -
                  // shift region expect for the first, which encodes the value. This
         
     | 
| 
       635 
     | 
    
         
            -
                  // reduces the odds of a hash collision for these common values.
         
     | 
| 
       636 
     | 
    
         
            -
                  return v ? 0x42108421 : 0x42108420;
         
     | 
| 
       637 
     | 
    
         
            -
                case 'number':
         
     | 
| 
       638 
     | 
    
         
            -
                  return hashNumber(v);
         
     | 
| 
       639 
     | 
    
         
            -
                case 'string':
         
     | 
| 
       640 
     | 
    
         
            -
                  return v.length > STRING_HASH_CACHE_MIN_STRLEN ? cachedHashString(v) : hashString(v);
         
     | 
| 
       641 
     | 
    
         
            -
                case 'object':
         
     | 
| 
       642 
     | 
    
         
            -
                case 'function':
         
     | 
| 
       643 
     | 
    
         
            -
                  return hashJSObj(v);
         
     | 
| 
       644 
     | 
    
         
            -
                case 'symbol':
         
     | 
| 
       645 
     | 
    
         
            -
                  return hashSymbol(v);
         
     | 
| 
       646 
     | 
    
         
            -
                default:
         
     | 
| 
       647 
     | 
    
         
            -
                  if (typeof v.toString === 'function') {
         
     | 
| 
       648 
     | 
    
         
            -
                    return hashString(v.toString());
         
     | 
| 
       649 
     | 
    
         
            -
                  }
         
     | 
| 
       650 
     | 
    
         
            -
                  throw new Error('Value type ' + typeof v + ' cannot be hashed.');
         
     | 
| 
       651 
     | 
    
         
            -
              }
         
     | 
| 
       652 
     | 
    
         
            -
            }
         
     | 
| 
       653 
     | 
    
         
            -
            function hashNullish(nullish) {
         
     | 
| 
       654 
     | 
    
         
            -
              return nullish === null ? 0x42108422 : /* undefined */0x42108423;
         
     | 
| 
       655 
     | 
    
         
            -
            }
         
     | 
| 
       656 
     | 
    
         
            -
             
     | 
| 
       657 
     | 
    
         
            -
            // Compress arbitrarily large numbers into smi hashes.
         
     | 
| 
       658 
     | 
    
         
            -
            function hashNumber(n) {
         
     | 
| 
       659 
     | 
    
         
            -
              if (n !== n || n === Infinity) {
         
     | 
| 
       660 
     | 
    
         
            -
                return 0;
         
     | 
| 
       661 
     | 
    
         
            -
              }
         
     | 
| 
       662 
     | 
    
         
            -
              var hash = n | 0;
         
     | 
| 
       663 
     | 
    
         
            -
              if (hash !== n) {
         
     | 
| 
       664 
     | 
    
         
            -
                hash ^= n * 0xffffffff;
         
     | 
| 
       665 
     | 
    
         
            -
              }
         
     | 
| 
       666 
     | 
    
         
            -
              while (n > 0xffffffff) {
         
     | 
| 
       667 
     | 
    
         
            -
                n /= 0xffffffff;
         
     | 
| 
       668 
     | 
    
         
            -
                hash ^= n;
         
     | 
| 
       669 
     | 
    
         
            -
              }
         
     | 
| 
       670 
     | 
    
         
            -
              return smi(hash);
         
     | 
| 
       671 
     | 
    
         
            -
            }
         
     | 
| 
       672 
     | 
    
         
            -
            function cachedHashString(string) {
         
     | 
| 
       673 
     | 
    
         
            -
              var hashed = stringHashCache[string];
         
     | 
| 
       674 
     | 
    
         
            -
              if (hashed === undefined) {
         
     | 
| 
       675 
     | 
    
         
            -
                hashed = hashString(string);
         
     | 
| 
       676 
     | 
    
         
            -
                if (STRING_HASH_CACHE_SIZE === STRING_HASH_CACHE_MAX_SIZE) {
         
     | 
| 
       677 
     | 
    
         
            -
                  STRING_HASH_CACHE_SIZE = 0;
         
     | 
| 
       678 
     | 
    
         
            -
                  stringHashCache = {};
         
     | 
| 
       679 
     | 
    
         
            -
                }
         
     | 
| 
       680 
     | 
    
         
            -
                STRING_HASH_CACHE_SIZE++;
         
     | 
| 
       681 
     | 
    
         
            -
                stringHashCache[string] = hashed;
         
     | 
| 
       682 
     | 
    
         
            -
              }
         
     | 
| 
       683 
     | 
    
         
            -
              return hashed;
         
     | 
| 
       684 
     | 
    
         
            -
            }
         
     | 
| 
       685 
     | 
    
         
            -
             
     | 
| 
       686 
     | 
    
         
            -
            // http://jsperf.com/hashing-strings
         
     | 
| 
       687 
     | 
    
         
            -
            function hashString(string) {
         
     | 
| 
       688 
     | 
    
         
            -
              // This is the hash from JVM
         
     | 
| 
       689 
     | 
    
         
            -
              // The hash code for a string is computed as
         
     | 
| 
       690 
     | 
    
         
            -
              // s[0] * 31 ^ (n - 1) + s[1] * 31 ^ (n - 2) + ... + s[n - 1],
         
     | 
| 
       691 
     | 
    
         
            -
              // where s[i] is the ith character of the string and n is the length of
         
     | 
| 
       692 
     | 
    
         
            -
              // the string. We "mod" the result to make it between 0 (inclusive) and 2^31
         
     | 
| 
       693 
     | 
    
         
            -
              // (exclusive) by dropping high bits.
         
     | 
| 
       694 
     | 
    
         
            -
              var hashed = 0;
         
     | 
| 
       695 
     | 
    
         
            -
              for (var ii = 0; ii < string.length; ii++) {
         
     | 
| 
       696 
     | 
    
         
            -
                hashed = 31 * hashed + string.charCodeAt(ii) | 0;
         
     | 
| 
       697 
     | 
    
         
            -
              }
         
     | 
| 
       698 
     | 
    
         
            -
              return smi(hashed);
         
     | 
| 
       699 
     | 
    
         
            -
            }
         
     | 
| 
       700 
     | 
    
         
            -
            function hashSymbol(sym) {
         
     | 
| 
       701 
     | 
    
         
            -
              var hashed = symbolMap[sym];
         
     | 
| 
       702 
     | 
    
         
            -
              if (hashed !== undefined) {
         
     | 
| 
       703 
     | 
    
         
            -
                return hashed;
         
     | 
| 
       704 
     | 
    
         
            -
              }
         
     | 
| 
       705 
     | 
    
         
            -
              hashed = nextHash();
         
     | 
| 
       706 
     | 
    
         
            -
              symbolMap[sym] = hashed;
         
     | 
| 
       707 
     | 
    
         
            -
              return hashed;
         
     | 
| 
       708 
     | 
    
         
            -
            }
         
     | 
| 
       709 
     | 
    
         
            -
            function hashJSObj(obj) {
         
     | 
| 
       710 
     | 
    
         
            -
              var hashed;
         
     | 
| 
       711 
     | 
    
         
            -
              if (usingWeakMap) {
         
     | 
| 
       712 
     | 
    
         
            -
                hashed = weakMap.get(obj);
         
     | 
| 
       713 
     | 
    
         
            -
                if (hashed !== undefined) {
         
     | 
| 
       714 
     | 
    
         
            -
                  return hashed;
         
     | 
| 
       715 
     | 
    
         
            -
                }
         
     | 
| 
       716 
     | 
    
         
            -
              }
         
     | 
| 
       717 
     | 
    
         
            -
              hashed = obj[UID_HASH_KEY];
         
     | 
| 
       718 
     | 
    
         
            -
              if (hashed !== undefined) {
         
     | 
| 
       719 
     | 
    
         
            -
                return hashed;
         
     | 
| 
       720 
     | 
    
         
            -
              }
         
     | 
| 
       721 
     | 
    
         
            -
              if (!canDefineProperty) {
         
     | 
| 
       722 
     | 
    
         
            -
                hashed = obj.propertyIsEnumerable && obj.propertyIsEnumerable[UID_HASH_KEY];
         
     | 
| 
       723 
     | 
    
         
            -
                if (hashed !== undefined) {
         
     | 
| 
       724 
     | 
    
         
            -
                  return hashed;
         
     | 
| 
       725 
     | 
    
         
            -
                }
         
     | 
| 
       726 
     | 
    
         
            -
                hashed = getIENodeHash(obj);
         
     | 
| 
       727 
     | 
    
         
            -
                if (hashed !== undefined) {
         
     | 
| 
       728 
     | 
    
         
            -
                  return hashed;
         
     | 
| 
       729 
     | 
    
         
            -
                }
         
     | 
| 
       730 
     | 
    
         
            -
              }
         
     | 
| 
       731 
     | 
    
         
            -
              hashed = nextHash();
         
     | 
| 
       732 
     | 
    
         
            -
              if (usingWeakMap) {
         
     | 
| 
       733 
     | 
    
         
            -
                weakMap.set(obj, hashed);
         
     | 
| 
       734 
     | 
    
         
            -
              } else if (isExtensible !== undefined && isExtensible(obj) === false) {
         
     | 
| 
       735 
     | 
    
         
            -
                throw new Error('Non-extensible objects are not allowed as keys.');
         
     | 
| 
       736 
     | 
    
         
            -
              } else if (canDefineProperty) {
         
     | 
| 
       737 
     | 
    
         
            -
                Object.defineProperty(obj, UID_HASH_KEY, {
         
     | 
| 
       738 
     | 
    
         
            -
                  enumerable: false,
         
     | 
| 
       739 
     | 
    
         
            -
                  configurable: false,
         
     | 
| 
       740 
     | 
    
         
            -
                  writable: false,
         
     | 
| 
       741 
     | 
    
         
            -
                  value: hashed
         
     | 
| 
       742 
     | 
    
         
            -
                });
         
     | 
| 
       743 
     | 
    
         
            -
              } else if (obj.propertyIsEnumerable !== undefined && obj.propertyIsEnumerable === obj.constructor.prototype.propertyIsEnumerable) {
         
     | 
| 
       744 
     | 
    
         
            -
                // Since we can't define a non-enumerable property on the object
         
     | 
| 
       745 
     | 
    
         
            -
                // we'll hijack one of the less-used non-enumerable properties to
         
     | 
| 
       746 
     | 
    
         
            -
                // save our hash on it. Since this is a function it will not show up in
         
     | 
| 
       747 
     | 
    
         
            -
                // `JSON.stringify` which is what we want.
         
     | 
| 
       748 
     | 
    
         
            -
                obj.propertyIsEnumerable = function () {
         
     | 
| 
       749 
     | 
    
         
            -
                  return this.constructor.prototype.propertyIsEnumerable.apply(this, arguments);
         
     | 
| 
       750 
     | 
    
         
            -
                };
         
     | 
| 
       751 
     | 
    
         
            -
                obj.propertyIsEnumerable[UID_HASH_KEY] = hashed;
         
     | 
| 
       752 
     | 
    
         
            -
              } else if (obj.nodeType !== undefined) {
         
     | 
| 
       753 
     | 
    
         
            -
                // At this point we couldn't get the IE `uniqueID` to use as a hash
         
     | 
| 
       754 
     | 
    
         
            -
                // and we couldn't use a non-enumerable property to exploit the
         
     | 
| 
       755 
     | 
    
         
            -
                // dontEnum bug so we simply add the `UID_HASH_KEY` on the node
         
     | 
| 
       756 
     | 
    
         
            -
                // itself.
         
     | 
| 
       757 
     | 
    
         
            -
                obj[UID_HASH_KEY] = hashed;
         
     | 
| 
       758 
     | 
    
         
            -
              } else {
         
     | 
| 
       759 
     | 
    
         
            -
                throw new Error('Unable to set a non-enumerable property on object.');
         
     | 
| 
       760 
     | 
    
         
            -
              }
         
     | 
| 
       761 
     | 
    
         
            -
              return hashed;
         
     | 
| 
       762 
     | 
    
         
            -
            }
         
     | 
| 
       763 
     | 
    
         
            -
             
     | 
| 
       764 
     | 
    
         
            -
            // Get references to ES5 object methods.
         
     | 
| 
       765 
     | 
    
         
            -
            var isExtensible = Object.isExtensible;
         
     | 
| 
       766 
     | 
    
         
            -
             
     | 
| 
       767 
     | 
    
         
            -
            // True if Object.defineProperty works as expected. IE8 fails this test.
         
     | 
| 
       768 
     | 
    
         
            -
            var canDefineProperty = function () {
         
     | 
| 
       769 
     | 
    
         
            -
              try {
         
     | 
| 
       770 
     | 
    
         
            -
                Object.defineProperty({}, '@', {});
         
     | 
| 
       771 
     | 
    
         
            -
                return true;
         
     | 
| 
       772 
     | 
    
         
            -
              } catch (e) {
         
     | 
| 
       773 
     | 
    
         
            -
                return false;
         
     | 
| 
       774 
     | 
    
         
            -
              }
         
     | 
| 
       775 
     | 
    
         
            -
            }();
         
     | 
| 
       776 
     | 
    
         
            -
             
     | 
| 
       777 
     | 
    
         
            -
            // IE has a `uniqueID` property on DOM nodes. We can construct the hash from it
         
     | 
| 
       778 
     | 
    
         
            -
            // and avoid memory leaks from the IE cloneNode bug.
         
     | 
| 
       779 
     | 
    
         
            -
            function getIENodeHash(node) {
         
     | 
| 
       780 
     | 
    
         
            -
              if (node && node.nodeType > 0) {
         
     | 
| 
       781 
     | 
    
         
            -
                switch (node.nodeType) {
         
     | 
| 
       782 
     | 
    
         
            -
                  case 1:
         
     | 
| 
       783 
     | 
    
         
            -
                    // Element
         
     | 
| 
       784 
     | 
    
         
            -
                    return node.uniqueID;
         
     | 
| 
       785 
     | 
    
         
            -
                  case 9:
         
     | 
| 
       786 
     | 
    
         
            -
                    // Document
         
     | 
| 
       787 
     | 
    
         
            -
                    return node.documentElement && node.documentElement.uniqueID;
         
     | 
| 
       788 
     | 
    
         
            -
                }
         
     | 
| 
       789 
     | 
    
         
            -
              }
         
     | 
| 
       790 
     | 
    
         
            -
            }
         
     | 
| 
       791 
     | 
    
         
            -
            function valueOf(obj) {
         
     | 
| 
       792 
     | 
    
         
            -
              return obj.valueOf !== defaultValueOf && typeof obj.valueOf === 'function' ? obj.valueOf(obj) : obj;
         
     | 
| 
       793 
     | 
    
         
            -
            }
         
     | 
| 
       794 
     | 
    
         
            -
            function nextHash() {
         
     | 
| 
       795 
     | 
    
         
            -
              var nextHash = ++_objHashUID;
         
     | 
| 
       796 
     | 
    
         
            -
              if (_objHashUID & 0x40000000) {
         
     | 
| 
       797 
     | 
    
         
            -
                _objHashUID = 0;
         
     | 
| 
       798 
     | 
    
         
            -
              }
         
     | 
| 
       799 
     | 
    
         
            -
              return nextHash;
         
     | 
| 
       800 
     | 
    
         
            -
            }
         
     | 
| 
       801 
     | 
    
         
            -
             
     | 
| 
       802 
     | 
    
         
            -
            // If possible, use a WeakMap.
         
     | 
| 
       803 
     | 
    
         
            -
            var usingWeakMap = typeof WeakMap === 'function';
         
     | 
| 
       804 
     | 
    
         
            -
            var weakMap;
         
     | 
| 
       805 
     | 
    
         
            -
            if (usingWeakMap) {
         
     | 
| 
       806 
     | 
    
         
            -
              weakMap = new WeakMap();
         
     | 
| 
       807 
     | 
    
         
            -
            }
         
     | 
| 
       808 
     | 
    
         
            -
            var symbolMap = Object.create(null);
         
     | 
| 
       809 
     | 
    
         
            -
            var _objHashUID = 0;
         
     | 
| 
       810 
     | 
    
         
            -
            var UID_HASH_KEY = '__immutablehash__';
         
     | 
| 
       811 
     | 
    
         
            -
            if (typeof Symbol === 'function') {
         
     | 
| 
       812 
     | 
    
         
            -
              UID_HASH_KEY = Symbol(UID_HASH_KEY);
         
     | 
| 
       813 
     | 
    
         
            -
            }
         
     | 
| 
       814 
     | 
    
         
            -
            var STRING_HASH_CACHE_MIN_STRLEN = 16;
         
     | 
| 
       815 
     | 
    
         
            -
            var STRING_HASH_CACHE_MAX_SIZE = 255;
         
     | 
| 
       816 
     | 
    
         
            -
            var STRING_HASH_CACHE_SIZE = 0;
         
     | 
| 
       817 
     | 
    
         
            -
            var stringHashCache = {};
         
     | 
| 
       818 
     | 
    
         
            -
            var ToKeyedSequence = /*@__PURE__*/function (KeyedSeq) {
         
     | 
| 
       819 
     | 
    
         
            -
              function ToKeyedSequence(indexed, useKeys) {
         
     | 
| 
       820 
     | 
    
         
            -
                this._iter = indexed;
         
     | 
| 
       821 
     | 
    
         
            -
                this._useKeys = useKeys;
         
     | 
| 
       822 
     | 
    
         
            -
                this.size = indexed.size;
         
     | 
| 
       823 
     | 
    
         
            -
              }
         
     | 
| 
       824 
     | 
    
         
            -
              if (KeyedSeq) ToKeyedSequence.__proto__ = KeyedSeq;
         
     | 
| 
       825 
     | 
    
         
            -
              ToKeyedSequence.prototype = Object.create(KeyedSeq && KeyedSeq.prototype);
         
     | 
| 
       826 
     | 
    
         
            -
              ToKeyedSequence.prototype.constructor = ToKeyedSequence;
         
     | 
| 
       827 
     | 
    
         
            -
              ToKeyedSequence.prototype.get = function get(key, notSetValue) {
         
     | 
| 
       828 
     | 
    
         
            -
                return this._iter.get(key, notSetValue);
         
     | 
| 
       829 
     | 
    
         
            -
              };
         
     | 
| 
       830 
     | 
    
         
            -
              ToKeyedSequence.prototype.has = function has(key) {
         
     | 
| 
       831 
     | 
    
         
            -
                return this._iter.has(key);
         
     | 
| 
       832 
     | 
    
         
            -
              };
         
     | 
| 
       833 
     | 
    
         
            -
              ToKeyedSequence.prototype.valueSeq = function valueSeq() {
         
     | 
| 
       834 
     | 
    
         
            -
                return this._iter.valueSeq();
         
     | 
| 
       835 
     | 
    
         
            -
              };
         
     | 
| 
       836 
     | 
    
         
            -
              ToKeyedSequence.prototype.reverse = function reverse() {
         
     | 
| 
       837 
     | 
    
         
            -
                var this$1$1 = this;
         
     | 
| 
       838 
     | 
    
         
            -
                var reversedSequence = reverseFactory(this, true);
         
     | 
| 
       839 
     | 
    
         
            -
                if (!this._useKeys) {
         
     | 
| 
       840 
     | 
    
         
            -
                  reversedSequence.valueSeq = function () {
         
     | 
| 
       841 
     | 
    
         
            -
                    return this$1$1._iter.toSeq().reverse();
         
     | 
| 
       842 
     | 
    
         
            -
                  };
         
     | 
| 
       843 
     | 
    
         
            -
                }
         
     | 
| 
       844 
     | 
    
         
            -
                return reversedSequence;
         
     | 
| 
       845 
     | 
    
         
            -
              };
         
     | 
| 
       846 
     | 
    
         
            -
              ToKeyedSequence.prototype.map = function map(mapper, context) {
         
     | 
| 
       847 
     | 
    
         
            -
                var this$1$1 = this;
         
     | 
| 
       848 
     | 
    
         
            -
                var mappedSequence = mapFactory(this, mapper, context);
         
     | 
| 
       849 
     | 
    
         
            -
                if (!this._useKeys) {
         
     | 
| 
       850 
     | 
    
         
            -
                  mappedSequence.valueSeq = function () {
         
     | 
| 
       851 
     | 
    
         
            -
                    return this$1$1._iter.toSeq().map(mapper, context);
         
     | 
| 
       852 
     | 
    
         
            -
                  };
         
     | 
| 
       853 
     | 
    
         
            -
                }
         
     | 
| 
       854 
     | 
    
         
            -
                return mappedSequence;
         
     | 
| 
       855 
     | 
    
         
            -
              };
         
     | 
| 
       856 
     | 
    
         
            -
              ToKeyedSequence.prototype.__iterate = function __iterate(fn, reverse) {
         
     | 
| 
       857 
     | 
    
         
            -
                var this$1$1 = this;
         
     | 
| 
       858 
     | 
    
         
            -
                return this._iter.__iterate(function (v, k) {
         
     | 
| 
       859 
     | 
    
         
            -
                  return fn(v, k, this$1$1);
         
     | 
| 
       860 
     | 
    
         
            -
                }, reverse);
         
     | 
| 
       861 
     | 
    
         
            -
              };
         
     | 
| 
       862 
     | 
    
         
            -
              ToKeyedSequence.prototype.__iterator = function __iterator(type, reverse) {
         
     | 
| 
       863 
     | 
    
         
            -
                return this._iter.__iterator(type, reverse);
         
     | 
| 
       864 
     | 
    
         
            -
              };
         
     | 
| 
       865 
     | 
    
         
            -
              return ToKeyedSequence;
         
     | 
| 
       866 
     | 
    
         
            -
            }(KeyedSeq);
         
     | 
| 
       867 
     | 
    
         
            -
            ToKeyedSequence.prototype[IS_ORDERED_SYMBOL] = true;
         
     | 
| 
       868 
     | 
    
         
            -
            var ToIndexedSequence = /*@__PURE__*/function (IndexedSeq) {
         
     | 
| 
       869 
     | 
    
         
            -
              function ToIndexedSequence(iter) {
         
     | 
| 
       870 
     | 
    
         
            -
                this._iter = iter;
         
     | 
| 
       871 
     | 
    
         
            -
                this.size = iter.size;
         
     | 
| 
       872 
     | 
    
         
            -
              }
         
     | 
| 
       873 
     | 
    
         
            -
              if (IndexedSeq) ToIndexedSequence.__proto__ = IndexedSeq;
         
     | 
| 
       874 
     | 
    
         
            -
              ToIndexedSequence.prototype = Object.create(IndexedSeq && IndexedSeq.prototype);
         
     | 
| 
       875 
     | 
    
         
            -
              ToIndexedSequence.prototype.constructor = ToIndexedSequence;
         
     | 
| 
       876 
     | 
    
         
            -
              ToIndexedSequence.prototype.includes = function includes(value) {
         
     | 
| 
       877 
     | 
    
         
            -
                return this._iter.includes(value);
         
     | 
| 
       878 
     | 
    
         
            -
              };
         
     | 
| 
       879 
     | 
    
         
            -
              ToIndexedSequence.prototype.__iterate = function __iterate(fn, reverse) {
         
     | 
| 
       880 
     | 
    
         
            -
                var this$1$1 = this;
         
     | 
| 
       881 
     | 
    
         
            -
                var i = 0;
         
     | 
| 
       882 
     | 
    
         
            -
                reverse && ensureSize(this);
         
     | 
| 
       883 
     | 
    
         
            -
                return this._iter.__iterate(function (v) {
         
     | 
| 
       884 
     | 
    
         
            -
                  return fn(v, reverse ? this$1$1.size - ++i : i++, this$1$1);
         
     | 
| 
       885 
     | 
    
         
            -
                }, reverse);
         
     | 
| 
       886 
     | 
    
         
            -
              };
         
     | 
| 
       887 
     | 
    
         
            -
              ToIndexedSequence.prototype.__iterator = function __iterator(type, reverse) {
         
     | 
| 
       888 
     | 
    
         
            -
                var this$1$1 = this;
         
     | 
| 
       889 
     | 
    
         
            -
                var iterator = this._iter.__iterator(ITERATE_VALUES, reverse);
         
     | 
| 
       890 
     | 
    
         
            -
                var i = 0;
         
     | 
| 
       891 
     | 
    
         
            -
                reverse && ensureSize(this);
         
     | 
| 
       892 
     | 
    
         
            -
                return new Iterator(function () {
         
     | 
| 
       893 
     | 
    
         
            -
                  var step = iterator.next();
         
     | 
| 
       894 
     | 
    
         
            -
                  return step.done ? step : iteratorValue(type, reverse ? this$1$1.size - ++i : i++, step.value, step);
         
     | 
| 
       895 
     | 
    
         
            -
                });
         
     | 
| 
       896 
     | 
    
         
            -
              };
         
     | 
| 
       897 
     | 
    
         
            -
              return ToIndexedSequence;
         
     | 
| 
       898 
     | 
    
         
            -
            }(IndexedSeq);
         
     | 
| 
       899 
     | 
    
         
            -
            var ToSetSequence = /*@__PURE__*/function (SetSeq) {
         
     | 
| 
       900 
     | 
    
         
            -
              function ToSetSequence(iter) {
         
     | 
| 
       901 
     | 
    
         
            -
                this._iter = iter;
         
     | 
| 
       902 
     | 
    
         
            -
                this.size = iter.size;
         
     | 
| 
       903 
     | 
    
         
            -
              }
         
     | 
| 
       904 
     | 
    
         
            -
              if (SetSeq) ToSetSequence.__proto__ = SetSeq;
         
     | 
| 
       905 
     | 
    
         
            -
              ToSetSequence.prototype = Object.create(SetSeq && SetSeq.prototype);
         
     | 
| 
       906 
     | 
    
         
            -
              ToSetSequence.prototype.constructor = ToSetSequence;
         
     | 
| 
       907 
     | 
    
         
            -
              ToSetSequence.prototype.has = function has(key) {
         
     | 
| 
       908 
     | 
    
         
            -
                return this._iter.includes(key);
         
     | 
| 
       909 
     | 
    
         
            -
              };
         
     | 
| 
       910 
     | 
    
         
            -
              ToSetSequence.prototype.__iterate = function __iterate(fn, reverse) {
         
     | 
| 
       911 
     | 
    
         
            -
                var this$1$1 = this;
         
     | 
| 
       912 
     | 
    
         
            -
                return this._iter.__iterate(function (v) {
         
     | 
| 
       913 
     | 
    
         
            -
                  return fn(v, v, this$1$1);
         
     | 
| 
       914 
     | 
    
         
            -
                }, reverse);
         
     | 
| 
       915 
     | 
    
         
            -
              };
         
     | 
| 
       916 
     | 
    
         
            -
              ToSetSequence.prototype.__iterator = function __iterator(type, reverse) {
         
     | 
| 
       917 
     | 
    
         
            -
                var iterator = this._iter.__iterator(ITERATE_VALUES, reverse);
         
     | 
| 
       918 
     | 
    
         
            -
                return new Iterator(function () {
         
     | 
| 
       919 
     | 
    
         
            -
                  var step = iterator.next();
         
     | 
| 
       920 
     | 
    
         
            -
                  return step.done ? step : iteratorValue(type, step.value, step.value, step);
         
     | 
| 
       921 
     | 
    
         
            -
                });
         
     | 
| 
       922 
     | 
    
         
            -
              };
         
     | 
| 
       923 
     | 
    
         
            -
              return ToSetSequence;
         
     | 
| 
       924 
     | 
    
         
            -
            }(SetSeq);
         
     | 
| 
       925 
     | 
    
         
            -
            var FromEntriesSequence = /*@__PURE__*/function (KeyedSeq) {
         
     | 
| 
       926 
     | 
    
         
            -
              function FromEntriesSequence(entries) {
         
     | 
| 
       927 
     | 
    
         
            -
                this._iter = entries;
         
     | 
| 
       928 
     | 
    
         
            -
                this.size = entries.size;
         
     | 
| 
       929 
     | 
    
         
            -
              }
         
     | 
| 
       930 
     | 
    
         
            -
              if (KeyedSeq) FromEntriesSequence.__proto__ = KeyedSeq;
         
     | 
| 
       931 
     | 
    
         
            -
              FromEntriesSequence.prototype = Object.create(KeyedSeq && KeyedSeq.prototype);
         
     | 
| 
       932 
     | 
    
         
            -
              FromEntriesSequence.prototype.constructor = FromEntriesSequence;
         
     | 
| 
       933 
     | 
    
         
            -
              FromEntriesSequence.prototype.entrySeq = function entrySeq() {
         
     | 
| 
       934 
     | 
    
         
            -
                return this._iter.toSeq();
         
     | 
| 
       935 
     | 
    
         
            -
              };
         
     | 
| 
       936 
     | 
    
         
            -
              FromEntriesSequence.prototype.__iterate = function __iterate(fn, reverse) {
         
     | 
| 
       937 
     | 
    
         
            -
                var this$1$1 = this;
         
     | 
| 
       938 
     | 
    
         
            -
                return this._iter.__iterate(function (entry) {
         
     | 
| 
       939 
     | 
    
         
            -
                  // Check if entry exists first so array access doesn't throw for holes
         
     | 
| 
       940 
     | 
    
         
            -
                  // in the parent iteration.
         
     | 
| 
       941 
     | 
    
         
            -
                  if (entry) {
         
     | 
| 
       942 
     | 
    
         
            -
                    validateEntry(entry);
         
     | 
| 
       943 
     | 
    
         
            -
                    var indexedCollection = isCollection(entry);
         
     | 
| 
       944 
     | 
    
         
            -
                    return fn(indexedCollection ? entry.get(1) : entry[1], indexedCollection ? entry.get(0) : entry[0], this$1$1);
         
     | 
| 
       945 
     | 
    
         
            -
                  }
         
     | 
| 
       946 
     | 
    
         
            -
                }, reverse);
         
     | 
| 
       947 
     | 
    
         
            -
              };
         
     | 
| 
       948 
     | 
    
         
            -
              FromEntriesSequence.prototype.__iterator = function __iterator(type, reverse) {
         
     | 
| 
       949 
     | 
    
         
            -
                var iterator = this._iter.__iterator(ITERATE_VALUES, reverse);
         
     | 
| 
       950 
     | 
    
         
            -
                return new Iterator(function () {
         
     | 
| 
       951 
     | 
    
         
            -
                  while (true) {
         
     | 
| 
       952 
     | 
    
         
            -
                    var step = iterator.next();
         
     | 
| 
       953 
     | 
    
         
            -
                    if (step.done) {
         
     | 
| 
       954 
     | 
    
         
            -
                      return step;
         
     | 
| 
       955 
     | 
    
         
            -
                    }
         
     | 
| 
       956 
     | 
    
         
            -
                    var entry = step.value;
         
     | 
| 
       957 
     | 
    
         
            -
                    // Check if entry exists first so array access doesn't throw for holes
         
     | 
| 
       958 
     | 
    
         
            -
                    // in the parent iteration.
         
     | 
| 
       959 
     | 
    
         
            -
                    if (entry) {
         
     | 
| 
       960 
     | 
    
         
            -
                      validateEntry(entry);
         
     | 
| 
       961 
     | 
    
         
            -
                      var indexedCollection = isCollection(entry);
         
     | 
| 
       962 
     | 
    
         
            -
                      return iteratorValue(type, indexedCollection ? entry.get(0) : entry[0], indexedCollection ? entry.get(1) : entry[1], step);
         
     | 
| 
       963 
     | 
    
         
            -
                    }
         
     | 
| 
       964 
     | 
    
         
            -
                  }
         
     | 
| 
       965 
     | 
    
         
            -
                });
         
     | 
| 
       966 
     | 
    
         
            -
              };
         
     | 
| 
       967 
     | 
    
         
            -
              return FromEntriesSequence;
         
     | 
| 
       968 
     | 
    
         
            -
            }(KeyedSeq);
         
     | 
| 
       969 
     | 
    
         
            -
            ToIndexedSequence.prototype.cacheResult = ToKeyedSequence.prototype.cacheResult = ToSetSequence.prototype.cacheResult = FromEntriesSequence.prototype.cacheResult = cacheResultThrough;
         
     | 
| 
       970 
     | 
    
         
            -
            function flipFactory(collection) {
         
     | 
| 
       971 
     | 
    
         
            -
              var flipSequence = makeSequence(collection);
         
     | 
| 
       972 
     | 
    
         
            -
              flipSequence._iter = collection;
         
     | 
| 
       973 
     | 
    
         
            -
              flipSequence.size = collection.size;
         
     | 
| 
       974 
     | 
    
         
            -
              flipSequence.flip = function () {
         
     | 
| 
       975 
     | 
    
         
            -
                return collection;
         
     | 
| 
       976 
     | 
    
         
            -
              };
         
     | 
| 
       977 
     | 
    
         
            -
              flipSequence.reverse = function () {
         
     | 
| 
       978 
     | 
    
         
            -
                var reversedSequence = collection.reverse.apply(this); // super.reverse()
         
     | 
| 
       979 
     | 
    
         
            -
                reversedSequence.flip = function () {
         
     | 
| 
       980 
     | 
    
         
            -
                  return collection.reverse();
         
     | 
| 
       981 
     | 
    
         
            -
                };
         
     | 
| 
       982 
     | 
    
         
            -
                return reversedSequence;
         
     | 
| 
       983 
     | 
    
         
            -
              };
         
     | 
| 
       984 
     | 
    
         
            -
              flipSequence.has = function (key) {
         
     | 
| 
       985 
     | 
    
         
            -
                return collection.includes(key);
         
     | 
| 
       986 
     | 
    
         
            -
              };
         
     | 
| 
       987 
     | 
    
         
            -
              flipSequence.includes = function (key) {
         
     | 
| 
       988 
     | 
    
         
            -
                return collection.has(key);
         
     | 
| 
       989 
     | 
    
         
            -
              };
         
     | 
| 
       990 
     | 
    
         
            -
              flipSequence.cacheResult = cacheResultThrough;
         
     | 
| 
       991 
     | 
    
         
            -
              flipSequence.__iterateUncached = function (fn, reverse) {
         
     | 
| 
       992 
     | 
    
         
            -
                var this$1$1 = this;
         
     | 
| 
       993 
     | 
    
         
            -
                return collection.__iterate(function (v, k) {
         
     | 
| 
       994 
     | 
    
         
            -
                  return fn(k, v, this$1$1) !== false;
         
     | 
| 
       995 
     | 
    
         
            -
                }, reverse);
         
     | 
| 
       996 
     | 
    
         
            -
              };
         
     | 
| 
       997 
     | 
    
         
            -
              flipSequence.__iteratorUncached = function (type, reverse) {
         
     | 
| 
       998 
     | 
    
         
            -
                if (type === ITERATE_ENTRIES) {
         
     | 
| 
       999 
     | 
    
         
            -
                  var iterator = collection.__iterator(type, reverse);
         
     | 
| 
       1000 
     | 
    
         
            -
                  return new Iterator(function () {
         
     | 
| 
       1001 
     | 
    
         
            -
                    var step = iterator.next();
         
     | 
| 
       1002 
     | 
    
         
            -
                    if (!step.done) {
         
     | 
| 
       1003 
     | 
    
         
            -
                      var k = step.value[0];
         
     | 
| 
       1004 
     | 
    
         
            -
                      step.value[0] = step.value[1];
         
     | 
| 
       1005 
     | 
    
         
            -
                      step.value[1] = k;
         
     | 
| 
       1006 
     | 
    
         
            -
                    }
         
     | 
| 
       1007 
     | 
    
         
            -
                    return step;
         
     | 
| 
       1008 
     | 
    
         
            -
                  });
         
     | 
| 
       1009 
     | 
    
         
            -
                }
         
     | 
| 
       1010 
     | 
    
         
            -
                return collection.__iterator(type === ITERATE_VALUES ? ITERATE_KEYS : ITERATE_VALUES, reverse);
         
     | 
| 
       1011 
     | 
    
         
            -
              };
         
     | 
| 
       1012 
     | 
    
         
            -
              return flipSequence;
         
     | 
| 
       1013 
     | 
    
         
            -
            }
         
     | 
| 
       1014 
     | 
    
         
            -
            function mapFactory(collection, mapper, context) {
         
     | 
| 
       1015 
     | 
    
         
            -
              var mappedSequence = makeSequence(collection);
         
     | 
| 
       1016 
     | 
    
         
            -
              mappedSequence.size = collection.size;
         
     | 
| 
       1017 
     | 
    
         
            -
              mappedSequence.has = function (key) {
         
     | 
| 
       1018 
     | 
    
         
            -
                return collection.has(key);
         
     | 
| 
       1019 
     | 
    
         
            -
              };
         
     | 
| 
       1020 
     | 
    
         
            -
              mappedSequence.get = function (key, notSetValue) {
         
     | 
| 
       1021 
     | 
    
         
            -
                var v = collection.get(key, NOT_SET);
         
     | 
| 
       1022 
     | 
    
         
            -
                return v === NOT_SET ? notSetValue : mapper.call(context, v, key, collection);
         
     | 
| 
       1023 
     | 
    
         
            -
              };
         
     | 
| 
       1024 
     | 
    
         
            -
              mappedSequence.__iterateUncached = function (fn, reverse) {
         
     | 
| 
       1025 
     | 
    
         
            -
                var this$1$1 = this;
         
     | 
| 
       1026 
     | 
    
         
            -
                return collection.__iterate(function (v, k, c) {
         
     | 
| 
       1027 
     | 
    
         
            -
                  return fn(mapper.call(context, v, k, c), k, this$1$1) !== false;
         
     | 
| 
       1028 
     | 
    
         
            -
                }, reverse);
         
     | 
| 
       1029 
     | 
    
         
            -
              };
         
     | 
| 
       1030 
     | 
    
         
            -
              mappedSequence.__iteratorUncached = function (type, reverse) {
         
     | 
| 
       1031 
     | 
    
         
            -
                var iterator = collection.__iterator(ITERATE_ENTRIES, reverse);
         
     | 
| 
       1032 
     | 
    
         
            -
                return new Iterator(function () {
         
     | 
| 
       1033 
     | 
    
         
            -
                  var step = iterator.next();
         
     | 
| 
       1034 
     | 
    
         
            -
                  if (step.done) {
         
     | 
| 
       1035 
     | 
    
         
            -
                    return step;
         
     | 
| 
       1036 
     | 
    
         
            -
                  }
         
     | 
| 
       1037 
     | 
    
         
            -
                  var entry = step.value;
         
     | 
| 
       1038 
     | 
    
         
            -
                  var key = entry[0];
         
     | 
| 
       1039 
     | 
    
         
            -
                  return iteratorValue(type, key, mapper.call(context, entry[1], key, collection), step);
         
     | 
| 
       1040 
     | 
    
         
            -
                });
         
     | 
| 
       1041 
     | 
    
         
            -
              };
         
     | 
| 
       1042 
     | 
    
         
            -
              return mappedSequence;
         
     | 
| 
       1043 
     | 
    
         
            -
            }
         
     | 
| 
       1044 
     | 
    
         
            -
            function reverseFactory(collection, useKeys) {
         
     | 
| 
       1045 
     | 
    
         
            -
              var this$1$1 = this;
         
     | 
| 
       1046 
     | 
    
         
            -
              var reversedSequence = makeSequence(collection);
         
     | 
| 
       1047 
     | 
    
         
            -
              reversedSequence._iter = collection;
         
     | 
| 
       1048 
     | 
    
         
            -
              reversedSequence.size = collection.size;
         
     | 
| 
       1049 
     | 
    
         
            -
              reversedSequence.reverse = function () {
         
     | 
| 
       1050 
     | 
    
         
            -
                return collection;
         
     | 
| 
       1051 
     | 
    
         
            -
              };
         
     | 
| 
       1052 
     | 
    
         
            -
              if (collection.flip) {
         
     | 
| 
       1053 
     | 
    
         
            -
                reversedSequence.flip = function () {
         
     | 
| 
       1054 
     | 
    
         
            -
                  var flipSequence = flipFactory(collection);
         
     | 
| 
       1055 
     | 
    
         
            -
                  flipSequence.reverse = function () {
         
     | 
| 
       1056 
     | 
    
         
            -
                    return collection.flip();
         
     | 
| 
       1057 
     | 
    
         
            -
                  };
         
     | 
| 
       1058 
     | 
    
         
            -
                  return flipSequence;
         
     | 
| 
       1059 
     | 
    
         
            -
                };
         
     | 
| 
       1060 
     | 
    
         
            -
              }
         
     | 
| 
       1061 
     | 
    
         
            -
              reversedSequence.get = function (key, notSetValue) {
         
     | 
| 
       1062 
     | 
    
         
            -
                return collection.get(useKeys ? key : -1 - key, notSetValue);
         
     | 
| 
       1063 
     | 
    
         
            -
              };
         
     | 
| 
       1064 
     | 
    
         
            -
              reversedSequence.has = function (key) {
         
     | 
| 
       1065 
     | 
    
         
            -
                return collection.has(useKeys ? key : -1 - key);
         
     | 
| 
       1066 
     | 
    
         
            -
              };
         
     | 
| 
       1067 
     | 
    
         
            -
              reversedSequence.includes = function (value) {
         
     | 
| 
       1068 
     | 
    
         
            -
                return collection.includes(value);
         
     | 
| 
       1069 
     | 
    
         
            -
              };
         
     | 
| 
       1070 
     | 
    
         
            -
              reversedSequence.cacheResult = cacheResultThrough;
         
     | 
| 
       1071 
     | 
    
         
            -
              reversedSequence.__iterate = function (fn, reverse) {
         
     | 
| 
       1072 
     | 
    
         
            -
                var this$1$1 = this;
         
     | 
| 
       1073 
     | 
    
         
            -
                var i = 0;
         
     | 
| 
       1074 
     | 
    
         
            -
                reverse && ensureSize(collection);
         
     | 
| 
       1075 
     | 
    
         
            -
                return collection.__iterate(function (v, k) {
         
     | 
| 
       1076 
     | 
    
         
            -
                  return fn(v, useKeys ? k : reverse ? this$1$1.size - ++i : i++, this$1$1);
         
     | 
| 
       1077 
     | 
    
         
            -
                }, !reverse);
         
     | 
| 
       1078 
     | 
    
         
            -
              };
         
     | 
| 
       1079 
     | 
    
         
            -
              reversedSequence.__iterator = function (type, reverse) {
         
     | 
| 
       1080 
     | 
    
         
            -
                var i = 0;
         
     | 
| 
       1081 
     | 
    
         
            -
                reverse && ensureSize(collection);
         
     | 
| 
       1082 
     | 
    
         
            -
                var iterator = collection.__iterator(ITERATE_ENTRIES, !reverse);
         
     | 
| 
       1083 
     | 
    
         
            -
                return new Iterator(function () {
         
     | 
| 
       1084 
     | 
    
         
            -
                  var step = iterator.next();
         
     | 
| 
       1085 
     | 
    
         
            -
                  if (step.done) {
         
     | 
| 
       1086 
     | 
    
         
            -
                    return step;
         
     | 
| 
       1087 
     | 
    
         
            -
                  }
         
     | 
| 
       1088 
     | 
    
         
            -
                  var entry = step.value;
         
     | 
| 
       1089 
     | 
    
         
            -
                  return iteratorValue(type, useKeys ? entry[0] : reverse ? this$1$1.size - ++i : i++, entry[1], step);
         
     | 
| 
       1090 
     | 
    
         
            -
                });
         
     | 
| 
       1091 
     | 
    
         
            -
              };
         
     | 
| 
       1092 
     | 
    
         
            -
              return reversedSequence;
         
     | 
| 
       1093 
     | 
    
         
            -
            }
         
     | 
| 
       1094 
     | 
    
         
            -
            function filterFactory(collection, predicate, context, useKeys) {
         
     | 
| 
       1095 
     | 
    
         
            -
              var filterSequence = makeSequence(collection);
         
     | 
| 
       1096 
     | 
    
         
            -
              if (useKeys) {
         
     | 
| 
       1097 
     | 
    
         
            -
                filterSequence.has = function (key) {
         
     | 
| 
       1098 
     | 
    
         
            -
                  var v = collection.get(key, NOT_SET);
         
     | 
| 
       1099 
     | 
    
         
            -
                  return v !== NOT_SET && !!predicate.call(context, v, key, collection);
         
     | 
| 
       1100 
     | 
    
         
            -
                };
         
     | 
| 
       1101 
     | 
    
         
            -
                filterSequence.get = function (key, notSetValue) {
         
     | 
| 
       1102 
     | 
    
         
            -
                  var v = collection.get(key, NOT_SET);
         
     | 
| 
       1103 
     | 
    
         
            -
                  return v !== NOT_SET && predicate.call(context, v, key, collection) ? v : notSetValue;
         
     | 
| 
       1104 
     | 
    
         
            -
                };
         
     | 
| 
       1105 
     | 
    
         
            -
              }
         
     | 
| 
       1106 
     | 
    
         
            -
              filterSequence.__iterateUncached = function (fn, reverse) {
         
     | 
| 
       1107 
     | 
    
         
            -
                var this$1$1 = this;
         
     | 
| 
       1108 
     | 
    
         
            -
                var iterations = 0;
         
     | 
| 
       1109 
     | 
    
         
            -
                collection.__iterate(function (v, k, c) {
         
     | 
| 
       1110 
     | 
    
         
            -
                  if (predicate.call(context, v, k, c)) {
         
     | 
| 
       1111 
     | 
    
         
            -
                    iterations++;
         
     | 
| 
       1112 
     | 
    
         
            -
                    return fn(v, useKeys ? k : iterations - 1, this$1$1);
         
     | 
| 
       1113 
     | 
    
         
            -
                  }
         
     | 
| 
       1114 
     | 
    
         
            -
                }, reverse);
         
     | 
| 
       1115 
     | 
    
         
            -
                return iterations;
         
     | 
| 
       1116 
     | 
    
         
            -
              };
         
     | 
| 
       1117 
     | 
    
         
            -
              filterSequence.__iteratorUncached = function (type, reverse) {
         
     | 
| 
       1118 
     | 
    
         
            -
                var iterator = collection.__iterator(ITERATE_ENTRIES, reverse);
         
     | 
| 
       1119 
     | 
    
         
            -
                var iterations = 0;
         
     | 
| 
       1120 
     | 
    
         
            -
                return new Iterator(function () {
         
     | 
| 
       1121 
     | 
    
         
            -
                  while (true) {
         
     | 
| 
       1122 
     | 
    
         
            -
                    var step = iterator.next();
         
     | 
| 
       1123 
     | 
    
         
            -
                    if (step.done) {
         
     | 
| 
       1124 
     | 
    
         
            -
                      return step;
         
     | 
| 
       1125 
     | 
    
         
            -
                    }
         
     | 
| 
       1126 
     | 
    
         
            -
                    var entry = step.value;
         
     | 
| 
       1127 
     | 
    
         
            -
                    var key = entry[0];
         
     | 
| 
       1128 
     | 
    
         
            -
                    var value = entry[1];
         
     | 
| 
       1129 
     | 
    
         
            -
                    if (predicate.call(context, value, key, collection)) {
         
     | 
| 
       1130 
     | 
    
         
            -
                      return iteratorValue(type, useKeys ? key : iterations++, value, step);
         
     | 
| 
       1131 
     | 
    
         
            -
                    }
         
     | 
| 
       1132 
     | 
    
         
            -
                  }
         
     | 
| 
       1133 
     | 
    
         
            -
                });
         
     | 
| 
       1134 
     | 
    
         
            -
              };
         
     | 
| 
       1135 
     | 
    
         
            -
              return filterSequence;
         
     | 
| 
       1136 
     | 
    
         
            -
            }
         
     | 
| 
       1137 
     | 
    
         
            -
            function countByFactory(collection, grouper, context) {
         
     | 
| 
       1138 
     | 
    
         
            -
              var groups = Map().asMutable();
         
     | 
| 
       1139 
     | 
    
         
            -
              collection.__iterate(function (v, k) {
         
     | 
| 
       1140 
     | 
    
         
            -
                groups.update(grouper.call(context, v, k, collection), 0, function (a) {
         
     | 
| 
       1141 
     | 
    
         
            -
                  return a + 1;
         
     | 
| 
       1142 
     | 
    
         
            -
                });
         
     | 
| 
       1143 
     | 
    
         
            -
              });
         
     | 
| 
       1144 
     | 
    
         
            -
              return groups.asImmutable();
         
     | 
| 
       1145 
     | 
    
         
            -
            }
         
     | 
| 
       1146 
     | 
    
         
            -
            function groupByFactory(collection, grouper, context) {
         
     | 
| 
       1147 
     | 
    
         
            -
              var isKeyedIter = isKeyed(collection);
         
     | 
| 
       1148 
     | 
    
         
            -
              var groups = (isOrdered(collection) ? OrderedMap() : Map()).asMutable();
         
     | 
| 
       1149 
     | 
    
         
            -
              collection.__iterate(function (v, k) {
         
     | 
| 
       1150 
     | 
    
         
            -
                groups.update(grouper.call(context, v, k, collection), function (a) {
         
     | 
| 
       1151 
     | 
    
         
            -
                  return a = a || [], a.push(isKeyedIter ? [k, v] : v), a;
         
     | 
| 
       1152 
     | 
    
         
            -
                });
         
     | 
| 
       1153 
     | 
    
         
            -
              });
         
     | 
| 
       1154 
     | 
    
         
            -
              var coerce = collectionClass(collection);
         
     | 
| 
       1155 
     | 
    
         
            -
              return groups.map(function (arr) {
         
     | 
| 
       1156 
     | 
    
         
            -
                return reify(collection, coerce(arr));
         
     | 
| 
       1157 
     | 
    
         
            -
              }).asImmutable();
         
     | 
| 
       1158 
     | 
    
         
            -
            }
         
     | 
| 
       1159 
     | 
    
         
            -
            function partitionFactory(collection, predicate, context) {
         
     | 
| 
       1160 
     | 
    
         
            -
              var isKeyedIter = isKeyed(collection);
         
     | 
| 
       1161 
     | 
    
         
            -
              var groups = [[], []];
         
     | 
| 
       1162 
     | 
    
         
            -
              collection.__iterate(function (v, k) {
         
     | 
| 
       1163 
     | 
    
         
            -
                groups[predicate.call(context, v, k, collection) ? 1 : 0].push(isKeyedIter ? [k, v] : v);
         
     | 
| 
       1164 
     | 
    
         
            -
              });
         
     | 
| 
       1165 
     | 
    
         
            -
              var coerce = collectionClass(collection);
         
     | 
| 
       1166 
     | 
    
         
            -
              return groups.map(function (arr) {
         
     | 
| 
       1167 
     | 
    
         
            -
                return reify(collection, coerce(arr));
         
     | 
| 
       1168 
     | 
    
         
            -
              });
         
     | 
| 
       1169 
     | 
    
         
            -
            }
         
     | 
| 
       1170 
     | 
    
         
            -
            function sliceFactory(collection, begin, end, useKeys) {
         
     | 
| 
       1171 
     | 
    
         
            -
              var originalSize = collection.size;
         
     | 
| 
       1172 
     | 
    
         
            -
              if (wholeSlice(begin, end, originalSize)) {
         
     | 
| 
       1173 
     | 
    
         
            -
                return collection;
         
     | 
| 
       1174 
     | 
    
         
            -
              }
         
     | 
| 
       1175 
     | 
    
         
            -
             
     | 
| 
       1176 
     | 
    
         
            -
              // begin or end can not be resolved if they were provided as negative numbers and
         
     | 
| 
       1177 
     | 
    
         
            -
              // this collection's size is unknown. In that case, cache first so there is
         
     | 
| 
       1178 
     | 
    
         
            -
              // a known size and these do not resolve to NaN.
         
     | 
| 
       1179 
     | 
    
         
            -
              if (typeof originalSize === 'undefined' && (begin < 0 || end < 0)) {
         
     | 
| 
       1180 
     | 
    
         
            -
                return sliceFactory(collection.toSeq().cacheResult(), begin, end, useKeys);
         
     | 
| 
       1181 
     | 
    
         
            -
              }
         
     | 
| 
       1182 
     | 
    
         
            -
              var resolvedBegin = resolveBegin(begin, originalSize);
         
     | 
| 
       1183 
     | 
    
         
            -
              var resolvedEnd = resolveEnd(end, originalSize);
         
     | 
| 
       1184 
     | 
    
         
            -
             
     | 
| 
       1185 
     | 
    
         
            -
              // Note: resolvedEnd is undefined when the original sequence's length is
         
     | 
| 
       1186 
     | 
    
         
            -
              // unknown and this slice did not supply an end and should contain all
         
     | 
| 
       1187 
     | 
    
         
            -
              // elements after resolvedBegin.
         
     | 
| 
       1188 
     | 
    
         
            -
              // In that case, resolvedSize will be NaN and sliceSize will remain undefined.
         
     | 
| 
       1189 
     | 
    
         
            -
              var resolvedSize = resolvedEnd - resolvedBegin;
         
     | 
| 
       1190 
     | 
    
         
            -
              var sliceSize;
         
     | 
| 
       1191 
     | 
    
         
            -
              if (resolvedSize === resolvedSize) {
         
     | 
| 
       1192 
     | 
    
         
            -
                sliceSize = resolvedSize < 0 ? 0 : resolvedSize;
         
     | 
| 
       1193 
     | 
    
         
            -
              }
         
     | 
| 
       1194 
     | 
    
         
            -
              var sliceSeq = makeSequence(collection);
         
     | 
| 
       1195 
     | 
    
         
            -
             
     | 
| 
       1196 
     | 
    
         
            -
              // If collection.size is undefined, the size of the realized sliceSeq is
         
     | 
| 
       1197 
     | 
    
         
            -
              // unknown at this point unless the number of items to slice is 0
         
     | 
| 
       1198 
     | 
    
         
            -
              sliceSeq.size = sliceSize === 0 ? sliceSize : collection.size && sliceSize || undefined;
         
     | 
| 
       1199 
     | 
    
         
            -
              if (!useKeys && isSeq(collection) && sliceSize >= 0) {
         
     | 
| 
       1200 
     | 
    
         
            -
                sliceSeq.get = function (index, notSetValue) {
         
     | 
| 
       1201 
     | 
    
         
            -
                  index = wrapIndex(this, index);
         
     | 
| 
       1202 
     | 
    
         
            -
                  return index >= 0 && index < sliceSize ? collection.get(index + resolvedBegin, notSetValue) : notSetValue;
         
     | 
| 
       1203 
     | 
    
         
            -
                };
         
     | 
| 
       1204 
     | 
    
         
            -
              }
         
     | 
| 
       1205 
     | 
    
         
            -
              sliceSeq.__iterateUncached = function (fn, reverse) {
         
     | 
| 
       1206 
     | 
    
         
            -
                var this$1$1 = this;
         
     | 
| 
       1207 
     | 
    
         
            -
                if (sliceSize === 0) {
         
     | 
| 
       1208 
     | 
    
         
            -
                  return 0;
         
     | 
| 
       1209 
     | 
    
         
            -
                }
         
     | 
| 
       1210 
     | 
    
         
            -
                if (reverse) {
         
     | 
| 
       1211 
     | 
    
         
            -
                  return this.cacheResult().__iterate(fn, reverse);
         
     | 
| 
       1212 
     | 
    
         
            -
                }
         
     | 
| 
       1213 
     | 
    
         
            -
                var skipped = 0;
         
     | 
| 
       1214 
     | 
    
         
            -
                var isSkipping = true;
         
     | 
| 
       1215 
     | 
    
         
            -
                var iterations = 0;
         
     | 
| 
       1216 
     | 
    
         
            -
                collection.__iterate(function (v, k) {
         
     | 
| 
       1217 
     | 
    
         
            -
                  if (!(isSkipping && (isSkipping = skipped++ < resolvedBegin))) {
         
     | 
| 
       1218 
     | 
    
         
            -
                    iterations++;
         
     | 
| 
       1219 
     | 
    
         
            -
                    return fn(v, useKeys ? k : iterations - 1, this$1$1) !== false && iterations !== sliceSize;
         
     | 
| 
       1220 
     | 
    
         
            -
                  }
         
     | 
| 
       1221 
     | 
    
         
            -
                });
         
     | 
| 
       1222 
     | 
    
         
            -
                return iterations;
         
     | 
| 
       1223 
     | 
    
         
            -
              };
         
     | 
| 
       1224 
     | 
    
         
            -
              sliceSeq.__iteratorUncached = function (type, reverse) {
         
     | 
| 
       1225 
     | 
    
         
            -
                if (sliceSize !== 0 && reverse) {
         
     | 
| 
       1226 
     | 
    
         
            -
                  return this.cacheResult().__iterator(type, reverse);
         
     | 
| 
       1227 
     | 
    
         
            -
                }
         
     | 
| 
       1228 
     | 
    
         
            -
                // Don't bother instantiating parent iterator if taking 0.
         
     | 
| 
       1229 
     | 
    
         
            -
                if (sliceSize === 0) {
         
     | 
| 
       1230 
     | 
    
         
            -
                  return new Iterator(iteratorDone);
         
     | 
| 
       1231 
     | 
    
         
            -
                }
         
     | 
| 
       1232 
     | 
    
         
            -
                var iterator = collection.__iterator(type, reverse);
         
     | 
| 
       1233 
     | 
    
         
            -
                var skipped = 0;
         
     | 
| 
       1234 
     | 
    
         
            -
                var iterations = 0;
         
     | 
| 
       1235 
     | 
    
         
            -
                return new Iterator(function () {
         
     | 
| 
       1236 
     | 
    
         
            -
                  while (skipped++ < resolvedBegin) {
         
     | 
| 
       1237 
     | 
    
         
            -
                    iterator.next();
         
     | 
| 
       1238 
     | 
    
         
            -
                  }
         
     | 
| 
       1239 
     | 
    
         
            -
                  if (++iterations > sliceSize) {
         
     | 
| 
       1240 
     | 
    
         
            -
                    return iteratorDone();
         
     | 
| 
       1241 
     | 
    
         
            -
                  }
         
     | 
| 
       1242 
     | 
    
         
            -
                  var step = iterator.next();
         
     | 
| 
       1243 
     | 
    
         
            -
                  if (useKeys || type === ITERATE_VALUES || step.done) {
         
     | 
| 
       1244 
     | 
    
         
            -
                    return step;
         
     | 
| 
       1245 
     | 
    
         
            -
                  }
         
     | 
| 
       1246 
     | 
    
         
            -
                  if (type === ITERATE_KEYS) {
         
     | 
| 
       1247 
     | 
    
         
            -
                    return iteratorValue(type, iterations - 1, undefined, step);
         
     | 
| 
       1248 
     | 
    
         
            -
                  }
         
     | 
| 
       1249 
     | 
    
         
            -
                  return iteratorValue(type, iterations - 1, step.value[1], step);
         
     | 
| 
       1250 
     | 
    
         
            -
                });
         
     | 
| 
       1251 
     | 
    
         
            -
              };
         
     | 
| 
       1252 
     | 
    
         
            -
              return sliceSeq;
         
     | 
| 
       1253 
     | 
    
         
            -
            }
         
     | 
| 
       1254 
     | 
    
         
            -
            function takeWhileFactory(collection, predicate, context) {
         
     | 
| 
       1255 
     | 
    
         
            -
              var takeSequence = makeSequence(collection);
         
     | 
| 
       1256 
     | 
    
         
            -
              takeSequence.__iterateUncached = function (fn, reverse) {
         
     | 
| 
       1257 
     | 
    
         
            -
                var this$1$1 = this;
         
     | 
| 
       1258 
     | 
    
         
            -
                if (reverse) {
         
     | 
| 
       1259 
     | 
    
         
            -
                  return this.cacheResult().__iterate(fn, reverse);
         
     | 
| 
       1260 
     | 
    
         
            -
                }
         
     | 
| 
       1261 
     | 
    
         
            -
                var iterations = 0;
         
     | 
| 
       1262 
     | 
    
         
            -
                collection.__iterate(function (v, k, c) {
         
     | 
| 
       1263 
     | 
    
         
            -
                  return predicate.call(context, v, k, c) && ++iterations && fn(v, k, this$1$1);
         
     | 
| 
       1264 
     | 
    
         
            -
                });
         
     | 
| 
       1265 
     | 
    
         
            -
                return iterations;
         
     | 
| 
       1266 
     | 
    
         
            -
              };
         
     | 
| 
       1267 
     | 
    
         
            -
              takeSequence.__iteratorUncached = function (type, reverse) {
         
     | 
| 
       1268 
     | 
    
         
            -
                var this$1$1 = this;
         
     | 
| 
       1269 
     | 
    
         
            -
                if (reverse) {
         
     | 
| 
       1270 
     | 
    
         
            -
                  return this.cacheResult().__iterator(type, reverse);
         
     | 
| 
       1271 
     | 
    
         
            -
                }
         
     | 
| 
       1272 
     | 
    
         
            -
                var iterator = collection.__iterator(ITERATE_ENTRIES, reverse);
         
     | 
| 
       1273 
     | 
    
         
            -
                var iterating = true;
         
     | 
| 
       1274 
     | 
    
         
            -
                return new Iterator(function () {
         
     | 
| 
       1275 
     | 
    
         
            -
                  if (!iterating) {
         
     | 
| 
       1276 
     | 
    
         
            -
                    return iteratorDone();
         
     | 
| 
       1277 
     | 
    
         
            -
                  }
         
     | 
| 
       1278 
     | 
    
         
            -
                  var step = iterator.next();
         
     | 
| 
       1279 
     | 
    
         
            -
                  if (step.done) {
         
     | 
| 
       1280 
     | 
    
         
            -
                    return step;
         
     | 
| 
       1281 
     | 
    
         
            -
                  }
         
     | 
| 
       1282 
     | 
    
         
            -
                  var entry = step.value;
         
     | 
| 
       1283 
     | 
    
         
            -
                  var k = entry[0];
         
     | 
| 
       1284 
     | 
    
         
            -
                  var v = entry[1];
         
     | 
| 
       1285 
     | 
    
         
            -
                  if (!predicate.call(context, v, k, this$1$1)) {
         
     | 
| 
       1286 
     | 
    
         
            -
                    iterating = false;
         
     | 
| 
       1287 
     | 
    
         
            -
                    return iteratorDone();
         
     | 
| 
       1288 
     | 
    
         
            -
                  }
         
     | 
| 
       1289 
     | 
    
         
            -
                  return type === ITERATE_ENTRIES ? step : iteratorValue(type, k, v, step);
         
     | 
| 
       1290 
     | 
    
         
            -
                });
         
     | 
| 
       1291 
     | 
    
         
            -
              };
         
     | 
| 
       1292 
     | 
    
         
            -
              return takeSequence;
         
     | 
| 
       1293 
     | 
    
         
            -
            }
         
     | 
| 
       1294 
     | 
    
         
            -
            function skipWhileFactory(collection, predicate, context, useKeys) {
         
     | 
| 
       1295 
     | 
    
         
            -
              var skipSequence = makeSequence(collection);
         
     | 
| 
       1296 
     | 
    
         
            -
              skipSequence.__iterateUncached = function (fn, reverse) {
         
     | 
| 
       1297 
     | 
    
         
            -
                var this$1$1 = this;
         
     | 
| 
       1298 
     | 
    
         
            -
                if (reverse) {
         
     | 
| 
       1299 
     | 
    
         
            -
                  return this.cacheResult().__iterate(fn, reverse);
         
     | 
| 
       1300 
     | 
    
         
            -
                }
         
     | 
| 
       1301 
     | 
    
         
            -
                var isSkipping = true;
         
     | 
| 
       1302 
     | 
    
         
            -
                var iterations = 0;
         
     | 
| 
       1303 
     | 
    
         
            -
                collection.__iterate(function (v, k, c) {
         
     | 
| 
       1304 
     | 
    
         
            -
                  if (!(isSkipping && (isSkipping = predicate.call(context, v, k, c)))) {
         
     | 
| 
       1305 
     | 
    
         
            -
                    iterations++;
         
     | 
| 
       1306 
     | 
    
         
            -
                    return fn(v, useKeys ? k : iterations - 1, this$1$1);
         
     | 
| 
       1307 
     | 
    
         
            -
                  }
         
     | 
| 
       1308 
     | 
    
         
            -
                });
         
     | 
| 
       1309 
     | 
    
         
            -
                return iterations;
         
     | 
| 
       1310 
     | 
    
         
            -
              };
         
     | 
| 
       1311 
     | 
    
         
            -
              skipSequence.__iteratorUncached = function (type, reverse) {
         
     | 
| 
       1312 
     | 
    
         
            -
                var this$1$1 = this;
         
     | 
| 
       1313 
     | 
    
         
            -
                if (reverse) {
         
     | 
| 
       1314 
     | 
    
         
            -
                  return this.cacheResult().__iterator(type, reverse);
         
     | 
| 
       1315 
     | 
    
         
            -
                }
         
     | 
| 
       1316 
     | 
    
         
            -
                var iterator = collection.__iterator(ITERATE_ENTRIES, reverse);
         
     | 
| 
       1317 
     | 
    
         
            -
                var skipping = true;
         
     | 
| 
       1318 
     | 
    
         
            -
                var iterations = 0;
         
     | 
| 
       1319 
     | 
    
         
            -
                return new Iterator(function () {
         
     | 
| 
       1320 
     | 
    
         
            -
                  var step;
         
     | 
| 
       1321 
     | 
    
         
            -
                  var k;
         
     | 
| 
       1322 
     | 
    
         
            -
                  var v;
         
     | 
| 
       1323 
     | 
    
         
            -
                  do {
         
     | 
| 
       1324 
     | 
    
         
            -
                    step = iterator.next();
         
     | 
| 
       1325 
     | 
    
         
            -
                    if (step.done) {
         
     | 
| 
       1326 
     | 
    
         
            -
                      if (useKeys || type === ITERATE_VALUES) {
         
     | 
| 
       1327 
     | 
    
         
            -
                        return step;
         
     | 
| 
       1328 
     | 
    
         
            -
                      }
         
     | 
| 
       1329 
     | 
    
         
            -
                      if (type === ITERATE_KEYS) {
         
     | 
| 
       1330 
     | 
    
         
            -
                        return iteratorValue(type, iterations++, undefined, step);
         
     | 
| 
       1331 
     | 
    
         
            -
                      }
         
     | 
| 
       1332 
     | 
    
         
            -
                      return iteratorValue(type, iterations++, step.value[1], step);
         
     | 
| 
       1333 
     | 
    
         
            -
                    }
         
     | 
| 
       1334 
     | 
    
         
            -
                    var entry = step.value;
         
     | 
| 
       1335 
     | 
    
         
            -
                    k = entry[0];
         
     | 
| 
       1336 
     | 
    
         
            -
                    v = entry[1];
         
     | 
| 
       1337 
     | 
    
         
            -
                    skipping && (skipping = predicate.call(context, v, k, this$1$1));
         
     | 
| 
       1338 
     | 
    
         
            -
                  } while (skipping);
         
     | 
| 
       1339 
     | 
    
         
            -
                  return type === ITERATE_ENTRIES ? step : iteratorValue(type, k, v, step);
         
     | 
| 
       1340 
     | 
    
         
            -
                });
         
     | 
| 
       1341 
     | 
    
         
            -
              };
         
     | 
| 
       1342 
     | 
    
         
            -
              return skipSequence;
         
     | 
| 
       1343 
     | 
    
         
            -
            }
         
     | 
| 
       1344 
     | 
    
         
            -
            function concatFactory(collection, values) {
         
     | 
| 
       1345 
     | 
    
         
            -
              var isKeyedCollection = isKeyed(collection);
         
     | 
| 
       1346 
     | 
    
         
            -
              var iters = [collection].concat(values).map(function (v) {
         
     | 
| 
       1347 
     | 
    
         
            -
                if (!isCollection(v)) {
         
     | 
| 
       1348 
     | 
    
         
            -
                  v = isKeyedCollection ? keyedSeqFromValue(v) : indexedSeqFromValue(Array.isArray(v) ? v : [v]);
         
     | 
| 
       1349 
     | 
    
         
            -
                } else if (isKeyedCollection) {
         
     | 
| 
       1350 
     | 
    
         
            -
                  v = KeyedCollection(v);
         
     | 
| 
       1351 
     | 
    
         
            -
                }
         
     | 
| 
       1352 
     | 
    
         
            -
                return v;
         
     | 
| 
       1353 
     | 
    
         
            -
              }).filter(function (v) {
         
     | 
| 
       1354 
     | 
    
         
            -
                return v.size !== 0;
         
     | 
| 
       1355 
     | 
    
         
            -
              });
         
     | 
| 
       1356 
     | 
    
         
            -
              if (iters.length === 0) {
         
     | 
| 
       1357 
     | 
    
         
            -
                return collection;
         
     | 
| 
       1358 
     | 
    
         
            -
              }
         
     | 
| 
       1359 
     | 
    
         
            -
              if (iters.length === 1) {
         
     | 
| 
       1360 
     | 
    
         
            -
                var singleton = iters[0];
         
     | 
| 
       1361 
     | 
    
         
            -
                if (singleton === collection || isKeyedCollection && isKeyed(singleton) || isIndexed(collection) && isIndexed(singleton)) {
         
     | 
| 
       1362 
     | 
    
         
            -
                  return singleton;
         
     | 
| 
       1363 
     | 
    
         
            -
                }
         
     | 
| 
       1364 
     | 
    
         
            -
              }
         
     | 
| 
       1365 
     | 
    
         
            -
              var concatSeq = new ArraySeq(iters);
         
     | 
| 
       1366 
     | 
    
         
            -
              if (isKeyedCollection) {
         
     | 
| 
       1367 
     | 
    
         
            -
                concatSeq = concatSeq.toKeyedSeq();
         
     | 
| 
       1368 
     | 
    
         
            -
              } else if (!isIndexed(collection)) {
         
     | 
| 
       1369 
     | 
    
         
            -
                concatSeq = concatSeq.toSetSeq();
         
     | 
| 
       1370 
     | 
    
         
            -
              }
         
     | 
| 
       1371 
     | 
    
         
            -
              concatSeq = concatSeq.flatten(true);
         
     | 
| 
       1372 
     | 
    
         
            -
              concatSeq.size = iters.reduce(function (sum, seq) {
         
     | 
| 
       1373 
     | 
    
         
            -
                if (sum !== undefined) {
         
     | 
| 
       1374 
     | 
    
         
            -
                  var size = seq.size;
         
     | 
| 
       1375 
     | 
    
         
            -
                  if (size !== undefined) {
         
     | 
| 
       1376 
     | 
    
         
            -
                    return sum + size;
         
     | 
| 
       1377 
     | 
    
         
            -
                  }
         
     | 
| 
       1378 
     | 
    
         
            -
                }
         
     | 
| 
       1379 
     | 
    
         
            -
              }, 0);
         
     | 
| 
       1380 
     | 
    
         
            -
              return concatSeq;
         
     | 
| 
       1381 
     | 
    
         
            -
            }
         
     | 
| 
       1382 
     | 
    
         
            -
            function flattenFactory(collection, depth, useKeys) {
         
     | 
| 
       1383 
     | 
    
         
            -
              var flatSequence = makeSequence(collection);
         
     | 
| 
       1384 
     | 
    
         
            -
              flatSequence.__iterateUncached = function (fn, reverse) {
         
     | 
| 
       1385 
     | 
    
         
            -
                if (reverse) {
         
     | 
| 
       1386 
     | 
    
         
            -
                  return this.cacheResult().__iterate(fn, reverse);
         
     | 
| 
       1387 
     | 
    
         
            -
                }
         
     | 
| 
       1388 
     | 
    
         
            -
                var iterations = 0;
         
     | 
| 
       1389 
     | 
    
         
            -
                var stopped = false;
         
     | 
| 
       1390 
     | 
    
         
            -
                function flatDeep(iter, currentDepth) {
         
     | 
| 
       1391 
     | 
    
         
            -
                  iter.__iterate(function (v, k) {
         
     | 
| 
       1392 
     | 
    
         
            -
                    if ((!depth || currentDepth < depth) && isCollection(v)) {
         
     | 
| 
       1393 
     | 
    
         
            -
                      flatDeep(v, currentDepth + 1);
         
     | 
| 
       1394 
     | 
    
         
            -
                    } else {
         
     | 
| 
       1395 
     | 
    
         
            -
                      iterations++;
         
     | 
| 
       1396 
     | 
    
         
            -
                      if (fn(v, useKeys ? k : iterations - 1, flatSequence) === false) {
         
     | 
| 
       1397 
     | 
    
         
            -
                        stopped = true;
         
     | 
| 
       1398 
     | 
    
         
            -
                      }
         
     | 
| 
       1399 
     | 
    
         
            -
                    }
         
     | 
| 
       1400 
     | 
    
         
            -
                    return !stopped;
         
     | 
| 
       1401 
     | 
    
         
            -
                  }, reverse);
         
     | 
| 
       1402 
     | 
    
         
            -
                }
         
     | 
| 
       1403 
     | 
    
         
            -
                flatDeep(collection, 0);
         
     | 
| 
       1404 
     | 
    
         
            -
                return iterations;
         
     | 
| 
       1405 
     | 
    
         
            -
              };
         
     | 
| 
       1406 
     | 
    
         
            -
              flatSequence.__iteratorUncached = function (type, reverse) {
         
     | 
| 
       1407 
     | 
    
         
            -
                if (reverse) {
         
     | 
| 
       1408 
     | 
    
         
            -
                  return this.cacheResult().__iterator(type, reverse);
         
     | 
| 
       1409 
     | 
    
         
            -
                }
         
     | 
| 
       1410 
     | 
    
         
            -
                var iterator = collection.__iterator(type, reverse);
         
     | 
| 
       1411 
     | 
    
         
            -
                var stack = [];
         
     | 
| 
       1412 
     | 
    
         
            -
                var iterations = 0;
         
     | 
| 
       1413 
     | 
    
         
            -
                return new Iterator(function () {
         
     | 
| 
       1414 
     | 
    
         
            -
                  while (iterator) {
         
     | 
| 
       1415 
     | 
    
         
            -
                    var step = iterator.next();
         
     | 
| 
       1416 
     | 
    
         
            -
                    if (step.done !== false) {
         
     | 
| 
       1417 
     | 
    
         
            -
                      iterator = stack.pop();
         
     | 
| 
       1418 
     | 
    
         
            -
                      continue;
         
     | 
| 
       1419 
     | 
    
         
            -
                    }
         
     | 
| 
       1420 
     | 
    
         
            -
                    var v = step.value;
         
     | 
| 
       1421 
     | 
    
         
            -
                    if (type === ITERATE_ENTRIES) {
         
     | 
| 
       1422 
     | 
    
         
            -
                      v = v[1];
         
     | 
| 
       1423 
     | 
    
         
            -
                    }
         
     | 
| 
       1424 
     | 
    
         
            -
                    if ((!depth || stack.length < depth) && isCollection(v)) {
         
     | 
| 
       1425 
     | 
    
         
            -
                      stack.push(iterator);
         
     | 
| 
       1426 
     | 
    
         
            -
                      iterator = v.__iterator(type, reverse);
         
     | 
| 
       1427 
     | 
    
         
            -
                    } else {
         
     | 
| 
       1428 
     | 
    
         
            -
                      return useKeys ? step : iteratorValue(type, iterations++, v, step);
         
     | 
| 
       1429 
     | 
    
         
            -
                    }
         
     | 
| 
       1430 
     | 
    
         
            -
                  }
         
     | 
| 
       1431 
     | 
    
         
            -
                  return iteratorDone();
         
     | 
| 
       1432 
     | 
    
         
            -
                });
         
     | 
| 
       1433 
     | 
    
         
            -
              };
         
     | 
| 
       1434 
     | 
    
         
            -
              return flatSequence;
         
     | 
| 
       1435 
     | 
    
         
            -
            }
         
     | 
| 
       1436 
     | 
    
         
            -
            function flatMapFactory(collection, mapper, context) {
         
     | 
| 
       1437 
     | 
    
         
            -
              var coerce = collectionClass(collection);
         
     | 
| 
       1438 
     | 
    
         
            -
              return collection.toSeq().map(function (v, k) {
         
     | 
| 
       1439 
     | 
    
         
            -
                return coerce(mapper.call(context, v, k, collection));
         
     | 
| 
       1440 
     | 
    
         
            -
              }).flatten(true);
         
     | 
| 
       1441 
     | 
    
         
            -
            }
         
     | 
| 
       1442 
     | 
    
         
            -
            function interposeFactory(collection, separator) {
         
     | 
| 
       1443 
     | 
    
         
            -
              var interposedSequence = makeSequence(collection);
         
     | 
| 
       1444 
     | 
    
         
            -
              interposedSequence.size = collection.size && collection.size * 2 - 1;
         
     | 
| 
       1445 
     | 
    
         
            -
              interposedSequence.__iterateUncached = function (fn, reverse) {
         
     | 
| 
       1446 
     | 
    
         
            -
                var this$1$1 = this;
         
     | 
| 
       1447 
     | 
    
         
            -
                var iterations = 0;
         
     | 
| 
       1448 
     | 
    
         
            -
                collection.__iterate(function (v) {
         
     | 
| 
       1449 
     | 
    
         
            -
                  return (!iterations || fn(separator, iterations++, this$1$1) !== false) && fn(v, iterations++, this$1$1) !== false;
         
     | 
| 
       1450 
     | 
    
         
            -
                }, reverse);
         
     | 
| 
       1451 
     | 
    
         
            -
                return iterations;
         
     | 
| 
       1452 
     | 
    
         
            -
              };
         
     | 
| 
       1453 
     | 
    
         
            -
              interposedSequence.__iteratorUncached = function (type, reverse) {
         
     | 
| 
       1454 
     | 
    
         
            -
                var iterator = collection.__iterator(ITERATE_VALUES, reverse);
         
     | 
| 
       1455 
     | 
    
         
            -
                var iterations = 0;
         
     | 
| 
       1456 
     | 
    
         
            -
                var step;
         
     | 
| 
       1457 
     | 
    
         
            -
                return new Iterator(function () {
         
     | 
| 
       1458 
     | 
    
         
            -
                  if (!step || iterations % 2) {
         
     | 
| 
       1459 
     | 
    
         
            -
                    step = iterator.next();
         
     | 
| 
       1460 
     | 
    
         
            -
                    if (step.done) {
         
     | 
| 
       1461 
     | 
    
         
            -
                      return step;
         
     | 
| 
       1462 
     | 
    
         
            -
                    }
         
     | 
| 
       1463 
     | 
    
         
            -
                  }
         
     | 
| 
       1464 
     | 
    
         
            -
                  return iterations % 2 ? iteratorValue(type, iterations++, separator) : iteratorValue(type, iterations++, step.value, step);
         
     | 
| 
       1465 
     | 
    
         
            -
                });
         
     | 
| 
       1466 
     | 
    
         
            -
              };
         
     | 
| 
       1467 
     | 
    
         
            -
              return interposedSequence;
         
     | 
| 
       1468 
     | 
    
         
            -
            }
         
     | 
| 
       1469 
     | 
    
         
            -
            function sortFactory(collection, comparator, mapper) {
         
     | 
| 
       1470 
     | 
    
         
            -
              if (!comparator) {
         
     | 
| 
       1471 
     | 
    
         
            -
                comparator = defaultComparator;
         
     | 
| 
       1472 
     | 
    
         
            -
              }
         
     | 
| 
       1473 
     | 
    
         
            -
              var isKeyedCollection = isKeyed(collection);
         
     | 
| 
       1474 
     | 
    
         
            -
              var index = 0;
         
     | 
| 
       1475 
     | 
    
         
            -
              var entries = collection.toSeq().map(function (v, k) {
         
     | 
| 
       1476 
     | 
    
         
            -
                return [k, v, index++, mapper ? mapper(v, k, collection) : v];
         
     | 
| 
       1477 
     | 
    
         
            -
              }).valueSeq().toArray();
         
     | 
| 
       1478 
     | 
    
         
            -
              entries.sort(function (a, b) {
         
     | 
| 
       1479 
     | 
    
         
            -
                return comparator(a[3], b[3]) || a[2] - b[2];
         
     | 
| 
       1480 
     | 
    
         
            -
              }).forEach(isKeyedCollection ? function (v, i) {
         
     | 
| 
       1481 
     | 
    
         
            -
                entries[i].length = 2;
         
     | 
| 
       1482 
     | 
    
         
            -
              } : function (v, i) {
         
     | 
| 
       1483 
     | 
    
         
            -
                entries[i] = v[1];
         
     | 
| 
       1484 
     | 
    
         
            -
              });
         
     | 
| 
       1485 
     | 
    
         
            -
              return isKeyedCollection ? KeyedSeq(entries) : isIndexed(collection) ? IndexedSeq(entries) : SetSeq(entries);
         
     | 
| 
       1486 
     | 
    
         
            -
            }
         
     | 
| 
       1487 
     | 
    
         
            -
            function maxFactory(collection, comparator, mapper) {
         
     | 
| 
       1488 
     | 
    
         
            -
              if (!comparator) {
         
     | 
| 
       1489 
     | 
    
         
            -
                comparator = defaultComparator;
         
     | 
| 
       1490 
     | 
    
         
            -
              }
         
     | 
| 
       1491 
     | 
    
         
            -
              if (mapper) {
         
     | 
| 
       1492 
     | 
    
         
            -
                var entry = collection.toSeq().map(function (v, k) {
         
     | 
| 
       1493 
     | 
    
         
            -
                  return [v, mapper(v, k, collection)];
         
     | 
| 
       1494 
     | 
    
         
            -
                }).reduce(function (a, b) {
         
     | 
| 
       1495 
     | 
    
         
            -
                  return maxCompare(comparator, a[1], b[1]) ? b : a;
         
     | 
| 
       1496 
     | 
    
         
            -
                });
         
     | 
| 
       1497 
     | 
    
         
            -
                return entry && entry[0];
         
     | 
| 
       1498 
     | 
    
         
            -
              }
         
     | 
| 
       1499 
     | 
    
         
            -
              return collection.reduce(function (a, b) {
         
     | 
| 
       1500 
     | 
    
         
            -
                return maxCompare(comparator, a, b) ? b : a;
         
     | 
| 
       1501 
     | 
    
         
            -
              });
         
     | 
| 
       1502 
     | 
    
         
            -
            }
         
     | 
| 
       1503 
     | 
    
         
            -
            function maxCompare(comparator, a, b) {
         
     | 
| 
       1504 
     | 
    
         
            -
              var comp = comparator(b, a);
         
     | 
| 
       1505 
     | 
    
         
            -
              // b is considered the new max if the comparator declares them equal, but
         
     | 
| 
       1506 
     | 
    
         
            -
              // they are not equal and b is in fact a nullish value.
         
     | 
| 
       1507 
     | 
    
         
            -
              return comp === 0 && b !== a && (b === undefined || b === null || b !== b) || comp > 0;
         
     | 
| 
       1508 
     | 
    
         
            -
            }
         
     | 
| 
       1509 
     | 
    
         
            -
            function zipWithFactory(keyIter, zipper, iters, zipAll) {
         
     | 
| 
       1510 
     | 
    
         
            -
              var zipSequence = makeSequence(keyIter);
         
     | 
| 
       1511 
     | 
    
         
            -
              var sizes = new ArraySeq(iters).map(function (i) {
         
     | 
| 
       1512 
     | 
    
         
            -
                return i.size;
         
     | 
| 
       1513 
     | 
    
         
            -
              });
         
     | 
| 
       1514 
     | 
    
         
            -
              zipSequence.size = zipAll ? sizes.max() : sizes.min();
         
     | 
| 
       1515 
     | 
    
         
            -
              // Note: this a generic base implementation of __iterate in terms of
         
     | 
| 
       1516 
     | 
    
         
            -
              // __iterator which may be more generically useful in the future.
         
     | 
| 
       1517 
     | 
    
         
            -
              zipSequence.__iterate = function (fn, reverse) {
         
     | 
| 
       1518 
     | 
    
         
            -
                /* generic:
         
     | 
| 
       1519 
     | 
    
         
            -
                var iterator = this.__iterator(ITERATE_ENTRIES, reverse);
         
     | 
| 
       1520 
     | 
    
         
            -
                var step;
         
     | 
| 
       1521 
     | 
    
         
            -
                var iterations = 0;
         
     | 
| 
       1522 
     | 
    
         
            -
                while (!(step = iterator.next()).done) {
         
     | 
| 
       1523 
     | 
    
         
            -
                  iterations++;
         
     | 
| 
       1524 
     | 
    
         
            -
                  if (fn(step.value[1], step.value[0], this) === false) {
         
     | 
| 
       1525 
     | 
    
         
            -
                    break;
         
     | 
| 
       1526 
     | 
    
         
            -
                  }
         
     | 
| 
       1527 
     | 
    
         
            -
                }
         
     | 
| 
       1528 
     | 
    
         
            -
                return iterations;
         
     | 
| 
       1529 
     | 
    
         
            -
                */
         
     | 
| 
       1530 
     | 
    
         
            -
                // indexed:
         
     | 
| 
       1531 
     | 
    
         
            -
                var iterator = this.__iterator(ITERATE_VALUES, reverse);
         
     | 
| 
       1532 
     | 
    
         
            -
                var step;
         
     | 
| 
       1533 
     | 
    
         
            -
                var iterations = 0;
         
     | 
| 
       1534 
     | 
    
         
            -
                while (!(step = iterator.next()).done) {
         
     | 
| 
       1535 
     | 
    
         
            -
                  if (fn(step.value, iterations++, this) === false) {
         
     | 
| 
       1536 
     | 
    
         
            -
                    break;
         
     | 
| 
       1537 
     | 
    
         
            -
                  }
         
     | 
| 
       1538 
     | 
    
         
            -
                }
         
     | 
| 
       1539 
     | 
    
         
            -
                return iterations;
         
     | 
| 
       1540 
     | 
    
         
            -
              };
         
     | 
| 
       1541 
     | 
    
         
            -
              zipSequence.__iteratorUncached = function (type, reverse) {
         
     | 
| 
       1542 
     | 
    
         
            -
                var iterators = iters.map(function (i) {
         
     | 
| 
       1543 
     | 
    
         
            -
                  return i = Collection(i), getIterator(reverse ? i.reverse() : i);
         
     | 
| 
       1544 
     | 
    
         
            -
                });
         
     | 
| 
       1545 
     | 
    
         
            -
                var iterations = 0;
         
     | 
| 
       1546 
     | 
    
         
            -
                var isDone = false;
         
     | 
| 
       1547 
     | 
    
         
            -
                return new Iterator(function () {
         
     | 
| 
       1548 
     | 
    
         
            -
                  var steps;
         
     | 
| 
       1549 
     | 
    
         
            -
                  if (!isDone) {
         
     | 
| 
       1550 
     | 
    
         
            -
                    steps = iterators.map(function (i) {
         
     | 
| 
       1551 
     | 
    
         
            -
                      return i.next();
         
     | 
| 
       1552 
     | 
    
         
            -
                    });
         
     | 
| 
       1553 
     | 
    
         
            -
                    isDone = zipAll ? steps.every(function (s) {
         
     | 
| 
       1554 
     | 
    
         
            -
                      return s.done;
         
     | 
| 
       1555 
     | 
    
         
            -
                    }) : steps.some(function (s) {
         
     | 
| 
       1556 
     | 
    
         
            -
                      return s.done;
         
     | 
| 
       1557 
     | 
    
         
            -
                    });
         
     | 
| 
       1558 
     | 
    
         
            -
                  }
         
     | 
| 
       1559 
     | 
    
         
            -
                  if (isDone) {
         
     | 
| 
       1560 
     | 
    
         
            -
                    return iteratorDone();
         
     | 
| 
       1561 
     | 
    
         
            -
                  }
         
     | 
| 
       1562 
     | 
    
         
            -
                  return iteratorValue(type, iterations++, zipper.apply(null, steps.map(function (s) {
         
     | 
| 
       1563 
     | 
    
         
            -
                    return s.value;
         
     | 
| 
       1564 
     | 
    
         
            -
                  })));
         
     | 
| 
       1565 
     | 
    
         
            -
                });
         
     | 
| 
       1566 
     | 
    
         
            -
              };
         
     | 
| 
       1567 
     | 
    
         
            -
              return zipSequence;
         
     | 
| 
       1568 
     | 
    
         
            -
            }
         
     | 
| 
       1569 
     | 
    
         
            -
             
     | 
| 
       1570 
     | 
    
         
            -
            // #pragma Helper Functions
         
     | 
| 
       1571 
     | 
    
         
            -
             
     | 
| 
       1572 
     | 
    
         
            -
            function reify(iter, seq) {
         
     | 
| 
       1573 
     | 
    
         
            -
              return iter === seq ? iter : isSeq(iter) ? seq : iter.constructor(seq);
         
     | 
| 
       1574 
     | 
    
         
            -
            }
         
     | 
| 
       1575 
     | 
    
         
            -
            function validateEntry(entry) {
         
     | 
| 
       1576 
     | 
    
         
            -
              if (entry !== Object(entry)) {
         
     | 
| 
       1577 
     | 
    
         
            -
                throw new TypeError('Expected [K, V] tuple: ' + entry);
         
     | 
| 
       1578 
     | 
    
         
            -
              }
         
     | 
| 
       1579 
     | 
    
         
            -
            }
         
     | 
| 
       1580 
     | 
    
         
            -
            function collectionClass(collection) {
         
     | 
| 
       1581 
     | 
    
         
            -
              return isKeyed(collection) ? KeyedCollection : isIndexed(collection) ? IndexedCollection : SetCollection;
         
     | 
| 
       1582 
     | 
    
         
            -
            }
         
     | 
| 
       1583 
     | 
    
         
            -
            function makeSequence(collection) {
         
     | 
| 
       1584 
     | 
    
         
            -
              return Object.create((isKeyed(collection) ? KeyedSeq : isIndexed(collection) ? IndexedSeq : SetSeq).prototype);
         
     | 
| 
       1585 
     | 
    
         
            -
            }
         
     | 
| 
       1586 
     | 
    
         
            -
            function cacheResultThrough() {
         
     | 
| 
       1587 
     | 
    
         
            -
              if (this._iter.cacheResult) {
         
     | 
| 
       1588 
     | 
    
         
            -
                this._iter.cacheResult();
         
     | 
| 
       1589 
     | 
    
         
            -
                this.size = this._iter.size;
         
     | 
| 
       1590 
     | 
    
         
            -
                return this;
         
     | 
| 
       1591 
     | 
    
         
            -
              }
         
     | 
| 
       1592 
     | 
    
         
            -
              return Seq.prototype.cacheResult.call(this);
         
     | 
| 
       1593 
     | 
    
         
            -
            }
         
     | 
| 
       1594 
     | 
    
         
            -
            function defaultComparator(a, b) {
         
     | 
| 
       1595 
     | 
    
         
            -
              if (a === undefined && b === undefined) {
         
     | 
| 
       1596 
     | 
    
         
            -
                return 0;
         
     | 
| 
       1597 
     | 
    
         
            -
              }
         
     | 
| 
       1598 
     | 
    
         
            -
              if (a === undefined) {
         
     | 
| 
       1599 
     | 
    
         
            -
                return 1;
         
     | 
| 
       1600 
     | 
    
         
            -
              }
         
     | 
| 
       1601 
     | 
    
         
            -
              if (b === undefined) {
         
     | 
| 
       1602 
     | 
    
         
            -
                return -1;
         
     | 
| 
       1603 
     | 
    
         
            -
              }
         
     | 
| 
       1604 
     | 
    
         
            -
              return a > b ? 1 : a < b ? -1 : 0;
         
     | 
| 
       1605 
     | 
    
         
            -
            }
         
     | 
| 
       1606 
     | 
    
         
            -
            function arrCopy(arr, offset) {
         
     | 
| 
       1607 
     | 
    
         
            -
              offset = offset || 0;
         
     | 
| 
       1608 
     | 
    
         
            -
              var len = Math.max(0, arr.length - offset);
         
     | 
| 
       1609 
     | 
    
         
            -
              var newArr = new Array(len);
         
     | 
| 
       1610 
     | 
    
         
            -
              for (var ii = 0; ii < len; ii++) {
         
     | 
| 
       1611 
     | 
    
         
            -
                newArr[ii] = arr[ii + offset];
         
     | 
| 
       1612 
     | 
    
         
            -
              }
         
     | 
| 
       1613 
     | 
    
         
            -
              return newArr;
         
     | 
| 
       1614 
     | 
    
         
            -
            }
         
     | 
| 
       1615 
     | 
    
         
            -
            function invariant(condition, error) {
         
     | 
| 
       1616 
     | 
    
         
            -
              if (!condition) {
         
     | 
| 
       1617 
     | 
    
         
            -
                throw new Error(error);
         
     | 
| 
       1618 
     | 
    
         
            -
              }
         
     | 
| 
       1619 
     | 
    
         
            -
            }
         
     | 
| 
       1620 
     | 
    
         
            -
            function assertNotInfinite(size) {
         
     | 
| 
       1621 
     | 
    
         
            -
              invariant(size !== Infinity, 'Cannot perform this action with an infinite size.');
         
     | 
| 
       1622 
     | 
    
         
            -
            }
         
     | 
| 
       1623 
     | 
    
         
            -
            function coerceKeyPath(keyPath) {
         
     | 
| 
       1624 
     | 
    
         
            -
              if (isArrayLike(keyPath) && typeof keyPath !== 'string') {
         
     | 
| 
       1625 
     | 
    
         
            -
                return keyPath;
         
     | 
| 
       1626 
     | 
    
         
            -
              }
         
     | 
| 
       1627 
     | 
    
         
            -
              if (isOrdered(keyPath)) {
         
     | 
| 
       1628 
     | 
    
         
            -
                return keyPath.toArray();
         
     | 
| 
       1629 
     | 
    
         
            -
              }
         
     | 
| 
       1630 
     | 
    
         
            -
              throw new TypeError('Invalid keyPath: expected Ordered Collection or Array: ' + keyPath);
         
     | 
| 
       1631 
     | 
    
         
            -
            }
         
     | 
| 
       1632 
     | 
    
         
            -
            var toString = Object.prototype.toString;
         
     | 
| 
       1633 
     | 
    
         
            -
            function isPlainObject(value) {
         
     | 
| 
       1634 
     | 
    
         
            -
              // The base prototype's toString deals with Argument objects and native namespaces like Math
         
     | 
| 
       1635 
     | 
    
         
            -
              if (!value || typeof value !== 'object' || toString.call(value) !== '[object Object]') {
         
     | 
| 
       1636 
     | 
    
         
            -
                return false;
         
     | 
| 
       1637 
     | 
    
         
            -
              }
         
     | 
| 
       1638 
     | 
    
         
            -
              var proto = Object.getPrototypeOf(value);
         
     | 
| 
       1639 
     | 
    
         
            -
              if (proto === null) {
         
     | 
| 
       1640 
     | 
    
         
            -
                return true;
         
     | 
| 
       1641 
     | 
    
         
            -
              }
         
     | 
| 
       1642 
     | 
    
         
            -
             
     | 
| 
       1643 
     | 
    
         
            -
              // Iteratively going up the prototype chain is needed for cross-realm environments (differing contexts, iframes, etc)
         
     | 
| 
       1644 
     | 
    
         
            -
              var parentProto = proto;
         
     | 
| 
       1645 
     | 
    
         
            -
              var nextProto = Object.getPrototypeOf(proto);
         
     | 
| 
       1646 
     | 
    
         
            -
              while (nextProto !== null) {
         
     | 
| 
       1647 
     | 
    
         
            -
                parentProto = nextProto;
         
     | 
| 
       1648 
     | 
    
         
            -
                nextProto = Object.getPrototypeOf(parentProto);
         
     | 
| 
       1649 
     | 
    
         
            -
              }
         
     | 
| 
       1650 
     | 
    
         
            -
              return parentProto === proto;
         
     | 
| 
       1651 
     | 
    
         
            -
            }
         
     | 
| 
       1652 
     | 
    
         
            -
             
     | 
| 
       1653 
     | 
    
         
            -
            /**
         
     | 
| 
       1654 
     | 
    
         
            -
             * Returns true if the value is a potentially-persistent data structure, either
         
     | 
| 
       1655 
     | 
    
         
            -
             * provided by Immutable.js or a plain Array or Object.
         
     | 
| 
       1656 
     | 
    
         
            -
             */
         
     | 
| 
       1657 
     | 
    
         
            -
            function isDataStructure(value) {
         
     | 
| 
       1658 
     | 
    
         
            -
              return typeof value === 'object' && (isImmutable(value) || Array.isArray(value) || isPlainObject(value));
         
     | 
| 
       1659 
     | 
    
         
            -
            }
         
     | 
| 
       1660 
     | 
    
         
            -
            function quoteString(value) {
         
     | 
| 
       1661 
     | 
    
         
            -
              try {
         
     | 
| 
       1662 
     | 
    
         
            -
                return typeof value === 'string' ? JSON.stringify(value) : String(value);
         
     | 
| 
       1663 
     | 
    
         
            -
              } catch (_ignoreError) {
         
     | 
| 
       1664 
     | 
    
         
            -
                return JSON.stringify(value);
         
     | 
| 
       1665 
     | 
    
         
            -
              }
         
     | 
| 
       1666 
     | 
    
         
            -
            }
         
     | 
| 
       1667 
     | 
    
         
            -
            function has(collection, key) {
         
     | 
| 
       1668 
     | 
    
         
            -
              return isImmutable(collection) ? collection.has(key) : isDataStructure(collection) && hasOwnProperty.call(collection, key);
         
     | 
| 
       1669 
     | 
    
         
            -
            }
         
     | 
| 
       1670 
     | 
    
         
            -
            function get(collection, key, notSetValue) {
         
     | 
| 
       1671 
     | 
    
         
            -
              return isImmutable(collection) ? collection.get(key, notSetValue) : !has(collection, key) ? notSetValue : typeof collection.get === 'function' ? collection.get(key) : collection[key];
         
     | 
| 
       1672 
     | 
    
         
            -
            }
         
     | 
| 
       1673 
     | 
    
         
            -
            function shallowCopy(from) {
         
     | 
| 
       1674 
     | 
    
         
            -
              if (Array.isArray(from)) {
         
     | 
| 
       1675 
     | 
    
         
            -
                return arrCopy(from);
         
     | 
| 
       1676 
     | 
    
         
            -
              }
         
     | 
| 
       1677 
     | 
    
         
            -
              var to = {};
         
     | 
| 
       1678 
     | 
    
         
            -
              for (var key in from) {
         
     | 
| 
       1679 
     | 
    
         
            -
                if (hasOwnProperty.call(from, key)) {
         
     | 
| 
       1680 
     | 
    
         
            -
                  to[key] = from[key];
         
     | 
| 
       1681 
     | 
    
         
            -
                }
         
     | 
| 
       1682 
     | 
    
         
            -
              }
         
     | 
| 
       1683 
     | 
    
         
            -
              return to;
         
     | 
| 
       1684 
     | 
    
         
            -
            }
         
     | 
| 
       1685 
     | 
    
         
            -
            function remove(collection, key) {
         
     | 
| 
       1686 
     | 
    
         
            -
              if (!isDataStructure(collection)) {
         
     | 
| 
       1687 
     | 
    
         
            -
                throw new TypeError('Cannot update non-data-structure value: ' + collection);
         
     | 
| 
       1688 
     | 
    
         
            -
              }
         
     | 
| 
       1689 
     | 
    
         
            -
              if (isImmutable(collection)) {
         
     | 
| 
       1690 
     | 
    
         
            -
                if (!collection.remove) {
         
     | 
| 
       1691 
     | 
    
         
            -
                  throw new TypeError('Cannot update immutable value without .remove() method: ' + collection);
         
     | 
| 
       1692 
     | 
    
         
            -
                }
         
     | 
| 
       1693 
     | 
    
         
            -
                return collection.remove(key);
         
     | 
| 
       1694 
     | 
    
         
            -
              }
         
     | 
| 
       1695 
     | 
    
         
            -
              if (!hasOwnProperty.call(collection, key)) {
         
     | 
| 
       1696 
     | 
    
         
            -
                return collection;
         
     | 
| 
       1697 
     | 
    
         
            -
              }
         
     | 
| 
       1698 
     | 
    
         
            -
              var collectionCopy = shallowCopy(collection);
         
     | 
| 
       1699 
     | 
    
         
            -
              if (Array.isArray(collectionCopy)) {
         
     | 
| 
       1700 
     | 
    
         
            -
                collectionCopy.splice(key, 1);
         
     | 
| 
       1701 
     | 
    
         
            -
              } else {
         
     | 
| 
       1702 
     | 
    
         
            -
                delete collectionCopy[key];
         
     | 
| 
       1703 
     | 
    
         
            -
              }
         
     | 
| 
       1704 
     | 
    
         
            -
              return collectionCopy;
         
     | 
| 
       1705 
     | 
    
         
            -
            }
         
     | 
| 
       1706 
     | 
    
         
            -
            function set(collection, key, value) {
         
     | 
| 
       1707 
     | 
    
         
            -
              if (!isDataStructure(collection)) {
         
     | 
| 
       1708 
     | 
    
         
            -
                throw new TypeError('Cannot update non-data-structure value: ' + collection);
         
     | 
| 
       1709 
     | 
    
         
            -
              }
         
     | 
| 
       1710 
     | 
    
         
            -
              if (isImmutable(collection)) {
         
     | 
| 
       1711 
     | 
    
         
            -
                if (!collection.set) {
         
     | 
| 
       1712 
     | 
    
         
            -
                  throw new TypeError('Cannot update immutable value without .set() method: ' + collection);
         
     | 
| 
       1713 
     | 
    
         
            -
                }
         
     | 
| 
       1714 
     | 
    
         
            -
                return collection.set(key, value);
         
     | 
| 
       1715 
     | 
    
         
            -
              }
         
     | 
| 
       1716 
     | 
    
         
            -
              if (hasOwnProperty.call(collection, key) && value === collection[key]) {
         
     | 
| 
       1717 
     | 
    
         
            -
                return collection;
         
     | 
| 
       1718 
     | 
    
         
            -
              }
         
     | 
| 
       1719 
     | 
    
         
            -
              var collectionCopy = shallowCopy(collection);
         
     | 
| 
       1720 
     | 
    
         
            -
              collectionCopy[key] = value;
         
     | 
| 
       1721 
     | 
    
         
            -
              return collectionCopy;
         
     | 
| 
       1722 
     | 
    
         
            -
            }
         
     | 
| 
       1723 
     | 
    
         
            -
            function updateIn$1(collection, keyPath, notSetValue, updater) {
         
     | 
| 
       1724 
     | 
    
         
            -
              if (!updater) {
         
     | 
| 
       1725 
     | 
    
         
            -
                updater = notSetValue;
         
     | 
| 
       1726 
     | 
    
         
            -
                notSetValue = undefined;
         
     | 
| 
       1727 
     | 
    
         
            -
              }
         
     | 
| 
       1728 
     | 
    
         
            -
              var updatedValue = updateInDeeply(isImmutable(collection), collection, coerceKeyPath(keyPath), 0, notSetValue, updater);
         
     | 
| 
       1729 
     | 
    
         
            -
              return updatedValue === NOT_SET ? notSetValue : updatedValue;
         
     | 
| 
       1730 
     | 
    
         
            -
            }
         
     | 
| 
       1731 
     | 
    
         
            -
            function updateInDeeply(inImmutable, existing, keyPath, i, notSetValue, updater) {
         
     | 
| 
       1732 
     | 
    
         
            -
              var wasNotSet = existing === NOT_SET;
         
     | 
| 
       1733 
     | 
    
         
            -
              if (i === keyPath.length) {
         
     | 
| 
       1734 
     | 
    
         
            -
                var existingValue = wasNotSet ? notSetValue : existing;
         
     | 
| 
       1735 
     | 
    
         
            -
                var newValue = updater(existingValue);
         
     | 
| 
       1736 
     | 
    
         
            -
                return newValue === existingValue ? existing : newValue;
         
     | 
| 
       1737 
     | 
    
         
            -
              }
         
     | 
| 
       1738 
     | 
    
         
            -
              if (!wasNotSet && !isDataStructure(existing)) {
         
     | 
| 
       1739 
     | 
    
         
            -
                throw new TypeError('Cannot update within non-data-structure value in path [' + keyPath.slice(0, i).map(quoteString) + ']: ' + existing);
         
     | 
| 
       1740 
     | 
    
         
            -
              }
         
     | 
| 
       1741 
     | 
    
         
            -
              var key = keyPath[i];
         
     | 
| 
       1742 
     | 
    
         
            -
              var nextExisting = wasNotSet ? NOT_SET : get(existing, key, NOT_SET);
         
     | 
| 
       1743 
     | 
    
         
            -
              var nextUpdated = updateInDeeply(nextExisting === NOT_SET ? inImmutable : isImmutable(nextExisting), nextExisting, keyPath, i + 1, notSetValue, updater);
         
     | 
| 
       1744 
     | 
    
         
            -
              return nextUpdated === nextExisting ? existing : nextUpdated === NOT_SET ? remove(existing, key) : set(wasNotSet ? inImmutable ? emptyMap() : {} : existing, key, nextUpdated);
         
     | 
| 
       1745 
     | 
    
         
            -
            }
         
     | 
| 
       1746 
     | 
    
         
            -
            function setIn$1(collection, keyPath, value) {
         
     | 
| 
       1747 
     | 
    
         
            -
              return updateIn$1(collection, keyPath, NOT_SET, function () {
         
     | 
| 
       1748 
     | 
    
         
            -
                return value;
         
     | 
| 
       1749 
     | 
    
         
            -
              });
         
     | 
| 
       1750 
     | 
    
         
            -
            }
         
     | 
| 
       1751 
     | 
    
         
            -
            function setIn(keyPath, v) {
         
     | 
| 
       1752 
     | 
    
         
            -
              return setIn$1(this, keyPath, v);
         
     | 
| 
       1753 
     | 
    
         
            -
            }
         
     | 
| 
       1754 
     | 
    
         
            -
            function removeIn(collection, keyPath) {
         
     | 
| 
       1755 
     | 
    
         
            -
              return updateIn$1(collection, keyPath, function () {
         
     | 
| 
       1756 
     | 
    
         
            -
                return NOT_SET;
         
     | 
| 
       1757 
     | 
    
         
            -
              });
         
     | 
| 
       1758 
     | 
    
         
            -
            }
         
     | 
| 
       1759 
     | 
    
         
            -
            function deleteIn(keyPath) {
         
     | 
| 
       1760 
     | 
    
         
            -
              return removeIn(this, keyPath);
         
     | 
| 
       1761 
     | 
    
         
            -
            }
         
     | 
| 
       1762 
     | 
    
         
            -
            function update$1(collection, key, notSetValue, updater) {
         
     | 
| 
       1763 
     | 
    
         
            -
              return updateIn$1(collection, [key], notSetValue, updater);
         
     | 
| 
       1764 
     | 
    
         
            -
            }
         
     | 
| 
       1765 
     | 
    
         
            -
            function update(key, notSetValue, updater) {
         
     | 
| 
       1766 
     | 
    
         
            -
              return arguments.length === 1 ? key(this) : update$1(this, key, notSetValue, updater);
         
     | 
| 
       1767 
     | 
    
         
            -
            }
         
     | 
| 
       1768 
     | 
    
         
            -
            function updateIn(keyPath, notSetValue, updater) {
         
     | 
| 
       1769 
     | 
    
         
            -
              return updateIn$1(this, keyPath, notSetValue, updater);
         
     | 
| 
       1770 
     | 
    
         
            -
            }
         
     | 
| 
       1771 
     | 
    
         
            -
            function merge$1() {
         
     | 
| 
       1772 
     | 
    
         
            -
              var iters = [],
         
     | 
| 
       1773 
     | 
    
         
            -
                len = arguments.length;
         
     | 
| 
       1774 
     | 
    
         
            -
              while (len--) iters[len] = arguments[len];
         
     | 
| 
       1775 
     | 
    
         
            -
              return mergeIntoKeyedWith(this, iters);
         
     | 
| 
       1776 
     | 
    
         
            -
            }
         
     | 
| 
       1777 
     | 
    
         
            -
            function mergeWith$1(merger) {
         
     | 
| 
       1778 
     | 
    
         
            -
              var iters = [],
         
     | 
| 
       1779 
     | 
    
         
            -
                len = arguments.length - 1;
         
     | 
| 
       1780 
     | 
    
         
            -
              while (len-- > 0) iters[len] = arguments[len + 1];
         
     | 
| 
       1781 
     | 
    
         
            -
              if (typeof merger !== 'function') {
         
     | 
| 
       1782 
     | 
    
         
            -
                throw new TypeError('Invalid merger function: ' + merger);
         
     | 
| 
       1783 
     | 
    
         
            -
              }
         
     | 
| 
       1784 
     | 
    
         
            -
              return mergeIntoKeyedWith(this, iters, merger);
         
     | 
| 
       1785 
     | 
    
         
            -
            }
         
     | 
| 
       1786 
     | 
    
         
            -
            function mergeIntoKeyedWith(collection, collections, merger) {
         
     | 
| 
       1787 
     | 
    
         
            -
              var iters = [];
         
     | 
| 
       1788 
     | 
    
         
            -
              for (var ii = 0; ii < collections.length; ii++) {
         
     | 
| 
       1789 
     | 
    
         
            -
                var collection$1 = KeyedCollection(collections[ii]);
         
     | 
| 
       1790 
     | 
    
         
            -
                if (collection$1.size !== 0) {
         
     | 
| 
       1791 
     | 
    
         
            -
                  iters.push(collection$1);
         
     | 
| 
       1792 
     | 
    
         
            -
                }
         
     | 
| 
       1793 
     | 
    
         
            -
              }
         
     | 
| 
       1794 
     | 
    
         
            -
              if (iters.length === 0) {
         
     | 
| 
       1795 
     | 
    
         
            -
                return collection;
         
     | 
| 
       1796 
     | 
    
         
            -
              }
         
     | 
| 
       1797 
     | 
    
         
            -
              if (collection.toSeq().size === 0 && !collection.__ownerID && iters.length === 1) {
         
     | 
| 
       1798 
     | 
    
         
            -
                return collection.constructor(iters[0]);
         
     | 
| 
       1799 
     | 
    
         
            -
              }
         
     | 
| 
       1800 
     | 
    
         
            -
              return collection.withMutations(function (collection) {
         
     | 
| 
       1801 
     | 
    
         
            -
                var mergeIntoCollection = merger ? function (value, key) {
         
     | 
| 
       1802 
     | 
    
         
            -
                  update$1(collection, key, NOT_SET, function (oldVal) {
         
     | 
| 
       1803 
     | 
    
         
            -
                    return oldVal === NOT_SET ? value : merger(oldVal, value, key);
         
     | 
| 
       1804 
     | 
    
         
            -
                  });
         
     | 
| 
       1805 
     | 
    
         
            -
                } : function (value, key) {
         
     | 
| 
       1806 
     | 
    
         
            -
                  collection.set(key, value);
         
     | 
| 
       1807 
     | 
    
         
            -
                };
         
     | 
| 
       1808 
     | 
    
         
            -
                for (var ii = 0; ii < iters.length; ii++) {
         
     | 
| 
       1809 
     | 
    
         
            -
                  iters[ii].forEach(mergeIntoCollection);
         
     | 
| 
       1810 
     | 
    
         
            -
                }
         
     | 
| 
       1811 
     | 
    
         
            -
              });
         
     | 
| 
       1812 
     | 
    
         
            -
            }
         
     | 
| 
       1813 
     | 
    
         
            -
            function merge(collection) {
         
     | 
| 
       1814 
     | 
    
         
            -
              var sources = [],
         
     | 
| 
       1815 
     | 
    
         
            -
                len = arguments.length - 1;
         
     | 
| 
       1816 
     | 
    
         
            -
              while (len-- > 0) sources[len] = arguments[len + 1];
         
     | 
| 
       1817 
     | 
    
         
            -
              return mergeWithSources(collection, sources);
         
     | 
| 
       1818 
     | 
    
         
            -
            }
         
     | 
| 
       1819 
     | 
    
         
            -
            function mergeWith(merger, collection) {
         
     | 
| 
       1820 
     | 
    
         
            -
              var sources = [],
         
     | 
| 
       1821 
     | 
    
         
            -
                len = arguments.length - 2;
         
     | 
| 
       1822 
     | 
    
         
            -
              while (len-- > 0) sources[len] = arguments[len + 2];
         
     | 
| 
       1823 
     | 
    
         
            -
              return mergeWithSources(collection, sources, merger);
         
     | 
| 
       1824 
     | 
    
         
            -
            }
         
     | 
| 
       1825 
     | 
    
         
            -
            function mergeDeep$1(collection) {
         
     | 
| 
       1826 
     | 
    
         
            -
              var sources = [],
         
     | 
| 
       1827 
     | 
    
         
            -
                len = arguments.length - 1;
         
     | 
| 
       1828 
     | 
    
         
            -
              while (len-- > 0) sources[len] = arguments[len + 1];
         
     | 
| 
       1829 
     | 
    
         
            -
              return mergeDeepWithSources(collection, sources);
         
     | 
| 
       1830 
     | 
    
         
            -
            }
         
     | 
| 
       1831 
     | 
    
         
            -
            function mergeDeepWith$1(merger, collection) {
         
     | 
| 
       1832 
     | 
    
         
            -
              var sources = [],
         
     | 
| 
       1833 
     | 
    
         
            -
                len = arguments.length - 2;
         
     | 
| 
       1834 
     | 
    
         
            -
              while (len-- > 0) sources[len] = arguments[len + 2];
         
     | 
| 
       1835 
     | 
    
         
            -
              return mergeDeepWithSources(collection, sources, merger);
         
     | 
| 
       1836 
     | 
    
         
            -
            }
         
     | 
| 
       1837 
     | 
    
         
            -
            function mergeDeepWithSources(collection, sources, merger) {
         
     | 
| 
       1838 
     | 
    
         
            -
              return mergeWithSources(collection, sources, deepMergerWith(merger));
         
     | 
| 
       1839 
     | 
    
         
            -
            }
         
     | 
| 
       1840 
     | 
    
         
            -
            function mergeWithSources(collection, sources, merger) {
         
     | 
| 
       1841 
     | 
    
         
            -
              if (!isDataStructure(collection)) {
         
     | 
| 
       1842 
     | 
    
         
            -
                throw new TypeError('Cannot merge into non-data-structure value: ' + collection);
         
     | 
| 
       1843 
     | 
    
         
            -
              }
         
     | 
| 
       1844 
     | 
    
         
            -
              if (isImmutable(collection)) {
         
     | 
| 
       1845 
     | 
    
         
            -
                return typeof merger === 'function' && collection.mergeWith ? collection.mergeWith.apply(collection, [merger].concat(sources)) : collection.merge ? collection.merge.apply(collection, sources) : collection.concat.apply(collection, sources);
         
     | 
| 
       1846 
     | 
    
         
            -
              }
         
     | 
| 
       1847 
     | 
    
         
            -
              var isArray = Array.isArray(collection);
         
     | 
| 
       1848 
     | 
    
         
            -
              var merged = collection;
         
     | 
| 
       1849 
     | 
    
         
            -
              var Collection = isArray ? IndexedCollection : KeyedCollection;
         
     | 
| 
       1850 
     | 
    
         
            -
              var mergeItem = isArray ? function (value) {
         
     | 
| 
       1851 
     | 
    
         
            -
                // Copy on write
         
     | 
| 
       1852 
     | 
    
         
            -
                if (merged === collection) {
         
     | 
| 
       1853 
     | 
    
         
            -
                  merged = shallowCopy(merged);
         
     | 
| 
       1854 
     | 
    
         
            -
                }
         
     | 
| 
       1855 
     | 
    
         
            -
                merged.push(value);
         
     | 
| 
       1856 
     | 
    
         
            -
              } : function (value, key) {
         
     | 
| 
       1857 
     | 
    
         
            -
                var hasVal = hasOwnProperty.call(merged, key);
         
     | 
| 
       1858 
     | 
    
         
            -
                var nextVal = hasVal && merger ? merger(merged[key], value, key) : value;
         
     | 
| 
       1859 
     | 
    
         
            -
                if (!hasVal || nextVal !== merged[key]) {
         
     | 
| 
       1860 
     | 
    
         
            -
                  // Copy on write
         
     | 
| 
       1861 
     | 
    
         
            -
                  if (merged === collection) {
         
     | 
| 
       1862 
     | 
    
         
            -
                    merged = shallowCopy(merged);
         
     | 
| 
       1863 
     | 
    
         
            -
                  }
         
     | 
| 
       1864 
     | 
    
         
            -
                  merged[key] = nextVal;
         
     | 
| 
       1865 
     | 
    
         
            -
                }
         
     | 
| 
       1866 
     | 
    
         
            -
              };
         
     | 
| 
       1867 
     | 
    
         
            -
              for (var i = 0; i < sources.length; i++) {
         
     | 
| 
       1868 
     | 
    
         
            -
                Collection(sources[i]).forEach(mergeItem);
         
     | 
| 
       1869 
     | 
    
         
            -
              }
         
     | 
| 
       1870 
     | 
    
         
            -
              return merged;
         
     | 
| 
       1871 
     | 
    
         
            -
            }
         
     | 
| 
       1872 
     | 
    
         
            -
            function deepMergerWith(merger) {
         
     | 
| 
       1873 
     | 
    
         
            -
              function deepMerger(oldValue, newValue, key) {
         
     | 
| 
       1874 
     | 
    
         
            -
                return isDataStructure(oldValue) && isDataStructure(newValue) && areMergeable(oldValue, newValue) ? mergeWithSources(oldValue, [newValue], deepMerger) : merger ? merger(oldValue, newValue, key) : newValue;
         
     | 
| 
       1875 
     | 
    
         
            -
              }
         
     | 
| 
       1876 
     | 
    
         
            -
              return deepMerger;
         
     | 
| 
       1877 
     | 
    
         
            -
            }
         
     | 
| 
       1878 
     | 
    
         
            -
             
     | 
| 
       1879 
     | 
    
         
            -
            /**
         
     | 
| 
       1880 
     | 
    
         
            -
             * It's unclear what the desired behavior is for merging two collections that
         
     | 
| 
       1881 
     | 
    
         
            -
             * fall into separate categories between keyed, indexed, or set-like, so we only
         
     | 
| 
       1882 
     | 
    
         
            -
             * consider them mergeable if they fall into the same category.
         
     | 
| 
       1883 
     | 
    
         
            -
             */
         
     | 
| 
       1884 
     | 
    
         
            -
            function areMergeable(oldDataStructure, newDataStructure) {
         
     | 
| 
       1885 
     | 
    
         
            -
              var oldSeq = Seq(oldDataStructure);
         
     | 
| 
       1886 
     | 
    
         
            -
              var newSeq = Seq(newDataStructure);
         
     | 
| 
       1887 
     | 
    
         
            -
              // This logic assumes that a sequence can only fall into one of the three
         
     | 
| 
       1888 
     | 
    
         
            -
              // categories mentioned above (since there's no `isSetLike()` method).
         
     | 
| 
       1889 
     | 
    
         
            -
              return isIndexed(oldSeq) === isIndexed(newSeq) && isKeyed(oldSeq) === isKeyed(newSeq);
         
     | 
| 
       1890 
     | 
    
         
            -
            }
         
     | 
| 
       1891 
     | 
    
         
            -
            function mergeDeep() {
         
     | 
| 
       1892 
     | 
    
         
            -
              var iters = [],
         
     | 
| 
       1893 
     | 
    
         
            -
                len = arguments.length;
         
     | 
| 
       1894 
     | 
    
         
            -
              while (len--) iters[len] = arguments[len];
         
     | 
| 
       1895 
     | 
    
         
            -
              return mergeDeepWithSources(this, iters);
         
     | 
| 
       1896 
     | 
    
         
            -
            }
         
     | 
| 
       1897 
     | 
    
         
            -
            function mergeDeepWith(merger) {
         
     | 
| 
       1898 
     | 
    
         
            -
              var iters = [],
         
     | 
| 
       1899 
     | 
    
         
            -
                len = arguments.length - 1;
         
     | 
| 
       1900 
     | 
    
         
            -
              while (len-- > 0) iters[len] = arguments[len + 1];
         
     | 
| 
       1901 
     | 
    
         
            -
              return mergeDeepWithSources(this, iters, merger);
         
     | 
| 
       1902 
     | 
    
         
            -
            }
         
     | 
| 
       1903 
     | 
    
         
            -
            function mergeIn(keyPath) {
         
     | 
| 
       1904 
     | 
    
         
            -
              var iters = [],
         
     | 
| 
       1905 
     | 
    
         
            -
                len = arguments.length - 1;
         
     | 
| 
       1906 
     | 
    
         
            -
              while (len-- > 0) iters[len] = arguments[len + 1];
         
     | 
| 
       1907 
     | 
    
         
            -
              return updateIn$1(this, keyPath, emptyMap(), function (m) {
         
     | 
| 
       1908 
     | 
    
         
            -
                return mergeWithSources(m, iters);
         
     | 
| 
       1909 
     | 
    
         
            -
              });
         
     | 
| 
       1910 
     | 
    
         
            -
            }
         
     | 
| 
       1911 
     | 
    
         
            -
            function mergeDeepIn(keyPath) {
         
     | 
| 
       1912 
     | 
    
         
            -
              var iters = [],
         
     | 
| 
       1913 
     | 
    
         
            -
                len = arguments.length - 1;
         
     | 
| 
       1914 
     | 
    
         
            -
              while (len-- > 0) iters[len] = arguments[len + 1];
         
     | 
| 
       1915 
     | 
    
         
            -
              return updateIn$1(this, keyPath, emptyMap(), function (m) {
         
     | 
| 
       1916 
     | 
    
         
            -
                return mergeDeepWithSources(m, iters);
         
     | 
| 
       1917 
     | 
    
         
            -
              });
         
     | 
| 
       1918 
     | 
    
         
            -
            }
         
     | 
| 
       1919 
     | 
    
         
            -
            function withMutations(fn) {
         
     | 
| 
       1920 
     | 
    
         
            -
              var mutable = this.asMutable();
         
     | 
| 
       1921 
     | 
    
         
            -
              fn(mutable);
         
     | 
| 
       1922 
     | 
    
         
            -
              return mutable.wasAltered() ? mutable.__ensureOwner(this.__ownerID) : this;
         
     | 
| 
       1923 
     | 
    
         
            -
            }
         
     | 
| 
       1924 
     | 
    
         
            -
            function asMutable() {
         
     | 
| 
       1925 
     | 
    
         
            -
              return this.__ownerID ? this : this.__ensureOwner(new OwnerID());
         
     | 
| 
       1926 
     | 
    
         
            -
            }
         
     | 
| 
       1927 
     | 
    
         
            -
            function asImmutable() {
         
     | 
| 
       1928 
     | 
    
         
            -
              return this.__ensureOwner();
         
     | 
| 
       1929 
     | 
    
         
            -
            }
         
     | 
| 
       1930 
     | 
    
         
            -
            function wasAltered() {
         
     | 
| 
       1931 
     | 
    
         
            -
              return this.__altered;
         
     | 
| 
       1932 
     | 
    
         
            -
            }
         
     | 
| 
       1933 
     | 
    
         
            -
            var Map = /*@__PURE__*/function (KeyedCollection) {
         
     | 
| 
       1934 
     | 
    
         
            -
              function Map(value) {
         
     | 
| 
       1935 
     | 
    
         
            -
                // eslint-disable-next-line no-constructor-return
         
     | 
| 
       1936 
     | 
    
         
            -
                return value === undefined || value === null ? emptyMap() : isMap(value) && !isOrdered(value) ? value : emptyMap().withMutations(function (map) {
         
     | 
| 
       1937 
     | 
    
         
            -
                  var iter = KeyedCollection(value);
         
     | 
| 
       1938 
     | 
    
         
            -
                  assertNotInfinite(iter.size);
         
     | 
| 
       1939 
     | 
    
         
            -
                  iter.forEach(function (v, k) {
         
     | 
| 
       1940 
     | 
    
         
            -
                    return map.set(k, v);
         
     | 
| 
       1941 
     | 
    
         
            -
                  });
         
     | 
| 
       1942 
     | 
    
         
            -
                });
         
     | 
| 
       1943 
     | 
    
         
            -
              }
         
     | 
| 
       1944 
     | 
    
         
            -
              if (KeyedCollection) Map.__proto__ = KeyedCollection;
         
     | 
| 
       1945 
     | 
    
         
            -
              Map.prototype = Object.create(KeyedCollection && KeyedCollection.prototype);
         
     | 
| 
       1946 
     | 
    
         
            -
              Map.prototype.constructor = Map;
         
     | 
| 
       1947 
     | 
    
         
            -
              Map.of = function of() {
         
     | 
| 
       1948 
     | 
    
         
            -
                var keyValues = [],
         
     | 
| 
       1949 
     | 
    
         
            -
                  len = arguments.length;
         
     | 
| 
       1950 
     | 
    
         
            -
                while (len--) keyValues[len] = arguments[len];
         
     | 
| 
       1951 
     | 
    
         
            -
                return emptyMap().withMutations(function (map) {
         
     | 
| 
       1952 
     | 
    
         
            -
                  for (var i = 0; i < keyValues.length; i += 2) {
         
     | 
| 
       1953 
     | 
    
         
            -
                    if (i + 1 >= keyValues.length) {
         
     | 
| 
       1954 
     | 
    
         
            -
                      throw new Error('Missing value for key: ' + keyValues[i]);
         
     | 
| 
       1955 
     | 
    
         
            -
                    }
         
     | 
| 
       1956 
     | 
    
         
            -
                    map.set(keyValues[i], keyValues[i + 1]);
         
     | 
| 
       1957 
     | 
    
         
            -
                  }
         
     | 
| 
       1958 
     | 
    
         
            -
                });
         
     | 
| 
       1959 
     | 
    
         
            -
              };
         
     | 
| 
       1960 
     | 
    
         
            -
              Map.prototype.toString = function toString() {
         
     | 
| 
       1961 
     | 
    
         
            -
                return this.__toString('Map {', '}');
         
     | 
| 
       1962 
     | 
    
         
            -
              };
         
     | 
| 
       1963 
     | 
    
         
            -
             
     | 
| 
       1964 
     | 
    
         
            -
              // @pragma Access
         
     | 
| 
       1965 
     | 
    
         
            -
             
     | 
| 
       1966 
     | 
    
         
            -
              Map.prototype.get = function get(k, notSetValue) {
         
     | 
| 
       1967 
     | 
    
         
            -
                return this._root ? this._root.get(0, undefined, k, notSetValue) : notSetValue;
         
     | 
| 
       1968 
     | 
    
         
            -
              };
         
     | 
| 
       1969 
     | 
    
         
            -
             
     | 
| 
       1970 
     | 
    
         
            -
              // @pragma Modification
         
     | 
| 
       1971 
     | 
    
         
            -
             
     | 
| 
       1972 
     | 
    
         
            -
              Map.prototype.set = function set(k, v) {
         
     | 
| 
       1973 
     | 
    
         
            -
                return updateMap(this, k, v);
         
     | 
| 
       1974 
     | 
    
         
            -
              };
         
     | 
| 
       1975 
     | 
    
         
            -
              Map.prototype.remove = function remove(k) {
         
     | 
| 
       1976 
     | 
    
         
            -
                return updateMap(this, k, NOT_SET);
         
     | 
| 
       1977 
     | 
    
         
            -
              };
         
     | 
| 
       1978 
     | 
    
         
            -
              Map.prototype.deleteAll = function deleteAll(keys) {
         
     | 
| 
       1979 
     | 
    
         
            -
                var collection = Collection(keys);
         
     | 
| 
       1980 
     | 
    
         
            -
                if (collection.size === 0) {
         
     | 
| 
       1981 
     | 
    
         
            -
                  return this;
         
     | 
| 
       1982 
     | 
    
         
            -
                }
         
     | 
| 
       1983 
     | 
    
         
            -
                return this.withMutations(function (map) {
         
     | 
| 
       1984 
     | 
    
         
            -
                  collection.forEach(function (key) {
         
     | 
| 
       1985 
     | 
    
         
            -
                    return map.remove(key);
         
     | 
| 
       1986 
     | 
    
         
            -
                  });
         
     | 
| 
       1987 
     | 
    
         
            -
                });
         
     | 
| 
       1988 
     | 
    
         
            -
              };
         
     | 
| 
       1989 
     | 
    
         
            -
              Map.prototype.clear = function clear() {
         
     | 
| 
       1990 
     | 
    
         
            -
                if (this.size === 0) {
         
     | 
| 
       1991 
     | 
    
         
            -
                  return this;
         
     | 
| 
       1992 
     | 
    
         
            -
                }
         
     | 
| 
       1993 
     | 
    
         
            -
                if (this.__ownerID) {
         
     | 
| 
       1994 
     | 
    
         
            -
                  this.size = 0;
         
     | 
| 
       1995 
     | 
    
         
            -
                  this._root = null;
         
     | 
| 
       1996 
     | 
    
         
            -
                  this.__hash = undefined;
         
     | 
| 
       1997 
     | 
    
         
            -
                  this.__altered = true;
         
     | 
| 
       1998 
     | 
    
         
            -
                  return this;
         
     | 
| 
       1999 
     | 
    
         
            -
                }
         
     | 
| 
       2000 
     | 
    
         
            -
                return emptyMap();
         
     | 
| 
       2001 
     | 
    
         
            -
              };
         
     | 
| 
       2002 
     | 
    
         
            -
             
     | 
| 
       2003 
     | 
    
         
            -
              // @pragma Composition
         
     | 
| 
       2004 
     | 
    
         
            -
             
     | 
| 
       2005 
     | 
    
         
            -
              Map.prototype.sort = function sort(comparator) {
         
     | 
| 
       2006 
     | 
    
         
            -
                // Late binding
         
     | 
| 
       2007 
     | 
    
         
            -
                return OrderedMap(sortFactory(this, comparator));
         
     | 
| 
       2008 
     | 
    
         
            -
              };
         
     | 
| 
       2009 
     | 
    
         
            -
              Map.prototype.sortBy = function sortBy(mapper, comparator) {
         
     | 
| 
       2010 
     | 
    
         
            -
                // Late binding
         
     | 
| 
       2011 
     | 
    
         
            -
                return OrderedMap(sortFactory(this, comparator, mapper));
         
     | 
| 
       2012 
     | 
    
         
            -
              };
         
     | 
| 
       2013 
     | 
    
         
            -
              Map.prototype.map = function map(mapper, context) {
         
     | 
| 
       2014 
     | 
    
         
            -
                var this$1$1 = this;
         
     | 
| 
       2015 
     | 
    
         
            -
                return this.withMutations(function (map) {
         
     | 
| 
       2016 
     | 
    
         
            -
                  map.forEach(function (value, key) {
         
     | 
| 
       2017 
     | 
    
         
            -
                    map.set(key, mapper.call(context, value, key, this$1$1));
         
     | 
| 
       2018 
     | 
    
         
            -
                  });
         
     | 
| 
       2019 
     | 
    
         
            -
                });
         
     | 
| 
       2020 
     | 
    
         
            -
              };
         
     | 
| 
       2021 
     | 
    
         
            -
             
     | 
| 
       2022 
     | 
    
         
            -
              // @pragma Mutability
         
     | 
| 
       2023 
     | 
    
         
            -
             
     | 
| 
       2024 
     | 
    
         
            -
              Map.prototype.__iterator = function __iterator(type, reverse) {
         
     | 
| 
       2025 
     | 
    
         
            -
                return new MapIterator(this, type, reverse);
         
     | 
| 
       2026 
     | 
    
         
            -
              };
         
     | 
| 
       2027 
     | 
    
         
            -
              Map.prototype.__iterate = function __iterate(fn, reverse) {
         
     | 
| 
       2028 
     | 
    
         
            -
                var this$1$1 = this;
         
     | 
| 
       2029 
     | 
    
         
            -
                var iterations = 0;
         
     | 
| 
       2030 
     | 
    
         
            -
                this._root && this._root.iterate(function (entry) {
         
     | 
| 
       2031 
     | 
    
         
            -
                  iterations++;
         
     | 
| 
       2032 
     | 
    
         
            -
                  return fn(entry[1], entry[0], this$1$1);
         
     | 
| 
       2033 
     | 
    
         
            -
                }, reverse);
         
     | 
| 
       2034 
     | 
    
         
            -
                return iterations;
         
     | 
| 
       2035 
     | 
    
         
            -
              };
         
     | 
| 
       2036 
     | 
    
         
            -
              Map.prototype.__ensureOwner = function __ensureOwner(ownerID) {
         
     | 
| 
       2037 
     | 
    
         
            -
                if (ownerID === this.__ownerID) {
         
     | 
| 
       2038 
     | 
    
         
            -
                  return this;
         
     | 
| 
       2039 
     | 
    
         
            -
                }
         
     | 
| 
       2040 
     | 
    
         
            -
                if (!ownerID) {
         
     | 
| 
       2041 
     | 
    
         
            -
                  if (this.size === 0) {
         
     | 
| 
       2042 
     | 
    
         
            -
                    return emptyMap();
         
     | 
| 
       2043 
     | 
    
         
            -
                  }
         
     | 
| 
       2044 
     | 
    
         
            -
                  this.__ownerID = ownerID;
         
     | 
| 
       2045 
     | 
    
         
            -
                  this.__altered = false;
         
     | 
| 
       2046 
     | 
    
         
            -
                  return this;
         
     | 
| 
       2047 
     | 
    
         
            -
                }
         
     | 
| 
       2048 
     | 
    
         
            -
                return makeMap(this.size, this._root, ownerID, this.__hash);
         
     | 
| 
       2049 
     | 
    
         
            -
              };
         
     | 
| 
       2050 
     | 
    
         
            -
              return Map;
         
     | 
| 
       2051 
     | 
    
         
            -
            }(KeyedCollection);
         
     | 
| 
       2052 
     | 
    
         
            -
            Map.isMap = isMap;
         
     | 
| 
       2053 
     | 
    
         
            -
            var MapPrototype = Map.prototype;
         
     | 
| 
       2054 
     | 
    
         
            -
            MapPrototype[IS_MAP_SYMBOL] = true;
         
     | 
| 
       2055 
     | 
    
         
            -
            MapPrototype[DELETE] = MapPrototype.remove;
         
     | 
| 
       2056 
     | 
    
         
            -
            MapPrototype.removeAll = MapPrototype.deleteAll;
         
     | 
| 
       2057 
     | 
    
         
            -
            MapPrototype.setIn = setIn;
         
     | 
| 
       2058 
     | 
    
         
            -
            MapPrototype.removeIn = MapPrototype.deleteIn = deleteIn;
         
     | 
| 
       2059 
     | 
    
         
            -
            MapPrototype.update = update;
         
     | 
| 
       2060 
     | 
    
         
            -
            MapPrototype.updateIn = updateIn;
         
     | 
| 
       2061 
     | 
    
         
            -
            MapPrototype.merge = MapPrototype.concat = merge$1;
         
     | 
| 
       2062 
     | 
    
         
            -
            MapPrototype.mergeWith = mergeWith$1;
         
     | 
| 
       2063 
     | 
    
         
            -
            MapPrototype.mergeDeep = mergeDeep;
         
     | 
| 
       2064 
     | 
    
         
            -
            MapPrototype.mergeDeepWith = mergeDeepWith;
         
     | 
| 
       2065 
     | 
    
         
            -
            MapPrototype.mergeIn = mergeIn;
         
     | 
| 
       2066 
     | 
    
         
            -
            MapPrototype.mergeDeepIn = mergeDeepIn;
         
     | 
| 
       2067 
     | 
    
         
            -
            MapPrototype.withMutations = withMutations;
         
     | 
| 
       2068 
     | 
    
         
            -
            MapPrototype.wasAltered = wasAltered;
         
     | 
| 
       2069 
     | 
    
         
            -
            MapPrototype.asImmutable = asImmutable;
         
     | 
| 
       2070 
     | 
    
         
            -
            MapPrototype['@@transducer/init'] = MapPrototype.asMutable = asMutable;
         
     | 
| 
       2071 
     | 
    
         
            -
            MapPrototype['@@transducer/step'] = function (result, arr) {
         
     | 
| 
       2072 
     | 
    
         
            -
              return result.set(arr[0], arr[1]);
         
     | 
| 
       2073 
     | 
    
         
            -
            };
         
     | 
| 
       2074 
     | 
    
         
            -
            MapPrototype['@@transducer/result'] = function (obj) {
         
     | 
| 
       2075 
     | 
    
         
            -
              return obj.asImmutable();
         
     | 
| 
       2076 
     | 
    
         
            -
            };
         
     | 
| 
       2077 
     | 
    
         
            -
             
     | 
| 
       2078 
     | 
    
         
            -
            // #pragma Trie Nodes
         
     | 
| 
       2079 
     | 
    
         
            -
             
     | 
| 
       2080 
     | 
    
         
            -
            var ArrayMapNode = function ArrayMapNode(ownerID, entries) {
         
     | 
| 
       2081 
     | 
    
         
            -
              this.ownerID = ownerID;
         
     | 
| 
       2082 
     | 
    
         
            -
              this.entries = entries;
         
     | 
| 
       2083 
     | 
    
         
            -
            };
         
     | 
| 
       2084 
     | 
    
         
            -
            ArrayMapNode.prototype.get = function get(shift, keyHash, key, notSetValue) {
         
     | 
| 
       2085 
     | 
    
         
            -
              var entries = this.entries;
         
     | 
| 
       2086 
     | 
    
         
            -
              for (var ii = 0, len = entries.length; ii < len; ii++) {
         
     | 
| 
       2087 
     | 
    
         
            -
                if (is(key, entries[ii][0])) {
         
     | 
| 
       2088 
     | 
    
         
            -
                  return entries[ii][1];
         
     | 
| 
       2089 
     | 
    
         
            -
                }
         
     | 
| 
       2090 
     | 
    
         
            -
              }
         
     | 
| 
       2091 
     | 
    
         
            -
              return notSetValue;
         
     | 
| 
       2092 
     | 
    
         
            -
            };
         
     | 
| 
       2093 
     | 
    
         
            -
            ArrayMapNode.prototype.update = function update(ownerID, shift, keyHash, key, value, didChangeSize, didAlter) {
         
     | 
| 
       2094 
     | 
    
         
            -
              var removed = value === NOT_SET;
         
     | 
| 
       2095 
     | 
    
         
            -
              var entries = this.entries;
         
     | 
| 
       2096 
     | 
    
         
            -
              var idx = 0;
         
     | 
| 
       2097 
     | 
    
         
            -
              var len = entries.length;
         
     | 
| 
       2098 
     | 
    
         
            -
              for (; idx < len; idx++) {
         
     | 
| 
       2099 
     | 
    
         
            -
                if (is(key, entries[idx][0])) {
         
     | 
| 
       2100 
     | 
    
         
            -
                  break;
         
     | 
| 
       2101 
     | 
    
         
            -
                }
         
     | 
| 
       2102 
     | 
    
         
            -
              }
         
     | 
| 
       2103 
     | 
    
         
            -
              var exists = idx < len;
         
     | 
| 
       2104 
     | 
    
         
            -
              if (exists ? entries[idx][1] === value : removed) {
         
     | 
| 
       2105 
     | 
    
         
            -
                return this;
         
     | 
| 
       2106 
     | 
    
         
            -
              }
         
     | 
| 
       2107 
     | 
    
         
            -
              SetRef(didAlter);
         
     | 
| 
       2108 
     | 
    
         
            -
              (removed || !exists) && SetRef(didChangeSize);
         
     | 
| 
       2109 
     | 
    
         
            -
              if (removed && entries.length === 1) {
         
     | 
| 
       2110 
     | 
    
         
            -
                return; // undefined
         
     | 
| 
       2111 
     | 
    
         
            -
              }
         
     | 
| 
       2112 
     | 
    
         
            -
              if (!exists && !removed && entries.length >= MAX_ARRAY_MAP_SIZE) {
         
     | 
| 
       2113 
     | 
    
         
            -
                return createNodes(ownerID, entries, key, value);
         
     | 
| 
       2114 
     | 
    
         
            -
              }
         
     | 
| 
       2115 
     | 
    
         
            -
              var isEditable = ownerID && ownerID === this.ownerID;
         
     | 
| 
       2116 
     | 
    
         
            -
              var newEntries = isEditable ? entries : arrCopy(entries);
         
     | 
| 
       2117 
     | 
    
         
            -
              if (exists) {
         
     | 
| 
       2118 
     | 
    
         
            -
                if (removed) {
         
     | 
| 
       2119 
     | 
    
         
            -
                  idx === len - 1 ? newEntries.pop() : newEntries[idx] = newEntries.pop();
         
     | 
| 
       2120 
     | 
    
         
            -
                } else {
         
     | 
| 
       2121 
     | 
    
         
            -
                  newEntries[idx] = [key, value];
         
     | 
| 
       2122 
     | 
    
         
            -
                }
         
     | 
| 
       2123 
     | 
    
         
            -
              } else {
         
     | 
| 
       2124 
     | 
    
         
            -
                newEntries.push([key, value]);
         
     | 
| 
       2125 
     | 
    
         
            -
              }
         
     | 
| 
       2126 
     | 
    
         
            -
              if (isEditable) {
         
     | 
| 
       2127 
     | 
    
         
            -
                this.entries = newEntries;
         
     | 
| 
       2128 
     | 
    
         
            -
                return this;
         
     | 
| 
       2129 
     | 
    
         
            -
              }
         
     | 
| 
       2130 
     | 
    
         
            -
              return new ArrayMapNode(ownerID, newEntries);
         
     | 
| 
       2131 
     | 
    
         
            -
            };
         
     | 
| 
       2132 
     | 
    
         
            -
            var BitmapIndexedNode = function BitmapIndexedNode(ownerID, bitmap, nodes) {
         
     | 
| 
       2133 
     | 
    
         
            -
              this.ownerID = ownerID;
         
     | 
| 
       2134 
     | 
    
         
            -
              this.bitmap = bitmap;
         
     | 
| 
       2135 
     | 
    
         
            -
              this.nodes = nodes;
         
     | 
| 
       2136 
     | 
    
         
            -
            };
         
     | 
| 
       2137 
     | 
    
         
            -
            BitmapIndexedNode.prototype.get = function get(shift, keyHash, key, notSetValue) {
         
     | 
| 
       2138 
     | 
    
         
            -
              if (keyHash === undefined) {
         
     | 
| 
       2139 
     | 
    
         
            -
                keyHash = hash(key);
         
     | 
| 
       2140 
     | 
    
         
            -
              }
         
     | 
| 
       2141 
     | 
    
         
            -
              var bit = 1 << ((shift === 0 ? keyHash : keyHash >>> shift) & MASK);
         
     | 
| 
       2142 
     | 
    
         
            -
              var bitmap = this.bitmap;
         
     | 
| 
       2143 
     | 
    
         
            -
              return (bitmap & bit) === 0 ? notSetValue : this.nodes[popCount(bitmap & bit - 1)].get(shift + SHIFT, keyHash, key, notSetValue);
         
     | 
| 
       2144 
     | 
    
         
            -
            };
         
     | 
| 
       2145 
     | 
    
         
            -
            BitmapIndexedNode.prototype.update = function update(ownerID, shift, keyHash, key, value, didChangeSize, didAlter) {
         
     | 
| 
       2146 
     | 
    
         
            -
              if (keyHash === undefined) {
         
     | 
| 
       2147 
     | 
    
         
            -
                keyHash = hash(key);
         
     | 
| 
       2148 
     | 
    
         
            -
              }
         
     | 
| 
       2149 
     | 
    
         
            -
              var keyHashFrag = (shift === 0 ? keyHash : keyHash >>> shift) & MASK;
         
     | 
| 
       2150 
     | 
    
         
            -
              var bit = 1 << keyHashFrag;
         
     | 
| 
       2151 
     | 
    
         
            -
              var bitmap = this.bitmap;
         
     | 
| 
       2152 
     | 
    
         
            -
              var exists = (bitmap & bit) !== 0;
         
     | 
| 
       2153 
     | 
    
         
            -
              if (!exists && value === NOT_SET) {
         
     | 
| 
       2154 
     | 
    
         
            -
                return this;
         
     | 
| 
       2155 
     | 
    
         
            -
              }
         
     | 
| 
       2156 
     | 
    
         
            -
              var idx = popCount(bitmap & bit - 1);
         
     | 
| 
       2157 
     | 
    
         
            -
              var nodes = this.nodes;
         
     | 
| 
       2158 
     | 
    
         
            -
              var node = exists ? nodes[idx] : undefined;
         
     | 
| 
       2159 
     | 
    
         
            -
              var newNode = updateNode(node, ownerID, shift + SHIFT, keyHash, key, value, didChangeSize, didAlter);
         
     | 
| 
       2160 
     | 
    
         
            -
              if (newNode === node) {
         
     | 
| 
       2161 
     | 
    
         
            -
                return this;
         
     | 
| 
       2162 
     | 
    
         
            -
              }
         
     | 
| 
       2163 
     | 
    
         
            -
              if (!exists && newNode && nodes.length >= MAX_BITMAP_INDEXED_SIZE) {
         
     | 
| 
       2164 
     | 
    
         
            -
                return expandNodes(ownerID, nodes, bitmap, keyHashFrag, newNode);
         
     | 
| 
       2165 
     | 
    
         
            -
              }
         
     | 
| 
       2166 
     | 
    
         
            -
              if (exists && !newNode && nodes.length === 2 && isLeafNode(nodes[idx ^ 1])) {
         
     | 
| 
       2167 
     | 
    
         
            -
                return nodes[idx ^ 1];
         
     | 
| 
       2168 
     | 
    
         
            -
              }
         
     | 
| 
       2169 
     | 
    
         
            -
              if (exists && newNode && nodes.length === 1 && isLeafNode(newNode)) {
         
     | 
| 
       2170 
     | 
    
         
            -
                return newNode;
         
     | 
| 
       2171 
     | 
    
         
            -
              }
         
     | 
| 
       2172 
     | 
    
         
            -
              var isEditable = ownerID && ownerID === this.ownerID;
         
     | 
| 
       2173 
     | 
    
         
            -
              var newBitmap = exists ? newNode ? bitmap : bitmap ^ bit : bitmap | bit;
         
     | 
| 
       2174 
     | 
    
         
            -
              var newNodes = exists ? newNode ? setAt(nodes, idx, newNode, isEditable) : spliceOut(nodes, idx, isEditable) : spliceIn(nodes, idx, newNode, isEditable);
         
     | 
| 
       2175 
     | 
    
         
            -
              if (isEditable) {
         
     | 
| 
       2176 
     | 
    
         
            -
                this.bitmap = newBitmap;
         
     | 
| 
       2177 
     | 
    
         
            -
                this.nodes = newNodes;
         
     | 
| 
       2178 
     | 
    
         
            -
                return this;
         
     | 
| 
       2179 
     | 
    
         
            -
              }
         
     | 
| 
       2180 
     | 
    
         
            -
              return new BitmapIndexedNode(ownerID, newBitmap, newNodes);
         
     | 
| 
       2181 
     | 
    
         
            -
            };
         
     | 
| 
       2182 
     | 
    
         
            -
            var HashArrayMapNode = function HashArrayMapNode(ownerID, count, nodes) {
         
     | 
| 
       2183 
     | 
    
         
            -
              this.ownerID = ownerID;
         
     | 
| 
       2184 
     | 
    
         
            -
              this.count = count;
         
     | 
| 
       2185 
     | 
    
         
            -
              this.nodes = nodes;
         
     | 
| 
       2186 
     | 
    
         
            -
            };
         
     | 
| 
       2187 
     | 
    
         
            -
            HashArrayMapNode.prototype.get = function get(shift, keyHash, key, notSetValue) {
         
     | 
| 
       2188 
     | 
    
         
            -
              if (keyHash === undefined) {
         
     | 
| 
       2189 
     | 
    
         
            -
                keyHash = hash(key);
         
     | 
| 
       2190 
     | 
    
         
            -
              }
         
     | 
| 
       2191 
     | 
    
         
            -
              var idx = (shift === 0 ? keyHash : keyHash >>> shift) & MASK;
         
     | 
| 
       2192 
     | 
    
         
            -
              var node = this.nodes[idx];
         
     | 
| 
       2193 
     | 
    
         
            -
              return node ? node.get(shift + SHIFT, keyHash, key, notSetValue) : notSetValue;
         
     | 
| 
       2194 
     | 
    
         
            -
            };
         
     | 
| 
       2195 
     | 
    
         
            -
            HashArrayMapNode.prototype.update = function update(ownerID, shift, keyHash, key, value, didChangeSize, didAlter) {
         
     | 
| 
       2196 
     | 
    
         
            -
              if (keyHash === undefined) {
         
     | 
| 
       2197 
     | 
    
         
            -
                keyHash = hash(key);
         
     | 
| 
       2198 
     | 
    
         
            -
              }
         
     | 
| 
       2199 
     | 
    
         
            -
              var idx = (shift === 0 ? keyHash : keyHash >>> shift) & MASK;
         
     | 
| 
       2200 
     | 
    
         
            -
              var removed = value === NOT_SET;
         
     | 
| 
       2201 
     | 
    
         
            -
              var nodes = this.nodes;
         
     | 
| 
       2202 
     | 
    
         
            -
              var node = nodes[idx];
         
     | 
| 
       2203 
     | 
    
         
            -
              if (removed && !node) {
         
     | 
| 
       2204 
     | 
    
         
            -
                return this;
         
     | 
| 
       2205 
     | 
    
         
            -
              }
         
     | 
| 
       2206 
     | 
    
         
            -
              var newNode = updateNode(node, ownerID, shift + SHIFT, keyHash, key, value, didChangeSize, didAlter);
         
     | 
| 
       2207 
     | 
    
         
            -
              if (newNode === node) {
         
     | 
| 
       2208 
     | 
    
         
            -
                return this;
         
     | 
| 
       2209 
     | 
    
         
            -
              }
         
     | 
| 
       2210 
     | 
    
         
            -
              var newCount = this.count;
         
     | 
| 
       2211 
     | 
    
         
            -
              if (!node) {
         
     | 
| 
       2212 
     | 
    
         
            -
                newCount++;
         
     | 
| 
       2213 
     | 
    
         
            -
              } else if (!newNode) {
         
     | 
| 
       2214 
     | 
    
         
            -
                newCount--;
         
     | 
| 
       2215 
     | 
    
         
            -
                if (newCount < MIN_HASH_ARRAY_MAP_SIZE) {
         
     | 
| 
       2216 
     | 
    
         
            -
                  return packNodes(ownerID, nodes, newCount, idx);
         
     | 
| 
       2217 
     | 
    
         
            -
                }
         
     | 
| 
       2218 
     | 
    
         
            -
              }
         
     | 
| 
       2219 
     | 
    
         
            -
              var isEditable = ownerID && ownerID === this.ownerID;
         
     | 
| 
       2220 
     | 
    
         
            -
              var newNodes = setAt(nodes, idx, newNode, isEditable);
         
     | 
| 
       2221 
     | 
    
         
            -
              if (isEditable) {
         
     | 
| 
       2222 
     | 
    
         
            -
                this.count = newCount;
         
     | 
| 
       2223 
     | 
    
         
            -
                this.nodes = newNodes;
         
     | 
| 
       2224 
     | 
    
         
            -
                return this;
         
     | 
| 
       2225 
     | 
    
         
            -
              }
         
     | 
| 
       2226 
     | 
    
         
            -
              return new HashArrayMapNode(ownerID, newCount, newNodes);
         
     | 
| 
       2227 
     | 
    
         
            -
            };
         
     | 
| 
       2228 
     | 
    
         
            -
            var HashCollisionNode = function HashCollisionNode(ownerID, keyHash, entries) {
         
     | 
| 
       2229 
     | 
    
         
            -
              this.ownerID = ownerID;
         
     | 
| 
       2230 
     | 
    
         
            -
              this.keyHash = keyHash;
         
     | 
| 
       2231 
     | 
    
         
            -
              this.entries = entries;
         
     | 
| 
       2232 
     | 
    
         
            -
            };
         
     | 
| 
       2233 
     | 
    
         
            -
            HashCollisionNode.prototype.get = function get(shift, keyHash, key, notSetValue) {
         
     | 
| 
       2234 
     | 
    
         
            -
              var entries = this.entries;
         
     | 
| 
       2235 
     | 
    
         
            -
              for (var ii = 0, len = entries.length; ii < len; ii++) {
         
     | 
| 
       2236 
     | 
    
         
            -
                if (is(key, entries[ii][0])) {
         
     | 
| 
       2237 
     | 
    
         
            -
                  return entries[ii][1];
         
     | 
| 
       2238 
     | 
    
         
            -
                }
         
     | 
| 
       2239 
     | 
    
         
            -
              }
         
     | 
| 
       2240 
     | 
    
         
            -
              return notSetValue;
         
     | 
| 
       2241 
     | 
    
         
            -
            };
         
     | 
| 
       2242 
     | 
    
         
            -
            HashCollisionNode.prototype.update = function update(ownerID, shift, keyHash, key, value, didChangeSize, didAlter) {
         
     | 
| 
       2243 
     | 
    
         
            -
              if (keyHash === undefined) {
         
     | 
| 
       2244 
     | 
    
         
            -
                keyHash = hash(key);
         
     | 
| 
       2245 
     | 
    
         
            -
              }
         
     | 
| 
       2246 
     | 
    
         
            -
              var removed = value === NOT_SET;
         
     | 
| 
       2247 
     | 
    
         
            -
              if (keyHash !== this.keyHash) {
         
     | 
| 
       2248 
     | 
    
         
            -
                if (removed) {
         
     | 
| 
       2249 
     | 
    
         
            -
                  return this;
         
     | 
| 
       2250 
     | 
    
         
            -
                }
         
     | 
| 
       2251 
     | 
    
         
            -
                SetRef(didAlter);
         
     | 
| 
       2252 
     | 
    
         
            -
                SetRef(didChangeSize);
         
     | 
| 
       2253 
     | 
    
         
            -
                return mergeIntoNode(this, ownerID, shift, keyHash, [key, value]);
         
     | 
| 
       2254 
     | 
    
         
            -
              }
         
     | 
| 
       2255 
     | 
    
         
            -
              var entries = this.entries;
         
     | 
| 
       2256 
     | 
    
         
            -
              var idx = 0;
         
     | 
| 
       2257 
     | 
    
         
            -
              var len = entries.length;
         
     | 
| 
       2258 
     | 
    
         
            -
              for (; idx < len; idx++) {
         
     | 
| 
       2259 
     | 
    
         
            -
                if (is(key, entries[idx][0])) {
         
     | 
| 
       2260 
     | 
    
         
            -
                  break;
         
     | 
| 
       2261 
     | 
    
         
            -
                }
         
     | 
| 
       2262 
     | 
    
         
            -
              }
         
     | 
| 
       2263 
     | 
    
         
            -
              var exists = idx < len;
         
     | 
| 
       2264 
     | 
    
         
            -
              if (exists ? entries[idx][1] === value : removed) {
         
     | 
| 
       2265 
     | 
    
         
            -
                return this;
         
     | 
| 
       2266 
     | 
    
         
            -
              }
         
     | 
| 
       2267 
     | 
    
         
            -
              SetRef(didAlter);
         
     | 
| 
       2268 
     | 
    
         
            -
              (removed || !exists) && SetRef(didChangeSize);
         
     | 
| 
       2269 
     | 
    
         
            -
              if (removed && len === 2) {
         
     | 
| 
       2270 
     | 
    
         
            -
                return new ValueNode(ownerID, this.keyHash, entries[idx ^ 1]);
         
     | 
| 
       2271 
     | 
    
         
            -
              }
         
     | 
| 
       2272 
     | 
    
         
            -
              var isEditable = ownerID && ownerID === this.ownerID;
         
     | 
| 
       2273 
     | 
    
         
            -
              var newEntries = isEditable ? entries : arrCopy(entries);
         
     | 
| 
       2274 
     | 
    
         
            -
              if (exists) {
         
     | 
| 
       2275 
     | 
    
         
            -
                if (removed) {
         
     | 
| 
       2276 
     | 
    
         
            -
                  idx === len - 1 ? newEntries.pop() : newEntries[idx] = newEntries.pop();
         
     | 
| 
       2277 
     | 
    
         
            -
                } else {
         
     | 
| 
       2278 
     | 
    
         
            -
                  newEntries[idx] = [key, value];
         
     | 
| 
       2279 
     | 
    
         
            -
                }
         
     | 
| 
       2280 
     | 
    
         
            -
              } else {
         
     | 
| 
       2281 
     | 
    
         
            -
                newEntries.push([key, value]);
         
     | 
| 
       2282 
     | 
    
         
            -
              }
         
     | 
| 
       2283 
     | 
    
         
            -
              if (isEditable) {
         
     | 
| 
       2284 
     | 
    
         
            -
                this.entries = newEntries;
         
     | 
| 
       2285 
     | 
    
         
            -
                return this;
         
     | 
| 
       2286 
     | 
    
         
            -
              }
         
     | 
| 
       2287 
     | 
    
         
            -
              return new HashCollisionNode(ownerID, this.keyHash, newEntries);
         
     | 
| 
       2288 
     | 
    
         
            -
            };
         
     | 
| 
       2289 
     | 
    
         
            -
            var ValueNode = function ValueNode(ownerID, keyHash, entry) {
         
     | 
| 
       2290 
     | 
    
         
            -
              this.ownerID = ownerID;
         
     | 
| 
       2291 
     | 
    
         
            -
              this.keyHash = keyHash;
         
     | 
| 
       2292 
     | 
    
         
            -
              this.entry = entry;
         
     | 
| 
       2293 
     | 
    
         
            -
            };
         
     | 
| 
       2294 
     | 
    
         
            -
            ValueNode.prototype.get = function get(shift, keyHash, key, notSetValue) {
         
     | 
| 
       2295 
     | 
    
         
            -
              return is(key, this.entry[0]) ? this.entry[1] : notSetValue;
         
     | 
| 
       2296 
     | 
    
         
            -
            };
         
     | 
| 
       2297 
     | 
    
         
            -
            ValueNode.prototype.update = function update(ownerID, shift, keyHash, key, value, didChangeSize, didAlter) {
         
     | 
| 
       2298 
     | 
    
         
            -
              var removed = value === NOT_SET;
         
     | 
| 
       2299 
     | 
    
         
            -
              var keyMatch = is(key, this.entry[0]);
         
     | 
| 
       2300 
     | 
    
         
            -
              if (keyMatch ? value === this.entry[1] : removed) {
         
     | 
| 
       2301 
     | 
    
         
            -
                return this;
         
     | 
| 
       2302 
     | 
    
         
            -
              }
         
     | 
| 
       2303 
     | 
    
         
            -
              SetRef(didAlter);
         
     | 
| 
       2304 
     | 
    
         
            -
              if (removed) {
         
     | 
| 
       2305 
     | 
    
         
            -
                SetRef(didChangeSize);
         
     | 
| 
       2306 
     | 
    
         
            -
                return; // undefined
         
     | 
| 
       2307 
     | 
    
         
            -
              }
         
     | 
| 
       2308 
     | 
    
         
            -
              if (keyMatch) {
         
     | 
| 
       2309 
     | 
    
         
            -
                if (ownerID && ownerID === this.ownerID) {
         
     | 
| 
       2310 
     | 
    
         
            -
                  this.entry[1] = value;
         
     | 
| 
       2311 
     | 
    
         
            -
                  return this;
         
     | 
| 
       2312 
     | 
    
         
            -
                }
         
     | 
| 
       2313 
     | 
    
         
            -
                return new ValueNode(ownerID, this.keyHash, [key, value]);
         
     | 
| 
       2314 
     | 
    
         
            -
              }
         
     | 
| 
       2315 
     | 
    
         
            -
              SetRef(didChangeSize);
         
     | 
| 
       2316 
     | 
    
         
            -
              return mergeIntoNode(this, ownerID, shift, hash(key), [key, value]);
         
     | 
| 
       2317 
     | 
    
         
            -
            };
         
     | 
| 
       2318 
     | 
    
         
            -
             
     | 
| 
       2319 
     | 
    
         
            -
            // #pragma Iterators
         
     | 
| 
       2320 
     | 
    
         
            -
             
     | 
| 
       2321 
     | 
    
         
            -
            ArrayMapNode.prototype.iterate = HashCollisionNode.prototype.iterate = function (fn, reverse) {
         
     | 
| 
       2322 
     | 
    
         
            -
              var entries = this.entries;
         
     | 
| 
       2323 
     | 
    
         
            -
              for (var ii = 0, maxIndex = entries.length - 1; ii <= maxIndex; ii++) {
         
     | 
| 
       2324 
     | 
    
         
            -
                if (fn(entries[reverse ? maxIndex - ii : ii]) === false) {
         
     | 
| 
       2325 
     | 
    
         
            -
                  return false;
         
     | 
| 
       2326 
     | 
    
         
            -
                }
         
     | 
| 
       2327 
     | 
    
         
            -
              }
         
     | 
| 
       2328 
     | 
    
         
            -
            };
         
     | 
| 
       2329 
     | 
    
         
            -
            BitmapIndexedNode.prototype.iterate = HashArrayMapNode.prototype.iterate = function (fn, reverse) {
         
     | 
| 
       2330 
     | 
    
         
            -
              var nodes = this.nodes;
         
     | 
| 
       2331 
     | 
    
         
            -
              for (var ii = 0, maxIndex = nodes.length - 1; ii <= maxIndex; ii++) {
         
     | 
| 
       2332 
     | 
    
         
            -
                var node = nodes[reverse ? maxIndex - ii : ii];
         
     | 
| 
       2333 
     | 
    
         
            -
                if (node && node.iterate(fn, reverse) === false) {
         
     | 
| 
       2334 
     | 
    
         
            -
                  return false;
         
     | 
| 
       2335 
     | 
    
         
            -
                }
         
     | 
| 
       2336 
     | 
    
         
            -
              }
         
     | 
| 
       2337 
     | 
    
         
            -
            };
         
     | 
| 
       2338 
     | 
    
         
            -
             
     | 
| 
       2339 
     | 
    
         
            -
            // eslint-disable-next-line no-unused-vars
         
     | 
| 
       2340 
     | 
    
         
            -
            ValueNode.prototype.iterate = function (fn, reverse) {
         
     | 
| 
       2341 
     | 
    
         
            -
              return fn(this.entry);
         
     | 
| 
       2342 
     | 
    
         
            -
            };
         
     | 
| 
       2343 
     | 
    
         
            -
            var MapIterator = /*@__PURE__*/function (Iterator) {
         
     | 
| 
       2344 
     | 
    
         
            -
              function MapIterator(map, type, reverse) {
         
     | 
| 
       2345 
     | 
    
         
            -
                this._type = type;
         
     | 
| 
       2346 
     | 
    
         
            -
                this._reverse = reverse;
         
     | 
| 
       2347 
     | 
    
         
            -
                this._stack = map._root && mapIteratorFrame(map._root);
         
     | 
| 
       2348 
     | 
    
         
            -
              }
         
     | 
| 
       2349 
     | 
    
         
            -
              if (Iterator) MapIterator.__proto__ = Iterator;
         
     | 
| 
       2350 
     | 
    
         
            -
              MapIterator.prototype = Object.create(Iterator && Iterator.prototype);
         
     | 
| 
       2351 
     | 
    
         
            -
              MapIterator.prototype.constructor = MapIterator;
         
     | 
| 
       2352 
     | 
    
         
            -
              MapIterator.prototype.next = function next() {
         
     | 
| 
       2353 
     | 
    
         
            -
                var type = this._type;
         
     | 
| 
       2354 
     | 
    
         
            -
                var stack = this._stack;
         
     | 
| 
       2355 
     | 
    
         
            -
                while (stack) {
         
     | 
| 
       2356 
     | 
    
         
            -
                  var node = stack.node;
         
     | 
| 
       2357 
     | 
    
         
            -
                  var index = stack.index++;
         
     | 
| 
       2358 
     | 
    
         
            -
                  var maxIndex = void 0;
         
     | 
| 
       2359 
     | 
    
         
            -
                  if (node.entry) {
         
     | 
| 
       2360 
     | 
    
         
            -
                    if (index === 0) {
         
     | 
| 
       2361 
     | 
    
         
            -
                      return mapIteratorValue(type, node.entry);
         
     | 
| 
       2362 
     | 
    
         
            -
                    }
         
     | 
| 
       2363 
     | 
    
         
            -
                  } else if (node.entries) {
         
     | 
| 
       2364 
     | 
    
         
            -
                    maxIndex = node.entries.length - 1;
         
     | 
| 
       2365 
     | 
    
         
            -
                    if (index <= maxIndex) {
         
     | 
| 
       2366 
     | 
    
         
            -
                      return mapIteratorValue(type, node.entries[this._reverse ? maxIndex - index : index]);
         
     | 
| 
       2367 
     | 
    
         
            -
                    }
         
     | 
| 
       2368 
     | 
    
         
            -
                  } else {
         
     | 
| 
       2369 
     | 
    
         
            -
                    maxIndex = node.nodes.length - 1;
         
     | 
| 
       2370 
     | 
    
         
            -
                    if (index <= maxIndex) {
         
     | 
| 
       2371 
     | 
    
         
            -
                      var subNode = node.nodes[this._reverse ? maxIndex - index : index];
         
     | 
| 
       2372 
     | 
    
         
            -
                      if (subNode) {
         
     | 
| 
       2373 
     | 
    
         
            -
                        if (subNode.entry) {
         
     | 
| 
       2374 
     | 
    
         
            -
                          return mapIteratorValue(type, subNode.entry);
         
     | 
| 
       2375 
     | 
    
         
            -
                        }
         
     | 
| 
       2376 
     | 
    
         
            -
                        stack = this._stack = mapIteratorFrame(subNode, stack);
         
     | 
| 
       2377 
     | 
    
         
            -
                      }
         
     | 
| 
       2378 
     | 
    
         
            -
                      continue;
         
     | 
| 
       2379 
     | 
    
         
            -
                    }
         
     | 
| 
       2380 
     | 
    
         
            -
                  }
         
     | 
| 
       2381 
     | 
    
         
            -
                  stack = this._stack = this._stack.__prev;
         
     | 
| 
       2382 
     | 
    
         
            -
                }
         
     | 
| 
       2383 
     | 
    
         
            -
                return iteratorDone();
         
     | 
| 
       2384 
     | 
    
         
            -
              };
         
     | 
| 
       2385 
     | 
    
         
            -
              return MapIterator;
         
     | 
| 
       2386 
     | 
    
         
            -
            }(Iterator);
         
     | 
| 
       2387 
     | 
    
         
            -
            function mapIteratorValue(type, entry) {
         
     | 
| 
       2388 
     | 
    
         
            -
              return iteratorValue(type, entry[0], entry[1]);
         
     | 
| 
       2389 
     | 
    
         
            -
            }
         
     | 
| 
       2390 
     | 
    
         
            -
            function mapIteratorFrame(node, prev) {
         
     | 
| 
       2391 
     | 
    
         
            -
              return {
         
     | 
| 
       2392 
     | 
    
         
            -
                node: node,
         
     | 
| 
       2393 
     | 
    
         
            -
                index: 0,
         
     | 
| 
       2394 
     | 
    
         
            -
                __prev: prev
         
     | 
| 
       2395 
     | 
    
         
            -
              };
         
     | 
| 
       2396 
     | 
    
         
            -
            }
         
     | 
| 
       2397 
     | 
    
         
            -
            function makeMap(size, root, ownerID, hash) {
         
     | 
| 
       2398 
     | 
    
         
            -
              var map = Object.create(MapPrototype);
         
     | 
| 
       2399 
     | 
    
         
            -
              map.size = size;
         
     | 
| 
       2400 
     | 
    
         
            -
              map._root = root;
         
     | 
| 
       2401 
     | 
    
         
            -
              map.__ownerID = ownerID;
         
     | 
| 
       2402 
     | 
    
         
            -
              map.__hash = hash;
         
     | 
| 
       2403 
     | 
    
         
            -
              map.__altered = false;
         
     | 
| 
       2404 
     | 
    
         
            -
              return map;
         
     | 
| 
       2405 
     | 
    
         
            -
            }
         
     | 
| 
       2406 
     | 
    
         
            -
            var EMPTY_MAP;
         
     | 
| 
       2407 
     | 
    
         
            -
            function emptyMap() {
         
     | 
| 
       2408 
     | 
    
         
            -
              return EMPTY_MAP || (EMPTY_MAP = makeMap(0));
         
     | 
| 
       2409 
     | 
    
         
            -
            }
         
     | 
| 
       2410 
     | 
    
         
            -
            function updateMap(map, k, v) {
         
     | 
| 
       2411 
     | 
    
         
            -
              var newRoot;
         
     | 
| 
       2412 
     | 
    
         
            -
              var newSize;
         
     | 
| 
       2413 
     | 
    
         
            -
              if (!map._root) {
         
     | 
| 
       2414 
     | 
    
         
            -
                if (v === NOT_SET) {
         
     | 
| 
       2415 
     | 
    
         
            -
                  return map;
         
     | 
| 
       2416 
     | 
    
         
            -
                }
         
     | 
| 
       2417 
     | 
    
         
            -
                newSize = 1;
         
     | 
| 
       2418 
     | 
    
         
            -
                newRoot = new ArrayMapNode(map.__ownerID, [[k, v]]);
         
     | 
| 
       2419 
     | 
    
         
            -
              } else {
         
     | 
| 
       2420 
     | 
    
         
            -
                var didChangeSize = MakeRef();
         
     | 
| 
       2421 
     | 
    
         
            -
                var didAlter = MakeRef();
         
     | 
| 
       2422 
     | 
    
         
            -
                newRoot = updateNode(map._root, map.__ownerID, 0, undefined, k, v, didChangeSize, didAlter);
         
     | 
| 
       2423 
     | 
    
         
            -
                if (!didAlter.value) {
         
     | 
| 
       2424 
     | 
    
         
            -
                  return map;
         
     | 
| 
       2425 
     | 
    
         
            -
                }
         
     | 
| 
       2426 
     | 
    
         
            -
                newSize = map.size + (didChangeSize.value ? v === NOT_SET ? -1 : 1 : 0);
         
     | 
| 
       2427 
     | 
    
         
            -
              }
         
     | 
| 
       2428 
     | 
    
         
            -
              if (map.__ownerID) {
         
     | 
| 
       2429 
     | 
    
         
            -
                map.size = newSize;
         
     | 
| 
       2430 
     | 
    
         
            -
                map._root = newRoot;
         
     | 
| 
       2431 
     | 
    
         
            -
                map.__hash = undefined;
         
     | 
| 
       2432 
     | 
    
         
            -
                map.__altered = true;
         
     | 
| 
       2433 
     | 
    
         
            -
                return map;
         
     | 
| 
       2434 
     | 
    
         
            -
              }
         
     | 
| 
       2435 
     | 
    
         
            -
              return newRoot ? makeMap(newSize, newRoot) : emptyMap();
         
     | 
| 
       2436 
     | 
    
         
            -
            }
         
     | 
| 
       2437 
     | 
    
         
            -
            function updateNode(node, ownerID, shift, keyHash, key, value, didChangeSize, didAlter) {
         
     | 
| 
       2438 
     | 
    
         
            -
              if (!node) {
         
     | 
| 
       2439 
     | 
    
         
            -
                if (value === NOT_SET) {
         
     | 
| 
       2440 
     | 
    
         
            -
                  return node;
         
     | 
| 
       2441 
     | 
    
         
            -
                }
         
     | 
| 
       2442 
     | 
    
         
            -
                SetRef(didAlter);
         
     | 
| 
       2443 
     | 
    
         
            -
                SetRef(didChangeSize);
         
     | 
| 
       2444 
     | 
    
         
            -
                return new ValueNode(ownerID, keyHash, [key, value]);
         
     | 
| 
       2445 
     | 
    
         
            -
              }
         
     | 
| 
       2446 
     | 
    
         
            -
              return node.update(ownerID, shift, keyHash, key, value, didChangeSize, didAlter);
         
     | 
| 
       2447 
     | 
    
         
            -
            }
         
     | 
| 
       2448 
     | 
    
         
            -
            function isLeafNode(node) {
         
     | 
| 
       2449 
     | 
    
         
            -
              return node.constructor === ValueNode || node.constructor === HashCollisionNode;
         
     | 
| 
       2450 
     | 
    
         
            -
            }
         
     | 
| 
       2451 
     | 
    
         
            -
            function mergeIntoNode(node, ownerID, shift, keyHash, entry) {
         
     | 
| 
       2452 
     | 
    
         
            -
              if (node.keyHash === keyHash) {
         
     | 
| 
       2453 
     | 
    
         
            -
                return new HashCollisionNode(ownerID, keyHash, [node.entry, entry]);
         
     | 
| 
       2454 
     | 
    
         
            -
              }
         
     | 
| 
       2455 
     | 
    
         
            -
              var idx1 = (shift === 0 ? node.keyHash : node.keyHash >>> shift) & MASK;
         
     | 
| 
       2456 
     | 
    
         
            -
              var idx2 = (shift === 0 ? keyHash : keyHash >>> shift) & MASK;
         
     | 
| 
       2457 
     | 
    
         
            -
              var newNode;
         
     | 
| 
       2458 
     | 
    
         
            -
              var nodes = idx1 === idx2 ? [mergeIntoNode(node, ownerID, shift + SHIFT, keyHash, entry)] : (newNode = new ValueNode(ownerID, keyHash, entry), idx1 < idx2 ? [node, newNode] : [newNode, node]);
         
     | 
| 
       2459 
     | 
    
         
            -
              return new BitmapIndexedNode(ownerID, 1 << idx1 | 1 << idx2, nodes);
         
     | 
| 
       2460 
     | 
    
         
            -
            }
         
     | 
| 
       2461 
     | 
    
         
            -
            function createNodes(ownerID, entries, key, value) {
         
     | 
| 
       2462 
     | 
    
         
            -
              if (!ownerID) {
         
     | 
| 
       2463 
     | 
    
         
            -
                ownerID = new OwnerID();
         
     | 
| 
       2464 
     | 
    
         
            -
              }
         
     | 
| 
       2465 
     | 
    
         
            -
              var node = new ValueNode(ownerID, hash(key), [key, value]);
         
     | 
| 
       2466 
     | 
    
         
            -
              for (var ii = 0; ii < entries.length; ii++) {
         
     | 
| 
       2467 
     | 
    
         
            -
                var entry = entries[ii];
         
     | 
| 
       2468 
     | 
    
         
            -
                node = node.update(ownerID, 0, undefined, entry[0], entry[1]);
         
     | 
| 
       2469 
     | 
    
         
            -
              }
         
     | 
| 
       2470 
     | 
    
         
            -
              return node;
         
     | 
| 
       2471 
     | 
    
         
            -
            }
         
     | 
| 
       2472 
     | 
    
         
            -
            function packNodes(ownerID, nodes, count, excluding) {
         
     | 
| 
       2473 
     | 
    
         
            -
              var bitmap = 0;
         
     | 
| 
       2474 
     | 
    
         
            -
              var packedII = 0;
         
     | 
| 
       2475 
     | 
    
         
            -
              var packedNodes = new Array(count);
         
     | 
| 
       2476 
     | 
    
         
            -
              for (var ii = 0, bit = 1, len = nodes.length; ii < len; ii++, bit <<= 1) {
         
     | 
| 
       2477 
     | 
    
         
            -
                var node = nodes[ii];
         
     | 
| 
       2478 
     | 
    
         
            -
                if (node !== undefined && ii !== excluding) {
         
     | 
| 
       2479 
     | 
    
         
            -
                  bitmap |= bit;
         
     | 
| 
       2480 
     | 
    
         
            -
                  packedNodes[packedII++] = node;
         
     | 
| 
       2481 
     | 
    
         
            -
                }
         
     | 
| 
       2482 
     | 
    
         
            -
              }
         
     | 
| 
       2483 
     | 
    
         
            -
              return new BitmapIndexedNode(ownerID, bitmap, packedNodes);
         
     | 
| 
       2484 
     | 
    
         
            -
            }
         
     | 
| 
       2485 
     | 
    
         
            -
            function expandNodes(ownerID, nodes, bitmap, including, node) {
         
     | 
| 
       2486 
     | 
    
         
            -
              var count = 0;
         
     | 
| 
       2487 
     | 
    
         
            -
              var expandedNodes = new Array(SIZE);
         
     | 
| 
       2488 
     | 
    
         
            -
              for (var ii = 0; bitmap !== 0; ii++, bitmap >>>= 1) {
         
     | 
| 
       2489 
     | 
    
         
            -
                expandedNodes[ii] = bitmap & 1 ? nodes[count++] : undefined;
         
     | 
| 
       2490 
     | 
    
         
            -
              }
         
     | 
| 
       2491 
     | 
    
         
            -
              expandedNodes[including] = node;
         
     | 
| 
       2492 
     | 
    
         
            -
              return new HashArrayMapNode(ownerID, count + 1, expandedNodes);
         
     | 
| 
       2493 
     | 
    
         
            -
            }
         
     | 
| 
       2494 
     | 
    
         
            -
            function popCount(x) {
         
     | 
| 
       2495 
     | 
    
         
            -
              x -= x >> 1 & 0x55555555;
         
     | 
| 
       2496 
     | 
    
         
            -
              x = (x & 0x33333333) + (x >> 2 & 0x33333333);
         
     | 
| 
       2497 
     | 
    
         
            -
              x = x + (x >> 4) & 0x0f0f0f0f;
         
     | 
| 
       2498 
     | 
    
         
            -
              x += x >> 8;
         
     | 
| 
       2499 
     | 
    
         
            -
              x += x >> 16;
         
     | 
| 
       2500 
     | 
    
         
            -
              return x & 0x7f;
         
     | 
| 
       2501 
     | 
    
         
            -
            }
         
     | 
| 
       2502 
     | 
    
         
            -
            function setAt(array, idx, val, canEdit) {
         
     | 
| 
       2503 
     | 
    
         
            -
              var newArray = canEdit ? array : arrCopy(array);
         
     | 
| 
       2504 
     | 
    
         
            -
              newArray[idx] = val;
         
     | 
| 
       2505 
     | 
    
         
            -
              return newArray;
         
     | 
| 
       2506 
     | 
    
         
            -
            }
         
     | 
| 
       2507 
     | 
    
         
            -
            function spliceIn(array, idx, val, canEdit) {
         
     | 
| 
       2508 
     | 
    
         
            -
              var newLen = array.length + 1;
         
     | 
| 
       2509 
     | 
    
         
            -
              if (canEdit && idx + 1 === newLen) {
         
     | 
| 
       2510 
     | 
    
         
            -
                array[idx] = val;
         
     | 
| 
       2511 
     | 
    
         
            -
                return array;
         
     | 
| 
       2512 
     | 
    
         
            -
              }
         
     | 
| 
       2513 
     | 
    
         
            -
              var newArray = new Array(newLen);
         
     | 
| 
       2514 
     | 
    
         
            -
              var after = 0;
         
     | 
| 
       2515 
     | 
    
         
            -
              for (var ii = 0; ii < newLen; ii++) {
         
     | 
| 
       2516 
     | 
    
         
            -
                if (ii === idx) {
         
     | 
| 
       2517 
     | 
    
         
            -
                  newArray[ii] = val;
         
     | 
| 
       2518 
     | 
    
         
            -
                  after = -1;
         
     | 
| 
       2519 
     | 
    
         
            -
                } else {
         
     | 
| 
       2520 
     | 
    
         
            -
                  newArray[ii] = array[ii + after];
         
     | 
| 
       2521 
     | 
    
         
            -
                }
         
     | 
| 
       2522 
     | 
    
         
            -
              }
         
     | 
| 
       2523 
     | 
    
         
            -
              return newArray;
         
     | 
| 
       2524 
     | 
    
         
            -
            }
         
     | 
| 
       2525 
     | 
    
         
            -
            function spliceOut(array, idx, canEdit) {
         
     | 
| 
       2526 
     | 
    
         
            -
              var newLen = array.length - 1;
         
     | 
| 
       2527 
     | 
    
         
            -
              if (canEdit && idx === newLen) {
         
     | 
| 
       2528 
     | 
    
         
            -
                array.pop();
         
     | 
| 
       2529 
     | 
    
         
            -
                return array;
         
     | 
| 
       2530 
     | 
    
         
            -
              }
         
     | 
| 
       2531 
     | 
    
         
            -
              var newArray = new Array(newLen);
         
     | 
| 
       2532 
     | 
    
         
            -
              var after = 0;
         
     | 
| 
       2533 
     | 
    
         
            -
              for (var ii = 0; ii < newLen; ii++) {
         
     | 
| 
       2534 
     | 
    
         
            -
                if (ii === idx) {
         
     | 
| 
       2535 
     | 
    
         
            -
                  after = 1;
         
     | 
| 
       2536 
     | 
    
         
            -
                }
         
     | 
| 
       2537 
     | 
    
         
            -
                newArray[ii] = array[ii + after];
         
     | 
| 
       2538 
     | 
    
         
            -
              }
         
     | 
| 
       2539 
     | 
    
         
            -
              return newArray;
         
     | 
| 
       2540 
     | 
    
         
            -
            }
         
     | 
| 
       2541 
     | 
    
         
            -
            var MAX_ARRAY_MAP_SIZE = SIZE / 4;
         
     | 
| 
       2542 
     | 
    
         
            -
            var MAX_BITMAP_INDEXED_SIZE = SIZE / 2;
         
     | 
| 
       2543 
     | 
    
         
            -
            var MIN_HASH_ARRAY_MAP_SIZE = SIZE / 4;
         
     | 
| 
       2544 
     | 
    
         
            -
            var IS_LIST_SYMBOL = '@@__IMMUTABLE_LIST__@@';
         
     | 
| 
       2545 
     | 
    
         
            -
            function isList(maybeList) {
         
     | 
| 
       2546 
     | 
    
         
            -
              return Boolean(maybeList && maybeList[IS_LIST_SYMBOL]);
         
     | 
| 
       2547 
     | 
    
         
            -
            }
         
     | 
| 
       2548 
     | 
    
         
            -
            var List = /*@__PURE__*/function (IndexedCollection) {
         
     | 
| 
       2549 
     | 
    
         
            -
              function List(value) {
         
     | 
| 
       2550 
     | 
    
         
            -
                var empty = emptyList();
         
     | 
| 
       2551 
     | 
    
         
            -
                if (value === undefined || value === null) {
         
     | 
| 
       2552 
     | 
    
         
            -
                  // eslint-disable-next-line no-constructor-return
         
     | 
| 
       2553 
     | 
    
         
            -
                  return empty;
         
     | 
| 
       2554 
     | 
    
         
            -
                }
         
     | 
| 
       2555 
     | 
    
         
            -
                if (isList(value)) {
         
     | 
| 
       2556 
     | 
    
         
            -
                  // eslint-disable-next-line no-constructor-return
         
     | 
| 
       2557 
     | 
    
         
            -
                  return value;
         
     | 
| 
       2558 
     | 
    
         
            -
                }
         
     | 
| 
       2559 
     | 
    
         
            -
                var iter = IndexedCollection(value);
         
     | 
| 
       2560 
     | 
    
         
            -
                var size = iter.size;
         
     | 
| 
       2561 
     | 
    
         
            -
                if (size === 0) {
         
     | 
| 
       2562 
     | 
    
         
            -
                  // eslint-disable-next-line no-constructor-return
         
     | 
| 
       2563 
     | 
    
         
            -
                  return empty;
         
     | 
| 
       2564 
     | 
    
         
            -
                }
         
     | 
| 
       2565 
     | 
    
         
            -
                assertNotInfinite(size);
         
     | 
| 
       2566 
     | 
    
         
            -
                if (size > 0 && size < SIZE) {
         
     | 
| 
       2567 
     | 
    
         
            -
                  // eslint-disable-next-line no-constructor-return
         
     | 
| 
       2568 
     | 
    
         
            -
                  return makeList(0, size, SHIFT, null, new VNode(iter.toArray()));
         
     | 
| 
       2569 
     | 
    
         
            -
                }
         
     | 
| 
       2570 
     | 
    
         
            -
                // eslint-disable-next-line no-constructor-return
         
     | 
| 
       2571 
     | 
    
         
            -
                return empty.withMutations(function (list) {
         
     | 
| 
       2572 
     | 
    
         
            -
                  list.setSize(size);
         
     | 
| 
       2573 
     | 
    
         
            -
                  iter.forEach(function (v, i) {
         
     | 
| 
       2574 
     | 
    
         
            -
                    return list.set(i, v);
         
     | 
| 
       2575 
     | 
    
         
            -
                  });
         
     | 
| 
       2576 
     | 
    
         
            -
                });
         
     | 
| 
       2577 
     | 
    
         
            -
              }
         
     | 
| 
       2578 
     | 
    
         
            -
              if (IndexedCollection) List.__proto__ = IndexedCollection;
         
     | 
| 
       2579 
     | 
    
         
            -
              List.prototype = Object.create(IndexedCollection && IndexedCollection.prototype);
         
     | 
| 
       2580 
     | 
    
         
            -
              List.prototype.constructor = List;
         
     | 
| 
       2581 
     | 
    
         
            -
              List.of = function of(/*...values*/
         
     | 
| 
       2582 
     | 
    
         
            -
              ) {
         
     | 
| 
       2583 
     | 
    
         
            -
                return this(arguments);
         
     | 
| 
       2584 
     | 
    
         
            -
              };
         
     | 
| 
       2585 
     | 
    
         
            -
              List.prototype.toString = function toString() {
         
     | 
| 
       2586 
     | 
    
         
            -
                return this.__toString('List [', ']');
         
     | 
| 
       2587 
     | 
    
         
            -
              };
         
     | 
| 
       2588 
     | 
    
         
            -
             
     | 
| 
       2589 
     | 
    
         
            -
              // @pragma Access
         
     | 
| 
       2590 
     | 
    
         
            -
             
     | 
| 
       2591 
     | 
    
         
            -
              List.prototype.get = function get(index, notSetValue) {
         
     | 
| 
       2592 
     | 
    
         
            -
                index = wrapIndex(this, index);
         
     | 
| 
       2593 
     | 
    
         
            -
                if (index >= 0 && index < this.size) {
         
     | 
| 
       2594 
     | 
    
         
            -
                  index += this._origin;
         
     | 
| 
       2595 
     | 
    
         
            -
                  var node = listNodeFor(this, index);
         
     | 
| 
       2596 
     | 
    
         
            -
                  return node && node.array[index & MASK];
         
     | 
| 
       2597 
     | 
    
         
            -
                }
         
     | 
| 
       2598 
     | 
    
         
            -
                return notSetValue;
         
     | 
| 
       2599 
     | 
    
         
            -
              };
         
     | 
| 
       2600 
     | 
    
         
            -
             
     | 
| 
       2601 
     | 
    
         
            -
              // @pragma Modification
         
     | 
| 
       2602 
     | 
    
         
            -
             
     | 
| 
       2603 
     | 
    
         
            -
              List.prototype.set = function set(index, value) {
         
     | 
| 
       2604 
     | 
    
         
            -
                return updateList(this, index, value);
         
     | 
| 
       2605 
     | 
    
         
            -
              };
         
     | 
| 
       2606 
     | 
    
         
            -
              List.prototype.remove = function remove(index) {
         
     | 
| 
       2607 
     | 
    
         
            -
                return !this.has(index) ? this : index === 0 ? this.shift() : index === this.size - 1 ? this.pop() : this.splice(index, 1);
         
     | 
| 
       2608 
     | 
    
         
            -
              };
         
     | 
| 
       2609 
     | 
    
         
            -
              List.prototype.insert = function insert(index, value) {
         
     | 
| 
       2610 
     | 
    
         
            -
                return this.splice(index, 0, value);
         
     | 
| 
       2611 
     | 
    
         
            -
              };
         
     | 
| 
       2612 
     | 
    
         
            -
              List.prototype.clear = function clear() {
         
     | 
| 
       2613 
     | 
    
         
            -
                if (this.size === 0) {
         
     | 
| 
       2614 
     | 
    
         
            -
                  return this;
         
     | 
| 
       2615 
     | 
    
         
            -
                }
         
     | 
| 
       2616 
     | 
    
         
            -
                if (this.__ownerID) {
         
     | 
| 
       2617 
     | 
    
         
            -
                  this.size = this._origin = this._capacity = 0;
         
     | 
| 
       2618 
     | 
    
         
            -
                  this._level = SHIFT;
         
     | 
| 
       2619 
     | 
    
         
            -
                  this._root = this._tail = this.__hash = undefined;
         
     | 
| 
       2620 
     | 
    
         
            -
                  this.__altered = true;
         
     | 
| 
       2621 
     | 
    
         
            -
                  return this;
         
     | 
| 
       2622 
     | 
    
         
            -
                }
         
     | 
| 
       2623 
     | 
    
         
            -
                return emptyList();
         
     | 
| 
       2624 
     | 
    
         
            -
              };
         
     | 
| 
       2625 
     | 
    
         
            -
              List.prototype.push = function push(/*...values*/
         
     | 
| 
       2626 
     | 
    
         
            -
              ) {
         
     | 
| 
       2627 
     | 
    
         
            -
                var values = arguments;
         
     | 
| 
       2628 
     | 
    
         
            -
                var oldSize = this.size;
         
     | 
| 
       2629 
     | 
    
         
            -
                return this.withMutations(function (list) {
         
     | 
| 
       2630 
     | 
    
         
            -
                  setListBounds(list, 0, oldSize + values.length);
         
     | 
| 
       2631 
     | 
    
         
            -
                  for (var ii = 0; ii < values.length; ii++) {
         
     | 
| 
       2632 
     | 
    
         
            -
                    list.set(oldSize + ii, values[ii]);
         
     | 
| 
       2633 
     | 
    
         
            -
                  }
         
     | 
| 
       2634 
     | 
    
         
            -
                });
         
     | 
| 
       2635 
     | 
    
         
            -
              };
         
     | 
| 
       2636 
     | 
    
         
            -
              List.prototype.pop = function pop() {
         
     | 
| 
       2637 
     | 
    
         
            -
                return setListBounds(this, 0, -1);
         
     | 
| 
       2638 
     | 
    
         
            -
              };
         
     | 
| 
       2639 
     | 
    
         
            -
              List.prototype.unshift = function unshift(/*...values*/
         
     | 
| 
       2640 
     | 
    
         
            -
              ) {
         
     | 
| 
       2641 
     | 
    
         
            -
                var values = arguments;
         
     | 
| 
       2642 
     | 
    
         
            -
                return this.withMutations(function (list) {
         
     | 
| 
       2643 
     | 
    
         
            -
                  setListBounds(list, -values.length);
         
     | 
| 
       2644 
     | 
    
         
            -
                  for (var ii = 0; ii < values.length; ii++) {
         
     | 
| 
       2645 
     | 
    
         
            -
                    list.set(ii, values[ii]);
         
     | 
| 
       2646 
     | 
    
         
            -
                  }
         
     | 
| 
       2647 
     | 
    
         
            -
                });
         
     | 
| 
       2648 
     | 
    
         
            -
              };
         
     | 
| 
       2649 
     | 
    
         
            -
              List.prototype.shift = function shift() {
         
     | 
| 
       2650 
     | 
    
         
            -
                return setListBounds(this, 1);
         
     | 
| 
       2651 
     | 
    
         
            -
              };
         
     | 
| 
       2652 
     | 
    
         
            -
             
     | 
| 
       2653 
     | 
    
         
            -
              // @pragma Composition
         
     | 
| 
       2654 
     | 
    
         
            -
             
     | 
| 
       2655 
     | 
    
         
            -
              List.prototype.concat = function concat(/*...collections*/
         
     | 
| 
       2656 
     | 
    
         
            -
              ) {
         
     | 
| 
       2657 
     | 
    
         
            -
                var arguments$1 = arguments;
         
     | 
| 
       2658 
     | 
    
         
            -
                var seqs = [];
         
     | 
| 
       2659 
     | 
    
         
            -
                for (var i = 0; i < arguments.length; i++) {
         
     | 
| 
       2660 
     | 
    
         
            -
                  var argument = arguments$1[i];
         
     | 
| 
       2661 
     | 
    
         
            -
                  var seq = IndexedCollection(typeof argument !== 'string' && hasIterator(argument) ? argument : [argument]);
         
     | 
| 
       2662 
     | 
    
         
            -
                  if (seq.size !== 0) {
         
     | 
| 
       2663 
     | 
    
         
            -
                    seqs.push(seq);
         
     | 
| 
       2664 
     | 
    
         
            -
                  }
         
     | 
| 
       2665 
     | 
    
         
            -
                }
         
     | 
| 
       2666 
     | 
    
         
            -
                if (seqs.length === 0) {
         
     | 
| 
       2667 
     | 
    
         
            -
                  return this;
         
     | 
| 
       2668 
     | 
    
         
            -
                }
         
     | 
| 
       2669 
     | 
    
         
            -
                if (this.size === 0 && !this.__ownerID && seqs.length === 1) {
         
     | 
| 
       2670 
     | 
    
         
            -
                  return this.constructor(seqs[0]);
         
     | 
| 
       2671 
     | 
    
         
            -
                }
         
     | 
| 
       2672 
     | 
    
         
            -
                return this.withMutations(function (list) {
         
     | 
| 
       2673 
     | 
    
         
            -
                  seqs.forEach(function (seq) {
         
     | 
| 
       2674 
     | 
    
         
            -
                    return seq.forEach(function (value) {
         
     | 
| 
       2675 
     | 
    
         
            -
                      return list.push(value);
         
     | 
| 
       2676 
     | 
    
         
            -
                    });
         
     | 
| 
       2677 
     | 
    
         
            -
                  });
         
     | 
| 
       2678 
     | 
    
         
            -
                });
         
     | 
| 
       2679 
     | 
    
         
            -
              };
         
     | 
| 
       2680 
     | 
    
         
            -
              List.prototype.setSize = function setSize(size) {
         
     | 
| 
       2681 
     | 
    
         
            -
                return setListBounds(this, 0, size);
         
     | 
| 
       2682 
     | 
    
         
            -
              };
         
     | 
| 
       2683 
     | 
    
         
            -
              List.prototype.map = function map(mapper, context) {
         
     | 
| 
       2684 
     | 
    
         
            -
                var this$1$1 = this;
         
     | 
| 
       2685 
     | 
    
         
            -
                return this.withMutations(function (list) {
         
     | 
| 
       2686 
     | 
    
         
            -
                  for (var i = 0; i < this$1$1.size; i++) {
         
     | 
| 
       2687 
     | 
    
         
            -
                    list.set(i, mapper.call(context, list.get(i), i, this$1$1));
         
     | 
| 
       2688 
     | 
    
         
            -
                  }
         
     | 
| 
       2689 
     | 
    
         
            -
                });
         
     | 
| 
       2690 
     | 
    
         
            -
              };
         
     | 
| 
       2691 
     | 
    
         
            -
             
     | 
| 
       2692 
     | 
    
         
            -
              // @pragma Iteration
         
     | 
| 
       2693 
     | 
    
         
            -
             
     | 
| 
       2694 
     | 
    
         
            -
              List.prototype.slice = function slice(begin, end) {
         
     | 
| 
       2695 
     | 
    
         
            -
                var size = this.size;
         
     | 
| 
       2696 
     | 
    
         
            -
                if (wholeSlice(begin, end, size)) {
         
     | 
| 
       2697 
     | 
    
         
            -
                  return this;
         
     | 
| 
       2698 
     | 
    
         
            -
                }
         
     | 
| 
       2699 
     | 
    
         
            -
                return setListBounds(this, resolveBegin(begin, size), resolveEnd(end, size));
         
     | 
| 
       2700 
     | 
    
         
            -
              };
         
     | 
| 
       2701 
     | 
    
         
            -
              List.prototype.__iterator = function __iterator(type, reverse) {
         
     | 
| 
       2702 
     | 
    
         
            -
                var index = reverse ? this.size : 0;
         
     | 
| 
       2703 
     | 
    
         
            -
                var values = iterateList(this, reverse);
         
     | 
| 
       2704 
     | 
    
         
            -
                return new Iterator(function () {
         
     | 
| 
       2705 
     | 
    
         
            -
                  var value = values();
         
     | 
| 
       2706 
     | 
    
         
            -
                  return value === DONE ? iteratorDone() : iteratorValue(type, reverse ? --index : index++, value);
         
     | 
| 
       2707 
     | 
    
         
            -
                });
         
     | 
| 
       2708 
     | 
    
         
            -
              };
         
     | 
| 
       2709 
     | 
    
         
            -
              List.prototype.__iterate = function __iterate(fn, reverse) {
         
     | 
| 
       2710 
     | 
    
         
            -
                var index = reverse ? this.size : 0;
         
     | 
| 
       2711 
     | 
    
         
            -
                var values = iterateList(this, reverse);
         
     | 
| 
       2712 
     | 
    
         
            -
                var value;
         
     | 
| 
       2713 
     | 
    
         
            -
                while ((value = values()) !== DONE) {
         
     | 
| 
       2714 
     | 
    
         
            -
                  if (fn(value, reverse ? --index : index++, this) === false) {
         
     | 
| 
       2715 
     | 
    
         
            -
                    break;
         
     | 
| 
       2716 
     | 
    
         
            -
                  }
         
     | 
| 
       2717 
     | 
    
         
            -
                }
         
     | 
| 
       2718 
     | 
    
         
            -
                return index;
         
     | 
| 
       2719 
     | 
    
         
            -
              };
         
     | 
| 
       2720 
     | 
    
         
            -
              List.prototype.__ensureOwner = function __ensureOwner(ownerID) {
         
     | 
| 
       2721 
     | 
    
         
            -
                if (ownerID === this.__ownerID) {
         
     | 
| 
       2722 
     | 
    
         
            -
                  return this;
         
     | 
| 
       2723 
     | 
    
         
            -
                }
         
     | 
| 
       2724 
     | 
    
         
            -
                if (!ownerID) {
         
     | 
| 
       2725 
     | 
    
         
            -
                  if (this.size === 0) {
         
     | 
| 
       2726 
     | 
    
         
            -
                    return emptyList();
         
     | 
| 
       2727 
     | 
    
         
            -
                  }
         
     | 
| 
       2728 
     | 
    
         
            -
                  this.__ownerID = ownerID;
         
     | 
| 
       2729 
     | 
    
         
            -
                  this.__altered = false;
         
     | 
| 
       2730 
     | 
    
         
            -
                  return this;
         
     | 
| 
       2731 
     | 
    
         
            -
                }
         
     | 
| 
       2732 
     | 
    
         
            -
                return makeList(this._origin, this._capacity, this._level, this._root, this._tail, ownerID, this.__hash);
         
     | 
| 
       2733 
     | 
    
         
            -
              };
         
     | 
| 
       2734 
     | 
    
         
            -
              return List;
         
     | 
| 
       2735 
     | 
    
         
            -
            }(IndexedCollection);
         
     | 
| 
       2736 
     | 
    
         
            -
            List.isList = isList;
         
     | 
| 
       2737 
     | 
    
         
            -
            var ListPrototype = List.prototype;
         
     | 
| 
       2738 
     | 
    
         
            -
            ListPrototype[IS_LIST_SYMBOL] = true;
         
     | 
| 
       2739 
     | 
    
         
            -
            ListPrototype[DELETE] = ListPrototype.remove;
         
     | 
| 
       2740 
     | 
    
         
            -
            ListPrototype.merge = ListPrototype.concat;
         
     | 
| 
       2741 
     | 
    
         
            -
            ListPrototype.setIn = setIn;
         
     | 
| 
       2742 
     | 
    
         
            -
            ListPrototype.deleteIn = ListPrototype.removeIn = deleteIn;
         
     | 
| 
       2743 
     | 
    
         
            -
            ListPrototype.update = update;
         
     | 
| 
       2744 
     | 
    
         
            -
            ListPrototype.updateIn = updateIn;
         
     | 
| 
       2745 
     | 
    
         
            -
            ListPrototype.mergeIn = mergeIn;
         
     | 
| 
       2746 
     | 
    
         
            -
            ListPrototype.mergeDeepIn = mergeDeepIn;
         
     | 
| 
       2747 
     | 
    
         
            -
            ListPrototype.withMutations = withMutations;
         
     | 
| 
       2748 
     | 
    
         
            -
            ListPrototype.wasAltered = wasAltered;
         
     | 
| 
       2749 
     | 
    
         
            -
            ListPrototype.asImmutable = asImmutable;
         
     | 
| 
       2750 
     | 
    
         
            -
            ListPrototype['@@transducer/init'] = ListPrototype.asMutable = asMutable;
         
     | 
| 
       2751 
     | 
    
         
            -
            ListPrototype['@@transducer/step'] = function (result, arr) {
         
     | 
| 
       2752 
     | 
    
         
            -
              return result.push(arr);
         
     | 
| 
       2753 
     | 
    
         
            -
            };
         
     | 
| 
       2754 
     | 
    
         
            -
            ListPrototype['@@transducer/result'] = function (obj) {
         
     | 
| 
       2755 
     | 
    
         
            -
              return obj.asImmutable();
         
     | 
| 
       2756 
     | 
    
         
            -
            };
         
     | 
| 
       2757 
     | 
    
         
            -
            var VNode = function VNode(array, ownerID) {
         
     | 
| 
       2758 
     | 
    
         
            -
              this.array = array;
         
     | 
| 
       2759 
     | 
    
         
            -
              this.ownerID = ownerID;
         
     | 
| 
       2760 
     | 
    
         
            -
            };
         
     | 
| 
       2761 
     | 
    
         
            -
             
     | 
| 
       2762 
     | 
    
         
            -
            // TODO: seems like these methods are very similar
         
     | 
| 
       2763 
     | 
    
         
            -
             
     | 
| 
       2764 
     | 
    
         
            -
            VNode.prototype.removeBefore = function removeBefore(ownerID, level, index) {
         
     | 
| 
       2765 
     | 
    
         
            -
              if (index === level ? 1 << level : this.array.length === 0) {
         
     | 
| 
       2766 
     | 
    
         
            -
                return this;
         
     | 
| 
       2767 
     | 
    
         
            -
              }
         
     | 
| 
       2768 
     | 
    
         
            -
              var originIndex = index >>> level & MASK;
         
     | 
| 
       2769 
     | 
    
         
            -
              if (originIndex >= this.array.length) {
         
     | 
| 
       2770 
     | 
    
         
            -
                return new VNode([], ownerID);
         
     | 
| 
       2771 
     | 
    
         
            -
              }
         
     | 
| 
       2772 
     | 
    
         
            -
              var removingFirst = originIndex === 0;
         
     | 
| 
       2773 
     | 
    
         
            -
              var newChild;
         
     | 
| 
       2774 
     | 
    
         
            -
              if (level > 0) {
         
     | 
| 
       2775 
     | 
    
         
            -
                var oldChild = this.array[originIndex];
         
     | 
| 
       2776 
     | 
    
         
            -
                newChild = oldChild && oldChild.removeBefore(ownerID, level - SHIFT, index);
         
     | 
| 
       2777 
     | 
    
         
            -
                if (newChild === oldChild && removingFirst) {
         
     | 
| 
       2778 
     | 
    
         
            -
                  return this;
         
     | 
| 
       2779 
     | 
    
         
            -
                }
         
     | 
| 
       2780 
     | 
    
         
            -
              }
         
     | 
| 
       2781 
     | 
    
         
            -
              if (removingFirst && !newChild) {
         
     | 
| 
       2782 
     | 
    
         
            -
                return this;
         
     | 
| 
       2783 
     | 
    
         
            -
              }
         
     | 
| 
       2784 
     | 
    
         
            -
              var editable = editableVNode(this, ownerID);
         
     | 
| 
       2785 
     | 
    
         
            -
              if (!removingFirst) {
         
     | 
| 
       2786 
     | 
    
         
            -
                for (var ii = 0; ii < originIndex; ii++) {
         
     | 
| 
       2787 
     | 
    
         
            -
                  editable.array[ii] = undefined;
         
     | 
| 
       2788 
     | 
    
         
            -
                }
         
     | 
| 
       2789 
     | 
    
         
            -
              }
         
     | 
| 
       2790 
     | 
    
         
            -
              if (newChild) {
         
     | 
| 
       2791 
     | 
    
         
            -
                editable.array[originIndex] = newChild;
         
     | 
| 
       2792 
     | 
    
         
            -
              }
         
     | 
| 
       2793 
     | 
    
         
            -
              return editable;
         
     | 
| 
       2794 
     | 
    
         
            -
            };
         
     | 
| 
       2795 
     | 
    
         
            -
            VNode.prototype.removeAfter = function removeAfter(ownerID, level, index) {
         
     | 
| 
       2796 
     | 
    
         
            -
              if (index === (level ? 1 << level : 0) || this.array.length === 0) {
         
     | 
| 
       2797 
     | 
    
         
            -
                return this;
         
     | 
| 
       2798 
     | 
    
         
            -
              }
         
     | 
| 
       2799 
     | 
    
         
            -
              var sizeIndex = index - 1 >>> level & MASK;
         
     | 
| 
       2800 
     | 
    
         
            -
              if (sizeIndex >= this.array.length) {
         
     | 
| 
       2801 
     | 
    
         
            -
                return this;
         
     | 
| 
       2802 
     | 
    
         
            -
              }
         
     | 
| 
       2803 
     | 
    
         
            -
              var newChild;
         
     | 
| 
       2804 
     | 
    
         
            -
              if (level > 0) {
         
     | 
| 
       2805 
     | 
    
         
            -
                var oldChild = this.array[sizeIndex];
         
     | 
| 
       2806 
     | 
    
         
            -
                newChild = oldChild && oldChild.removeAfter(ownerID, level - SHIFT, index);
         
     | 
| 
       2807 
     | 
    
         
            -
                if (newChild === oldChild && sizeIndex === this.array.length - 1) {
         
     | 
| 
       2808 
     | 
    
         
            -
                  return this;
         
     | 
| 
       2809 
     | 
    
         
            -
                }
         
     | 
| 
       2810 
     | 
    
         
            -
              }
         
     | 
| 
       2811 
     | 
    
         
            -
              var editable = editableVNode(this, ownerID);
         
     | 
| 
       2812 
     | 
    
         
            -
              editable.array.splice(sizeIndex + 1);
         
     | 
| 
       2813 
     | 
    
         
            -
              if (newChild) {
         
     | 
| 
       2814 
     | 
    
         
            -
                editable.array[sizeIndex] = newChild;
         
     | 
| 
       2815 
     | 
    
         
            -
              }
         
     | 
| 
       2816 
     | 
    
         
            -
              return editable;
         
     | 
| 
       2817 
     | 
    
         
            -
            };
         
     | 
| 
       2818 
     | 
    
         
            -
            var DONE = {};
         
     | 
| 
       2819 
     | 
    
         
            -
            function iterateList(list, reverse) {
         
     | 
| 
       2820 
     | 
    
         
            -
              var left = list._origin;
         
     | 
| 
       2821 
     | 
    
         
            -
              var right = list._capacity;
         
     | 
| 
       2822 
     | 
    
         
            -
              var tailPos = getTailOffset(right);
         
     | 
| 
       2823 
     | 
    
         
            -
              var tail = list._tail;
         
     | 
| 
       2824 
     | 
    
         
            -
              return iterateNodeOrLeaf(list._root, list._level, 0);
         
     | 
| 
       2825 
     | 
    
         
            -
              function iterateNodeOrLeaf(node, level, offset) {
         
     | 
| 
       2826 
     | 
    
         
            -
                return level === 0 ? iterateLeaf(node, offset) : iterateNode(node, level, offset);
         
     | 
| 
       2827 
     | 
    
         
            -
              }
         
     | 
| 
       2828 
     | 
    
         
            -
              function iterateLeaf(node, offset) {
         
     | 
| 
       2829 
     | 
    
         
            -
                var array = offset === tailPos ? tail && tail.array : node && node.array;
         
     | 
| 
       2830 
     | 
    
         
            -
                var from = offset > left ? 0 : left - offset;
         
     | 
| 
       2831 
     | 
    
         
            -
                var to = right - offset;
         
     | 
| 
       2832 
     | 
    
         
            -
                if (to > SIZE) {
         
     | 
| 
       2833 
     | 
    
         
            -
                  to = SIZE;
         
     | 
| 
       2834 
     | 
    
         
            -
                }
         
     | 
| 
       2835 
     | 
    
         
            -
                return function () {
         
     | 
| 
       2836 
     | 
    
         
            -
                  if (from === to) {
         
     | 
| 
       2837 
     | 
    
         
            -
                    return DONE;
         
     | 
| 
       2838 
     | 
    
         
            -
                  }
         
     | 
| 
       2839 
     | 
    
         
            -
                  var idx = reverse ? --to : from++;
         
     | 
| 
       2840 
     | 
    
         
            -
                  return array && array[idx];
         
     | 
| 
       2841 
     | 
    
         
            -
                };
         
     | 
| 
       2842 
     | 
    
         
            -
              }
         
     | 
| 
       2843 
     | 
    
         
            -
              function iterateNode(node, level, offset) {
         
     | 
| 
       2844 
     | 
    
         
            -
                var values;
         
     | 
| 
       2845 
     | 
    
         
            -
                var array = node && node.array;
         
     | 
| 
       2846 
     | 
    
         
            -
                var from = offset > left ? 0 : left - offset >> level;
         
     | 
| 
       2847 
     | 
    
         
            -
                var to = (right - offset >> level) + 1;
         
     | 
| 
       2848 
     | 
    
         
            -
                if (to > SIZE) {
         
     | 
| 
       2849 
     | 
    
         
            -
                  to = SIZE;
         
     | 
| 
       2850 
     | 
    
         
            -
                }
         
     | 
| 
       2851 
     | 
    
         
            -
                return function () {
         
     | 
| 
       2852 
     | 
    
         
            -
                  while (true) {
         
     | 
| 
       2853 
     | 
    
         
            -
                    if (values) {
         
     | 
| 
       2854 
     | 
    
         
            -
                      var value = values();
         
     | 
| 
       2855 
     | 
    
         
            -
                      if (value !== DONE) {
         
     | 
| 
       2856 
     | 
    
         
            -
                        return value;
         
     | 
| 
       2857 
     | 
    
         
            -
                      }
         
     | 
| 
       2858 
     | 
    
         
            -
                      values = null;
         
     | 
| 
       2859 
     | 
    
         
            -
                    }
         
     | 
| 
       2860 
     | 
    
         
            -
                    if (from === to) {
         
     | 
| 
       2861 
     | 
    
         
            -
                      return DONE;
         
     | 
| 
       2862 
     | 
    
         
            -
                    }
         
     | 
| 
       2863 
     | 
    
         
            -
                    var idx = reverse ? --to : from++;
         
     | 
| 
       2864 
     | 
    
         
            -
                    values = iterateNodeOrLeaf(array && array[idx], level - SHIFT, offset + (idx << level));
         
     | 
| 
       2865 
     | 
    
         
            -
                  }
         
     | 
| 
       2866 
     | 
    
         
            -
                };
         
     | 
| 
       2867 
     | 
    
         
            -
              }
         
     | 
| 
       2868 
     | 
    
         
            -
            }
         
     | 
| 
       2869 
     | 
    
         
            -
            function makeList(origin, capacity, level, root, tail, ownerID, hash) {
         
     | 
| 
       2870 
     | 
    
         
            -
              var list = Object.create(ListPrototype);
         
     | 
| 
       2871 
     | 
    
         
            -
              list.size = capacity - origin;
         
     | 
| 
       2872 
     | 
    
         
            -
              list._origin = origin;
         
     | 
| 
       2873 
     | 
    
         
            -
              list._capacity = capacity;
         
     | 
| 
       2874 
     | 
    
         
            -
              list._level = level;
         
     | 
| 
       2875 
     | 
    
         
            -
              list._root = root;
         
     | 
| 
       2876 
     | 
    
         
            -
              list._tail = tail;
         
     | 
| 
       2877 
     | 
    
         
            -
              list.__ownerID = ownerID;
         
     | 
| 
       2878 
     | 
    
         
            -
              list.__hash = hash;
         
     | 
| 
       2879 
     | 
    
         
            -
              list.__altered = false;
         
     | 
| 
       2880 
     | 
    
         
            -
              return list;
         
     | 
| 
       2881 
     | 
    
         
            -
            }
         
     | 
| 
       2882 
     | 
    
         
            -
            var EMPTY_LIST;
         
     | 
| 
       2883 
     | 
    
         
            -
            function emptyList() {
         
     | 
| 
       2884 
     | 
    
         
            -
              return EMPTY_LIST || (EMPTY_LIST = makeList(0, 0, SHIFT));
         
     | 
| 
       2885 
     | 
    
         
            -
            }
         
     | 
| 
       2886 
     | 
    
         
            -
            function updateList(list, index, value) {
         
     | 
| 
       2887 
     | 
    
         
            -
              index = wrapIndex(list, index);
         
     | 
| 
       2888 
     | 
    
         
            -
              if (index !== index) {
         
     | 
| 
       2889 
     | 
    
         
            -
                return list;
         
     | 
| 
       2890 
     | 
    
         
            -
              }
         
     | 
| 
       2891 
     | 
    
         
            -
              if (index >= list.size || index < 0) {
         
     | 
| 
       2892 
     | 
    
         
            -
                return list.withMutations(function (list) {
         
     | 
| 
       2893 
     | 
    
         
            -
                  index < 0 ? setListBounds(list, index).set(0, value) : setListBounds(list, 0, index + 1).set(index, value);
         
     | 
| 
       2894 
     | 
    
         
            -
                });
         
     | 
| 
       2895 
     | 
    
         
            -
              }
         
     | 
| 
       2896 
     | 
    
         
            -
              index += list._origin;
         
     | 
| 
       2897 
     | 
    
         
            -
              var newTail = list._tail;
         
     | 
| 
       2898 
     | 
    
         
            -
              var newRoot = list._root;
         
     | 
| 
       2899 
     | 
    
         
            -
              var didAlter = MakeRef();
         
     | 
| 
       2900 
     | 
    
         
            -
              if (index >= getTailOffset(list._capacity)) {
         
     | 
| 
       2901 
     | 
    
         
            -
                newTail = updateVNode(newTail, list.__ownerID, 0, index, value, didAlter);
         
     | 
| 
       2902 
     | 
    
         
            -
              } else {
         
     | 
| 
       2903 
     | 
    
         
            -
                newRoot = updateVNode(newRoot, list.__ownerID, list._level, index, value, didAlter);
         
     | 
| 
       2904 
     | 
    
         
            -
              }
         
     | 
| 
       2905 
     | 
    
         
            -
              if (!didAlter.value) {
         
     | 
| 
       2906 
     | 
    
         
            -
                return list;
         
     | 
| 
       2907 
     | 
    
         
            -
              }
         
     | 
| 
       2908 
     | 
    
         
            -
              if (list.__ownerID) {
         
     | 
| 
       2909 
     | 
    
         
            -
                list._root = newRoot;
         
     | 
| 
       2910 
     | 
    
         
            -
                list._tail = newTail;
         
     | 
| 
       2911 
     | 
    
         
            -
                list.__hash = undefined;
         
     | 
| 
       2912 
     | 
    
         
            -
                list.__altered = true;
         
     | 
| 
       2913 
     | 
    
         
            -
                return list;
         
     | 
| 
       2914 
     | 
    
         
            -
              }
         
     | 
| 
       2915 
     | 
    
         
            -
              return makeList(list._origin, list._capacity, list._level, newRoot, newTail);
         
     | 
| 
       2916 
     | 
    
         
            -
            }
         
     | 
| 
       2917 
     | 
    
         
            -
            function updateVNode(node, ownerID, level, index, value, didAlter) {
         
     | 
| 
       2918 
     | 
    
         
            -
              var idx = index >>> level & MASK;
         
     | 
| 
       2919 
     | 
    
         
            -
              var nodeHas = node && idx < node.array.length;
         
     | 
| 
       2920 
     | 
    
         
            -
              if (!nodeHas && value === undefined) {
         
     | 
| 
       2921 
     | 
    
         
            -
                return node;
         
     | 
| 
       2922 
     | 
    
         
            -
              }
         
     | 
| 
       2923 
     | 
    
         
            -
              var newNode;
         
     | 
| 
       2924 
     | 
    
         
            -
              if (level > 0) {
         
     | 
| 
       2925 
     | 
    
         
            -
                var lowerNode = node && node.array[idx];
         
     | 
| 
       2926 
     | 
    
         
            -
                var newLowerNode = updateVNode(lowerNode, ownerID, level - SHIFT, index, value, didAlter);
         
     | 
| 
       2927 
     | 
    
         
            -
                if (newLowerNode === lowerNode) {
         
     | 
| 
       2928 
     | 
    
         
            -
                  return node;
         
     | 
| 
       2929 
     | 
    
         
            -
                }
         
     | 
| 
       2930 
     | 
    
         
            -
                newNode = editableVNode(node, ownerID);
         
     | 
| 
       2931 
     | 
    
         
            -
                newNode.array[idx] = newLowerNode;
         
     | 
| 
       2932 
     | 
    
         
            -
                return newNode;
         
     | 
| 
       2933 
     | 
    
         
            -
              }
         
     | 
| 
       2934 
     | 
    
         
            -
              if (nodeHas && node.array[idx] === value) {
         
     | 
| 
       2935 
     | 
    
         
            -
                return node;
         
     | 
| 
       2936 
     | 
    
         
            -
              }
         
     | 
| 
       2937 
     | 
    
         
            -
              if (didAlter) {
         
     | 
| 
       2938 
     | 
    
         
            -
                SetRef(didAlter);
         
     | 
| 
       2939 
     | 
    
         
            -
              }
         
     | 
| 
       2940 
     | 
    
         
            -
              newNode = editableVNode(node, ownerID);
         
     | 
| 
       2941 
     | 
    
         
            -
              if (value === undefined && idx === newNode.array.length - 1) {
         
     | 
| 
       2942 
     | 
    
         
            -
                newNode.array.pop();
         
     | 
| 
       2943 
     | 
    
         
            -
              } else {
         
     | 
| 
       2944 
     | 
    
         
            -
                newNode.array[idx] = value;
         
     | 
| 
       2945 
     | 
    
         
            -
              }
         
     | 
| 
       2946 
     | 
    
         
            -
              return newNode;
         
     | 
| 
       2947 
     | 
    
         
            -
            }
         
     | 
| 
       2948 
     | 
    
         
            -
            function editableVNode(node, ownerID) {
         
     | 
| 
       2949 
     | 
    
         
            -
              if (ownerID && node && ownerID === node.ownerID) {
         
     | 
| 
       2950 
     | 
    
         
            -
                return node;
         
     | 
| 
       2951 
     | 
    
         
            -
              }
         
     | 
| 
       2952 
     | 
    
         
            -
              return new VNode(node ? node.array.slice() : [], ownerID);
         
     | 
| 
       2953 
     | 
    
         
            -
            }
         
     | 
| 
       2954 
     | 
    
         
            -
            function listNodeFor(list, rawIndex) {
         
     | 
| 
       2955 
     | 
    
         
            -
              if (rawIndex >= getTailOffset(list._capacity)) {
         
     | 
| 
       2956 
     | 
    
         
            -
                return list._tail;
         
     | 
| 
       2957 
     | 
    
         
            -
              }
         
     | 
| 
       2958 
     | 
    
         
            -
              if (rawIndex < 1 << list._level + SHIFT) {
         
     | 
| 
       2959 
     | 
    
         
            -
                var node = list._root;
         
     | 
| 
       2960 
     | 
    
         
            -
                var level = list._level;
         
     | 
| 
       2961 
     | 
    
         
            -
                while (node && level > 0) {
         
     | 
| 
       2962 
     | 
    
         
            -
                  node = node.array[rawIndex >>> level & MASK];
         
     | 
| 
       2963 
     | 
    
         
            -
                  level -= SHIFT;
         
     | 
| 
       2964 
     | 
    
         
            -
                }
         
     | 
| 
       2965 
     | 
    
         
            -
                return node;
         
     | 
| 
       2966 
     | 
    
         
            -
              }
         
     | 
| 
       2967 
     | 
    
         
            -
            }
         
     | 
| 
       2968 
     | 
    
         
            -
            function setListBounds(list, begin, end) {
         
     | 
| 
       2969 
     | 
    
         
            -
              // Sanitize begin & end using this shorthand for ToInt32(argument)
         
     | 
| 
       2970 
     | 
    
         
            -
              // http://www.ecma-international.org/ecma-262/6.0/#sec-toint32
         
     | 
| 
       2971 
     | 
    
         
            -
              if (begin !== undefined) {
         
     | 
| 
       2972 
     | 
    
         
            -
                begin |= 0;
         
     | 
| 
       2973 
     | 
    
         
            -
              }
         
     | 
| 
       2974 
     | 
    
         
            -
              if (end !== undefined) {
         
     | 
| 
       2975 
     | 
    
         
            -
                end |= 0;
         
     | 
| 
       2976 
     | 
    
         
            -
              }
         
     | 
| 
       2977 
     | 
    
         
            -
              var owner = list.__ownerID || new OwnerID();
         
     | 
| 
       2978 
     | 
    
         
            -
              var oldOrigin = list._origin;
         
     | 
| 
       2979 
     | 
    
         
            -
              var oldCapacity = list._capacity;
         
     | 
| 
       2980 
     | 
    
         
            -
              var newOrigin = oldOrigin + begin;
         
     | 
| 
       2981 
     | 
    
         
            -
              var newCapacity = end === undefined ? oldCapacity : end < 0 ? oldCapacity + end : oldOrigin + end;
         
     | 
| 
       2982 
     | 
    
         
            -
              if (newOrigin === oldOrigin && newCapacity === oldCapacity) {
         
     | 
| 
       2983 
     | 
    
         
            -
                return list;
         
     | 
| 
       2984 
     | 
    
         
            -
              }
         
     | 
| 
       2985 
     | 
    
         
            -
             
     | 
| 
       2986 
     | 
    
         
            -
              // If it's going to end after it starts, it's empty.
         
     | 
| 
       2987 
     | 
    
         
            -
              if (newOrigin >= newCapacity) {
         
     | 
| 
       2988 
     | 
    
         
            -
                return list.clear();
         
     | 
| 
       2989 
     | 
    
         
            -
              }
         
     | 
| 
       2990 
     | 
    
         
            -
              var newLevel = list._level;
         
     | 
| 
       2991 
     | 
    
         
            -
              var newRoot = list._root;
         
     | 
| 
       2992 
     | 
    
         
            -
             
     | 
| 
       2993 
     | 
    
         
            -
              // New origin might need creating a higher root.
         
     | 
| 
       2994 
     | 
    
         
            -
              var offsetShift = 0;
         
     | 
| 
       2995 
     | 
    
         
            -
              while (newOrigin + offsetShift < 0) {
         
     | 
| 
       2996 
     | 
    
         
            -
                newRoot = new VNode(newRoot && newRoot.array.length ? [undefined, newRoot] : [], owner);
         
     | 
| 
       2997 
     | 
    
         
            -
                newLevel += SHIFT;
         
     | 
| 
       2998 
     | 
    
         
            -
                offsetShift += 1 << newLevel;
         
     | 
| 
       2999 
     | 
    
         
            -
              }
         
     | 
| 
       3000 
     | 
    
         
            -
              if (offsetShift) {
         
     | 
| 
       3001 
     | 
    
         
            -
                newOrigin += offsetShift;
         
     | 
| 
       3002 
     | 
    
         
            -
                oldOrigin += offsetShift;
         
     | 
| 
       3003 
     | 
    
         
            -
                newCapacity += offsetShift;
         
     | 
| 
       3004 
     | 
    
         
            -
                oldCapacity += offsetShift;
         
     | 
| 
       3005 
     | 
    
         
            -
              }
         
     | 
| 
       3006 
     | 
    
         
            -
              var oldTailOffset = getTailOffset(oldCapacity);
         
     | 
| 
       3007 
     | 
    
         
            -
              var newTailOffset = getTailOffset(newCapacity);
         
     | 
| 
       3008 
     | 
    
         
            -
             
     | 
| 
       3009 
     | 
    
         
            -
              // New size might need creating a higher root.
         
     | 
| 
       3010 
     | 
    
         
            -
              while (newTailOffset >= 1 << newLevel + SHIFT) {
         
     | 
| 
       3011 
     | 
    
         
            -
                newRoot = new VNode(newRoot && newRoot.array.length ? [newRoot] : [], owner);
         
     | 
| 
       3012 
     | 
    
         
            -
                newLevel += SHIFT;
         
     | 
| 
       3013 
     | 
    
         
            -
              }
         
     | 
| 
       3014 
     | 
    
         
            -
             
     | 
| 
       3015 
     | 
    
         
            -
              // Locate or create the new tail.
         
     | 
| 
       3016 
     | 
    
         
            -
              var oldTail = list._tail;
         
     | 
| 
       3017 
     | 
    
         
            -
              var newTail = newTailOffset < oldTailOffset ? listNodeFor(list, newCapacity - 1) : newTailOffset > oldTailOffset ? new VNode([], owner) : oldTail;
         
     | 
| 
       3018 
     | 
    
         
            -
             
     | 
| 
       3019 
     | 
    
         
            -
              // Merge Tail into tree.
         
     | 
| 
       3020 
     | 
    
         
            -
              if (oldTail && newTailOffset > oldTailOffset && newOrigin < oldCapacity && oldTail.array.length) {
         
     | 
| 
       3021 
     | 
    
         
            -
                newRoot = editableVNode(newRoot, owner);
         
     | 
| 
       3022 
     | 
    
         
            -
                var node = newRoot;
         
     | 
| 
       3023 
     | 
    
         
            -
                for (var level = newLevel; level > SHIFT; level -= SHIFT) {
         
     | 
| 
       3024 
     | 
    
         
            -
                  var idx = oldTailOffset >>> level & MASK;
         
     | 
| 
       3025 
     | 
    
         
            -
                  node = node.array[idx] = editableVNode(node.array[idx], owner);
         
     | 
| 
       3026 
     | 
    
         
            -
                }
         
     | 
| 
       3027 
     | 
    
         
            -
                node.array[oldTailOffset >>> SHIFT & MASK] = oldTail;
         
     | 
| 
       3028 
     | 
    
         
            -
              }
         
     | 
| 
       3029 
     | 
    
         
            -
             
     | 
| 
       3030 
     | 
    
         
            -
              // If the size has been reduced, there's a chance the tail needs to be trimmed.
         
     | 
| 
       3031 
     | 
    
         
            -
              if (newCapacity < oldCapacity) {
         
     | 
| 
       3032 
     | 
    
         
            -
                newTail = newTail && newTail.removeAfter(owner, 0, newCapacity);
         
     | 
| 
       3033 
     | 
    
         
            -
              }
         
     | 
| 
       3034 
     | 
    
         
            -
             
     | 
| 
       3035 
     | 
    
         
            -
              // If the new origin is within the tail, then we do not need a root.
         
     | 
| 
       3036 
     | 
    
         
            -
              if (newOrigin >= newTailOffset) {
         
     | 
| 
       3037 
     | 
    
         
            -
                newOrigin -= newTailOffset;
         
     | 
| 
       3038 
     | 
    
         
            -
                newCapacity -= newTailOffset;
         
     | 
| 
       3039 
     | 
    
         
            -
                newLevel = SHIFT;
         
     | 
| 
       3040 
     | 
    
         
            -
                newRoot = null;
         
     | 
| 
       3041 
     | 
    
         
            -
                newTail = newTail && newTail.removeBefore(owner, 0, newOrigin);
         
     | 
| 
       3042 
     | 
    
         
            -
             
     | 
| 
       3043 
     | 
    
         
            -
                // Otherwise, if the root has been trimmed, garbage collect.
         
     | 
| 
       3044 
     | 
    
         
            -
              } else if (newOrigin > oldOrigin || newTailOffset < oldTailOffset) {
         
     | 
| 
       3045 
     | 
    
         
            -
                offsetShift = 0;
         
     | 
| 
       3046 
     | 
    
         
            -
             
     | 
| 
       3047 
     | 
    
         
            -
                // Identify the new top root node of the subtree of the old root.
         
     | 
| 
       3048 
     | 
    
         
            -
                while (newRoot) {
         
     | 
| 
       3049 
     | 
    
         
            -
                  var beginIndex = newOrigin >>> newLevel & MASK;
         
     | 
| 
       3050 
     | 
    
         
            -
                  if (beginIndex !== newTailOffset >>> newLevel & MASK) {
         
     | 
| 
       3051 
     | 
    
         
            -
                    break;
         
     | 
| 
       3052 
     | 
    
         
            -
                  }
         
     | 
| 
       3053 
     | 
    
         
            -
                  if (beginIndex) {
         
     | 
| 
       3054 
     | 
    
         
            -
                    offsetShift += (1 << newLevel) * beginIndex;
         
     | 
| 
       3055 
     | 
    
         
            -
                  }
         
     | 
| 
       3056 
     | 
    
         
            -
                  newLevel -= SHIFT;
         
     | 
| 
       3057 
     | 
    
         
            -
                  newRoot = newRoot.array[beginIndex];
         
     | 
| 
       3058 
     | 
    
         
            -
                }
         
     | 
| 
       3059 
     | 
    
         
            -
             
     | 
| 
       3060 
     | 
    
         
            -
                // Trim the new sides of the new root.
         
     | 
| 
       3061 
     | 
    
         
            -
                if (newRoot && newOrigin > oldOrigin) {
         
     | 
| 
       3062 
     | 
    
         
            -
                  newRoot = newRoot.removeBefore(owner, newLevel, newOrigin - offsetShift);
         
     | 
| 
       3063 
     | 
    
         
            -
                }
         
     | 
| 
       3064 
     | 
    
         
            -
                if (newRoot && newTailOffset < oldTailOffset) {
         
     | 
| 
       3065 
     | 
    
         
            -
                  newRoot = newRoot.removeAfter(owner, newLevel, newTailOffset - offsetShift);
         
     | 
| 
       3066 
     | 
    
         
            -
                }
         
     | 
| 
       3067 
     | 
    
         
            -
                if (offsetShift) {
         
     | 
| 
       3068 
     | 
    
         
            -
                  newOrigin -= offsetShift;
         
     | 
| 
       3069 
     | 
    
         
            -
                  newCapacity -= offsetShift;
         
     | 
| 
       3070 
     | 
    
         
            -
                }
         
     | 
| 
       3071 
     | 
    
         
            -
              }
         
     | 
| 
       3072 
     | 
    
         
            -
              if (list.__ownerID) {
         
     | 
| 
       3073 
     | 
    
         
            -
                list.size = newCapacity - newOrigin;
         
     | 
| 
       3074 
     | 
    
         
            -
                list._origin = newOrigin;
         
     | 
| 
       3075 
     | 
    
         
            -
                list._capacity = newCapacity;
         
     | 
| 
       3076 
     | 
    
         
            -
                list._level = newLevel;
         
     | 
| 
       3077 
     | 
    
         
            -
                list._root = newRoot;
         
     | 
| 
       3078 
     | 
    
         
            -
                list._tail = newTail;
         
     | 
| 
       3079 
     | 
    
         
            -
                list.__hash = undefined;
         
     | 
| 
       3080 
     | 
    
         
            -
                list.__altered = true;
         
     | 
| 
       3081 
     | 
    
         
            -
                return list;
         
     | 
| 
       3082 
     | 
    
         
            -
              }
         
     | 
| 
       3083 
     | 
    
         
            -
              return makeList(newOrigin, newCapacity, newLevel, newRoot, newTail);
         
     | 
| 
       3084 
     | 
    
         
            -
            }
         
     | 
| 
       3085 
     | 
    
         
            -
            function getTailOffset(size) {
         
     | 
| 
       3086 
     | 
    
         
            -
              return size < SIZE ? 0 : size - 1 >>> SHIFT << SHIFT;
         
     | 
| 
       3087 
     | 
    
         
            -
            }
         
     | 
| 
       3088 
     | 
    
         
            -
            var OrderedMap = /*@__PURE__*/function (Map) {
         
     | 
| 
       3089 
     | 
    
         
            -
              function OrderedMap(value) {
         
     | 
| 
       3090 
     | 
    
         
            -
                // eslint-disable-next-line no-constructor-return
         
     | 
| 
       3091 
     | 
    
         
            -
                return value === undefined || value === null ? emptyOrderedMap() : isOrderedMap(value) ? value : emptyOrderedMap().withMutations(function (map) {
         
     | 
| 
       3092 
     | 
    
         
            -
                  var iter = KeyedCollection(value);
         
     | 
| 
       3093 
     | 
    
         
            -
                  assertNotInfinite(iter.size);
         
     | 
| 
       3094 
     | 
    
         
            -
                  iter.forEach(function (v, k) {
         
     | 
| 
       3095 
     | 
    
         
            -
                    return map.set(k, v);
         
     | 
| 
       3096 
     | 
    
         
            -
                  });
         
     | 
| 
       3097 
     | 
    
         
            -
                });
         
     | 
| 
       3098 
     | 
    
         
            -
              }
         
     | 
| 
       3099 
     | 
    
         
            -
              if (Map) OrderedMap.__proto__ = Map;
         
     | 
| 
       3100 
     | 
    
         
            -
              OrderedMap.prototype = Object.create(Map && Map.prototype);
         
     | 
| 
       3101 
     | 
    
         
            -
              OrderedMap.prototype.constructor = OrderedMap;
         
     | 
| 
       3102 
     | 
    
         
            -
              OrderedMap.of = function of(/*...values*/
         
     | 
| 
       3103 
     | 
    
         
            -
              ) {
         
     | 
| 
       3104 
     | 
    
         
            -
                return this(arguments);
         
     | 
| 
       3105 
     | 
    
         
            -
              };
         
     | 
| 
       3106 
     | 
    
         
            -
              OrderedMap.prototype.toString = function toString() {
         
     | 
| 
       3107 
     | 
    
         
            -
                return this.__toString('OrderedMap {', '}');
         
     | 
| 
       3108 
     | 
    
         
            -
              };
         
     | 
| 
       3109 
     | 
    
         
            -
             
     | 
| 
       3110 
     | 
    
         
            -
              // @pragma Access
         
     | 
| 
       3111 
     | 
    
         
            -
             
     | 
| 
       3112 
     | 
    
         
            -
              OrderedMap.prototype.get = function get(k, notSetValue) {
         
     | 
| 
       3113 
     | 
    
         
            -
                var index = this._map.get(k);
         
     | 
| 
       3114 
     | 
    
         
            -
                return index !== undefined ? this._list.get(index)[1] : notSetValue;
         
     | 
| 
       3115 
     | 
    
         
            -
              };
         
     | 
| 
       3116 
     | 
    
         
            -
             
     | 
| 
       3117 
     | 
    
         
            -
              // @pragma Modification
         
     | 
| 
       3118 
     | 
    
         
            -
             
     | 
| 
       3119 
     | 
    
         
            -
              OrderedMap.prototype.clear = function clear() {
         
     | 
| 
       3120 
     | 
    
         
            -
                if (this.size === 0) {
         
     | 
| 
       3121 
     | 
    
         
            -
                  return this;
         
     | 
| 
       3122 
     | 
    
         
            -
                }
         
     | 
| 
       3123 
     | 
    
         
            -
                if (this.__ownerID) {
         
     | 
| 
       3124 
     | 
    
         
            -
                  this.size = 0;
         
     | 
| 
       3125 
     | 
    
         
            -
                  this._map.clear();
         
     | 
| 
       3126 
     | 
    
         
            -
                  this._list.clear();
         
     | 
| 
       3127 
     | 
    
         
            -
                  this.__altered = true;
         
     | 
| 
       3128 
     | 
    
         
            -
                  return this;
         
     | 
| 
       3129 
     | 
    
         
            -
                }
         
     | 
| 
       3130 
     | 
    
         
            -
                return emptyOrderedMap();
         
     | 
| 
       3131 
     | 
    
         
            -
              };
         
     | 
| 
       3132 
     | 
    
         
            -
              OrderedMap.prototype.set = function set(k, v) {
         
     | 
| 
       3133 
     | 
    
         
            -
                return updateOrderedMap(this, k, v);
         
     | 
| 
       3134 
     | 
    
         
            -
              };
         
     | 
| 
       3135 
     | 
    
         
            -
              OrderedMap.prototype.remove = function remove(k) {
         
     | 
| 
       3136 
     | 
    
         
            -
                return updateOrderedMap(this, k, NOT_SET);
         
     | 
| 
       3137 
     | 
    
         
            -
              };
         
     | 
| 
       3138 
     | 
    
         
            -
              OrderedMap.prototype.__iterate = function __iterate(fn, reverse) {
         
     | 
| 
       3139 
     | 
    
         
            -
                var this$1$1 = this;
         
     | 
| 
       3140 
     | 
    
         
            -
                return this._list.__iterate(function (entry) {
         
     | 
| 
       3141 
     | 
    
         
            -
                  return entry && fn(entry[1], entry[0], this$1$1);
         
     | 
| 
       3142 
     | 
    
         
            -
                }, reverse);
         
     | 
| 
       3143 
     | 
    
         
            -
              };
         
     | 
| 
       3144 
     | 
    
         
            -
              OrderedMap.prototype.__iterator = function __iterator(type, reverse) {
         
     | 
| 
       3145 
     | 
    
         
            -
                return this._list.fromEntrySeq().__iterator(type, reverse);
         
     | 
| 
       3146 
     | 
    
         
            -
              };
         
     | 
| 
       3147 
     | 
    
         
            -
              OrderedMap.prototype.__ensureOwner = function __ensureOwner(ownerID) {
         
     | 
| 
       3148 
     | 
    
         
            -
                if (ownerID === this.__ownerID) {
         
     | 
| 
       3149 
     | 
    
         
            -
                  return this;
         
     | 
| 
       3150 
     | 
    
         
            -
                }
         
     | 
| 
       3151 
     | 
    
         
            -
                var newMap = this._map.__ensureOwner(ownerID);
         
     | 
| 
       3152 
     | 
    
         
            -
                var newList = this._list.__ensureOwner(ownerID);
         
     | 
| 
       3153 
     | 
    
         
            -
                if (!ownerID) {
         
     | 
| 
       3154 
     | 
    
         
            -
                  if (this.size === 0) {
         
     | 
| 
       3155 
     | 
    
         
            -
                    return emptyOrderedMap();
         
     | 
| 
       3156 
     | 
    
         
            -
                  }
         
     | 
| 
       3157 
     | 
    
         
            -
                  this.__ownerID = ownerID;
         
     | 
| 
       3158 
     | 
    
         
            -
                  this.__altered = false;
         
     | 
| 
       3159 
     | 
    
         
            -
                  this._map = newMap;
         
     | 
| 
       3160 
     | 
    
         
            -
                  this._list = newList;
         
     | 
| 
       3161 
     | 
    
         
            -
                  return this;
         
     | 
| 
       3162 
     | 
    
         
            -
                }
         
     | 
| 
       3163 
     | 
    
         
            -
                return makeOrderedMap(newMap, newList, ownerID, this.__hash);
         
     | 
| 
       3164 
     | 
    
         
            -
              };
         
     | 
| 
       3165 
     | 
    
         
            -
              return OrderedMap;
         
     | 
| 
       3166 
     | 
    
         
            -
            }(Map);
         
     | 
| 
       3167 
     | 
    
         
            -
            OrderedMap.isOrderedMap = isOrderedMap;
         
     | 
| 
       3168 
     | 
    
         
            -
            OrderedMap.prototype[IS_ORDERED_SYMBOL] = true;
         
     | 
| 
       3169 
     | 
    
         
            -
            OrderedMap.prototype[DELETE] = OrderedMap.prototype.remove;
         
     | 
| 
       3170 
     | 
    
         
            -
            function makeOrderedMap(map, list, ownerID, hash) {
         
     | 
| 
       3171 
     | 
    
         
            -
              var omap = Object.create(OrderedMap.prototype);
         
     | 
| 
       3172 
     | 
    
         
            -
              omap.size = map ? map.size : 0;
         
     | 
| 
       3173 
     | 
    
         
            -
              omap._map = map;
         
     | 
| 
       3174 
     | 
    
         
            -
              omap._list = list;
         
     | 
| 
       3175 
     | 
    
         
            -
              omap.__ownerID = ownerID;
         
     | 
| 
       3176 
     | 
    
         
            -
              omap.__hash = hash;
         
     | 
| 
       3177 
     | 
    
         
            -
              omap.__altered = false;
         
     | 
| 
       3178 
     | 
    
         
            -
              return omap;
         
     | 
| 
       3179 
     | 
    
         
            -
            }
         
     | 
| 
       3180 
     | 
    
         
            -
            var EMPTY_ORDERED_MAP;
         
     | 
| 
       3181 
     | 
    
         
            -
            function emptyOrderedMap() {
         
     | 
| 
       3182 
     | 
    
         
            -
              return EMPTY_ORDERED_MAP || (EMPTY_ORDERED_MAP = makeOrderedMap(emptyMap(), emptyList()));
         
     | 
| 
       3183 
     | 
    
         
            -
            }
         
     | 
| 
       3184 
     | 
    
         
            -
            function updateOrderedMap(omap, k, v) {
         
     | 
| 
       3185 
     | 
    
         
            -
              var map = omap._map;
         
     | 
| 
       3186 
     | 
    
         
            -
              var list = omap._list;
         
     | 
| 
       3187 
     | 
    
         
            -
              var i = map.get(k);
         
     | 
| 
       3188 
     | 
    
         
            -
              var has = i !== undefined;
         
     | 
| 
       3189 
     | 
    
         
            -
              var newMap;
         
     | 
| 
       3190 
     | 
    
         
            -
              var newList;
         
     | 
| 
       3191 
     | 
    
         
            -
              if (v === NOT_SET) {
         
     | 
| 
       3192 
     | 
    
         
            -
                // removed
         
     | 
| 
       3193 
     | 
    
         
            -
                if (!has) {
         
     | 
| 
       3194 
     | 
    
         
            -
                  return omap;
         
     | 
| 
       3195 
     | 
    
         
            -
                }
         
     | 
| 
       3196 
     | 
    
         
            -
                if (list.size >= SIZE && list.size >= map.size * 2) {
         
     | 
| 
       3197 
     | 
    
         
            -
                  newList = list.filter(function (entry, idx) {
         
     | 
| 
       3198 
     | 
    
         
            -
                    return entry !== undefined && i !== idx;
         
     | 
| 
       3199 
     | 
    
         
            -
                  });
         
     | 
| 
       3200 
     | 
    
         
            -
                  newMap = newList.toKeyedSeq().map(function (entry) {
         
     | 
| 
       3201 
     | 
    
         
            -
                    return entry[0];
         
     | 
| 
       3202 
     | 
    
         
            -
                  }).flip().toMap();
         
     | 
| 
       3203 
     | 
    
         
            -
                  if (omap.__ownerID) {
         
     | 
| 
       3204 
     | 
    
         
            -
                    newMap.__ownerID = newList.__ownerID = omap.__ownerID;
         
     | 
| 
       3205 
     | 
    
         
            -
                  }
         
     | 
| 
       3206 
     | 
    
         
            -
                } else {
         
     | 
| 
       3207 
     | 
    
         
            -
                  newMap = map.remove(k);
         
     | 
| 
       3208 
     | 
    
         
            -
                  newList = i === list.size - 1 ? list.pop() : list.set(i, undefined);
         
     | 
| 
       3209 
     | 
    
         
            -
                }
         
     | 
| 
       3210 
     | 
    
         
            -
              } else if (has) {
         
     | 
| 
       3211 
     | 
    
         
            -
                if (v === list.get(i)[1]) {
         
     | 
| 
       3212 
     | 
    
         
            -
                  return omap;
         
     | 
| 
       3213 
     | 
    
         
            -
                }
         
     | 
| 
       3214 
     | 
    
         
            -
                newMap = map;
         
     | 
| 
       3215 
     | 
    
         
            -
                newList = list.set(i, [k, v]);
         
     | 
| 
       3216 
     | 
    
         
            -
              } else {
         
     | 
| 
       3217 
     | 
    
         
            -
                newMap = map.set(k, list.size);
         
     | 
| 
       3218 
     | 
    
         
            -
                newList = list.set(list.size, [k, v]);
         
     | 
| 
       3219 
     | 
    
         
            -
              }
         
     | 
| 
       3220 
     | 
    
         
            -
              if (omap.__ownerID) {
         
     | 
| 
       3221 
     | 
    
         
            -
                omap.size = newMap.size;
         
     | 
| 
       3222 
     | 
    
         
            -
                omap._map = newMap;
         
     | 
| 
       3223 
     | 
    
         
            -
                omap._list = newList;
         
     | 
| 
       3224 
     | 
    
         
            -
                omap.__hash = undefined;
         
     | 
| 
       3225 
     | 
    
         
            -
                omap.__altered = true;
         
     | 
| 
       3226 
     | 
    
         
            -
                return omap;
         
     | 
| 
       3227 
     | 
    
         
            -
              }
         
     | 
| 
       3228 
     | 
    
         
            -
              return makeOrderedMap(newMap, newList);
         
     | 
| 
       3229 
     | 
    
         
            -
            }
         
     | 
| 
       3230 
     | 
    
         
            -
            var IS_STACK_SYMBOL = '@@__IMMUTABLE_STACK__@@';
         
     | 
| 
       3231 
     | 
    
         
            -
            function isStack(maybeStack) {
         
     | 
| 
       3232 
     | 
    
         
            -
              return Boolean(maybeStack && maybeStack[IS_STACK_SYMBOL]);
         
     | 
| 
       3233 
     | 
    
         
            -
            }
         
     | 
| 
       3234 
     | 
    
         
            -
            var Stack = /*@__PURE__*/function (IndexedCollection) {
         
     | 
| 
       3235 
     | 
    
         
            -
              function Stack(value) {
         
     | 
| 
       3236 
     | 
    
         
            -
                // eslint-disable-next-line no-constructor-return
         
     | 
| 
       3237 
     | 
    
         
            -
                return value === undefined || value === null ? emptyStack() : isStack(value) ? value : emptyStack().pushAll(value);
         
     | 
| 
       3238 
     | 
    
         
            -
              }
         
     | 
| 
       3239 
     | 
    
         
            -
              if (IndexedCollection) Stack.__proto__ = IndexedCollection;
         
     | 
| 
       3240 
     | 
    
         
            -
              Stack.prototype = Object.create(IndexedCollection && IndexedCollection.prototype);
         
     | 
| 
       3241 
     | 
    
         
            -
              Stack.prototype.constructor = Stack;
         
     | 
| 
       3242 
     | 
    
         
            -
              Stack.of = function of(/*...values*/
         
     | 
| 
       3243 
     | 
    
         
            -
              ) {
         
     | 
| 
       3244 
     | 
    
         
            -
                return this(arguments);
         
     | 
| 
       3245 
     | 
    
         
            -
              };
         
     | 
| 
       3246 
     | 
    
         
            -
              Stack.prototype.toString = function toString() {
         
     | 
| 
       3247 
     | 
    
         
            -
                return this.__toString('Stack [', ']');
         
     | 
| 
       3248 
     | 
    
         
            -
              };
         
     | 
| 
       3249 
     | 
    
         
            -
             
     | 
| 
       3250 
     | 
    
         
            -
              // @pragma Access
         
     | 
| 
       3251 
     | 
    
         
            -
             
     | 
| 
       3252 
     | 
    
         
            -
              Stack.prototype.get = function get(index, notSetValue) {
         
     | 
| 
       3253 
     | 
    
         
            -
                var head = this._head;
         
     | 
| 
       3254 
     | 
    
         
            -
                index = wrapIndex(this, index);
         
     | 
| 
       3255 
     | 
    
         
            -
                while (head && index--) {
         
     | 
| 
       3256 
     | 
    
         
            -
                  head = head.next;
         
     | 
| 
       3257 
     | 
    
         
            -
                }
         
     | 
| 
       3258 
     | 
    
         
            -
                return head ? head.value : notSetValue;
         
     | 
| 
       3259 
     | 
    
         
            -
              };
         
     | 
| 
       3260 
     | 
    
         
            -
              Stack.prototype.peek = function peek() {
         
     | 
| 
       3261 
     | 
    
         
            -
                return this._head && this._head.value;
         
     | 
| 
       3262 
     | 
    
         
            -
              };
         
     | 
| 
       3263 
     | 
    
         
            -
             
     | 
| 
       3264 
     | 
    
         
            -
              // @pragma Modification
         
     | 
| 
       3265 
     | 
    
         
            -
             
     | 
| 
       3266 
     | 
    
         
            -
              Stack.prototype.push = function push(/*...values*/
         
     | 
| 
       3267 
     | 
    
         
            -
              ) {
         
     | 
| 
       3268 
     | 
    
         
            -
                var arguments$1 = arguments;
         
     | 
| 
       3269 
     | 
    
         
            -
                if (arguments.length === 0) {
         
     | 
| 
       3270 
     | 
    
         
            -
                  return this;
         
     | 
| 
       3271 
     | 
    
         
            -
                }
         
     | 
| 
       3272 
     | 
    
         
            -
                var newSize = this.size + arguments.length;
         
     | 
| 
       3273 
     | 
    
         
            -
                var head = this._head;
         
     | 
| 
       3274 
     | 
    
         
            -
                for (var ii = arguments.length - 1; ii >= 0; ii--) {
         
     | 
| 
       3275 
     | 
    
         
            -
                  head = {
         
     | 
| 
       3276 
     | 
    
         
            -
                    value: arguments$1[ii],
         
     | 
| 
       3277 
     | 
    
         
            -
                    next: head
         
     | 
| 
       3278 
     | 
    
         
            -
                  };
         
     | 
| 
       3279 
     | 
    
         
            -
                }
         
     | 
| 
       3280 
     | 
    
         
            -
                if (this.__ownerID) {
         
     | 
| 
       3281 
     | 
    
         
            -
                  this.size = newSize;
         
     | 
| 
       3282 
     | 
    
         
            -
                  this._head = head;
         
     | 
| 
       3283 
     | 
    
         
            -
                  this.__hash = undefined;
         
     | 
| 
       3284 
     | 
    
         
            -
                  this.__altered = true;
         
     | 
| 
       3285 
     | 
    
         
            -
                  return this;
         
     | 
| 
       3286 
     | 
    
         
            -
                }
         
     | 
| 
       3287 
     | 
    
         
            -
                return makeStack(newSize, head);
         
     | 
| 
       3288 
     | 
    
         
            -
              };
         
     | 
| 
       3289 
     | 
    
         
            -
              Stack.prototype.pushAll = function pushAll(iter) {
         
     | 
| 
       3290 
     | 
    
         
            -
                iter = IndexedCollection(iter);
         
     | 
| 
       3291 
     | 
    
         
            -
                if (iter.size === 0) {
         
     | 
| 
       3292 
     | 
    
         
            -
                  return this;
         
     | 
| 
       3293 
     | 
    
         
            -
                }
         
     | 
| 
       3294 
     | 
    
         
            -
                if (this.size === 0 && isStack(iter)) {
         
     | 
| 
       3295 
     | 
    
         
            -
                  return iter;
         
     | 
| 
       3296 
     | 
    
         
            -
                }
         
     | 
| 
       3297 
     | 
    
         
            -
                assertNotInfinite(iter.size);
         
     | 
| 
       3298 
     | 
    
         
            -
                var newSize = this.size;
         
     | 
| 
       3299 
     | 
    
         
            -
                var head = this._head;
         
     | 
| 
       3300 
     | 
    
         
            -
                iter.__iterate(function (value) {
         
     | 
| 
       3301 
     | 
    
         
            -
                  newSize++;
         
     | 
| 
       3302 
     | 
    
         
            -
                  head = {
         
     | 
| 
       3303 
     | 
    
         
            -
                    value: value,
         
     | 
| 
       3304 
     | 
    
         
            -
                    next: head
         
     | 
| 
       3305 
     | 
    
         
            -
                  };
         
     | 
| 
       3306 
     | 
    
         
            -
                }, /* reverse */true);
         
     | 
| 
       3307 
     | 
    
         
            -
                if (this.__ownerID) {
         
     | 
| 
       3308 
     | 
    
         
            -
                  this.size = newSize;
         
     | 
| 
       3309 
     | 
    
         
            -
                  this._head = head;
         
     | 
| 
       3310 
     | 
    
         
            -
                  this.__hash = undefined;
         
     | 
| 
       3311 
     | 
    
         
            -
                  this.__altered = true;
         
     | 
| 
       3312 
     | 
    
         
            -
                  return this;
         
     | 
| 
       3313 
     | 
    
         
            -
                }
         
     | 
| 
       3314 
     | 
    
         
            -
                return makeStack(newSize, head);
         
     | 
| 
       3315 
     | 
    
         
            -
              };
         
     | 
| 
       3316 
     | 
    
         
            -
              Stack.prototype.pop = function pop() {
         
     | 
| 
       3317 
     | 
    
         
            -
                return this.slice(1);
         
     | 
| 
       3318 
     | 
    
         
            -
              };
         
     | 
| 
       3319 
     | 
    
         
            -
              Stack.prototype.clear = function clear() {
         
     | 
| 
       3320 
     | 
    
         
            -
                if (this.size === 0) {
         
     | 
| 
       3321 
     | 
    
         
            -
                  return this;
         
     | 
| 
       3322 
     | 
    
         
            -
                }
         
     | 
| 
       3323 
     | 
    
         
            -
                if (this.__ownerID) {
         
     | 
| 
       3324 
     | 
    
         
            -
                  this.size = 0;
         
     | 
| 
       3325 
     | 
    
         
            -
                  this._head = undefined;
         
     | 
| 
       3326 
     | 
    
         
            -
                  this.__hash = undefined;
         
     | 
| 
       3327 
     | 
    
         
            -
                  this.__altered = true;
         
     | 
| 
       3328 
     | 
    
         
            -
                  return this;
         
     | 
| 
       3329 
     | 
    
         
            -
                }
         
     | 
| 
       3330 
     | 
    
         
            -
                return emptyStack();
         
     | 
| 
       3331 
     | 
    
         
            -
              };
         
     | 
| 
       3332 
     | 
    
         
            -
              Stack.prototype.slice = function slice(begin, end) {
         
     | 
| 
       3333 
     | 
    
         
            -
                if (wholeSlice(begin, end, this.size)) {
         
     | 
| 
       3334 
     | 
    
         
            -
                  return this;
         
     | 
| 
       3335 
     | 
    
         
            -
                }
         
     | 
| 
       3336 
     | 
    
         
            -
                var resolvedBegin = resolveBegin(begin, this.size);
         
     | 
| 
       3337 
     | 
    
         
            -
                var resolvedEnd = resolveEnd(end, this.size);
         
     | 
| 
       3338 
     | 
    
         
            -
                if (resolvedEnd !== this.size) {
         
     | 
| 
       3339 
     | 
    
         
            -
                  // super.slice(begin, end);
         
     | 
| 
       3340 
     | 
    
         
            -
                  return IndexedCollection.prototype.slice.call(this, begin, end);
         
     | 
| 
       3341 
     | 
    
         
            -
                }
         
     | 
| 
       3342 
     | 
    
         
            -
                var newSize = this.size - resolvedBegin;
         
     | 
| 
       3343 
     | 
    
         
            -
                var head = this._head;
         
     | 
| 
       3344 
     | 
    
         
            -
                while (resolvedBegin--) {
         
     | 
| 
       3345 
     | 
    
         
            -
                  head = head.next;
         
     | 
| 
       3346 
     | 
    
         
            -
                }
         
     | 
| 
       3347 
     | 
    
         
            -
                if (this.__ownerID) {
         
     | 
| 
       3348 
     | 
    
         
            -
                  this.size = newSize;
         
     | 
| 
       3349 
     | 
    
         
            -
                  this._head = head;
         
     | 
| 
       3350 
     | 
    
         
            -
                  this.__hash = undefined;
         
     | 
| 
       3351 
     | 
    
         
            -
                  this.__altered = true;
         
     | 
| 
       3352 
     | 
    
         
            -
                  return this;
         
     | 
| 
       3353 
     | 
    
         
            -
                }
         
     | 
| 
       3354 
     | 
    
         
            -
                return makeStack(newSize, head);
         
     | 
| 
       3355 
     | 
    
         
            -
              };
         
     | 
| 
       3356 
     | 
    
         
            -
             
     | 
| 
       3357 
     | 
    
         
            -
              // @pragma Mutability
         
     | 
| 
       3358 
     | 
    
         
            -
             
     | 
| 
       3359 
     | 
    
         
            -
              Stack.prototype.__ensureOwner = function __ensureOwner(ownerID) {
         
     | 
| 
       3360 
     | 
    
         
            -
                if (ownerID === this.__ownerID) {
         
     | 
| 
       3361 
     | 
    
         
            -
                  return this;
         
     | 
| 
       3362 
     | 
    
         
            -
                }
         
     | 
| 
       3363 
     | 
    
         
            -
                if (!ownerID) {
         
     | 
| 
       3364 
     | 
    
         
            -
                  if (this.size === 0) {
         
     | 
| 
       3365 
     | 
    
         
            -
                    return emptyStack();
         
     | 
| 
       3366 
     | 
    
         
            -
                  }
         
     | 
| 
       3367 
     | 
    
         
            -
                  this.__ownerID = ownerID;
         
     | 
| 
       3368 
     | 
    
         
            -
                  this.__altered = false;
         
     | 
| 
       3369 
     | 
    
         
            -
                  return this;
         
     | 
| 
       3370 
     | 
    
         
            -
                }
         
     | 
| 
       3371 
     | 
    
         
            -
                return makeStack(this.size, this._head, ownerID, this.__hash);
         
     | 
| 
       3372 
     | 
    
         
            -
              };
         
     | 
| 
       3373 
     | 
    
         
            -
             
     | 
| 
       3374 
     | 
    
         
            -
              // @pragma Iteration
         
     | 
| 
       3375 
     | 
    
         
            -
             
     | 
| 
       3376 
     | 
    
         
            -
              Stack.prototype.__iterate = function __iterate(fn, reverse) {
         
     | 
| 
       3377 
     | 
    
         
            -
                var this$1$1 = this;
         
     | 
| 
       3378 
     | 
    
         
            -
                if (reverse) {
         
     | 
| 
       3379 
     | 
    
         
            -
                  return new ArraySeq(this.toArray()).__iterate(function (v, k) {
         
     | 
| 
       3380 
     | 
    
         
            -
                    return fn(v, k, this$1$1);
         
     | 
| 
       3381 
     | 
    
         
            -
                  }, reverse);
         
     | 
| 
       3382 
     | 
    
         
            -
                }
         
     | 
| 
       3383 
     | 
    
         
            -
                var iterations = 0;
         
     | 
| 
       3384 
     | 
    
         
            -
                var node = this._head;
         
     | 
| 
       3385 
     | 
    
         
            -
                while (node) {
         
     | 
| 
       3386 
     | 
    
         
            -
                  if (fn(node.value, iterations++, this) === false) {
         
     | 
| 
       3387 
     | 
    
         
            -
                    break;
         
     | 
| 
       3388 
     | 
    
         
            -
                  }
         
     | 
| 
       3389 
     | 
    
         
            -
                  node = node.next;
         
     | 
| 
       3390 
     | 
    
         
            -
                }
         
     | 
| 
       3391 
     | 
    
         
            -
                return iterations;
         
     | 
| 
       3392 
     | 
    
         
            -
              };
         
     | 
| 
       3393 
     | 
    
         
            -
              Stack.prototype.__iterator = function __iterator(type, reverse) {
         
     | 
| 
       3394 
     | 
    
         
            -
                if (reverse) {
         
     | 
| 
       3395 
     | 
    
         
            -
                  return new ArraySeq(this.toArray()).__iterator(type, reverse);
         
     | 
| 
       3396 
     | 
    
         
            -
                }
         
     | 
| 
       3397 
     | 
    
         
            -
                var iterations = 0;
         
     | 
| 
       3398 
     | 
    
         
            -
                var node = this._head;
         
     | 
| 
       3399 
     | 
    
         
            -
                return new Iterator(function () {
         
     | 
| 
       3400 
     | 
    
         
            -
                  if (node) {
         
     | 
| 
       3401 
     | 
    
         
            -
                    var value = node.value;
         
     | 
| 
       3402 
     | 
    
         
            -
                    node = node.next;
         
     | 
| 
       3403 
     | 
    
         
            -
                    return iteratorValue(type, iterations++, value);
         
     | 
| 
       3404 
     | 
    
         
            -
                  }
         
     | 
| 
       3405 
     | 
    
         
            -
                  return iteratorDone();
         
     | 
| 
       3406 
     | 
    
         
            -
                });
         
     | 
| 
       3407 
     | 
    
         
            -
              };
         
     | 
| 
       3408 
     | 
    
         
            -
              return Stack;
         
     | 
| 
       3409 
     | 
    
         
            -
            }(IndexedCollection);
         
     | 
| 
       3410 
     | 
    
         
            -
            Stack.isStack = isStack;
         
     | 
| 
       3411 
     | 
    
         
            -
            var StackPrototype = Stack.prototype;
         
     | 
| 
       3412 
     | 
    
         
            -
            StackPrototype[IS_STACK_SYMBOL] = true;
         
     | 
| 
       3413 
     | 
    
         
            -
            StackPrototype.shift = StackPrototype.pop;
         
     | 
| 
       3414 
     | 
    
         
            -
            StackPrototype.unshift = StackPrototype.push;
         
     | 
| 
       3415 
     | 
    
         
            -
            StackPrototype.unshiftAll = StackPrototype.pushAll;
         
     | 
| 
       3416 
     | 
    
         
            -
            StackPrototype.withMutations = withMutations;
         
     | 
| 
       3417 
     | 
    
         
            -
            StackPrototype.wasAltered = wasAltered;
         
     | 
| 
       3418 
     | 
    
         
            -
            StackPrototype.asImmutable = asImmutable;
         
     | 
| 
       3419 
     | 
    
         
            -
            StackPrototype['@@transducer/init'] = StackPrototype.asMutable = asMutable;
         
     | 
| 
       3420 
     | 
    
         
            -
            StackPrototype['@@transducer/step'] = function (result, arr) {
         
     | 
| 
       3421 
     | 
    
         
            -
              return result.unshift(arr);
         
     | 
| 
       3422 
     | 
    
         
            -
            };
         
     | 
| 
       3423 
     | 
    
         
            -
            StackPrototype['@@transducer/result'] = function (obj) {
         
     | 
| 
       3424 
     | 
    
         
            -
              return obj.asImmutable();
         
     | 
| 
       3425 
     | 
    
         
            -
            };
         
     | 
| 
       3426 
     | 
    
         
            -
            function makeStack(size, head, ownerID, hash) {
         
     | 
| 
       3427 
     | 
    
         
            -
              var map = Object.create(StackPrototype);
         
     | 
| 
       3428 
     | 
    
         
            -
              map.size = size;
         
     | 
| 
       3429 
     | 
    
         
            -
              map._head = head;
         
     | 
| 
       3430 
     | 
    
         
            -
              map.__ownerID = ownerID;
         
     | 
| 
       3431 
     | 
    
         
            -
              map.__hash = hash;
         
     | 
| 
       3432 
     | 
    
         
            -
              map.__altered = false;
         
     | 
| 
       3433 
     | 
    
         
            -
              return map;
         
     | 
| 
       3434 
     | 
    
         
            -
            }
         
     | 
| 
       3435 
     | 
    
         
            -
            var EMPTY_STACK;
         
     | 
| 
       3436 
     | 
    
         
            -
            function emptyStack() {
         
     | 
| 
       3437 
     | 
    
         
            -
              return EMPTY_STACK || (EMPTY_STACK = makeStack(0));
         
     | 
| 
       3438 
     | 
    
         
            -
            }
         
     | 
| 
       3439 
     | 
    
         
            -
            var IS_SET_SYMBOL = '@@__IMMUTABLE_SET__@@';
         
     | 
| 
       3440 
     | 
    
         
            -
            function isSet(maybeSet) {
         
     | 
| 
       3441 
     | 
    
         
            -
              return Boolean(maybeSet && maybeSet[IS_SET_SYMBOL]);
         
     | 
| 
       3442 
     | 
    
         
            -
            }
         
     | 
| 
       3443 
     | 
    
         
            -
            function isOrderedSet(maybeOrderedSet) {
         
     | 
| 
       3444 
     | 
    
         
            -
              return isSet(maybeOrderedSet) && isOrdered(maybeOrderedSet);
         
     | 
| 
       3445 
     | 
    
         
            -
            }
         
     | 
| 
       3446 
     | 
    
         
            -
            function deepEqual(a, b) {
         
     | 
| 
       3447 
     | 
    
         
            -
              if (a === b) {
         
     | 
| 
       3448 
     | 
    
         
            -
                return true;
         
     | 
| 
       3449 
     | 
    
         
            -
              }
         
     | 
| 
       3450 
     | 
    
         
            -
              if (!isCollection(b) || a.size !== undefined && b.size !== undefined && a.size !== b.size || a.__hash !== undefined && b.__hash !== undefined && a.__hash !== b.__hash || isKeyed(a) !== isKeyed(b) || isIndexed(a) !== isIndexed(b) || isOrdered(a) !== isOrdered(b)) {
         
     | 
| 
       3451 
     | 
    
         
            -
                return false;
         
     | 
| 
       3452 
     | 
    
         
            -
              }
         
     | 
| 
       3453 
     | 
    
         
            -
              if (a.size === 0 && b.size === 0) {
         
     | 
| 
       3454 
     | 
    
         
            -
                return true;
         
     | 
| 
       3455 
     | 
    
         
            -
              }
         
     | 
| 
       3456 
     | 
    
         
            -
              var notAssociative = !isAssociative(a);
         
     | 
| 
       3457 
     | 
    
         
            -
              if (isOrdered(a)) {
         
     | 
| 
       3458 
     | 
    
         
            -
                var entries = a.entries();
         
     | 
| 
       3459 
     | 
    
         
            -
                return b.every(function (v, k) {
         
     | 
| 
       3460 
     | 
    
         
            -
                  var entry = entries.next().value;
         
     | 
| 
       3461 
     | 
    
         
            -
                  return entry && is(entry[1], v) && (notAssociative || is(entry[0], k));
         
     | 
| 
       3462 
     | 
    
         
            -
                }) && entries.next().done;
         
     | 
| 
       3463 
     | 
    
         
            -
              }
         
     | 
| 
       3464 
     | 
    
         
            -
              var flipped = false;
         
     | 
| 
       3465 
     | 
    
         
            -
              if (a.size === undefined) {
         
     | 
| 
       3466 
     | 
    
         
            -
                if (b.size === undefined) {
         
     | 
| 
       3467 
     | 
    
         
            -
                  if (typeof a.cacheResult === 'function') {
         
     | 
| 
       3468 
     | 
    
         
            -
                    a.cacheResult();
         
     | 
| 
       3469 
     | 
    
         
            -
                  }
         
     | 
| 
       3470 
     | 
    
         
            -
                } else {
         
     | 
| 
       3471 
     | 
    
         
            -
                  flipped = true;
         
     | 
| 
       3472 
     | 
    
         
            -
                  var _ = a;
         
     | 
| 
       3473 
     | 
    
         
            -
                  a = b;
         
     | 
| 
       3474 
     | 
    
         
            -
                  b = _;
         
     | 
| 
       3475 
     | 
    
         
            -
                }
         
     | 
| 
       3476 
     | 
    
         
            -
              }
         
     | 
| 
       3477 
     | 
    
         
            -
              var allEqual = true;
         
     | 
| 
       3478 
     | 
    
         
            -
              var bSize = b.__iterate(function (v, k) {
         
     | 
| 
       3479 
     | 
    
         
            -
                if (notAssociative ? !a.has(v) : flipped ? !is(v, a.get(k, NOT_SET)) : !is(a.get(k, NOT_SET), v)) {
         
     | 
| 
       3480 
     | 
    
         
            -
                  allEqual = false;
         
     | 
| 
       3481 
     | 
    
         
            -
                  return false;
         
     | 
| 
       3482 
     | 
    
         
            -
                }
         
     | 
| 
       3483 
     | 
    
         
            -
              });
         
     | 
| 
       3484 
     | 
    
         
            -
              return allEqual && a.size === bSize;
         
     | 
| 
       3485 
     | 
    
         
            -
            }
         
     | 
| 
       3486 
     | 
    
         
            -
            function mixin(ctor, methods) {
         
     | 
| 
       3487 
     | 
    
         
            -
              var keyCopier = function (key) {
         
     | 
| 
       3488 
     | 
    
         
            -
                ctor.prototype[key] = methods[key];
         
     | 
| 
       3489 
     | 
    
         
            -
              };
         
     | 
| 
       3490 
     | 
    
         
            -
              Object.keys(methods).forEach(keyCopier);
         
     | 
| 
       3491 
     | 
    
         
            -
              Object.getOwnPropertySymbols && Object.getOwnPropertySymbols(methods).forEach(keyCopier);
         
     | 
| 
       3492 
     | 
    
         
            -
              return ctor;
         
     | 
| 
       3493 
     | 
    
         
            -
            }
         
     | 
| 
       3494 
     | 
    
         
            -
            function toJS(value) {
         
     | 
| 
       3495 
     | 
    
         
            -
              if (!value || typeof value !== 'object') {
         
     | 
| 
       3496 
     | 
    
         
            -
                return value;
         
     | 
| 
       3497 
     | 
    
         
            -
              }
         
     | 
| 
       3498 
     | 
    
         
            -
              if (!isCollection(value)) {
         
     | 
| 
       3499 
     | 
    
         
            -
                if (!isDataStructure(value)) {
         
     | 
| 
       3500 
     | 
    
         
            -
                  return value;
         
     | 
| 
       3501 
     | 
    
         
            -
                }
         
     | 
| 
       3502 
     | 
    
         
            -
                value = Seq(value);
         
     | 
| 
       3503 
     | 
    
         
            -
              }
         
     | 
| 
       3504 
     | 
    
         
            -
              if (isKeyed(value)) {
         
     | 
| 
       3505 
     | 
    
         
            -
                var result$1 = {};
         
     | 
| 
       3506 
     | 
    
         
            -
                value.__iterate(function (v, k) {
         
     | 
| 
       3507 
     | 
    
         
            -
                  result$1[k] = toJS(v);
         
     | 
| 
       3508 
     | 
    
         
            -
                });
         
     | 
| 
       3509 
     | 
    
         
            -
                return result$1;
         
     | 
| 
       3510 
     | 
    
         
            -
              }
         
     | 
| 
       3511 
     | 
    
         
            -
              var result = [];
         
     | 
| 
       3512 
     | 
    
         
            -
              value.__iterate(function (v) {
         
     | 
| 
       3513 
     | 
    
         
            -
                result.push(toJS(v));
         
     | 
| 
       3514 
     | 
    
         
            -
              });
         
     | 
| 
       3515 
     | 
    
         
            -
              return result;
         
     | 
| 
       3516 
     | 
    
         
            -
            }
         
     | 
| 
       3517 
     | 
    
         
            -
            var Set = /*@__PURE__*/function (SetCollection) {
         
     | 
| 
       3518 
     | 
    
         
            -
              function Set(value) {
         
     | 
| 
       3519 
     | 
    
         
            -
                // eslint-disable-next-line no-constructor-return
         
     | 
| 
       3520 
     | 
    
         
            -
                return value === undefined || value === null ? emptySet() : isSet(value) && !isOrdered(value) ? value : emptySet().withMutations(function (set) {
         
     | 
| 
       3521 
     | 
    
         
            -
                  var iter = SetCollection(value);
         
     | 
| 
       3522 
     | 
    
         
            -
                  assertNotInfinite(iter.size);
         
     | 
| 
       3523 
     | 
    
         
            -
                  iter.forEach(function (v) {
         
     | 
| 
       3524 
     | 
    
         
            -
                    return set.add(v);
         
     | 
| 
       3525 
     | 
    
         
            -
                  });
         
     | 
| 
       3526 
     | 
    
         
            -
                });
         
     | 
| 
       3527 
     | 
    
         
            -
              }
         
     | 
| 
       3528 
     | 
    
         
            -
              if (SetCollection) Set.__proto__ = SetCollection;
         
     | 
| 
       3529 
     | 
    
         
            -
              Set.prototype = Object.create(SetCollection && SetCollection.prototype);
         
     | 
| 
       3530 
     | 
    
         
            -
              Set.prototype.constructor = Set;
         
     | 
| 
       3531 
     | 
    
         
            -
              Set.of = function of(/*...values*/
         
     | 
| 
       3532 
     | 
    
         
            -
              ) {
         
     | 
| 
       3533 
     | 
    
         
            -
                return this(arguments);
         
     | 
| 
       3534 
     | 
    
         
            -
              };
         
     | 
| 
       3535 
     | 
    
         
            -
              Set.fromKeys = function fromKeys(value) {
         
     | 
| 
       3536 
     | 
    
         
            -
                return this(KeyedCollection(value).keySeq());
         
     | 
| 
       3537 
     | 
    
         
            -
              };
         
     | 
| 
       3538 
     | 
    
         
            -
              Set.intersect = function intersect(sets) {
         
     | 
| 
       3539 
     | 
    
         
            -
                sets = Collection(sets).toArray();
         
     | 
| 
       3540 
     | 
    
         
            -
                return sets.length ? SetPrototype.intersect.apply(Set(sets.pop()), sets) : emptySet();
         
     | 
| 
       3541 
     | 
    
         
            -
              };
         
     | 
| 
       3542 
     | 
    
         
            -
              Set.union = function union(sets) {
         
     | 
| 
       3543 
     | 
    
         
            -
                sets = Collection(sets).toArray();
         
     | 
| 
       3544 
     | 
    
         
            -
                return sets.length ? SetPrototype.union.apply(Set(sets.pop()), sets) : emptySet();
         
     | 
| 
       3545 
     | 
    
         
            -
              };
         
     | 
| 
       3546 
     | 
    
         
            -
              Set.prototype.toString = function toString() {
         
     | 
| 
       3547 
     | 
    
         
            -
                return this.__toString('Set {', '}');
         
     | 
| 
       3548 
     | 
    
         
            -
              };
         
     | 
| 
       3549 
     | 
    
         
            -
             
     | 
| 
       3550 
     | 
    
         
            -
              // @pragma Access
         
     | 
| 
       3551 
     | 
    
         
            -
             
     | 
| 
       3552 
     | 
    
         
            -
              Set.prototype.has = function has(value) {
         
     | 
| 
       3553 
     | 
    
         
            -
                return this._map.has(value);
         
     | 
| 
       3554 
     | 
    
         
            -
              };
         
     | 
| 
       3555 
     | 
    
         
            -
             
     | 
| 
       3556 
     | 
    
         
            -
              // @pragma Modification
         
     | 
| 
       3557 
     | 
    
         
            -
             
     | 
| 
       3558 
     | 
    
         
            -
              Set.prototype.add = function add(value) {
         
     | 
| 
       3559 
     | 
    
         
            -
                return updateSet(this, this._map.set(value, value));
         
     | 
| 
       3560 
     | 
    
         
            -
              };
         
     | 
| 
       3561 
     | 
    
         
            -
              Set.prototype.remove = function remove(value) {
         
     | 
| 
       3562 
     | 
    
         
            -
                return updateSet(this, this._map.remove(value));
         
     | 
| 
       3563 
     | 
    
         
            -
              };
         
     | 
| 
       3564 
     | 
    
         
            -
              Set.prototype.clear = function clear() {
         
     | 
| 
       3565 
     | 
    
         
            -
                return updateSet(this, this._map.clear());
         
     | 
| 
       3566 
     | 
    
         
            -
              };
         
     | 
| 
       3567 
     | 
    
         
            -
             
     | 
| 
       3568 
     | 
    
         
            -
              // @pragma Composition
         
     | 
| 
       3569 
     | 
    
         
            -
             
     | 
| 
       3570 
     | 
    
         
            -
              Set.prototype.map = function map(mapper, context) {
         
     | 
| 
       3571 
     | 
    
         
            -
                var this$1$1 = this;
         
     | 
| 
       3572 
     | 
    
         
            -
             
     | 
| 
       3573 
     | 
    
         
            -
                // keep track if the set is altered by the map function
         
     | 
| 
       3574 
     | 
    
         
            -
                var didChanges = false;
         
     | 
| 
       3575 
     | 
    
         
            -
                var newMap = updateSet(this, this._map.mapEntries(function (ref) {
         
     | 
| 
       3576 
     | 
    
         
            -
                  var v = ref[1];
         
     | 
| 
       3577 
     | 
    
         
            -
                  var mapped = mapper.call(context, v, v, this$1$1);
         
     | 
| 
       3578 
     | 
    
         
            -
                  if (mapped !== v) {
         
     | 
| 
       3579 
     | 
    
         
            -
                    didChanges = true;
         
     | 
| 
       3580 
     | 
    
         
            -
                  }
         
     | 
| 
       3581 
     | 
    
         
            -
                  return [mapped, mapped];
         
     | 
| 
       3582 
     | 
    
         
            -
                }, context));
         
     | 
| 
       3583 
     | 
    
         
            -
                return didChanges ? newMap : this;
         
     | 
| 
       3584 
     | 
    
         
            -
              };
         
     | 
| 
       3585 
     | 
    
         
            -
              Set.prototype.union = function union() {
         
     | 
| 
       3586 
     | 
    
         
            -
                var iters = [],
         
     | 
| 
       3587 
     | 
    
         
            -
                  len = arguments.length;
         
     | 
| 
       3588 
     | 
    
         
            -
                while (len--) iters[len] = arguments[len];
         
     | 
| 
       3589 
     | 
    
         
            -
                iters = iters.filter(function (x) {
         
     | 
| 
       3590 
     | 
    
         
            -
                  return x.size !== 0;
         
     | 
| 
       3591 
     | 
    
         
            -
                });
         
     | 
| 
       3592 
     | 
    
         
            -
                if (iters.length === 0) {
         
     | 
| 
       3593 
     | 
    
         
            -
                  return this;
         
     | 
| 
       3594 
     | 
    
         
            -
                }
         
     | 
| 
       3595 
     | 
    
         
            -
                if (this.size === 0 && !this.__ownerID && iters.length === 1) {
         
     | 
| 
       3596 
     | 
    
         
            -
                  return this.constructor(iters[0]);
         
     | 
| 
       3597 
     | 
    
         
            -
                }
         
     | 
| 
       3598 
     | 
    
         
            -
                return this.withMutations(function (set) {
         
     | 
| 
       3599 
     | 
    
         
            -
                  for (var ii = 0; ii < iters.length; ii++) {
         
     | 
| 
       3600 
     | 
    
         
            -
                    if (typeof iters[ii] === 'string') {
         
     | 
| 
       3601 
     | 
    
         
            -
                      set.add(iters[ii]);
         
     | 
| 
       3602 
     | 
    
         
            -
                    } else {
         
     | 
| 
       3603 
     | 
    
         
            -
                      SetCollection(iters[ii]).forEach(function (value) {
         
     | 
| 
       3604 
     | 
    
         
            -
                        return set.add(value);
         
     | 
| 
       3605 
     | 
    
         
            -
                      });
         
     | 
| 
       3606 
     | 
    
         
            -
                    }
         
     | 
| 
       3607 
     | 
    
         
            -
                  }
         
     | 
| 
       3608 
     | 
    
         
            -
                });
         
     | 
| 
       3609 
     | 
    
         
            -
              };
         
     | 
| 
       3610 
     | 
    
         
            -
              Set.prototype.intersect = function intersect() {
         
     | 
| 
       3611 
     | 
    
         
            -
                var iters = [],
         
     | 
| 
       3612 
     | 
    
         
            -
                  len = arguments.length;
         
     | 
| 
       3613 
     | 
    
         
            -
                while (len--) iters[len] = arguments[len];
         
     | 
| 
       3614 
     | 
    
         
            -
                if (iters.length === 0) {
         
     | 
| 
       3615 
     | 
    
         
            -
                  return this;
         
     | 
| 
       3616 
     | 
    
         
            -
                }
         
     | 
| 
       3617 
     | 
    
         
            -
                iters = iters.map(function (iter) {
         
     | 
| 
       3618 
     | 
    
         
            -
                  return SetCollection(iter);
         
     | 
| 
       3619 
     | 
    
         
            -
                });
         
     | 
| 
       3620 
     | 
    
         
            -
                var toRemove = [];
         
     | 
| 
       3621 
     | 
    
         
            -
                this.forEach(function (value) {
         
     | 
| 
       3622 
     | 
    
         
            -
                  if (!iters.every(function (iter) {
         
     | 
| 
       3623 
     | 
    
         
            -
                    return iter.includes(value);
         
     | 
| 
       3624 
     | 
    
         
            -
                  })) {
         
     | 
| 
       3625 
     | 
    
         
            -
                    toRemove.push(value);
         
     | 
| 
       3626 
     | 
    
         
            -
                  }
         
     | 
| 
       3627 
     | 
    
         
            -
                });
         
     | 
| 
       3628 
     | 
    
         
            -
                return this.withMutations(function (set) {
         
     | 
| 
       3629 
     | 
    
         
            -
                  toRemove.forEach(function (value) {
         
     | 
| 
       3630 
     | 
    
         
            -
                    set.remove(value);
         
     | 
| 
       3631 
     | 
    
         
            -
                  });
         
     | 
| 
       3632 
     | 
    
         
            -
                });
         
     | 
| 
       3633 
     | 
    
         
            -
              };
         
     | 
| 
       3634 
     | 
    
         
            -
              Set.prototype.subtract = function subtract() {
         
     | 
| 
       3635 
     | 
    
         
            -
                var iters = [],
         
     | 
| 
       3636 
     | 
    
         
            -
                  len = arguments.length;
         
     | 
| 
       3637 
     | 
    
         
            -
                while (len--) iters[len] = arguments[len];
         
     | 
| 
       3638 
     | 
    
         
            -
                if (iters.length === 0) {
         
     | 
| 
       3639 
     | 
    
         
            -
                  return this;
         
     | 
| 
       3640 
     | 
    
         
            -
                }
         
     | 
| 
       3641 
     | 
    
         
            -
                iters = iters.map(function (iter) {
         
     | 
| 
       3642 
     | 
    
         
            -
                  return SetCollection(iter);
         
     | 
| 
       3643 
     | 
    
         
            -
                });
         
     | 
| 
       3644 
     | 
    
         
            -
                var toRemove = [];
         
     | 
| 
       3645 
     | 
    
         
            -
                this.forEach(function (value) {
         
     | 
| 
       3646 
     | 
    
         
            -
                  if (iters.some(function (iter) {
         
     | 
| 
       3647 
     | 
    
         
            -
                    return iter.includes(value);
         
     | 
| 
       3648 
     | 
    
         
            -
                  })) {
         
     | 
| 
       3649 
     | 
    
         
            -
                    toRemove.push(value);
         
     | 
| 
       3650 
     | 
    
         
            -
                  }
         
     | 
| 
       3651 
     | 
    
         
            -
                });
         
     | 
| 
       3652 
     | 
    
         
            -
                return this.withMutations(function (set) {
         
     | 
| 
       3653 
     | 
    
         
            -
                  toRemove.forEach(function (value) {
         
     | 
| 
       3654 
     | 
    
         
            -
                    set.remove(value);
         
     | 
| 
       3655 
     | 
    
         
            -
                  });
         
     | 
| 
       3656 
     | 
    
         
            -
                });
         
     | 
| 
       3657 
     | 
    
         
            -
              };
         
     | 
| 
       3658 
     | 
    
         
            -
              Set.prototype.sort = function sort(comparator) {
         
     | 
| 
       3659 
     | 
    
         
            -
                // Late binding
         
     | 
| 
       3660 
     | 
    
         
            -
                return OrderedSet(sortFactory(this, comparator));
         
     | 
| 
       3661 
     | 
    
         
            -
              };
         
     | 
| 
       3662 
     | 
    
         
            -
              Set.prototype.sortBy = function sortBy(mapper, comparator) {
         
     | 
| 
       3663 
     | 
    
         
            -
                // Late binding
         
     | 
| 
       3664 
     | 
    
         
            -
                return OrderedSet(sortFactory(this, comparator, mapper));
         
     | 
| 
       3665 
     | 
    
         
            -
              };
         
     | 
| 
       3666 
     | 
    
         
            -
              Set.prototype.wasAltered = function wasAltered() {
         
     | 
| 
       3667 
     | 
    
         
            -
                return this._map.wasAltered();
         
     | 
| 
       3668 
     | 
    
         
            -
              };
         
     | 
| 
       3669 
     | 
    
         
            -
              Set.prototype.__iterate = function __iterate(fn, reverse) {
         
     | 
| 
       3670 
     | 
    
         
            -
                var this$1$1 = this;
         
     | 
| 
       3671 
     | 
    
         
            -
                return this._map.__iterate(function (k) {
         
     | 
| 
       3672 
     | 
    
         
            -
                  return fn(k, k, this$1$1);
         
     | 
| 
       3673 
     | 
    
         
            -
                }, reverse);
         
     | 
| 
       3674 
     | 
    
         
            -
              };
         
     | 
| 
       3675 
     | 
    
         
            -
              Set.prototype.__iterator = function __iterator(type, reverse) {
         
     | 
| 
       3676 
     | 
    
         
            -
                return this._map.__iterator(type, reverse);
         
     | 
| 
       3677 
     | 
    
         
            -
              };
         
     | 
| 
       3678 
     | 
    
         
            -
              Set.prototype.__ensureOwner = function __ensureOwner(ownerID) {
         
     | 
| 
       3679 
     | 
    
         
            -
                if (ownerID === this.__ownerID) {
         
     | 
| 
       3680 
     | 
    
         
            -
                  return this;
         
     | 
| 
       3681 
     | 
    
         
            -
                }
         
     | 
| 
       3682 
     | 
    
         
            -
                var newMap = this._map.__ensureOwner(ownerID);
         
     | 
| 
       3683 
     | 
    
         
            -
                if (!ownerID) {
         
     | 
| 
       3684 
     | 
    
         
            -
                  if (this.size === 0) {
         
     | 
| 
       3685 
     | 
    
         
            -
                    return this.__empty();
         
     | 
| 
       3686 
     | 
    
         
            -
                  }
         
     | 
| 
       3687 
     | 
    
         
            -
                  this.__ownerID = ownerID;
         
     | 
| 
       3688 
     | 
    
         
            -
                  this._map = newMap;
         
     | 
| 
       3689 
     | 
    
         
            -
                  return this;
         
     | 
| 
       3690 
     | 
    
         
            -
                }
         
     | 
| 
       3691 
     | 
    
         
            -
                return this.__make(newMap, ownerID);
         
     | 
| 
       3692 
     | 
    
         
            -
              };
         
     | 
| 
       3693 
     | 
    
         
            -
              return Set;
         
     | 
| 
       3694 
     | 
    
         
            -
            }(SetCollection);
         
     | 
| 
       3695 
     | 
    
         
            -
            Set.isSet = isSet;
         
     | 
| 
       3696 
     | 
    
         
            -
            var SetPrototype = Set.prototype;
         
     | 
| 
       3697 
     | 
    
         
            -
            SetPrototype[IS_SET_SYMBOL] = true;
         
     | 
| 
       3698 
     | 
    
         
            -
            SetPrototype[DELETE] = SetPrototype.remove;
         
     | 
| 
       3699 
     | 
    
         
            -
            SetPrototype.merge = SetPrototype.concat = SetPrototype.union;
         
     | 
| 
       3700 
     | 
    
         
            -
            SetPrototype.withMutations = withMutations;
         
     | 
| 
       3701 
     | 
    
         
            -
            SetPrototype.asImmutable = asImmutable;
         
     | 
| 
       3702 
     | 
    
         
            -
            SetPrototype['@@transducer/init'] = SetPrototype.asMutable = asMutable;
         
     | 
| 
       3703 
     | 
    
         
            -
            SetPrototype['@@transducer/step'] = function (result, arr) {
         
     | 
| 
       3704 
     | 
    
         
            -
              return result.add(arr);
         
     | 
| 
       3705 
     | 
    
         
            -
            };
         
     | 
| 
       3706 
     | 
    
         
            -
            SetPrototype['@@transducer/result'] = function (obj) {
         
     | 
| 
       3707 
     | 
    
         
            -
              return obj.asImmutable();
         
     | 
| 
       3708 
     | 
    
         
            -
            };
         
     | 
| 
       3709 
     | 
    
         
            -
            SetPrototype.__empty = emptySet;
         
     | 
| 
       3710 
     | 
    
         
            -
            SetPrototype.__make = makeSet;
         
     | 
| 
       3711 
     | 
    
         
            -
            function updateSet(set, newMap) {
         
     | 
| 
       3712 
     | 
    
         
            -
              if (set.__ownerID) {
         
     | 
| 
       3713 
     | 
    
         
            -
                set.size = newMap.size;
         
     | 
| 
       3714 
     | 
    
         
            -
                set._map = newMap;
         
     | 
| 
       3715 
     | 
    
         
            -
                return set;
         
     | 
| 
       3716 
     | 
    
         
            -
              }
         
     | 
| 
       3717 
     | 
    
         
            -
              return newMap === set._map ? set : newMap.size === 0 ? set.__empty() : set.__make(newMap);
         
     | 
| 
       3718 
     | 
    
         
            -
            }
         
     | 
| 
       3719 
     | 
    
         
            -
            function makeSet(map, ownerID) {
         
     | 
| 
       3720 
     | 
    
         
            -
              var set = Object.create(SetPrototype);
         
     | 
| 
       3721 
     | 
    
         
            -
              set.size = map ? map.size : 0;
         
     | 
| 
       3722 
     | 
    
         
            -
              set._map = map;
         
     | 
| 
       3723 
     | 
    
         
            -
              set.__ownerID = ownerID;
         
     | 
| 
       3724 
     | 
    
         
            -
              return set;
         
     | 
| 
       3725 
     | 
    
         
            -
            }
         
     | 
| 
       3726 
     | 
    
         
            -
            var EMPTY_SET;
         
     | 
| 
       3727 
     | 
    
         
            -
            function emptySet() {
         
     | 
| 
       3728 
     | 
    
         
            -
              return EMPTY_SET || (EMPTY_SET = makeSet(emptyMap()));
         
     | 
| 
       3729 
     | 
    
         
            -
            }
         
     | 
| 
       3730 
     | 
    
         
            -
             
     | 
| 
       3731 
     | 
    
         
            -
            /**
         
     | 
| 
       3732 
     | 
    
         
            -
             * Returns a lazy seq of nums from start (inclusive) to end
         
     | 
| 
       3733 
     | 
    
         
            -
             * (exclusive), by step, where start defaults to 0, step to 1, and end to
         
     | 
| 
       3734 
     | 
    
         
            -
             * infinity. When start is equal to end, returns empty list.
         
     | 
| 
       3735 
     | 
    
         
            -
             */
         
     | 
| 
       3736 
     | 
    
         
            -
            var Range = /*@__PURE__*/function (IndexedSeq) {
         
     | 
| 
       3737 
     | 
    
         
            -
              function Range(start, end, step) {
         
     | 
| 
       3738 
     | 
    
         
            -
                if (!(this instanceof Range)) {
         
     | 
| 
       3739 
     | 
    
         
            -
                  // eslint-disable-next-line no-constructor-return
         
     | 
| 
       3740 
     | 
    
         
            -
                  return new Range(start, end, step);
         
     | 
| 
       3741 
     | 
    
         
            -
                }
         
     | 
| 
       3742 
     | 
    
         
            -
                invariant(step !== 0, 'Cannot step a Range by 0');
         
     | 
| 
       3743 
     | 
    
         
            -
                start = start || 0;
         
     | 
| 
       3744 
     | 
    
         
            -
                if (end === undefined) {
         
     | 
| 
       3745 
     | 
    
         
            -
                  end = Infinity;
         
     | 
| 
       3746 
     | 
    
         
            -
                }
         
     | 
| 
       3747 
     | 
    
         
            -
                step = step === undefined ? 1 : Math.abs(step);
         
     | 
| 
       3748 
     | 
    
         
            -
                if (end < start) {
         
     | 
| 
       3749 
     | 
    
         
            -
                  step = -step;
         
     | 
| 
       3750 
     | 
    
         
            -
                }
         
     | 
| 
       3751 
     | 
    
         
            -
                this._start = start;
         
     | 
| 
       3752 
     | 
    
         
            -
                this._end = end;
         
     | 
| 
       3753 
     | 
    
         
            -
                this._step = step;
         
     | 
| 
       3754 
     | 
    
         
            -
                this.size = Math.max(0, Math.ceil((end - start) / step - 1) + 1);
         
     | 
| 
       3755 
     | 
    
         
            -
                if (this.size === 0) {
         
     | 
| 
       3756 
     | 
    
         
            -
                  if (EMPTY_RANGE) {
         
     | 
| 
       3757 
     | 
    
         
            -
                    // eslint-disable-next-line no-constructor-return
         
     | 
| 
       3758 
     | 
    
         
            -
                    return EMPTY_RANGE;
         
     | 
| 
       3759 
     | 
    
         
            -
                  }
         
     | 
| 
       3760 
     | 
    
         
            -
                  EMPTY_RANGE = this;
         
     | 
| 
       3761 
     | 
    
         
            -
                }
         
     | 
| 
       3762 
     | 
    
         
            -
              }
         
     | 
| 
       3763 
     | 
    
         
            -
              if (IndexedSeq) Range.__proto__ = IndexedSeq;
         
     | 
| 
       3764 
     | 
    
         
            -
              Range.prototype = Object.create(IndexedSeq && IndexedSeq.prototype);
         
     | 
| 
       3765 
     | 
    
         
            -
              Range.prototype.constructor = Range;
         
     | 
| 
       3766 
     | 
    
         
            -
              Range.prototype.toString = function toString() {
         
     | 
| 
       3767 
     | 
    
         
            -
                if (this.size === 0) {
         
     | 
| 
       3768 
     | 
    
         
            -
                  return 'Range []';
         
     | 
| 
       3769 
     | 
    
         
            -
                }
         
     | 
| 
       3770 
     | 
    
         
            -
                return 'Range [ ' + this._start + '...' + this._end + (this._step !== 1 ? ' by ' + this._step : '') + ' ]';
         
     | 
| 
       3771 
     | 
    
         
            -
              };
         
     | 
| 
       3772 
     | 
    
         
            -
              Range.prototype.get = function get(index, notSetValue) {
         
     | 
| 
       3773 
     | 
    
         
            -
                return this.has(index) ? this._start + wrapIndex(this, index) * this._step : notSetValue;
         
     | 
| 
       3774 
     | 
    
         
            -
              };
         
     | 
| 
       3775 
     | 
    
         
            -
              Range.prototype.includes = function includes(searchValue) {
         
     | 
| 
       3776 
     | 
    
         
            -
                var possibleIndex = (searchValue - this._start) / this._step;
         
     | 
| 
       3777 
     | 
    
         
            -
                return possibleIndex >= 0 && possibleIndex < this.size && possibleIndex === Math.floor(possibleIndex);
         
     | 
| 
       3778 
     | 
    
         
            -
              };
         
     | 
| 
       3779 
     | 
    
         
            -
              Range.prototype.slice = function slice(begin, end) {
         
     | 
| 
       3780 
     | 
    
         
            -
                if (wholeSlice(begin, end, this.size)) {
         
     | 
| 
       3781 
     | 
    
         
            -
                  return this;
         
     | 
| 
       3782 
     | 
    
         
            -
                }
         
     | 
| 
       3783 
     | 
    
         
            -
                begin = resolveBegin(begin, this.size);
         
     | 
| 
       3784 
     | 
    
         
            -
                end = resolveEnd(end, this.size);
         
     | 
| 
       3785 
     | 
    
         
            -
                if (end <= begin) {
         
     | 
| 
       3786 
     | 
    
         
            -
                  return new Range(0, 0);
         
     | 
| 
       3787 
     | 
    
         
            -
                }
         
     | 
| 
       3788 
     | 
    
         
            -
                return new Range(this.get(begin, this._end), this.get(end, this._end), this._step);
         
     | 
| 
       3789 
     | 
    
         
            -
              };
         
     | 
| 
       3790 
     | 
    
         
            -
              Range.prototype.indexOf = function indexOf(searchValue) {
         
     | 
| 
       3791 
     | 
    
         
            -
                var offsetValue = searchValue - this._start;
         
     | 
| 
       3792 
     | 
    
         
            -
                if (offsetValue % this._step === 0) {
         
     | 
| 
       3793 
     | 
    
         
            -
                  var index = offsetValue / this._step;
         
     | 
| 
       3794 
     | 
    
         
            -
                  if (index >= 0 && index < this.size) {
         
     | 
| 
       3795 
     | 
    
         
            -
                    return index;
         
     | 
| 
       3796 
     | 
    
         
            -
                  }
         
     | 
| 
       3797 
     | 
    
         
            -
                }
         
     | 
| 
       3798 
     | 
    
         
            -
                return -1;
         
     | 
| 
       3799 
     | 
    
         
            -
              };
         
     | 
| 
       3800 
     | 
    
         
            -
              Range.prototype.lastIndexOf = function lastIndexOf(searchValue) {
         
     | 
| 
       3801 
     | 
    
         
            -
                return this.indexOf(searchValue);
         
     | 
| 
       3802 
     | 
    
         
            -
              };
         
     | 
| 
       3803 
     | 
    
         
            -
              Range.prototype.__iterate = function __iterate(fn, reverse) {
         
     | 
| 
       3804 
     | 
    
         
            -
                var size = this.size;
         
     | 
| 
       3805 
     | 
    
         
            -
                var step = this._step;
         
     | 
| 
       3806 
     | 
    
         
            -
                var value = reverse ? this._start + (size - 1) * step : this._start;
         
     | 
| 
       3807 
     | 
    
         
            -
                var i = 0;
         
     | 
| 
       3808 
     | 
    
         
            -
                while (i !== size) {
         
     | 
| 
       3809 
     | 
    
         
            -
                  if (fn(value, reverse ? size - ++i : i++, this) === false) {
         
     | 
| 
       3810 
     | 
    
         
            -
                    break;
         
     | 
| 
       3811 
     | 
    
         
            -
                  }
         
     | 
| 
       3812 
     | 
    
         
            -
                  value += reverse ? -step : step;
         
     | 
| 
       3813 
     | 
    
         
            -
                }
         
     | 
| 
       3814 
     | 
    
         
            -
                return i;
         
     | 
| 
       3815 
     | 
    
         
            -
              };
         
     | 
| 
       3816 
     | 
    
         
            -
              Range.prototype.__iterator = function __iterator(type, reverse) {
         
     | 
| 
       3817 
     | 
    
         
            -
                var size = this.size;
         
     | 
| 
       3818 
     | 
    
         
            -
                var step = this._step;
         
     | 
| 
       3819 
     | 
    
         
            -
                var value = reverse ? this._start + (size - 1) * step : this._start;
         
     | 
| 
       3820 
     | 
    
         
            -
                var i = 0;
         
     | 
| 
       3821 
     | 
    
         
            -
                return new Iterator(function () {
         
     | 
| 
       3822 
     | 
    
         
            -
                  if (i === size) {
         
     | 
| 
       3823 
     | 
    
         
            -
                    return iteratorDone();
         
     | 
| 
       3824 
     | 
    
         
            -
                  }
         
     | 
| 
       3825 
     | 
    
         
            -
                  var v = value;
         
     | 
| 
       3826 
     | 
    
         
            -
                  value += reverse ? -step : step;
         
     | 
| 
       3827 
     | 
    
         
            -
                  return iteratorValue(type, reverse ? size - ++i : i++, v);
         
     | 
| 
       3828 
     | 
    
         
            -
                });
         
     | 
| 
       3829 
     | 
    
         
            -
              };
         
     | 
| 
       3830 
     | 
    
         
            -
              Range.prototype.equals = function equals(other) {
         
     | 
| 
       3831 
     | 
    
         
            -
                return other instanceof Range ? this._start === other._start && this._end === other._end && this._step === other._step : deepEqual(this, other);
         
     | 
| 
       3832 
     | 
    
         
            -
              };
         
     | 
| 
       3833 
     | 
    
         
            -
              return Range;
         
     | 
| 
       3834 
     | 
    
         
            -
            }(IndexedSeq);
         
     | 
| 
       3835 
     | 
    
         
            -
            var EMPTY_RANGE;
         
     | 
| 
       3836 
     | 
    
         
            -
            function getIn$1(collection, searchKeyPath, notSetValue) {
         
     | 
| 
       3837 
     | 
    
         
            -
              var keyPath = coerceKeyPath(searchKeyPath);
         
     | 
| 
       3838 
     | 
    
         
            -
              var i = 0;
         
     | 
| 
       3839 
     | 
    
         
            -
              while (i !== keyPath.length) {
         
     | 
| 
       3840 
     | 
    
         
            -
                collection = get(collection, keyPath[i++], NOT_SET);
         
     | 
| 
       3841 
     | 
    
         
            -
                if (collection === NOT_SET) {
         
     | 
| 
       3842 
     | 
    
         
            -
                  return notSetValue;
         
     | 
| 
       3843 
     | 
    
         
            -
                }
         
     | 
| 
       3844 
     | 
    
         
            -
              }
         
     | 
| 
       3845 
     | 
    
         
            -
              return collection;
         
     | 
| 
       3846 
     | 
    
         
            -
            }
         
     | 
| 
       3847 
     | 
    
         
            -
            function getIn(searchKeyPath, notSetValue) {
         
     | 
| 
       3848 
     | 
    
         
            -
              return getIn$1(this, searchKeyPath, notSetValue);
         
     | 
| 
       3849 
     | 
    
         
            -
            }
         
     | 
| 
       3850 
     | 
    
         
            -
            function hasIn$1(collection, keyPath) {
         
     | 
| 
       3851 
     | 
    
         
            -
              return getIn$1(collection, keyPath, NOT_SET) !== NOT_SET;
         
     | 
| 
       3852 
     | 
    
         
            -
            }
         
     | 
| 
       3853 
     | 
    
         
            -
            function hasIn(searchKeyPath) {
         
     | 
| 
       3854 
     | 
    
         
            -
              return hasIn$1(this, searchKeyPath);
         
     | 
| 
       3855 
     | 
    
         
            -
            }
         
     | 
| 
       3856 
     | 
    
         
            -
            function toObject() {
         
     | 
| 
       3857 
     | 
    
         
            -
              assertNotInfinite(this.size);
         
     | 
| 
       3858 
     | 
    
         
            -
              var object = {};
         
     | 
| 
       3859 
     | 
    
         
            -
              this.__iterate(function (v, k) {
         
     | 
| 
       3860 
     | 
    
         
            -
                object[k] = v;
         
     | 
| 
       3861 
     | 
    
         
            -
              });
         
     | 
| 
       3862 
     | 
    
         
            -
              return object;
         
     | 
| 
       3863 
     | 
    
         
            -
            }
         
     | 
| 
       3864 
     | 
    
         
            -
             
     | 
| 
       3865 
     | 
    
         
            -
            // Note: all of these methods are deprecated.
         
     | 
| 
       3866 
     | 
    
         
            -
            Collection.isIterable = isCollection;
         
     | 
| 
       3867 
     | 
    
         
            -
            Collection.isKeyed = isKeyed;
         
     | 
| 
       3868 
     | 
    
         
            -
            Collection.isIndexed = isIndexed;
         
     | 
| 
       3869 
     | 
    
         
            -
            Collection.isAssociative = isAssociative;
         
     | 
| 
       3870 
     | 
    
         
            -
            Collection.isOrdered = isOrdered;
         
     | 
| 
       3871 
     | 
    
         
            -
            Collection.Iterator = Iterator;
         
     | 
| 
       3872 
     | 
    
         
            -
            mixin(Collection, {
         
     | 
| 
       3873 
     | 
    
         
            -
              // ### Conversion to other types
         
     | 
| 
       3874 
     | 
    
         
            -
             
     | 
| 
       3875 
     | 
    
         
            -
              toArray: function toArray() {
         
     | 
| 
       3876 
     | 
    
         
            -
                assertNotInfinite(this.size);
         
     | 
| 
       3877 
     | 
    
         
            -
                var array = new Array(this.size || 0);
         
     | 
| 
       3878 
     | 
    
         
            -
                var useTuples = isKeyed(this);
         
     | 
| 
       3879 
     | 
    
         
            -
                var i = 0;
         
     | 
| 
       3880 
     | 
    
         
            -
                this.__iterate(function (v, k) {
         
     | 
| 
       3881 
     | 
    
         
            -
                  // Keyed collections produce an array of tuples.
         
     | 
| 
       3882 
     | 
    
         
            -
                  array[i++] = useTuples ? [k, v] : v;
         
     | 
| 
       3883 
     | 
    
         
            -
                });
         
     | 
| 
       3884 
     | 
    
         
            -
                return array;
         
     | 
| 
       3885 
     | 
    
         
            -
              },
         
     | 
| 
       3886 
     | 
    
         
            -
              toIndexedSeq: function toIndexedSeq() {
         
     | 
| 
       3887 
     | 
    
         
            -
                return new ToIndexedSequence(this);
         
     | 
| 
       3888 
     | 
    
         
            -
              },
         
     | 
| 
       3889 
     | 
    
         
            -
              toJS: function toJS$1() {
         
     | 
| 
       3890 
     | 
    
         
            -
                return toJS(this);
         
     | 
| 
       3891 
     | 
    
         
            -
              },
         
     | 
| 
       3892 
     | 
    
         
            -
              toKeyedSeq: function toKeyedSeq() {
         
     | 
| 
       3893 
     | 
    
         
            -
                return new ToKeyedSequence(this, true);
         
     | 
| 
       3894 
     | 
    
         
            -
              },
         
     | 
| 
       3895 
     | 
    
         
            -
              toMap: function toMap() {
         
     | 
| 
       3896 
     | 
    
         
            -
                // Use Late Binding here to solve the circular dependency.
         
     | 
| 
       3897 
     | 
    
         
            -
                return Map(this.toKeyedSeq());
         
     | 
| 
       3898 
     | 
    
         
            -
              },
         
     | 
| 
       3899 
     | 
    
         
            -
              toObject: toObject,
         
     | 
| 
       3900 
     | 
    
         
            -
              toOrderedMap: function toOrderedMap() {
         
     | 
| 
       3901 
     | 
    
         
            -
                // Use Late Binding here to solve the circular dependency.
         
     | 
| 
       3902 
     | 
    
         
            -
                return OrderedMap(this.toKeyedSeq());
         
     | 
| 
       3903 
     | 
    
         
            -
              },
         
     | 
| 
       3904 
     | 
    
         
            -
              toOrderedSet: function toOrderedSet() {
         
     | 
| 
       3905 
     | 
    
         
            -
                // Use Late Binding here to solve the circular dependency.
         
     | 
| 
       3906 
     | 
    
         
            -
                return OrderedSet(isKeyed(this) ? this.valueSeq() : this);
         
     | 
| 
       3907 
     | 
    
         
            -
              },
         
     | 
| 
       3908 
     | 
    
         
            -
              toSet: function toSet() {
         
     | 
| 
       3909 
     | 
    
         
            -
                // Use Late Binding here to solve the circular dependency.
         
     | 
| 
       3910 
     | 
    
         
            -
                return Set(isKeyed(this) ? this.valueSeq() : this);
         
     | 
| 
       3911 
     | 
    
         
            -
              },
         
     | 
| 
       3912 
     | 
    
         
            -
              toSetSeq: function toSetSeq() {
         
     | 
| 
       3913 
     | 
    
         
            -
                return new ToSetSequence(this);
         
     | 
| 
       3914 
     | 
    
         
            -
              },
         
     | 
| 
       3915 
     | 
    
         
            -
              toSeq: function toSeq() {
         
     | 
| 
       3916 
     | 
    
         
            -
                return isIndexed(this) ? this.toIndexedSeq() : isKeyed(this) ? this.toKeyedSeq() : this.toSetSeq();
         
     | 
| 
       3917 
     | 
    
         
            -
              },
         
     | 
| 
       3918 
     | 
    
         
            -
              toStack: function toStack() {
         
     | 
| 
       3919 
     | 
    
         
            -
                // Use Late Binding here to solve the circular dependency.
         
     | 
| 
       3920 
     | 
    
         
            -
                return Stack(isKeyed(this) ? this.valueSeq() : this);
         
     | 
| 
       3921 
     | 
    
         
            -
              },
         
     | 
| 
       3922 
     | 
    
         
            -
              toList: function toList() {
         
     | 
| 
       3923 
     | 
    
         
            -
                // Use Late Binding here to solve the circular dependency.
         
     | 
| 
       3924 
     | 
    
         
            -
                return List(isKeyed(this) ? this.valueSeq() : this);
         
     | 
| 
       3925 
     | 
    
         
            -
              },
         
     | 
| 
       3926 
     | 
    
         
            -
              // ### Common JavaScript methods and properties
         
     | 
| 
       3927 
     | 
    
         
            -
             
     | 
| 
       3928 
     | 
    
         
            -
              toString: function toString() {
         
     | 
| 
       3929 
     | 
    
         
            -
                return '[Collection]';
         
     | 
| 
       3930 
     | 
    
         
            -
              },
         
     | 
| 
       3931 
     | 
    
         
            -
              __toString: function __toString(head, tail) {
         
     | 
| 
       3932 
     | 
    
         
            -
                if (this.size === 0) {
         
     | 
| 
       3933 
     | 
    
         
            -
                  return head + tail;
         
     | 
| 
       3934 
     | 
    
         
            -
                }
         
     | 
| 
       3935 
     | 
    
         
            -
                return head + ' ' + this.toSeq().map(this.__toStringMapper).join(', ') + ' ' + tail;
         
     | 
| 
       3936 
     | 
    
         
            -
              },
         
     | 
| 
       3937 
     | 
    
         
            -
              // ### ES6 Collection methods (ES6 Array and Map)
         
     | 
| 
       3938 
     | 
    
         
            -
             
     | 
| 
       3939 
     | 
    
         
            -
              concat: function concat() {
         
     | 
| 
       3940 
     | 
    
         
            -
                var values = [],
         
     | 
| 
       3941 
     | 
    
         
            -
                  len = arguments.length;
         
     | 
| 
       3942 
     | 
    
         
            -
                while (len--) values[len] = arguments[len];
         
     | 
| 
       3943 
     | 
    
         
            -
                return reify(this, concatFactory(this, values));
         
     | 
| 
       3944 
     | 
    
         
            -
              },
         
     | 
| 
       3945 
     | 
    
         
            -
              includes: function includes(searchValue) {
         
     | 
| 
       3946 
     | 
    
         
            -
                return this.some(function (value) {
         
     | 
| 
       3947 
     | 
    
         
            -
                  return is(value, searchValue);
         
     | 
| 
       3948 
     | 
    
         
            -
                });
         
     | 
| 
       3949 
     | 
    
         
            -
              },
         
     | 
| 
       3950 
     | 
    
         
            -
              entries: function entries() {
         
     | 
| 
       3951 
     | 
    
         
            -
                return this.__iterator(ITERATE_ENTRIES);
         
     | 
| 
       3952 
     | 
    
         
            -
              },
         
     | 
| 
       3953 
     | 
    
         
            -
              every: function every(predicate, context) {
         
     | 
| 
       3954 
     | 
    
         
            -
                assertNotInfinite(this.size);
         
     | 
| 
       3955 
     | 
    
         
            -
                var returnValue = true;
         
     | 
| 
       3956 
     | 
    
         
            -
                this.__iterate(function (v, k, c) {
         
     | 
| 
       3957 
     | 
    
         
            -
                  if (!predicate.call(context, v, k, c)) {
         
     | 
| 
       3958 
     | 
    
         
            -
                    returnValue = false;
         
     | 
| 
       3959 
     | 
    
         
            -
                    return false;
         
     | 
| 
       3960 
     | 
    
         
            -
                  }
         
     | 
| 
       3961 
     | 
    
         
            -
                });
         
     | 
| 
       3962 
     | 
    
         
            -
                return returnValue;
         
     | 
| 
       3963 
     | 
    
         
            -
              },
         
     | 
| 
       3964 
     | 
    
         
            -
              filter: function filter(predicate, context) {
         
     | 
| 
       3965 
     | 
    
         
            -
                return reify(this, filterFactory(this, predicate, context, true));
         
     | 
| 
       3966 
     | 
    
         
            -
              },
         
     | 
| 
       3967 
     | 
    
         
            -
              partition: function partition(predicate, context) {
         
     | 
| 
       3968 
     | 
    
         
            -
                return partitionFactory(this, predicate, context);
         
     | 
| 
       3969 
     | 
    
         
            -
              },
         
     | 
| 
       3970 
     | 
    
         
            -
              find: function find(predicate, context, notSetValue) {
         
     | 
| 
       3971 
     | 
    
         
            -
                var entry = this.findEntry(predicate, context);
         
     | 
| 
       3972 
     | 
    
         
            -
                return entry ? entry[1] : notSetValue;
         
     | 
| 
       3973 
     | 
    
         
            -
              },
         
     | 
| 
       3974 
     | 
    
         
            -
              forEach: function forEach(sideEffect, context) {
         
     | 
| 
       3975 
     | 
    
         
            -
                assertNotInfinite(this.size);
         
     | 
| 
       3976 
     | 
    
         
            -
                return this.__iterate(context ? sideEffect.bind(context) : sideEffect);
         
     | 
| 
       3977 
     | 
    
         
            -
              },
         
     | 
| 
       3978 
     | 
    
         
            -
              join: function join(separator) {
         
     | 
| 
       3979 
     | 
    
         
            -
                assertNotInfinite(this.size);
         
     | 
| 
       3980 
     | 
    
         
            -
                separator = separator !== undefined ? '' + separator : ',';
         
     | 
| 
       3981 
     | 
    
         
            -
                var joined = '';
         
     | 
| 
       3982 
     | 
    
         
            -
                var isFirst = true;
         
     | 
| 
       3983 
     | 
    
         
            -
                this.__iterate(function (v) {
         
     | 
| 
       3984 
     | 
    
         
            -
                  isFirst ? isFirst = false : joined += separator;
         
     | 
| 
       3985 
     | 
    
         
            -
                  joined += v !== null && v !== undefined ? v.toString() : '';
         
     | 
| 
       3986 
     | 
    
         
            -
                });
         
     | 
| 
       3987 
     | 
    
         
            -
                return joined;
         
     | 
| 
       3988 
     | 
    
         
            -
              },
         
     | 
| 
       3989 
     | 
    
         
            -
              keys: function keys() {
         
     | 
| 
       3990 
     | 
    
         
            -
                return this.__iterator(ITERATE_KEYS);
         
     | 
| 
       3991 
     | 
    
         
            -
              },
         
     | 
| 
       3992 
     | 
    
         
            -
              map: function map(mapper, context) {
         
     | 
| 
       3993 
     | 
    
         
            -
                return reify(this, mapFactory(this, mapper, context));
         
     | 
| 
       3994 
     | 
    
         
            -
              },
         
     | 
| 
       3995 
     | 
    
         
            -
              reduce: function reduce$1(reducer, initialReduction, context) {
         
     | 
| 
       3996 
     | 
    
         
            -
                return reduce(this, reducer, initialReduction, context, arguments.length < 2, false);
         
     | 
| 
       3997 
     | 
    
         
            -
              },
         
     | 
| 
       3998 
     | 
    
         
            -
              reduceRight: function reduceRight(reducer, initialReduction, context) {
         
     | 
| 
       3999 
     | 
    
         
            -
                return reduce(this, reducer, initialReduction, context, arguments.length < 2, true);
         
     | 
| 
       4000 
     | 
    
         
            -
              },
         
     | 
| 
       4001 
     | 
    
         
            -
              reverse: function reverse() {
         
     | 
| 
       4002 
     | 
    
         
            -
                return reify(this, reverseFactory(this, true));
         
     | 
| 
       4003 
     | 
    
         
            -
              },
         
     | 
| 
       4004 
     | 
    
         
            -
              slice: function slice(begin, end) {
         
     | 
| 
       4005 
     | 
    
         
            -
                return reify(this, sliceFactory(this, begin, end, true));
         
     | 
| 
       4006 
     | 
    
         
            -
              },
         
     | 
| 
       4007 
     | 
    
         
            -
              some: function some(predicate, context) {
         
     | 
| 
       4008 
     | 
    
         
            -
                assertNotInfinite(this.size);
         
     | 
| 
       4009 
     | 
    
         
            -
                var returnValue = false;
         
     | 
| 
       4010 
     | 
    
         
            -
                this.__iterate(function (v, k, c) {
         
     | 
| 
       4011 
     | 
    
         
            -
                  if (predicate.call(context, v, k, c)) {
         
     | 
| 
       4012 
     | 
    
         
            -
                    returnValue = true;
         
     | 
| 
       4013 
     | 
    
         
            -
                    return false;
         
     | 
| 
       4014 
     | 
    
         
            -
                  }
         
     | 
| 
       4015 
     | 
    
         
            -
                });
         
     | 
| 
       4016 
     | 
    
         
            -
                return returnValue;
         
     | 
| 
       4017 
     | 
    
         
            -
              },
         
     | 
| 
       4018 
     | 
    
         
            -
              sort: function sort(comparator) {
         
     | 
| 
       4019 
     | 
    
         
            -
                return reify(this, sortFactory(this, comparator));
         
     | 
| 
       4020 
     | 
    
         
            -
              },
         
     | 
| 
       4021 
     | 
    
         
            -
              values: function values() {
         
     | 
| 
       4022 
     | 
    
         
            -
                return this.__iterator(ITERATE_VALUES);
         
     | 
| 
       4023 
     | 
    
         
            -
              },
         
     | 
| 
       4024 
     | 
    
         
            -
              // ### More sequential methods
         
     | 
| 
       4025 
     | 
    
         
            -
             
     | 
| 
       4026 
     | 
    
         
            -
              butLast: function butLast() {
         
     | 
| 
       4027 
     | 
    
         
            -
                return this.slice(0, -1);
         
     | 
| 
       4028 
     | 
    
         
            -
              },
         
     | 
| 
       4029 
     | 
    
         
            -
              isEmpty: function isEmpty() {
         
     | 
| 
       4030 
     | 
    
         
            -
                return this.size !== undefined ? this.size === 0 : !this.some(function () {
         
     | 
| 
       4031 
     | 
    
         
            -
                  return true;
         
     | 
| 
       4032 
     | 
    
         
            -
                });
         
     | 
| 
       4033 
     | 
    
         
            -
              },
         
     | 
| 
       4034 
     | 
    
         
            -
              count: function count(predicate, context) {
         
     | 
| 
       4035 
     | 
    
         
            -
                return ensureSize(predicate ? this.toSeq().filter(predicate, context) : this);
         
     | 
| 
       4036 
     | 
    
         
            -
              },
         
     | 
| 
       4037 
     | 
    
         
            -
              countBy: function countBy(grouper, context) {
         
     | 
| 
       4038 
     | 
    
         
            -
                return countByFactory(this, grouper, context);
         
     | 
| 
       4039 
     | 
    
         
            -
              },
         
     | 
| 
       4040 
     | 
    
         
            -
              equals: function equals(other) {
         
     | 
| 
       4041 
     | 
    
         
            -
                return deepEqual(this, other);
         
     | 
| 
       4042 
     | 
    
         
            -
              },
         
     | 
| 
       4043 
     | 
    
         
            -
              entrySeq: function entrySeq() {
         
     | 
| 
       4044 
     | 
    
         
            -
                var collection = this;
         
     | 
| 
       4045 
     | 
    
         
            -
                if (collection._cache) {
         
     | 
| 
       4046 
     | 
    
         
            -
                  // We cache as an entries array, so we can just return the cache!
         
     | 
| 
       4047 
     | 
    
         
            -
                  return new ArraySeq(collection._cache);
         
     | 
| 
       4048 
     | 
    
         
            -
                }
         
     | 
| 
       4049 
     | 
    
         
            -
                var entriesSequence = collection.toSeq().map(entryMapper).toIndexedSeq();
         
     | 
| 
       4050 
     | 
    
         
            -
                entriesSequence.fromEntrySeq = function () {
         
     | 
| 
       4051 
     | 
    
         
            -
                  return collection.toSeq();
         
     | 
| 
       4052 
     | 
    
         
            -
                };
         
     | 
| 
       4053 
     | 
    
         
            -
                return entriesSequence;
         
     | 
| 
       4054 
     | 
    
         
            -
              },
         
     | 
| 
       4055 
     | 
    
         
            -
              filterNot: function filterNot(predicate, context) {
         
     | 
| 
       4056 
     | 
    
         
            -
                return this.filter(not(predicate), context);
         
     | 
| 
       4057 
     | 
    
         
            -
              },
         
     | 
| 
       4058 
     | 
    
         
            -
              findEntry: function findEntry(predicate, context, notSetValue) {
         
     | 
| 
       4059 
     | 
    
         
            -
                var found = notSetValue;
         
     | 
| 
       4060 
     | 
    
         
            -
                this.__iterate(function (v, k, c) {
         
     | 
| 
       4061 
     | 
    
         
            -
                  if (predicate.call(context, v, k, c)) {
         
     | 
| 
       4062 
     | 
    
         
            -
                    found = [k, v];
         
     | 
| 
       4063 
     | 
    
         
            -
                    return false;
         
     | 
| 
       4064 
     | 
    
         
            -
                  }
         
     | 
| 
       4065 
     | 
    
         
            -
                });
         
     | 
| 
       4066 
     | 
    
         
            -
                return found;
         
     | 
| 
       4067 
     | 
    
         
            -
              },
         
     | 
| 
       4068 
     | 
    
         
            -
              findKey: function findKey(predicate, context) {
         
     | 
| 
       4069 
     | 
    
         
            -
                var entry = this.findEntry(predicate, context);
         
     | 
| 
       4070 
     | 
    
         
            -
                return entry && entry[0];
         
     | 
| 
       4071 
     | 
    
         
            -
              },
         
     | 
| 
       4072 
     | 
    
         
            -
              findLast: function findLast(predicate, context, notSetValue) {
         
     | 
| 
       4073 
     | 
    
         
            -
                return this.toKeyedSeq().reverse().find(predicate, context, notSetValue);
         
     | 
| 
       4074 
     | 
    
         
            -
              },
         
     | 
| 
       4075 
     | 
    
         
            -
              findLastEntry: function findLastEntry(predicate, context, notSetValue) {
         
     | 
| 
       4076 
     | 
    
         
            -
                return this.toKeyedSeq().reverse().findEntry(predicate, context, notSetValue);
         
     | 
| 
       4077 
     | 
    
         
            -
              },
         
     | 
| 
       4078 
     | 
    
         
            -
              findLastKey: function findLastKey(predicate, context) {
         
     | 
| 
       4079 
     | 
    
         
            -
                return this.toKeyedSeq().reverse().findKey(predicate, context);
         
     | 
| 
       4080 
     | 
    
         
            -
              },
         
     | 
| 
       4081 
     | 
    
         
            -
              first: function first(notSetValue) {
         
     | 
| 
       4082 
     | 
    
         
            -
                return this.find(returnTrue, null, notSetValue);
         
     | 
| 
       4083 
     | 
    
         
            -
              },
         
     | 
| 
       4084 
     | 
    
         
            -
              flatMap: function flatMap(mapper, context) {
         
     | 
| 
       4085 
     | 
    
         
            -
                return reify(this, flatMapFactory(this, mapper, context));
         
     | 
| 
       4086 
     | 
    
         
            -
              },
         
     | 
| 
       4087 
     | 
    
         
            -
              flatten: function flatten(depth) {
         
     | 
| 
       4088 
     | 
    
         
            -
                return reify(this, flattenFactory(this, depth, true));
         
     | 
| 
       4089 
     | 
    
         
            -
              },
         
     | 
| 
       4090 
     | 
    
         
            -
              fromEntrySeq: function fromEntrySeq() {
         
     | 
| 
       4091 
     | 
    
         
            -
                return new FromEntriesSequence(this);
         
     | 
| 
       4092 
     | 
    
         
            -
              },
         
     | 
| 
       4093 
     | 
    
         
            -
              get: function get(searchKey, notSetValue) {
         
     | 
| 
       4094 
     | 
    
         
            -
                return this.find(function (_, key) {
         
     | 
| 
       4095 
     | 
    
         
            -
                  return is(key, searchKey);
         
     | 
| 
       4096 
     | 
    
         
            -
                }, undefined, notSetValue);
         
     | 
| 
       4097 
     | 
    
         
            -
              },
         
     | 
| 
       4098 
     | 
    
         
            -
              getIn: getIn,
         
     | 
| 
       4099 
     | 
    
         
            -
              groupBy: function groupBy(grouper, context) {
         
     | 
| 
       4100 
     | 
    
         
            -
                return groupByFactory(this, grouper, context);
         
     | 
| 
       4101 
     | 
    
         
            -
              },
         
     | 
| 
       4102 
     | 
    
         
            -
              has: function has(searchKey) {
         
     | 
| 
       4103 
     | 
    
         
            -
                return this.get(searchKey, NOT_SET) !== NOT_SET;
         
     | 
| 
       4104 
     | 
    
         
            -
              },
         
     | 
| 
       4105 
     | 
    
         
            -
              hasIn: hasIn,
         
     | 
| 
       4106 
     | 
    
         
            -
              isSubset: function isSubset(iter) {
         
     | 
| 
       4107 
     | 
    
         
            -
                iter = typeof iter.includes === 'function' ? iter : Collection(iter);
         
     | 
| 
       4108 
     | 
    
         
            -
                return this.every(function (value) {
         
     | 
| 
       4109 
     | 
    
         
            -
                  return iter.includes(value);
         
     | 
| 
       4110 
     | 
    
         
            -
                });
         
     | 
| 
       4111 
     | 
    
         
            -
              },
         
     | 
| 
       4112 
     | 
    
         
            -
              isSuperset: function isSuperset(iter) {
         
     | 
| 
       4113 
     | 
    
         
            -
                iter = typeof iter.isSubset === 'function' ? iter : Collection(iter);
         
     | 
| 
       4114 
     | 
    
         
            -
                return iter.isSubset(this);
         
     | 
| 
       4115 
     | 
    
         
            -
              },
         
     | 
| 
       4116 
     | 
    
         
            -
              keyOf: function keyOf(searchValue) {
         
     | 
| 
       4117 
     | 
    
         
            -
                return this.findKey(function (value) {
         
     | 
| 
       4118 
     | 
    
         
            -
                  return is(value, searchValue);
         
     | 
| 
       4119 
     | 
    
         
            -
                });
         
     | 
| 
       4120 
     | 
    
         
            -
              },
         
     | 
| 
       4121 
     | 
    
         
            -
              keySeq: function keySeq() {
         
     | 
| 
       4122 
     | 
    
         
            -
                return this.toSeq().map(keyMapper).toIndexedSeq();
         
     | 
| 
       4123 
     | 
    
         
            -
              },
         
     | 
| 
       4124 
     | 
    
         
            -
              last: function last(notSetValue) {
         
     | 
| 
       4125 
     | 
    
         
            -
                return this.toSeq().reverse().first(notSetValue);
         
     | 
| 
       4126 
     | 
    
         
            -
              },
         
     | 
| 
       4127 
     | 
    
         
            -
              lastKeyOf: function lastKeyOf(searchValue) {
         
     | 
| 
       4128 
     | 
    
         
            -
                return this.toKeyedSeq().reverse().keyOf(searchValue);
         
     | 
| 
       4129 
     | 
    
         
            -
              },
         
     | 
| 
       4130 
     | 
    
         
            -
              max: function max(comparator) {
         
     | 
| 
       4131 
     | 
    
         
            -
                return maxFactory(this, comparator);
         
     | 
| 
       4132 
     | 
    
         
            -
              },
         
     | 
| 
       4133 
     | 
    
         
            -
              maxBy: function maxBy(mapper, comparator) {
         
     | 
| 
       4134 
     | 
    
         
            -
                return maxFactory(this, comparator, mapper);
         
     | 
| 
       4135 
     | 
    
         
            -
              },
         
     | 
| 
       4136 
     | 
    
         
            -
              min: function min(comparator) {
         
     | 
| 
       4137 
     | 
    
         
            -
                return maxFactory(this, comparator ? neg(comparator) : defaultNegComparator);
         
     | 
| 
       4138 
     | 
    
         
            -
              },
         
     | 
| 
       4139 
     | 
    
         
            -
              minBy: function minBy(mapper, comparator) {
         
     | 
| 
       4140 
     | 
    
         
            -
                return maxFactory(this, comparator ? neg(comparator) : defaultNegComparator, mapper);
         
     | 
| 
       4141 
     | 
    
         
            -
              },
         
     | 
| 
       4142 
     | 
    
         
            -
              rest: function rest() {
         
     | 
| 
       4143 
     | 
    
         
            -
                return this.slice(1);
         
     | 
| 
       4144 
     | 
    
         
            -
              },
         
     | 
| 
       4145 
     | 
    
         
            -
              skip: function skip(amount) {
         
     | 
| 
       4146 
     | 
    
         
            -
                return amount === 0 ? this : this.slice(Math.max(0, amount));
         
     | 
| 
       4147 
     | 
    
         
            -
              },
         
     | 
| 
       4148 
     | 
    
         
            -
              skipLast: function skipLast(amount) {
         
     | 
| 
       4149 
     | 
    
         
            -
                return amount === 0 ? this : this.slice(0, -Math.max(0, amount));
         
     | 
| 
       4150 
     | 
    
         
            -
              },
         
     | 
| 
       4151 
     | 
    
         
            -
              skipWhile: function skipWhile(predicate, context) {
         
     | 
| 
       4152 
     | 
    
         
            -
                return reify(this, skipWhileFactory(this, predicate, context, true));
         
     | 
| 
       4153 
     | 
    
         
            -
              },
         
     | 
| 
       4154 
     | 
    
         
            -
              skipUntil: function skipUntil(predicate, context) {
         
     | 
| 
       4155 
     | 
    
         
            -
                return this.skipWhile(not(predicate), context);
         
     | 
| 
       4156 
     | 
    
         
            -
              },
         
     | 
| 
       4157 
     | 
    
         
            -
              sortBy: function sortBy(mapper, comparator) {
         
     | 
| 
       4158 
     | 
    
         
            -
                return reify(this, sortFactory(this, comparator, mapper));
         
     | 
| 
       4159 
     | 
    
         
            -
              },
         
     | 
| 
       4160 
     | 
    
         
            -
              take: function take(amount) {
         
     | 
| 
       4161 
     | 
    
         
            -
                return this.slice(0, Math.max(0, amount));
         
     | 
| 
       4162 
     | 
    
         
            -
              },
         
     | 
| 
       4163 
     | 
    
         
            -
              takeLast: function takeLast(amount) {
         
     | 
| 
       4164 
     | 
    
         
            -
                return this.slice(-Math.max(0, amount));
         
     | 
| 
       4165 
     | 
    
         
            -
              },
         
     | 
| 
       4166 
     | 
    
         
            -
              takeWhile: function takeWhile(predicate, context) {
         
     | 
| 
       4167 
     | 
    
         
            -
                return reify(this, takeWhileFactory(this, predicate, context));
         
     | 
| 
       4168 
     | 
    
         
            -
              },
         
     | 
| 
       4169 
     | 
    
         
            -
              takeUntil: function takeUntil(predicate, context) {
         
     | 
| 
       4170 
     | 
    
         
            -
                return this.takeWhile(not(predicate), context);
         
     | 
| 
       4171 
     | 
    
         
            -
              },
         
     | 
| 
       4172 
     | 
    
         
            -
              update: function update(fn) {
         
     | 
| 
       4173 
     | 
    
         
            -
                return fn(this);
         
     | 
| 
       4174 
     | 
    
         
            -
              },
         
     | 
| 
       4175 
     | 
    
         
            -
              valueSeq: function valueSeq() {
         
     | 
| 
       4176 
     | 
    
         
            -
                return this.toIndexedSeq();
         
     | 
| 
       4177 
     | 
    
         
            -
              },
         
     | 
| 
       4178 
     | 
    
         
            -
              // ### Hashable Object
         
     | 
| 
       4179 
     | 
    
         
            -
             
     | 
| 
       4180 
     | 
    
         
            -
              hashCode: function hashCode() {
         
     | 
| 
       4181 
     | 
    
         
            -
                return this.__hash || (this.__hash = hashCollection(this));
         
     | 
| 
       4182 
     | 
    
         
            -
              }
         
     | 
| 
       4183 
     | 
    
         
            -
             
     | 
| 
       4184 
     | 
    
         
            -
              // ### Internal
         
     | 
| 
       4185 
     | 
    
         
            -
             
     | 
| 
       4186 
     | 
    
         
            -
              // abstract __iterate(fn, reverse)
         
     | 
| 
       4187 
     | 
    
         
            -
             
     | 
| 
       4188 
     | 
    
         
            -
              // abstract __iterator(type, reverse)
         
     | 
| 
       4189 
     | 
    
         
            -
            });
         
     | 
| 
       4190 
     | 
    
         
            -
            var CollectionPrototype = Collection.prototype;
         
     | 
| 
       4191 
     | 
    
         
            -
            CollectionPrototype[IS_COLLECTION_SYMBOL] = true;
         
     | 
| 
       4192 
     | 
    
         
            -
            CollectionPrototype[ITERATOR_SYMBOL] = CollectionPrototype.values;
         
     | 
| 
       4193 
     | 
    
         
            -
            CollectionPrototype.toJSON = CollectionPrototype.toArray;
         
     | 
| 
       4194 
     | 
    
         
            -
            CollectionPrototype.__toStringMapper = quoteString;
         
     | 
| 
       4195 
     | 
    
         
            -
            CollectionPrototype.inspect = CollectionPrototype.toSource = function () {
         
     | 
| 
       4196 
     | 
    
         
            -
              return this.toString();
         
     | 
| 
       4197 
     | 
    
         
            -
            };
         
     | 
| 
       4198 
     | 
    
         
            -
            CollectionPrototype.chain = CollectionPrototype.flatMap;
         
     | 
| 
       4199 
     | 
    
         
            -
            CollectionPrototype.contains = CollectionPrototype.includes;
         
     | 
| 
       4200 
     | 
    
         
            -
            mixin(KeyedCollection, {
         
     | 
| 
       4201 
     | 
    
         
            -
              // ### More sequential methods
         
     | 
| 
       4202 
     | 
    
         
            -
             
     | 
| 
       4203 
     | 
    
         
            -
              flip: function flip() {
         
     | 
| 
       4204 
     | 
    
         
            -
                return reify(this, flipFactory(this));
         
     | 
| 
       4205 
     | 
    
         
            -
              },
         
     | 
| 
       4206 
     | 
    
         
            -
              mapEntries: function mapEntries(mapper, context) {
         
     | 
| 
       4207 
     | 
    
         
            -
                var this$1$1 = this;
         
     | 
| 
       4208 
     | 
    
         
            -
                var iterations = 0;
         
     | 
| 
       4209 
     | 
    
         
            -
                return reify(this, this.toSeq().map(function (v, k) {
         
     | 
| 
       4210 
     | 
    
         
            -
                  return mapper.call(context, [k, v], iterations++, this$1$1);
         
     | 
| 
       4211 
     | 
    
         
            -
                }).fromEntrySeq());
         
     | 
| 
       4212 
     | 
    
         
            -
              },
         
     | 
| 
       4213 
     | 
    
         
            -
              mapKeys: function mapKeys(mapper, context) {
         
     | 
| 
       4214 
     | 
    
         
            -
                var this$1$1 = this;
         
     | 
| 
       4215 
     | 
    
         
            -
                return reify(this, this.toSeq().flip().map(function (k, v) {
         
     | 
| 
       4216 
     | 
    
         
            -
                  return mapper.call(context, k, v, this$1$1);
         
     | 
| 
       4217 
     | 
    
         
            -
                }).flip());
         
     | 
| 
       4218 
     | 
    
         
            -
              }
         
     | 
| 
       4219 
     | 
    
         
            -
            });
         
     | 
| 
       4220 
     | 
    
         
            -
            var KeyedCollectionPrototype = KeyedCollection.prototype;
         
     | 
| 
       4221 
     | 
    
         
            -
            KeyedCollectionPrototype[IS_KEYED_SYMBOL] = true;
         
     | 
| 
       4222 
     | 
    
         
            -
            KeyedCollectionPrototype[ITERATOR_SYMBOL] = CollectionPrototype.entries;
         
     | 
| 
       4223 
     | 
    
         
            -
            KeyedCollectionPrototype.toJSON = toObject;
         
     | 
| 
       4224 
     | 
    
         
            -
            KeyedCollectionPrototype.__toStringMapper = function (v, k) {
         
     | 
| 
       4225 
     | 
    
         
            -
              return quoteString(k) + ': ' + quoteString(v);
         
     | 
| 
       4226 
     | 
    
         
            -
            };
         
     | 
| 
       4227 
     | 
    
         
            -
            mixin(IndexedCollection, {
         
     | 
| 
       4228 
     | 
    
         
            -
              // ### Conversion to other types
         
     | 
| 
       4229 
     | 
    
         
            -
             
     | 
| 
       4230 
     | 
    
         
            -
              toKeyedSeq: function toKeyedSeq() {
         
     | 
| 
       4231 
     | 
    
         
            -
                return new ToKeyedSequence(this, false);
         
     | 
| 
       4232 
     | 
    
         
            -
              },
         
     | 
| 
       4233 
     | 
    
         
            -
              // ### ES6 Collection methods (ES6 Array and Map)
         
     | 
| 
       4234 
     | 
    
         
            -
             
     | 
| 
       4235 
     | 
    
         
            -
              filter: function filter(predicate, context) {
         
     | 
| 
       4236 
     | 
    
         
            -
                return reify(this, filterFactory(this, predicate, context, false));
         
     | 
| 
       4237 
     | 
    
         
            -
              },
         
     | 
| 
       4238 
     | 
    
         
            -
              findIndex: function findIndex(predicate, context) {
         
     | 
| 
       4239 
     | 
    
         
            -
                var entry = this.findEntry(predicate, context);
         
     | 
| 
       4240 
     | 
    
         
            -
                return entry ? entry[0] : -1;
         
     | 
| 
       4241 
     | 
    
         
            -
              },
         
     | 
| 
       4242 
     | 
    
         
            -
              indexOf: function indexOf(searchValue) {
         
     | 
| 
       4243 
     | 
    
         
            -
                var key = this.keyOf(searchValue);
         
     | 
| 
       4244 
     | 
    
         
            -
                return key === undefined ? -1 : key;
         
     | 
| 
       4245 
     | 
    
         
            -
              },
         
     | 
| 
       4246 
     | 
    
         
            -
              lastIndexOf: function lastIndexOf(searchValue) {
         
     | 
| 
       4247 
     | 
    
         
            -
                var key = this.lastKeyOf(searchValue);
         
     | 
| 
       4248 
     | 
    
         
            -
                return key === undefined ? -1 : key;
         
     | 
| 
       4249 
     | 
    
         
            -
              },
         
     | 
| 
       4250 
     | 
    
         
            -
              reverse: function reverse() {
         
     | 
| 
       4251 
     | 
    
         
            -
                return reify(this, reverseFactory(this, false));
         
     | 
| 
       4252 
     | 
    
         
            -
              },
         
     | 
| 
       4253 
     | 
    
         
            -
              slice: function slice(begin, end) {
         
     | 
| 
       4254 
     | 
    
         
            -
                return reify(this, sliceFactory(this, begin, end, false));
         
     | 
| 
       4255 
     | 
    
         
            -
              },
         
     | 
| 
       4256 
     | 
    
         
            -
              splice: function splice(index, removeNum /*, ...values*/) {
         
     | 
| 
       4257 
     | 
    
         
            -
                var numArgs = arguments.length;
         
     | 
| 
       4258 
     | 
    
         
            -
                removeNum = Math.max(removeNum || 0, 0);
         
     | 
| 
       4259 
     | 
    
         
            -
                if (numArgs === 0 || numArgs === 2 && !removeNum) {
         
     | 
| 
       4260 
     | 
    
         
            -
                  return this;
         
     | 
| 
       4261 
     | 
    
         
            -
                }
         
     | 
| 
       4262 
     | 
    
         
            -
                // If index is negative, it should resolve relative to the size of the
         
     | 
| 
       4263 
     | 
    
         
            -
                // collection. However size may be expensive to compute if not cached, so
         
     | 
| 
       4264 
     | 
    
         
            -
                // only call count() if the number is in fact negative.
         
     | 
| 
       4265 
     | 
    
         
            -
                index = resolveBegin(index, index < 0 ? this.count() : this.size);
         
     | 
| 
       4266 
     | 
    
         
            -
                var spliced = this.slice(0, index);
         
     | 
| 
       4267 
     | 
    
         
            -
                return reify(this, numArgs === 1 ? spliced : spliced.concat(arrCopy(arguments, 2), this.slice(index + removeNum)));
         
     | 
| 
       4268 
     | 
    
         
            -
              },
         
     | 
| 
       4269 
     | 
    
         
            -
              // ### More collection methods
         
     | 
| 
       4270 
     | 
    
         
            -
             
     | 
| 
       4271 
     | 
    
         
            -
              findLastIndex: function findLastIndex(predicate, context) {
         
     | 
| 
       4272 
     | 
    
         
            -
                var entry = this.findLastEntry(predicate, context);
         
     | 
| 
       4273 
     | 
    
         
            -
                return entry ? entry[0] : -1;
         
     | 
| 
       4274 
     | 
    
         
            -
              },
         
     | 
| 
       4275 
     | 
    
         
            -
              first: function first(notSetValue) {
         
     | 
| 
       4276 
     | 
    
         
            -
                return this.get(0, notSetValue);
         
     | 
| 
       4277 
     | 
    
         
            -
              },
         
     | 
| 
       4278 
     | 
    
         
            -
              flatten: function flatten(depth) {
         
     | 
| 
       4279 
     | 
    
         
            -
                return reify(this, flattenFactory(this, depth, false));
         
     | 
| 
       4280 
     | 
    
         
            -
              },
         
     | 
| 
       4281 
     | 
    
         
            -
              get: function get(index, notSetValue) {
         
     | 
| 
       4282 
     | 
    
         
            -
                index = wrapIndex(this, index);
         
     | 
| 
       4283 
     | 
    
         
            -
                return index < 0 || this.size === Infinity || this.size !== undefined && index > this.size ? notSetValue : this.find(function (_, key) {
         
     | 
| 
       4284 
     | 
    
         
            -
                  return key === index;
         
     | 
| 
       4285 
     | 
    
         
            -
                }, undefined, notSetValue);
         
     | 
| 
       4286 
     | 
    
         
            -
              },
         
     | 
| 
       4287 
     | 
    
         
            -
              has: function has(index) {
         
     | 
| 
       4288 
     | 
    
         
            -
                index = wrapIndex(this, index);
         
     | 
| 
       4289 
     | 
    
         
            -
                return index >= 0 && (this.size !== undefined ? this.size === Infinity || index < this.size : this.indexOf(index) !== -1);
         
     | 
| 
       4290 
     | 
    
         
            -
              },
         
     | 
| 
       4291 
     | 
    
         
            -
              interpose: function interpose(separator) {
         
     | 
| 
       4292 
     | 
    
         
            -
                return reify(this, interposeFactory(this, separator));
         
     | 
| 
       4293 
     | 
    
         
            -
              },
         
     | 
| 
       4294 
     | 
    
         
            -
              interleave: function interleave(/*...collections*/
         
     | 
| 
       4295 
     | 
    
         
            -
              ) {
         
     | 
| 
       4296 
     | 
    
         
            -
                var collections = [this].concat(arrCopy(arguments));
         
     | 
| 
       4297 
     | 
    
         
            -
                var zipped = zipWithFactory(this.toSeq(), IndexedSeq.of, collections);
         
     | 
| 
       4298 
     | 
    
         
            -
                var interleaved = zipped.flatten(true);
         
     | 
| 
       4299 
     | 
    
         
            -
                if (zipped.size) {
         
     | 
| 
       4300 
     | 
    
         
            -
                  interleaved.size = zipped.size * collections.length;
         
     | 
| 
       4301 
     | 
    
         
            -
                }
         
     | 
| 
       4302 
     | 
    
         
            -
                return reify(this, interleaved);
         
     | 
| 
       4303 
     | 
    
         
            -
              },
         
     | 
| 
       4304 
     | 
    
         
            -
              keySeq: function keySeq() {
         
     | 
| 
       4305 
     | 
    
         
            -
                return Range(0, this.size);
         
     | 
| 
       4306 
     | 
    
         
            -
              },
         
     | 
| 
       4307 
     | 
    
         
            -
              last: function last(notSetValue) {
         
     | 
| 
       4308 
     | 
    
         
            -
                return this.get(-1, notSetValue);
         
     | 
| 
       4309 
     | 
    
         
            -
              },
         
     | 
| 
       4310 
     | 
    
         
            -
              skipWhile: function skipWhile(predicate, context) {
         
     | 
| 
       4311 
     | 
    
         
            -
                return reify(this, skipWhileFactory(this, predicate, context, false));
         
     | 
| 
       4312 
     | 
    
         
            -
              },
         
     | 
| 
       4313 
     | 
    
         
            -
              zip: function zip(/*, ...collections */
         
     | 
| 
       4314 
     | 
    
         
            -
              ) {
         
     | 
| 
       4315 
     | 
    
         
            -
                var collections = [this].concat(arrCopy(arguments));
         
     | 
| 
       4316 
     | 
    
         
            -
                return reify(this, zipWithFactory(this, defaultZipper, collections));
         
     | 
| 
       4317 
     | 
    
         
            -
              },
         
     | 
| 
       4318 
     | 
    
         
            -
              zipAll: function zipAll(/*, ...collections */
         
     | 
| 
       4319 
     | 
    
         
            -
              ) {
         
     | 
| 
       4320 
     | 
    
         
            -
                var collections = [this].concat(arrCopy(arguments));
         
     | 
| 
       4321 
     | 
    
         
            -
                return reify(this, zipWithFactory(this, defaultZipper, collections, true));
         
     | 
| 
       4322 
     | 
    
         
            -
              },
         
     | 
| 
       4323 
     | 
    
         
            -
              zipWith: function zipWith(zipper /*, ...collections */) {
         
     | 
| 
       4324 
     | 
    
         
            -
                var collections = arrCopy(arguments);
         
     | 
| 
       4325 
     | 
    
         
            -
                collections[0] = this;
         
     | 
| 
       4326 
     | 
    
         
            -
                return reify(this, zipWithFactory(this, zipper, collections));
         
     | 
| 
       4327 
     | 
    
         
            -
              }
         
     | 
| 
       4328 
     | 
    
         
            -
            });
         
     | 
| 
       4329 
     | 
    
         
            -
            var IndexedCollectionPrototype = IndexedCollection.prototype;
         
     | 
| 
       4330 
     | 
    
         
            -
            IndexedCollectionPrototype[IS_INDEXED_SYMBOL] = true;
         
     | 
| 
       4331 
     | 
    
         
            -
            IndexedCollectionPrototype[IS_ORDERED_SYMBOL] = true;
         
     | 
| 
       4332 
     | 
    
         
            -
            mixin(SetCollection, {
         
     | 
| 
       4333 
     | 
    
         
            -
              // ### ES6 Collection methods (ES6 Array and Map)
         
     | 
| 
       4334 
     | 
    
         
            -
             
     | 
| 
       4335 
     | 
    
         
            -
              get: function get(value, notSetValue) {
         
     | 
| 
       4336 
     | 
    
         
            -
                return this.has(value) ? value : notSetValue;
         
     | 
| 
       4337 
     | 
    
         
            -
              },
         
     | 
| 
       4338 
     | 
    
         
            -
              includes: function includes(value) {
         
     | 
| 
       4339 
     | 
    
         
            -
                return this.has(value);
         
     | 
| 
       4340 
     | 
    
         
            -
              },
         
     | 
| 
       4341 
     | 
    
         
            -
              // ### More sequential methods
         
     | 
| 
       4342 
     | 
    
         
            -
             
     | 
| 
       4343 
     | 
    
         
            -
              keySeq: function keySeq() {
         
     | 
| 
       4344 
     | 
    
         
            -
                return this.valueSeq();
         
     | 
| 
       4345 
     | 
    
         
            -
              }
         
     | 
| 
       4346 
     | 
    
         
            -
            });
         
     | 
| 
       4347 
     | 
    
         
            -
            var SetCollectionPrototype = SetCollection.prototype;
         
     | 
| 
       4348 
     | 
    
         
            -
            SetCollectionPrototype.has = CollectionPrototype.includes;
         
     | 
| 
       4349 
     | 
    
         
            -
            SetCollectionPrototype.contains = SetCollectionPrototype.includes;
         
     | 
| 
       4350 
     | 
    
         
            -
            SetCollectionPrototype.keys = SetCollectionPrototype.values;
         
     | 
| 
       4351 
     | 
    
         
            -
             
     | 
| 
       4352 
     | 
    
         
            -
            // Mixin subclasses
         
     | 
| 
       4353 
     | 
    
         
            -
             
     | 
| 
       4354 
     | 
    
         
            -
            mixin(KeyedSeq, KeyedCollectionPrototype);
         
     | 
| 
       4355 
     | 
    
         
            -
            mixin(IndexedSeq, IndexedCollectionPrototype);
         
     | 
| 
       4356 
     | 
    
         
            -
            mixin(SetSeq, SetCollectionPrototype);
         
     | 
| 
       4357 
     | 
    
         
            -
             
     | 
| 
       4358 
     | 
    
         
            -
            // #pragma Helper functions
         
     | 
| 
       4359 
     | 
    
         
            -
             
     | 
| 
       4360 
     | 
    
         
            -
            function reduce(collection, reducer, reduction, context, useFirst, reverse) {
         
     | 
| 
       4361 
     | 
    
         
            -
              assertNotInfinite(collection.size);
         
     | 
| 
       4362 
     | 
    
         
            -
              collection.__iterate(function (v, k, c) {
         
     | 
| 
       4363 
     | 
    
         
            -
                if (useFirst) {
         
     | 
| 
       4364 
     | 
    
         
            -
                  useFirst = false;
         
     | 
| 
       4365 
     | 
    
         
            -
                  reduction = v;
         
     | 
| 
       4366 
     | 
    
         
            -
                } else {
         
     | 
| 
       4367 
     | 
    
         
            -
                  reduction = reducer.call(context, reduction, v, k, c);
         
     | 
| 
       4368 
     | 
    
         
            -
                }
         
     | 
| 
       4369 
     | 
    
         
            -
              }, reverse);
         
     | 
| 
       4370 
     | 
    
         
            -
              return reduction;
         
     | 
| 
       4371 
     | 
    
         
            -
            }
         
     | 
| 
       4372 
     | 
    
         
            -
            function keyMapper(v, k) {
         
     | 
| 
       4373 
     | 
    
         
            -
              return k;
         
     | 
| 
       4374 
     | 
    
         
            -
            }
         
     | 
| 
       4375 
     | 
    
         
            -
            function entryMapper(v, k) {
         
     | 
| 
       4376 
     | 
    
         
            -
              return [k, v];
         
     | 
| 
       4377 
     | 
    
         
            -
            }
         
     | 
| 
       4378 
     | 
    
         
            -
            function not(predicate) {
         
     | 
| 
       4379 
     | 
    
         
            -
              return function () {
         
     | 
| 
       4380 
     | 
    
         
            -
                return !predicate.apply(this, arguments);
         
     | 
| 
       4381 
     | 
    
         
            -
              };
         
     | 
| 
       4382 
     | 
    
         
            -
            }
         
     | 
| 
       4383 
     | 
    
         
            -
            function neg(predicate) {
         
     | 
| 
       4384 
     | 
    
         
            -
              return function () {
         
     | 
| 
       4385 
     | 
    
         
            -
                return -predicate.apply(this, arguments);
         
     | 
| 
       4386 
     | 
    
         
            -
              };
         
     | 
| 
       4387 
     | 
    
         
            -
            }
         
     | 
| 
       4388 
     | 
    
         
            -
            function defaultZipper() {
         
     | 
| 
       4389 
     | 
    
         
            -
              return arrCopy(arguments);
         
     | 
| 
       4390 
     | 
    
         
            -
            }
         
     | 
| 
       4391 
     | 
    
         
            -
            function defaultNegComparator(a, b) {
         
     | 
| 
       4392 
     | 
    
         
            -
              return a < b ? 1 : a > b ? -1 : 0;
         
     | 
| 
       4393 
     | 
    
         
            -
            }
         
     | 
| 
       4394 
     | 
    
         
            -
            function hashCollection(collection) {
         
     | 
| 
       4395 
     | 
    
         
            -
              if (collection.size === Infinity) {
         
     | 
| 
       4396 
     | 
    
         
            -
                return 0;
         
     | 
| 
       4397 
     | 
    
         
            -
              }
         
     | 
| 
       4398 
     | 
    
         
            -
              var ordered = isOrdered(collection);
         
     | 
| 
       4399 
     | 
    
         
            -
              var keyed = isKeyed(collection);
         
     | 
| 
       4400 
     | 
    
         
            -
              var h = ordered ? 1 : 0;
         
     | 
| 
       4401 
     | 
    
         
            -
              var size = collection.__iterate(keyed ? ordered ? function (v, k) {
         
     | 
| 
       4402 
     | 
    
         
            -
                h = 31 * h + hashMerge(hash(v), hash(k)) | 0;
         
     | 
| 
       4403 
     | 
    
         
            -
              } : function (v, k) {
         
     | 
| 
       4404 
     | 
    
         
            -
                h = h + hashMerge(hash(v), hash(k)) | 0;
         
     | 
| 
       4405 
     | 
    
         
            -
              } : ordered ? function (v) {
         
     | 
| 
       4406 
     | 
    
         
            -
                h = 31 * h + hash(v) | 0;
         
     | 
| 
       4407 
     | 
    
         
            -
              } : function (v) {
         
     | 
| 
       4408 
     | 
    
         
            -
                h = h + hash(v) | 0;
         
     | 
| 
       4409 
     | 
    
         
            -
              });
         
     | 
| 
       4410 
     | 
    
         
            -
              return murmurHashOfSize(size, h);
         
     | 
| 
       4411 
     | 
    
         
            -
            }
         
     | 
| 
       4412 
     | 
    
         
            -
            function murmurHashOfSize(size, h) {
         
     | 
| 
       4413 
     | 
    
         
            -
              h = imul(h, 0xcc9e2d51);
         
     | 
| 
       4414 
     | 
    
         
            -
              h = imul(h << 15 | h >>> -15, 0x1b873593);
         
     | 
| 
       4415 
     | 
    
         
            -
              h = imul(h << 13 | h >>> -13, 5);
         
     | 
| 
       4416 
     | 
    
         
            -
              h = (h + 0xe6546b64 | 0) ^ size;
         
     | 
| 
       4417 
     | 
    
         
            -
              h = imul(h ^ h >>> 16, 0x85ebca6b);
         
     | 
| 
       4418 
     | 
    
         
            -
              h = imul(h ^ h >>> 13, 0xc2b2ae35);
         
     | 
| 
       4419 
     | 
    
         
            -
              h = smi(h ^ h >>> 16);
         
     | 
| 
       4420 
     | 
    
         
            -
              return h;
         
     | 
| 
       4421 
     | 
    
         
            -
            }
         
     | 
| 
       4422 
     | 
    
         
            -
            function hashMerge(a, b) {
         
     | 
| 
       4423 
     | 
    
         
            -
              return a ^ b + 0x9e3779b9 + (a << 6) + (a >> 2) | 0; // int
         
     | 
| 
       4424 
     | 
    
         
            -
            }
         
     | 
| 
       4425 
     | 
    
         
            -
            var OrderedSet = /*@__PURE__*/function (Set) {
         
     | 
| 
       4426 
     | 
    
         
            -
              function OrderedSet(value) {
         
     | 
| 
       4427 
     | 
    
         
            -
                // eslint-disable-next-line no-constructor-return
         
     | 
| 
       4428 
     | 
    
         
            -
                return value === undefined || value === null ? emptyOrderedSet() : isOrderedSet(value) ? value : emptyOrderedSet().withMutations(function (set) {
         
     | 
| 
       4429 
     | 
    
         
            -
                  var iter = SetCollection(value);
         
     | 
| 
       4430 
     | 
    
         
            -
                  assertNotInfinite(iter.size);
         
     | 
| 
       4431 
     | 
    
         
            -
                  iter.forEach(function (v) {
         
     | 
| 
       4432 
     | 
    
         
            -
                    return set.add(v);
         
     | 
| 
       4433 
     | 
    
         
            -
                  });
         
     | 
| 
       4434 
     | 
    
         
            -
                });
         
     | 
| 
       4435 
     | 
    
         
            -
              }
         
     | 
| 
       4436 
     | 
    
         
            -
              if (Set) OrderedSet.__proto__ = Set;
         
     | 
| 
       4437 
     | 
    
         
            -
              OrderedSet.prototype = Object.create(Set && Set.prototype);
         
     | 
| 
       4438 
     | 
    
         
            -
              OrderedSet.prototype.constructor = OrderedSet;
         
     | 
| 
       4439 
     | 
    
         
            -
              OrderedSet.of = function of(/*...values*/
         
     | 
| 
       4440 
     | 
    
         
            -
              ) {
         
     | 
| 
       4441 
     | 
    
         
            -
                return this(arguments);
         
     | 
| 
       4442 
     | 
    
         
            -
              };
         
     | 
| 
       4443 
     | 
    
         
            -
              OrderedSet.fromKeys = function fromKeys(value) {
         
     | 
| 
       4444 
     | 
    
         
            -
                return this(KeyedCollection(value).keySeq());
         
     | 
| 
       4445 
     | 
    
         
            -
              };
         
     | 
| 
       4446 
     | 
    
         
            -
              OrderedSet.prototype.toString = function toString() {
         
     | 
| 
       4447 
     | 
    
         
            -
                return this.__toString('OrderedSet {', '}');
         
     | 
| 
       4448 
     | 
    
         
            -
              };
         
     | 
| 
       4449 
     | 
    
         
            -
              return OrderedSet;
         
     | 
| 
       4450 
     | 
    
         
            -
            }(Set);
         
     | 
| 
       4451 
     | 
    
         
            -
            OrderedSet.isOrderedSet = isOrderedSet;
         
     | 
| 
       4452 
     | 
    
         
            -
            var OrderedSetPrototype = OrderedSet.prototype;
         
     | 
| 
       4453 
     | 
    
         
            -
            OrderedSetPrototype[IS_ORDERED_SYMBOL] = true;
         
     | 
| 
       4454 
     | 
    
         
            -
            OrderedSetPrototype.zip = IndexedCollectionPrototype.zip;
         
     | 
| 
       4455 
     | 
    
         
            -
            OrderedSetPrototype.zipWith = IndexedCollectionPrototype.zipWith;
         
     | 
| 
       4456 
     | 
    
         
            -
            OrderedSetPrototype.zipAll = IndexedCollectionPrototype.zipAll;
         
     | 
| 
       4457 
     | 
    
         
            -
            OrderedSetPrototype.__empty = emptyOrderedSet;
         
     | 
| 
       4458 
     | 
    
         
            -
            OrderedSetPrototype.__make = makeOrderedSet;
         
     | 
| 
       4459 
     | 
    
         
            -
            function makeOrderedSet(map, ownerID) {
         
     | 
| 
       4460 
     | 
    
         
            -
              var set = Object.create(OrderedSetPrototype);
         
     | 
| 
       4461 
     | 
    
         
            -
              set.size = map ? map.size : 0;
         
     | 
| 
       4462 
     | 
    
         
            -
              set._map = map;
         
     | 
| 
       4463 
     | 
    
         
            -
              set.__ownerID = ownerID;
         
     | 
| 
       4464 
     | 
    
         
            -
              return set;
         
     | 
| 
       4465 
     | 
    
         
            -
            }
         
     | 
| 
       4466 
     | 
    
         
            -
            var EMPTY_ORDERED_SET;
         
     | 
| 
       4467 
     | 
    
         
            -
            function emptyOrderedSet() {
         
     | 
| 
       4468 
     | 
    
         
            -
              return EMPTY_ORDERED_SET || (EMPTY_ORDERED_SET = makeOrderedSet(emptyOrderedMap()));
         
     | 
| 
       4469 
     | 
    
         
            -
            }
         
     | 
| 
       4470 
     | 
    
         
            -
            var PairSorting = {
         
     | 
| 
       4471 
     | 
    
         
            -
              LeftThenRight: -1,
         
     | 
| 
       4472 
     | 
    
         
            -
              RightThenLeft: 1
         
     | 
| 
       4473 
     | 
    
         
            -
            };
         
     | 
| 
       4474 
     | 
    
         
            -
            function throwOnInvalidDefaultValues(defaultValues) {
         
     | 
| 
       4475 
     | 
    
         
            -
              if (isRecord(defaultValues)) {
         
     | 
| 
       4476 
     | 
    
         
            -
                throw new Error('Can not call `Record` with an immutable Record as default values. Use a plain javascript object instead.');
         
     | 
| 
       4477 
     | 
    
         
            -
              }
         
     | 
| 
       4478 
     | 
    
         
            -
              if (isImmutable(defaultValues)) {
         
     | 
| 
       4479 
     | 
    
         
            -
                throw new Error('Can not call `Record` with an immutable Collection as default values. Use a plain javascript object instead.');
         
     | 
| 
       4480 
     | 
    
         
            -
              }
         
     | 
| 
       4481 
     | 
    
         
            -
              if (defaultValues === null || typeof defaultValues !== 'object') {
         
     | 
| 
       4482 
     | 
    
         
            -
                throw new Error('Can not call `Record` with a non-object as default values. Use a plain javascript object instead.');
         
     | 
| 
       4483 
     | 
    
         
            -
              }
         
     | 
| 
       4484 
     | 
    
         
            -
            }
         
     | 
| 
       4485 
     | 
    
         
            -
            var Record = function Record(defaultValues, name) {
         
     | 
| 
       4486 
     | 
    
         
            -
              var hasInitialized;
         
     | 
| 
       4487 
     | 
    
         
            -
              throwOnInvalidDefaultValues(defaultValues);
         
     | 
| 
       4488 
     | 
    
         
            -
              var RecordType = function Record(values) {
         
     | 
| 
       4489 
     | 
    
         
            -
                var this$1$1 = this;
         
     | 
| 
       4490 
     | 
    
         
            -
                if (values instanceof RecordType) {
         
     | 
| 
       4491 
     | 
    
         
            -
                  return values;
         
     | 
| 
       4492 
     | 
    
         
            -
                }
         
     | 
| 
       4493 
     | 
    
         
            -
                if (!(this instanceof RecordType)) {
         
     | 
| 
       4494 
     | 
    
         
            -
                  return new RecordType(values);
         
     | 
| 
       4495 
     | 
    
         
            -
                }
         
     | 
| 
       4496 
     | 
    
         
            -
                if (!hasInitialized) {
         
     | 
| 
       4497 
     | 
    
         
            -
                  hasInitialized = true;
         
     | 
| 
       4498 
     | 
    
         
            -
                  var keys = Object.keys(defaultValues);
         
     | 
| 
       4499 
     | 
    
         
            -
                  var indices = RecordTypePrototype._indices = {};
         
     | 
| 
       4500 
     | 
    
         
            -
                  // Deprecated: left to attempt not to break any external code which
         
     | 
| 
       4501 
     | 
    
         
            -
                  // relies on a ._name property existing on record instances.
         
     | 
| 
       4502 
     | 
    
         
            -
                  // Use Record.getDescriptiveName() instead
         
     | 
| 
       4503 
     | 
    
         
            -
                  RecordTypePrototype._name = name;
         
     | 
| 
       4504 
     | 
    
         
            -
                  RecordTypePrototype._keys = keys;
         
     | 
| 
       4505 
     | 
    
         
            -
                  RecordTypePrototype._defaultValues = defaultValues;
         
     | 
| 
       4506 
     | 
    
         
            -
                  for (var i = 0; i < keys.length; i++) {
         
     | 
| 
       4507 
     | 
    
         
            -
                    var propName = keys[i];
         
     | 
| 
       4508 
     | 
    
         
            -
                    indices[propName] = i;
         
     | 
| 
       4509 
     | 
    
         
            -
                    if (RecordTypePrototype[propName]) {
         
     | 
| 
       4510 
     | 
    
         
            -
                      /* eslint-disable no-console */
         
     | 
| 
       4511 
     | 
    
         
            -
                      typeof console === 'object' && console.warn && console.warn('Cannot define ' + recordName(this) + ' with property "' + propName + '" since that property name is part of the Record API.');
         
     | 
| 
       4512 
     | 
    
         
            -
                      /* eslint-enable no-console */
         
     | 
| 
       4513 
     | 
    
         
            -
                    } else {
         
     | 
| 
       4514 
     | 
    
         
            -
                      setProp(RecordTypePrototype, propName);
         
     | 
| 
       4515 
     | 
    
         
            -
                    }
         
     | 
| 
       4516 
     | 
    
         
            -
                  }
         
     | 
| 
       4517 
     | 
    
         
            -
                }
         
     | 
| 
       4518 
     | 
    
         
            -
                this.__ownerID = undefined;
         
     | 
| 
       4519 
     | 
    
         
            -
                this._values = List().withMutations(function (l) {
         
     | 
| 
       4520 
     | 
    
         
            -
                  l.setSize(this$1$1._keys.length);
         
     | 
| 
       4521 
     | 
    
         
            -
                  KeyedCollection(values).forEach(function (v, k) {
         
     | 
| 
       4522 
     | 
    
         
            -
                    l.set(this$1$1._indices[k], v === this$1$1._defaultValues[k] ? undefined : v);
         
     | 
| 
       4523 
     | 
    
         
            -
                  });
         
     | 
| 
       4524 
     | 
    
         
            -
                });
         
     | 
| 
       4525 
     | 
    
         
            -
                return this;
         
     | 
| 
       4526 
     | 
    
         
            -
              };
         
     | 
| 
       4527 
     | 
    
         
            -
              var RecordTypePrototype = RecordType.prototype = Object.create(RecordPrototype);
         
     | 
| 
       4528 
     | 
    
         
            -
              RecordTypePrototype.constructor = RecordType;
         
     | 
| 
       4529 
     | 
    
         
            -
              if (name) {
         
     | 
| 
       4530 
     | 
    
         
            -
                RecordType.displayName = name;
         
     | 
| 
       4531 
     | 
    
         
            -
              }
         
     | 
| 
       4532 
     | 
    
         
            -
             
     | 
| 
       4533 
     | 
    
         
            -
              // eslint-disable-next-line no-constructor-return
         
     | 
| 
       4534 
     | 
    
         
            -
              return RecordType;
         
     | 
| 
       4535 
     | 
    
         
            -
            };
         
     | 
| 
       4536 
     | 
    
         
            -
            Record.prototype.toString = function toString() {
         
     | 
| 
       4537 
     | 
    
         
            -
              var str = recordName(this) + ' { ';
         
     | 
| 
       4538 
     | 
    
         
            -
              var keys = this._keys;
         
     | 
| 
       4539 
     | 
    
         
            -
              var k;
         
     | 
| 
       4540 
     | 
    
         
            -
              for (var i = 0, l = keys.length; i !== l; i++) {
         
     | 
| 
       4541 
     | 
    
         
            -
                k = keys[i];
         
     | 
| 
       4542 
     | 
    
         
            -
                str += (i ? ', ' : '') + k + ': ' + quoteString(this.get(k));
         
     | 
| 
       4543 
     | 
    
         
            -
              }
         
     | 
| 
       4544 
     | 
    
         
            -
              return str + ' }';
         
     | 
| 
       4545 
     | 
    
         
            -
            };
         
     | 
| 
       4546 
     | 
    
         
            -
            Record.prototype.equals = function equals(other) {
         
     | 
| 
       4547 
     | 
    
         
            -
              return this === other || isRecord(other) && recordSeq(this).equals(recordSeq(other));
         
     | 
| 
       4548 
     | 
    
         
            -
            };
         
     | 
| 
       4549 
     | 
    
         
            -
            Record.prototype.hashCode = function hashCode() {
         
     | 
| 
       4550 
     | 
    
         
            -
              return recordSeq(this).hashCode();
         
     | 
| 
       4551 
     | 
    
         
            -
            };
         
     | 
| 
       4552 
     | 
    
         
            -
             
     | 
| 
       4553 
     | 
    
         
            -
            // @pragma Access
         
     | 
| 
       4554 
     | 
    
         
            -
             
     | 
| 
       4555 
     | 
    
         
            -
            Record.prototype.has = function has(k) {
         
     | 
| 
       4556 
     | 
    
         
            -
              return this._indices.hasOwnProperty(k);
         
     | 
| 
       4557 
     | 
    
         
            -
            };
         
     | 
| 
       4558 
     | 
    
         
            -
            Record.prototype.get = function get(k, notSetValue) {
         
     | 
| 
       4559 
     | 
    
         
            -
              if (!this.has(k)) {
         
     | 
| 
       4560 
     | 
    
         
            -
                return notSetValue;
         
     | 
| 
       4561 
     | 
    
         
            -
              }
         
     | 
| 
       4562 
     | 
    
         
            -
              var index = this._indices[k];
         
     | 
| 
       4563 
     | 
    
         
            -
              var value = this._values.get(index);
         
     | 
| 
       4564 
     | 
    
         
            -
              return value === undefined ? this._defaultValues[k] : value;
         
     | 
| 
       4565 
     | 
    
         
            -
            };
         
     | 
| 
       4566 
     | 
    
         
            -
             
     | 
| 
       4567 
     | 
    
         
            -
            // @pragma Modification
         
     | 
| 
       4568 
     | 
    
         
            -
             
     | 
| 
       4569 
     | 
    
         
            -
            Record.prototype.set = function set(k, v) {
         
     | 
| 
       4570 
     | 
    
         
            -
              if (this.has(k)) {
         
     | 
| 
       4571 
     | 
    
         
            -
                var newValues = this._values.set(this._indices[k], v === this._defaultValues[k] ? undefined : v);
         
     | 
| 
       4572 
     | 
    
         
            -
                if (newValues !== this._values && !this.__ownerID) {
         
     | 
| 
       4573 
     | 
    
         
            -
                  return makeRecord(this, newValues);
         
     | 
| 
       4574 
     | 
    
         
            -
                }
         
     | 
| 
       4575 
     | 
    
         
            -
              }
         
     | 
| 
       4576 
     | 
    
         
            -
              return this;
         
     | 
| 
       4577 
     | 
    
         
            -
            };
         
     | 
| 
       4578 
     | 
    
         
            -
            Record.prototype.remove = function remove(k) {
         
     | 
| 
       4579 
     | 
    
         
            -
              return this.set(k);
         
     | 
| 
       4580 
     | 
    
         
            -
            };
         
     | 
| 
       4581 
     | 
    
         
            -
            Record.prototype.clear = function clear() {
         
     | 
| 
       4582 
     | 
    
         
            -
              var newValues = this._values.clear().setSize(this._keys.length);
         
     | 
| 
       4583 
     | 
    
         
            -
              return this.__ownerID ? this : makeRecord(this, newValues);
         
     | 
| 
       4584 
     | 
    
         
            -
            };
         
     | 
| 
       4585 
     | 
    
         
            -
            Record.prototype.wasAltered = function wasAltered() {
         
     | 
| 
       4586 
     | 
    
         
            -
              return this._values.wasAltered();
         
     | 
| 
       4587 
     | 
    
         
            -
            };
         
     | 
| 
       4588 
     | 
    
         
            -
            Record.prototype.toSeq = function toSeq() {
         
     | 
| 
       4589 
     | 
    
         
            -
              return recordSeq(this);
         
     | 
| 
       4590 
     | 
    
         
            -
            };
         
     | 
| 
       4591 
     | 
    
         
            -
            Record.prototype.toJS = function toJS$1() {
         
     | 
| 
       4592 
     | 
    
         
            -
              return toJS(this);
         
     | 
| 
       4593 
     | 
    
         
            -
            };
         
     | 
| 
       4594 
     | 
    
         
            -
            Record.prototype.entries = function entries() {
         
     | 
| 
       4595 
     | 
    
         
            -
              return this.__iterator(ITERATE_ENTRIES);
         
     | 
| 
       4596 
     | 
    
         
            -
            };
         
     | 
| 
       4597 
     | 
    
         
            -
            Record.prototype.__iterator = function __iterator(type, reverse) {
         
     | 
| 
       4598 
     | 
    
         
            -
              return recordSeq(this).__iterator(type, reverse);
         
     | 
| 
       4599 
     | 
    
         
            -
            };
         
     | 
| 
       4600 
     | 
    
         
            -
            Record.prototype.__iterate = function __iterate(fn, reverse) {
         
     | 
| 
       4601 
     | 
    
         
            -
              return recordSeq(this).__iterate(fn, reverse);
         
     | 
| 
       4602 
     | 
    
         
            -
            };
         
     | 
| 
       4603 
     | 
    
         
            -
            Record.prototype.__ensureOwner = function __ensureOwner(ownerID) {
         
     | 
| 
       4604 
     | 
    
         
            -
              if (ownerID === this.__ownerID) {
         
     | 
| 
       4605 
     | 
    
         
            -
                return this;
         
     | 
| 
       4606 
     | 
    
         
            -
              }
         
     | 
| 
       4607 
     | 
    
         
            -
              var newValues = this._values.__ensureOwner(ownerID);
         
     | 
| 
       4608 
     | 
    
         
            -
              if (!ownerID) {
         
     | 
| 
       4609 
     | 
    
         
            -
                this.__ownerID = ownerID;
         
     | 
| 
       4610 
     | 
    
         
            -
                this._values = newValues;
         
     | 
| 
       4611 
     | 
    
         
            -
                return this;
         
     | 
| 
       4612 
     | 
    
         
            -
              }
         
     | 
| 
       4613 
     | 
    
         
            -
              return makeRecord(this, newValues, ownerID);
         
     | 
| 
       4614 
     | 
    
         
            -
            };
         
     | 
| 
       4615 
     | 
    
         
            -
            Record.isRecord = isRecord;
         
     | 
| 
       4616 
     | 
    
         
            -
            Record.getDescriptiveName = recordName;
         
     | 
| 
       4617 
     | 
    
         
            -
            var RecordPrototype = Record.prototype;
         
     | 
| 
       4618 
     | 
    
         
            -
            RecordPrototype[IS_RECORD_SYMBOL] = true;
         
     | 
| 
       4619 
     | 
    
         
            -
            RecordPrototype[DELETE] = RecordPrototype.remove;
         
     | 
| 
       4620 
     | 
    
         
            -
            RecordPrototype.deleteIn = RecordPrototype.removeIn = deleteIn;
         
     | 
| 
       4621 
     | 
    
         
            -
            RecordPrototype.getIn = getIn;
         
     | 
| 
       4622 
     | 
    
         
            -
            RecordPrototype.hasIn = CollectionPrototype.hasIn;
         
     | 
| 
       4623 
     | 
    
         
            -
            RecordPrototype.merge = merge$1;
         
     | 
| 
       4624 
     | 
    
         
            -
            RecordPrototype.mergeWith = mergeWith$1;
         
     | 
| 
       4625 
     | 
    
         
            -
            RecordPrototype.mergeIn = mergeIn;
         
     | 
| 
       4626 
     | 
    
         
            -
            RecordPrototype.mergeDeep = mergeDeep;
         
     | 
| 
       4627 
     | 
    
         
            -
            RecordPrototype.mergeDeepWith = mergeDeepWith;
         
     | 
| 
       4628 
     | 
    
         
            -
            RecordPrototype.mergeDeepIn = mergeDeepIn;
         
     | 
| 
       4629 
     | 
    
         
            -
            RecordPrototype.setIn = setIn;
         
     | 
| 
       4630 
     | 
    
         
            -
            RecordPrototype.update = update;
         
     | 
| 
       4631 
     | 
    
         
            -
            RecordPrototype.updateIn = updateIn;
         
     | 
| 
       4632 
     | 
    
         
            -
            RecordPrototype.withMutations = withMutations;
         
     | 
| 
       4633 
     | 
    
         
            -
            RecordPrototype.asMutable = asMutable;
         
     | 
| 
       4634 
     | 
    
         
            -
            RecordPrototype.asImmutable = asImmutable;
         
     | 
| 
       4635 
     | 
    
         
            -
            RecordPrototype[ITERATOR_SYMBOL] = RecordPrototype.entries;
         
     | 
| 
       4636 
     | 
    
         
            -
            RecordPrototype.toJSON = RecordPrototype.toObject = CollectionPrototype.toObject;
         
     | 
| 
       4637 
     | 
    
         
            -
            RecordPrototype.inspect = RecordPrototype.toSource = function () {
         
     | 
| 
       4638 
     | 
    
         
            -
              return this.toString();
         
     | 
| 
       4639 
     | 
    
         
            -
            };
         
     | 
| 
       4640 
     | 
    
         
            -
            function makeRecord(likeRecord, values, ownerID) {
         
     | 
| 
       4641 
     | 
    
         
            -
              var record = Object.create(Object.getPrototypeOf(likeRecord));
         
     | 
| 
       4642 
     | 
    
         
            -
              record._values = values;
         
     | 
| 
       4643 
     | 
    
         
            -
              record.__ownerID = ownerID;
         
     | 
| 
       4644 
     | 
    
         
            -
              return record;
         
     | 
| 
       4645 
     | 
    
         
            -
            }
         
     | 
| 
       4646 
     | 
    
         
            -
            function recordName(record) {
         
     | 
| 
       4647 
     | 
    
         
            -
              return record.constructor.displayName || record.constructor.name || 'Record';
         
     | 
| 
       4648 
     | 
    
         
            -
            }
         
     | 
| 
       4649 
     | 
    
         
            -
            function recordSeq(record) {
         
     | 
| 
       4650 
     | 
    
         
            -
              return keyedSeqFromValue(record._keys.map(function (k) {
         
     | 
| 
       4651 
     | 
    
         
            -
                return [k, record.get(k)];
         
     | 
| 
       4652 
     | 
    
         
            -
              }));
         
     | 
| 
       4653 
     | 
    
         
            -
            }
         
     | 
| 
       4654 
     | 
    
         
            -
            function setProp(prototype, name) {
         
     | 
| 
       4655 
     | 
    
         
            -
              try {
         
     | 
| 
       4656 
     | 
    
         
            -
                Object.defineProperty(prototype, name, {
         
     | 
| 
       4657 
     | 
    
         
            -
                  get: function () {
         
     | 
| 
       4658 
     | 
    
         
            -
                    return this.get(name);
         
     | 
| 
       4659 
     | 
    
         
            -
                  },
         
     | 
| 
       4660 
     | 
    
         
            -
                  set: function (value) {
         
     | 
| 
       4661 
     | 
    
         
            -
                    invariant(this.__ownerID, 'Cannot set on an immutable record.');
         
     | 
| 
       4662 
     | 
    
         
            -
                    this.set(name, value);
         
     | 
| 
       4663 
     | 
    
         
            -
                  }
         
     | 
| 
       4664 
     | 
    
         
            -
                });
         
     | 
| 
       4665 
     | 
    
         
            -
              } catch (error) {
         
     | 
| 
       4666 
     | 
    
         
            -
                // Object.defineProperty failed. Probably IE8.
         
     | 
| 
       4667 
     | 
    
         
            -
              }
         
     | 
| 
       4668 
     | 
    
         
            -
            }
         
     | 
| 
       4669 
     | 
    
         
            -
             
     | 
| 
       4670 
     | 
    
         
            -
            /**
         
     | 
| 
       4671 
     | 
    
         
            -
             * Returns a lazy Seq of `value` repeated `times` times. When `times` is
         
     | 
| 
       4672 
     | 
    
         
            -
             * undefined, returns an infinite sequence of `value`.
         
     | 
| 
       4673 
     | 
    
         
            -
             */
         
     | 
| 
       4674 
     | 
    
         
            -
            var Repeat = /*@__PURE__*/function (IndexedSeq) {
         
     | 
| 
       4675 
     | 
    
         
            -
              function Repeat(value, times) {
         
     | 
| 
       4676 
     | 
    
         
            -
                if (!(this instanceof Repeat)) {
         
     | 
| 
       4677 
     | 
    
         
            -
                  // eslint-disable-next-line no-constructor-return
         
     | 
| 
       4678 
     | 
    
         
            -
                  return new Repeat(value, times);
         
     | 
| 
       4679 
     | 
    
         
            -
                }
         
     | 
| 
       4680 
     | 
    
         
            -
                this._value = value;
         
     | 
| 
       4681 
     | 
    
         
            -
                this.size = times === undefined ? Infinity : Math.max(0, times);
         
     | 
| 
       4682 
     | 
    
         
            -
                if (this.size === 0) {
         
     | 
| 
       4683 
     | 
    
         
            -
                  if (EMPTY_REPEAT) {
         
     | 
| 
       4684 
     | 
    
         
            -
                    // eslint-disable-next-line no-constructor-return
         
     | 
| 
       4685 
     | 
    
         
            -
                    return EMPTY_REPEAT;
         
     | 
| 
       4686 
     | 
    
         
            -
                  }
         
     | 
| 
       4687 
     | 
    
         
            -
                  EMPTY_REPEAT = this;
         
     | 
| 
       4688 
     | 
    
         
            -
                }
         
     | 
| 
       4689 
     | 
    
         
            -
              }
         
     | 
| 
       4690 
     | 
    
         
            -
              if (IndexedSeq) Repeat.__proto__ = IndexedSeq;
         
     | 
| 
       4691 
     | 
    
         
            -
              Repeat.prototype = Object.create(IndexedSeq && IndexedSeq.prototype);
         
     | 
| 
       4692 
     | 
    
         
            -
              Repeat.prototype.constructor = Repeat;
         
     | 
| 
       4693 
     | 
    
         
            -
              Repeat.prototype.toString = function toString() {
         
     | 
| 
       4694 
     | 
    
         
            -
                if (this.size === 0) {
         
     | 
| 
       4695 
     | 
    
         
            -
                  return 'Repeat []';
         
     | 
| 
       4696 
     | 
    
         
            -
                }
         
     | 
| 
       4697 
     | 
    
         
            -
                return 'Repeat [ ' + this._value + ' ' + this.size + ' times ]';
         
     | 
| 
       4698 
     | 
    
         
            -
              };
         
     | 
| 
       4699 
     | 
    
         
            -
              Repeat.prototype.get = function get(index, notSetValue) {
         
     | 
| 
       4700 
     | 
    
         
            -
                return this.has(index) ? this._value : notSetValue;
         
     | 
| 
       4701 
     | 
    
         
            -
              };
         
     | 
| 
       4702 
     | 
    
         
            -
              Repeat.prototype.includes = function includes(searchValue) {
         
     | 
| 
       4703 
     | 
    
         
            -
                return is(this._value, searchValue);
         
     | 
| 
       4704 
     | 
    
         
            -
              };
         
     | 
| 
       4705 
     | 
    
         
            -
              Repeat.prototype.slice = function slice(begin, end) {
         
     | 
| 
       4706 
     | 
    
         
            -
                var size = this.size;
         
     | 
| 
       4707 
     | 
    
         
            -
                return wholeSlice(begin, end, size) ? this : new Repeat(this._value, resolveEnd(end, size) - resolveBegin(begin, size));
         
     | 
| 
       4708 
     | 
    
         
            -
              };
         
     | 
| 
       4709 
     | 
    
         
            -
              Repeat.prototype.reverse = function reverse() {
         
     | 
| 
       4710 
     | 
    
         
            -
                return this;
         
     | 
| 
       4711 
     | 
    
         
            -
              };
         
     | 
| 
       4712 
     | 
    
         
            -
              Repeat.prototype.indexOf = function indexOf(searchValue) {
         
     | 
| 
       4713 
     | 
    
         
            -
                if (is(this._value, searchValue)) {
         
     | 
| 
       4714 
     | 
    
         
            -
                  return 0;
         
     | 
| 
       4715 
     | 
    
         
            -
                }
         
     | 
| 
       4716 
     | 
    
         
            -
                return -1;
         
     | 
| 
       4717 
     | 
    
         
            -
              };
         
     | 
| 
       4718 
     | 
    
         
            -
              Repeat.prototype.lastIndexOf = function lastIndexOf(searchValue) {
         
     | 
| 
       4719 
     | 
    
         
            -
                if (is(this._value, searchValue)) {
         
     | 
| 
       4720 
     | 
    
         
            -
                  return this.size;
         
     | 
| 
       4721 
     | 
    
         
            -
                }
         
     | 
| 
       4722 
     | 
    
         
            -
                return -1;
         
     | 
| 
       4723 
     | 
    
         
            -
              };
         
     | 
| 
       4724 
     | 
    
         
            -
              Repeat.prototype.__iterate = function __iterate(fn, reverse) {
         
     | 
| 
       4725 
     | 
    
         
            -
                var size = this.size;
         
     | 
| 
       4726 
     | 
    
         
            -
                var i = 0;
         
     | 
| 
       4727 
     | 
    
         
            -
                while (i !== size) {
         
     | 
| 
       4728 
     | 
    
         
            -
                  if (fn(this._value, reverse ? size - ++i : i++, this) === false) {
         
     | 
| 
       4729 
     | 
    
         
            -
                    break;
         
     | 
| 
       4730 
     | 
    
         
            -
                  }
         
     | 
| 
       4731 
     | 
    
         
            -
                }
         
     | 
| 
       4732 
     | 
    
         
            -
                return i;
         
     | 
| 
       4733 
     | 
    
         
            -
              };
         
     | 
| 
       4734 
     | 
    
         
            -
              Repeat.prototype.__iterator = function __iterator(type, reverse) {
         
     | 
| 
       4735 
     | 
    
         
            -
                var this$1$1 = this;
         
     | 
| 
       4736 
     | 
    
         
            -
                var size = this.size;
         
     | 
| 
       4737 
     | 
    
         
            -
                var i = 0;
         
     | 
| 
       4738 
     | 
    
         
            -
                return new Iterator(function () {
         
     | 
| 
       4739 
     | 
    
         
            -
                  return i === size ? iteratorDone() : iteratorValue(type, reverse ? size - ++i : i++, this$1$1._value);
         
     | 
| 
       4740 
     | 
    
         
            -
                });
         
     | 
| 
       4741 
     | 
    
         
            -
              };
         
     | 
| 
       4742 
     | 
    
         
            -
              Repeat.prototype.equals = function equals(other) {
         
     | 
| 
       4743 
     | 
    
         
            -
                return other instanceof Repeat ? is(this._value, other._value) : deepEqual(this, other);
         
     | 
| 
       4744 
     | 
    
         
            -
              };
         
     | 
| 
       4745 
     | 
    
         
            -
              return Repeat;
         
     | 
| 
       4746 
     | 
    
         
            -
            }(IndexedSeq);
         
     | 
| 
       4747 
     | 
    
         
            -
            var EMPTY_REPEAT;
         
     | 
| 
       4748 
     | 
    
         
            -
            function fromJS(value, converter) {
         
     | 
| 
       4749 
     | 
    
         
            -
              return fromJSWith([], converter || defaultConverter, value, '', converter && converter.length > 2 ? [] : undefined, {
         
     | 
| 
       4750 
     | 
    
         
            -
                '': value
         
     | 
| 
       4751 
     | 
    
         
            -
              });
         
     | 
| 
       4752 
     | 
    
         
            -
            }
         
     | 
| 
       4753 
     | 
    
         
            -
            function fromJSWith(stack, converter, value, key, keyPath, parentValue) {
         
     | 
| 
       4754 
     | 
    
         
            -
              if (typeof value !== 'string' && !isImmutable(value) && (isArrayLike(value) || hasIterator(value) || isPlainObject(value))) {
         
     | 
| 
       4755 
     | 
    
         
            -
                if (~stack.indexOf(value)) {
         
     | 
| 
       4756 
     | 
    
         
            -
                  throw new TypeError('Cannot convert circular structure to Immutable');
         
     | 
| 
       4757 
     | 
    
         
            -
                }
         
     | 
| 
       4758 
     | 
    
         
            -
                stack.push(value);
         
     | 
| 
       4759 
     | 
    
         
            -
                keyPath && key !== '' && keyPath.push(key);
         
     | 
| 
       4760 
     | 
    
         
            -
                var converted = converter.call(parentValue, key, Seq(value).map(function (v, k) {
         
     | 
| 
       4761 
     | 
    
         
            -
                  return fromJSWith(stack, converter, v, k, keyPath, value);
         
     | 
| 
       4762 
     | 
    
         
            -
                }), keyPath && keyPath.slice());
         
     | 
| 
       4763 
     | 
    
         
            -
                stack.pop();
         
     | 
| 
       4764 
     | 
    
         
            -
                keyPath && keyPath.pop();
         
     | 
| 
       4765 
     | 
    
         
            -
                return converted;
         
     | 
| 
       4766 
     | 
    
         
            -
              }
         
     | 
| 
       4767 
     | 
    
         
            -
              return value;
         
     | 
| 
       4768 
     | 
    
         
            -
            }
         
     | 
| 
       4769 
     | 
    
         
            -
            function defaultConverter(k, v) {
         
     | 
| 
       4770 
     | 
    
         
            -
              // Effectively the opposite of "Collection.toSeq()"
         
     | 
| 
       4771 
     | 
    
         
            -
              return isIndexed(v) ? v.toList() : isKeyed(v) ? v.toMap() : v.toSet();
         
     | 
| 
       4772 
     | 
    
         
            -
            }
         
     | 
| 
       4773 
     | 
    
         
            -
            var version = "4.3.7";
         
     | 
| 
       4774 
     | 
    
         
            -
            var Immutable = {
         
     | 
| 
       4775 
     | 
    
         
            -
              version: version,
         
     | 
| 
       4776 
     | 
    
         
            -
              Collection: Collection,
         
     | 
| 
       4777 
     | 
    
         
            -
              // Note: Iterable is deprecated
         
     | 
| 
       4778 
     | 
    
         
            -
              Iterable: Collection,
         
     | 
| 
       4779 
     | 
    
         
            -
              Seq: Seq,
         
     | 
| 
       4780 
     | 
    
         
            -
              Map: Map,
         
     | 
| 
       4781 
     | 
    
         
            -
              OrderedMap: OrderedMap,
         
     | 
| 
       4782 
     | 
    
         
            -
              List: List,
         
     | 
| 
       4783 
     | 
    
         
            -
              Stack: Stack,
         
     | 
| 
       4784 
     | 
    
         
            -
              Set: Set,
         
     | 
| 
       4785 
     | 
    
         
            -
              OrderedSet: OrderedSet,
         
     | 
| 
       4786 
     | 
    
         
            -
              PairSorting: PairSorting,
         
     | 
| 
       4787 
     | 
    
         
            -
              Record: Record,
         
     | 
| 
       4788 
     | 
    
         
            -
              Range: Range,
         
     | 
| 
       4789 
     | 
    
         
            -
              Repeat: Repeat,
         
     | 
| 
       4790 
     | 
    
         
            -
              is: is,
         
     | 
| 
       4791 
     | 
    
         
            -
              fromJS: fromJS,
         
     | 
| 
       4792 
     | 
    
         
            -
              hash: hash,
         
     | 
| 
       4793 
     | 
    
         
            -
              isImmutable: isImmutable,
         
     | 
| 
       4794 
     | 
    
         
            -
              isCollection: isCollection,
         
     | 
| 
       4795 
     | 
    
         
            -
              isKeyed: isKeyed,
         
     | 
| 
       4796 
     | 
    
         
            -
              isIndexed: isIndexed,
         
     | 
| 
       4797 
     | 
    
         
            -
              isAssociative: isAssociative,
         
     | 
| 
       4798 
     | 
    
         
            -
              isOrdered: isOrdered,
         
     | 
| 
       4799 
     | 
    
         
            -
              isValueObject: isValueObject,
         
     | 
| 
       4800 
     | 
    
         
            -
              isPlainObject: isPlainObject,
         
     | 
| 
       4801 
     | 
    
         
            -
              isSeq: isSeq,
         
     | 
| 
       4802 
     | 
    
         
            -
              isList: isList,
         
     | 
| 
       4803 
     | 
    
         
            -
              isMap: isMap,
         
     | 
| 
       4804 
     | 
    
         
            -
              isOrderedMap: isOrderedMap,
         
     | 
| 
       4805 
     | 
    
         
            -
              isStack: isStack,
         
     | 
| 
       4806 
     | 
    
         
            -
              isSet: isSet,
         
     | 
| 
       4807 
     | 
    
         
            -
              isOrderedSet: isOrderedSet,
         
     | 
| 
       4808 
     | 
    
         
            -
              isRecord: isRecord,
         
     | 
| 
       4809 
     | 
    
         
            -
              get: get,
         
     | 
| 
       4810 
     | 
    
         
            -
              getIn: getIn$1,
         
     | 
| 
       4811 
     | 
    
         
            -
              has: has,
         
     | 
| 
       4812 
     | 
    
         
            -
              hasIn: hasIn$1,
         
     | 
| 
       4813 
     | 
    
         
            -
              merge: merge,
         
     | 
| 
       4814 
     | 
    
         
            -
              mergeDeep: mergeDeep$1,
         
     | 
| 
       4815 
     | 
    
         
            -
              mergeWith: mergeWith,
         
     | 
| 
       4816 
     | 
    
         
            -
              mergeDeepWith: mergeDeepWith$1,
         
     | 
| 
       4817 
     | 
    
         
            -
              remove: remove,
         
     | 
| 
       4818 
     | 
    
         
            -
              removeIn: removeIn,
         
     | 
| 
       4819 
     | 
    
         
            -
              set: set,
         
     | 
| 
       4820 
     | 
    
         
            -
              setIn: setIn$1,
         
     | 
| 
       4821 
     | 
    
         
            -
              update: update$1,
         
     | 
| 
       4822 
     | 
    
         
            -
              updateIn: updateIn$1
         
     | 
| 
       4823 
     | 
    
         
            -
            };
         
     | 
| 
       4824 
     | 
    
         
            -
             
     | 
| 
       4825 
     | 
    
         
            -
            // Note: Iterable is deprecated
         
     | 
| 
       4826 
     | 
    
         
            -
            var Iterable = Collection;
         
     | 
| 
       4827 
     | 
    
         
            -
             
     | 
| 
       4828 
     | 
    
         
            -
            export { Collection, Iterable, List, Map, OrderedMap, OrderedSet, PairSorting, Range, Record, Repeat, Seq, Set, Stack, Immutable as default, fromJS, get, getIn$1 as getIn, has, hasIn$1 as hasIn, hash, is, isAssociative, isCollection, isImmutable, isIndexed, isKeyed, isList, isMap, isOrdered, isOrderedMap, isOrderedSet, isPlainObject, isRecord, isSeq, isSet, isStack, isValueObject, merge, mergeDeep$1 as mergeDeep, mergeDeepWith$1 as mergeDeepWith, mergeWith, remove, removeIn, set, setIn$1 as setIn, update$1 as update, updateIn$1 as updateIn, version };
         
     | 
| 
       4829 
     | 
    
         
            -
            //# sourceMappingURL=immutable.es.js.map
         
     |