@tuprolog/2p-full 0.32.4 → 1.0.0

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.
@@ -43,12 +43,6 @@ if (typeof Math.clz32 === 'undefined') {
43
43
  };
44
44
  }(Math.log, Math.LN2);
45
45
  }
46
- if (typeof String.prototype.startsWith === 'undefined') {
47
- Object.defineProperty(String.prototype, 'startsWith', {value: function (searchString, position) {
48
- position = position || 0;
49
- return this.lastIndexOf(searchString, position) === position;
50
- }});
51
- }
52
46
  if (typeof String.prototype.endsWith === 'undefined') {
53
47
  Object.defineProperty(String.prototype, 'endsWith', {value: function (searchString, position) {
54
48
  var subjectString = this.toString();
@@ -60,6 +54,12 @@ if (typeof String.prototype.endsWith === 'undefined') {
60
54
  return lastIndex !== -1 && lastIndex === position;
61
55
  }});
62
56
  }
57
+ if (typeof String.prototype.startsWith === 'undefined') {
58
+ Object.defineProperty(String.prototype, 'startsWith', {value: function (searchString, position) {
59
+ position = position || 0;
60
+ return this.lastIndexOf(searchString, position) === position;
61
+ }});
62
+ }
63
63
  if (typeof Math.imul === 'undefined') {
64
64
  Math.imul = function imul(a, b) {
65
65
  return (a & 4.29490176E9) * (b & 65535) + (a & 65535) * (b | 0) | 0;
@@ -97,26 +97,26 @@ if (typeof Math.imul === 'undefined') {
97
97
  setMetadataFor(IteratorImpl, 'IteratorImpl', classMeta);
98
98
  setMetadataFor(ListIteratorImpl, 'ListIteratorImpl', classMeta, IteratorImpl);
99
99
  setMetadataFor(List, 'List', interfaceMeta, VOID, [Collection]);
100
- setMetadataFor(AbstractMutableList, 'AbstractMutableList', classMeta, AbstractMutableCollection, [AbstractMutableCollection, List, MutableIterable, Collection]);
100
+ setMetadataFor(AbstractMutableList, 'AbstractMutableList', classMeta, AbstractMutableCollection, [AbstractMutableCollection, Collection, MutableIterable, List]);
101
101
  setMetadataFor(RandomAccess, 'RandomAccess', interfaceMeta);
102
102
  setMetadataFor(SubList, 'SubList', classMeta, AbstractMutableList, [AbstractMutableList, RandomAccess]);
103
103
  setMetadataFor(Map_0, 'Map', interfaceMeta);
104
104
  setMetadataFor(AbstractMap, 'AbstractMap', classMeta, VOID, [Map_0]);
105
105
  setMetadataFor(AbstractMutableMap, 'AbstractMutableMap', classMeta, AbstractMap, [AbstractMap, Map_0]);
106
106
  setMetadataFor(Set, 'Set', interfaceMeta, VOID, [Collection]);
107
- setMetadataFor(AbstractMutableSet, 'AbstractMutableSet', classMeta, AbstractMutableCollection, [AbstractMutableCollection, MutableIterable, Collection, Set]);
107
+ setMetadataFor(AbstractMutableSet, 'AbstractMutableSet', classMeta, AbstractMutableCollection, [AbstractMutableCollection, Collection, MutableIterable, Set]);
108
108
  setMetadataFor(Companion, 'Companion', objectMeta);
109
- setMetadataFor(ArrayList, 'ArrayList', classMeta, AbstractMutableList, [AbstractMutableList, List, MutableIterable, Collection, RandomAccess], ArrayList_init_$Create$);
109
+ setMetadataFor(ArrayList, 'ArrayList', classMeta, AbstractMutableList, [AbstractMutableList, Collection, MutableIterable, List, RandomAccess], ArrayList_init_$Create$);
110
110
  setMetadataFor(HashMap, 'HashMap', classMeta, AbstractMutableMap, [AbstractMutableMap, Map_0], HashMap_init_$Create$);
111
- setMetadataFor(HashMapKeys, 'HashMapKeys', classMeta, AbstractMutableSet, [MutableIterable, Collection, Set, AbstractMutableSet]);
111
+ setMetadataFor(HashMapKeys, 'HashMapKeys', classMeta, AbstractMutableSet, [Collection, MutableIterable, Set, AbstractMutableSet]);
112
112
  setMetadataFor(HashMapValues, 'HashMapValues', classMeta, AbstractMutableCollection, [Collection, MutableIterable, AbstractMutableCollection]);
113
- setMetadataFor(HashMapEntrySetBase, 'HashMapEntrySetBase', classMeta, AbstractMutableSet, [MutableIterable, Collection, Set, AbstractMutableSet]);
113
+ setMetadataFor(HashMapEntrySetBase, 'HashMapEntrySetBase', classMeta, AbstractMutableSet, [Collection, MutableIterable, Set, AbstractMutableSet]);
114
114
  setMetadataFor(HashMapEntrySet, 'HashMapEntrySet', classMeta, HashMapEntrySetBase);
115
115
  setMetadataFor(HashMapKeysDefault$iterator$1, VOID, classMeta);
116
116
  setMetadataFor(HashMapKeysDefault, 'HashMapKeysDefault', classMeta, AbstractMutableSet);
117
117
  setMetadataFor(HashMapValuesDefault$iterator$1, VOID, classMeta);
118
118
  setMetadataFor(HashMapValuesDefault, 'HashMapValuesDefault', classMeta, AbstractMutableCollection);
119
- setMetadataFor(HashSet, 'HashSet', classMeta, AbstractMutableSet, [AbstractMutableSet, MutableIterable, Collection, Set], HashSet_init_$Create$);
119
+ setMetadataFor(HashSet, 'HashSet', classMeta, AbstractMutableSet, [AbstractMutableSet, Collection, MutableIterable, Set], HashSet_init_$Create$);
120
120
  setMetadataFor(Companion_0, 'Companion', objectMeta);
121
121
  setMetadataFor(Itr, 'Itr', classMeta);
122
122
  setMetadataFor(KeysItr, 'KeysItr', classMeta, Itr);
@@ -163,7 +163,7 @@ if (typeof Math.imul === 'undefined') {
163
163
  setMetadataFor(InternalMap, 'InternalMap', interfaceMeta);
164
164
  setMetadataFor(InternalHashMap, 'InternalHashMap', classMeta, VOID, [InternalMap], InternalHashMap_init_$Create$);
165
165
  setMetadataFor(LinkedHashMap, 'LinkedHashMap', classMeta, HashMap, [HashMap, Map_0], LinkedHashMap_init_$Create$);
166
- setMetadataFor(LinkedHashSet, 'LinkedHashSet', classMeta, HashSet, [HashSet, MutableIterable, Collection, Set], LinkedHashSet_init_$Create$);
166
+ setMetadataFor(LinkedHashSet, 'LinkedHashSet', classMeta, HashSet, [HashSet, Collection, MutableIterable, Set], LinkedHashSet_init_$Create$);
167
167
  setMetadataFor(BaseOutput, 'BaseOutput', classMeta);
168
168
  setMetadataFor(NodeJsOutput, 'NodeJsOutput', classMeta, BaseOutput);
169
169
  setMetadataFor(BufferedOutput, 'BufferedOutput', classMeta, BaseOutput, VOID, BufferedOutput);
@@ -7973,6 +7973,9 @@ if (typeof Math.imul === 'undefined') {
7973
7973
  function getValue(_this__u8e3s4, key) {
7974
7974
  return getOrImplicitDefault(_this__u8e3s4, key);
7975
7975
  }
7976
+ function mapOf_0(pairs) {
7977
+ return pairs.length > 0 ? toMap_2(pairs, LinkedHashMap_init_$Create$_0(mapCapacity(pairs.length))) : emptyMap();
7978
+ }
7976
7979
  function hashMapOf(pairs) {
7977
7980
  // Inline function 'kotlin.apply' call
7978
7981
  var this_0 = HashMap_init_$Create$_0(mapCapacity(pairs.length));
@@ -8064,6 +8067,13 @@ if (typeof Math.imul === 'undefined') {
8064
8067
  putAll_0(destination, _this__u8e3s4);
8065
8068
  return destination;
8066
8069
  }
8070
+ function toMap_2(_this__u8e3s4, destination) {
8071
+ // Inline function 'kotlin.apply' call
8072
+ // Inline function 'kotlin.contracts.contract' call
8073
+ // Inline function 'kotlin.collections.toMap.<anonymous>' call
8074
+ putAll(destination, _this__u8e3s4);
8075
+ return destination;
8076
+ }
8067
8077
  function putAll(_this__u8e3s4, pairs) {
8068
8078
  var inductionVariable = 0;
8069
8079
  var last = pairs.length;
@@ -8093,10 +8103,7 @@ if (typeof Math.imul === 'undefined') {
8093
8103
  this_0.o2(key);
8094
8104
  return optimizeReadOnlyMap(this_0);
8095
8105
  }
8096
- function mapOf_0(pairs) {
8097
- return pairs.length > 0 ? toMap_4(pairs, LinkedHashMap_init_$Create$_0(mapCapacity(pairs.length))) : emptyMap();
8098
- }
8099
- function toMap_2(_this__u8e3s4) {
8106
+ function toMap_3(_this__u8e3s4) {
8100
8107
  if (isInterface(_this__u8e3s4, Collection)) {
8101
8108
  var tmp;
8102
8109
  switch (_this__u8e3s4.l()) {
@@ -8121,14 +8128,14 @@ if (typeof Math.imul === 'undefined') {
8121
8128
  }
8122
8129
  return optimizeReadOnlyMap(toMap_5(_this__u8e3s4, LinkedHashMap_init_$Create$()));
8123
8130
  }
8124
- function toMap_3(_this__u8e3s4) {
8131
+ function toMap_4(_this__u8e3s4) {
8125
8132
  switch (_this__u8e3s4.length) {
8126
8133
  case 0:
8127
8134
  return emptyMap();
8128
8135
  case 1:
8129
8136
  return mapOf(_this__u8e3s4[0]);
8130
8137
  default:
8131
- return toMap_4(_this__u8e3s4, LinkedHashMap_init_$Create$_0(mapCapacity(_this__u8e3s4.length)));
8138
+ return toMap_2(_this__u8e3s4, LinkedHashMap_init_$Create$_0(mapCapacity(_this__u8e3s4.length)));
8132
8139
  }
8133
8140
  }
8134
8141
  function plus_8(_this__u8e3s4, pair) {
@@ -8154,13 +8161,6 @@ if (typeof Math.imul === 'undefined') {
8154
8161
  removeAll_2(this_0.l2(), keys);
8155
8162
  return optimizeReadOnlyMap(this_0);
8156
8163
  }
8157
- function toMap_4(_this__u8e3s4, destination) {
8158
- // Inline function 'kotlin.apply' call
8159
- // Inline function 'kotlin.contracts.contract' call
8160
- // Inline function 'kotlin.collections.toMap.<anonymous>' call
8161
- putAll(destination, _this__u8e3s4);
8162
- return destination;
8163
- }
8164
8164
  function toMap_5(_this__u8e3s4, destination) {
8165
8165
  // Inline function 'kotlin.apply' call
8166
8166
  // Inline function 'kotlin.contracts.contract' call
@@ -8972,12 +8972,12 @@ if (typeof Math.imul === 'undefined') {
8972
8972
  function setOf_0(elements) {
8973
8973
  return elements.length > 0 ? toSet(elements) : emptySet();
8974
8974
  }
8975
- function emptySet() {
8976
- return EmptySet_getInstance();
8977
- }
8978
8975
  function mutableSetOf(elements) {
8979
8976
  return toCollection(elements, LinkedHashSet_init_$Create$_1(mapCapacity(elements.length)));
8980
8977
  }
8978
+ function emptySet() {
8979
+ return EmptySet_getInstance();
8980
+ }
8981
8981
  function EmptySet() {
8982
8982
  EmptySet_instance = this;
8983
8983
  this.bi_1 = new Long(1993859828, 793161749);
@@ -10782,9 +10782,9 @@ if (typeof Math.imul === 'undefined') {
10782
10782
  _.$_$.w4 = toList_0;
10783
10783
  _.$_$.x4 = toList;
10784
10784
  _.$_$.y4 = toMap;
10785
- _.$_$.z4 = toMap_3;
10785
+ _.$_$.z4 = toMap_4;
10786
10786
  _.$_$.a5 = toMap_0;
10787
- _.$_$.b5 = toMap_2;
10787
+ _.$_$.b5 = toMap_3;
10788
10788
  _.$_$.c5 = toMutableList_0;
10789
10789
  _.$_$.d5 = toMutableList_1;
10790
10790
  _.$_$.e5 = toMutableMap;