jscrewit 2.35.1 → 2.36.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.
@@ -96,27 +96,27 @@ export interface FeatureAll
96
96
  /**
97
97
  * Features available in the current stable versions of Chrome, Edge and Opera.
98
98
  *
99
- * An alias for `CHROME_92`.
99
+ * An alias for `CHROME_122`.
100
100
  */
101
101
  CHROME: PredefinedFeature;
102
102
 
103
103
  /**
104
- * Features available in Chrome 92, Edge 92 and Opera 78 or later.
104
+ * Features available in Chrome 122, Edge 122 and Opera 108 or later.
105
105
  *
106
106
  * @remarks
107
107
  *
108
- * This feature may be replaced or removed in the near future when current browser versions become obsolete. Use `CHROME` or `CHROME_PREV` instead of `CHROME_92` for long term support.
108
+ * This feature may be replaced or removed in the near future when current browser versions become obsolete. Use `CHROME` or `CHROME_PREV` instead of `CHROME_122` for long term support.
109
109
  *
110
110
  * @see
111
111
  *
112
112
  * [Engine Support Policy](https://github.com/fasttime/JScrewIt#engine-support-policy)
113
113
  */
114
- CHROME_92: PredefinedFeature;
114
+ CHROME_122: PredefinedFeature;
115
115
 
116
116
  /**
117
117
  * Features available in the previous to current versions of Chrome and Edge.
118
118
  *
119
- * An alias for `CHROME_92`.
119
+ * An alias for `CHROME_122`.
120
120
  */
121
121
  CHROME_PREV: PredefinedFeature;
122
122
 
@@ -281,7 +281,7 @@ export interface FeatureAll
281
281
  *
282
282
  * @remarks
283
283
  *
284
- * Available in Chrome, Edge, Firefox, Opera, and Node.js 10+.
284
+ * Available in Chrome, Edge, Firefox, Safari 17.4+, Opera, and Node.js 10+.
285
285
  */
286
286
  FUNCTION_19_LF: ElementaryFeature;
287
287
 
@@ -290,7 +290,7 @@ export interface FeatureAll
290
290
  *
291
291
  * @remarks
292
292
  *
293
- * Available in Internet Explorer, Safari 9+, Android Browser, and Node.js before 10.
293
+ * Available in Internet Explorer, Safari 9+ before 17.4, Android Browser, and Node.js before 10.
294
294
  */
295
295
  FUNCTION_22_LF: ElementaryFeature;
296
296
 
@@ -501,7 +501,7 @@ export interface FeatureAll
501
501
  NO_IE_SRC: ElementaryFeature;
502
502
 
503
503
  /**
504
- * The property that the string representation of Array.prototype.entries\(\) evaluates to "\[object Array Iterator\]" and that Array.prototype.entries\(\).constructor is the global function Object.
504
+ * The property that the string representation of Array.prototype.entries\(\) evaluates to "\[object Array Iterator\]".
505
505
  *
506
506
  * @remarks
507
507
  *
@@ -521,7 +521,16 @@ export interface FeatureAll
521
521
  NO_V8_SRC: ElementaryFeature;
522
522
 
523
523
  /**
524
- * Existence of the global function location.constructor whose string representation starts with "\[object L"
524
+ * The property that the Array.prototype.entries\(\).constructor is the Object constructor.
525
+ *
526
+ * @remarks
527
+ *
528
+ * Available in Firefox, Safari 9+, and Node.js 0.12+.
529
+ */
530
+ OBJECT_ARRAY_ENTRIES_CTOR: ElementaryFeature;
531
+
532
+ /**
533
+ * Existence of the global function location.constructor whose string representation starts with "\[object L".
525
534
  *
526
535
  * @remarks
527
536
  *
@@ -539,7 +548,7 @@ export interface FeatureAll
539
548
  OBJECT_UNDEFINED: ElementaryFeature;
540
549
 
541
550
  /**
542
- * The property that the string representation of the global object constructor starts with "\[object W"
551
+ * The property that the string representation of the global object constructor starts with "\[object W".
543
552
  *
544
553
  * @remarks
545
554
  *
@@ -548,7 +557,7 @@ export interface FeatureAll
548
557
  OBJECT_W_CTOR: ElementaryFeature;
549
558
 
550
559
  /**
551
- * Existence of the global object location.constructor whose string representation starts with "\[object " and ends with "LocationConstructor\]"
560
+ * Existence of the global object location.constructor whose string representation starts with "\[object " and ends with "LocationConstructor\]".
552
561
  *
553
562
  * @remarks
554
563
  *
@@ -557,7 +566,7 @@ export interface FeatureAll
557
566
  OLD_SAFARI_LOCATION_CTOR: ElementaryFeature;
558
567
 
559
568
  /**
560
- * Existence of the global object Intl having the string representation "\[object Object\]"
569
+ * Existence of the global object Intl having the string representation "\[object Object\]".
561
570
  *
562
571
  * @remarks
563
572
  *
@@ -577,7 +586,7 @@ export interface FeatureAll
577
586
  /**
578
587
  * Features available in the current stable version of Safari.
579
588
  *
580
- * An alias for `SAFARI_15_4`.
589
+ * An alias for `SAFARI_17_4`.
581
590
  */
582
591
  SAFARI: PredefinedFeature;
583
592
 
@@ -596,9 +605,12 @@ export interface FeatureAll
596
605
  /** Features available in Safari 14.1 to 15.3. */
597
606
  SAFARI_14_1: PredefinedFeature;
598
607
 
599
- /** Features available in Safari 15.4 or later. */
608
+ /** Features available in Safari 15.4 to 17.3. */
600
609
  SAFARI_15_4: PredefinedFeature;
601
610
 
611
+ /** Features available in Safari 17.4 or later. */
612
+ SAFARI_17_4: PredefinedFeature;
613
+
602
614
  /** Features available in Safari 7.0. */
603
615
  SAFARI_7_0: PredefinedFeature;
604
616
 
@@ -713,6 +725,7 @@ type ElementaryFeatureName =
713
725
  | 'NO_IE_SRC'
714
726
  | 'NO_OLD_SAFARI_ARRAY_ITERATOR'
715
727
  | 'NO_V8_SRC'
728
+ | 'OBJECT_ARRAY_ENTRIES_CTOR'
716
729
  | 'OBJECT_L_LOCATION_CTOR'
717
730
  | 'OBJECT_UNDEFINED'
718
731
  | 'OBJECT_W_CTOR'
@@ -735,7 +748,7 @@ ElementaryFeatureName
735
748
  | 'ANDRO_4_4'
736
749
  | 'AUTO'
737
750
  | 'BROWSER'
738
- | 'CHROME_92'
751
+ | 'CHROME_122'
739
752
  | 'COMPACT'
740
753
  | 'DEFAULT'
741
754
  | 'FF_90'
@@ -760,6 +773,7 @@ ElementaryFeatureName
760
773
  | 'SAFARI_14_0_1'
761
774
  | 'SAFARI_14_1'
762
775
  | 'SAFARI_15_4'
776
+ | 'SAFARI_17_4'
763
777
  | 'SAFARI_7_0'
764
778
  | 'SAFARI_7_1'
765
779
  | 'SAFARI_9'
package/lib/jscrewit.js CHANGED
@@ -1,4 +1,4 @@
1
- // JScrewIt 2.35.1 – https://jscrew.it
1
+ // JScrewIt 2.36.0 – https://jscrew.it
2
2
 
3
3
  (function () {
4
4
  'use strict';
@@ -248,33 +248,39 @@
248
248
 
249
249
 
250
250
  var extendStatics = function(d, b) {
251
- extendStatics = Object.setPrototypeOf ||
252
- ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
253
- function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
254
- return extendStatics(d, b);
251
+ extendStatics = Object.setPrototypeOf ||
252
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
253
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
254
+ return extendStatics(d, b);
255
255
  };
256
256
 
257
257
  function __extends(d, b) {
258
- if (typeof b !== "function" && b !== null)
259
- throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
260
- extendStatics(d, b);
261
- function __() { this.constructor = d; }
262
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
258
+ if (typeof b !== "function" && b !== null)
259
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
260
+ extendStatics(d, b);
261
+ function __() { this.constructor = d; }
262
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
263
263
  }
264
264
 
265
265
  var __assign = function() {
266
- __assign = Object.assign || function __assign(t) {
267
- for (var s, i = 1, n = arguments.length; i < n; i++) {
268
- s = arguments[i];
269
- for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];
270
- }
271
- return t;
272
- };
273
- return __assign.apply(this, arguments);
266
+ __assign = Object.assign || function __assign(t) {
267
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
268
+ s = arguments[i];
269
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];
270
+ }
271
+ return t;
272
+ };
273
+ return __assign.apply(this, arguments);
274
+ };
275
+
276
+ typeof SuppressedError === "function" ? SuppressedError : function (error, suppressed, message) {
277
+ var e = new Error(message);
278
+ return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
274
279
  };
275
280
 
276
281
  // ~feature-hub – https://github.com/fasttime/JScrewIt/tree/master/packages/~feature-hub
277
282
 
283
+
278
284
  var BIN_POW_31 = 2147483648;
279
285
  var BIN_POW_32 = 4294967296;
280
286
  var BIN_POW_51 = 2251799813685248;
@@ -1513,17 +1519,13 @@
1513
1519
  {
1514
1520
  description:
1515
1521
  'The property that the string representation of Array.prototype.entries() evaluates to ' +
1516
- '"[object Array Iterator]" and that Array.prototype.entries().constructor is the global ' +
1517
- 'function Object.',
1522
+ '"[object Array Iterator]".',
1518
1523
  check:
1519
1524
  function ()
1520
1525
  {
1521
1526
  if (Array.prototype.entries)
1522
1527
  {
1523
- var arrayIterator = [].entries();
1524
- var available =
1525
- arrayIterator + '' === '[object Array Iterator]' &&
1526
- arrayIterator.constructor === Object;
1528
+ var available = [].entries() + '' === '[object Array Iterator]';
1527
1529
  return available;
1528
1530
  }
1529
1531
  },
@@ -1544,11 +1546,22 @@
1544
1546
  },
1545
1547
  excludes: ['V8_SRC'],
1546
1548
  },
1549
+ OBJECT_ARRAY_ENTRIES_CTOR:
1550
+ {
1551
+ description:
1552
+ 'The property that the Array.prototype.entries().constructor is the Object constructor.',
1553
+ check:
1554
+ function ()
1555
+ {
1556
+ var available = Array.prototype.entries && [].entries().constructor === Object;
1557
+ return available;
1558
+ },
1559
+ },
1547
1560
  OBJECT_L_LOCATION_CTOR:
1548
1561
  {
1549
1562
  description:
1550
1563
  'Existence of the global function location.constructor whose string representation ' +
1551
- 'starts with "[object L"',
1564
+ 'starts with "[object L".',
1552
1565
  check:
1553
1566
  function ()
1554
1567
  {
@@ -1576,7 +1589,7 @@
1576
1589
  {
1577
1590
  description:
1578
1591
  'The property that the string representation of the global object constructor starts ' +
1579
- 'with "[object W"',
1592
+ 'with "[object W".',
1580
1593
  check:
1581
1594
  function ()
1582
1595
  {
@@ -1589,7 +1602,7 @@
1589
1602
  {
1590
1603
  description:
1591
1604
  'Existence of the global object location.constructor whose string representation starts ' +
1592
- 'with "[object " and ends with "LocationConstructor]"',
1605
+ 'with "[object " and ends with "LocationConstructor]".',
1593
1606
  check:
1594
1607
  function ()
1595
1608
  {
@@ -1602,7 +1615,7 @@
1602
1615
  PLAIN_INTL:
1603
1616
  {
1604
1617
  description:
1605
- 'Existence of the global object Intl having the string representation "[object Object]"',
1618
+ 'Existence of the global object Intl having the string representation "[object Object]".',
1606
1619
  check:
1607
1620
  function ()
1608
1621
  {
@@ -1746,6 +1759,7 @@
1746
1759
  'FILL',
1747
1760
  'FLAT',
1748
1761
  'FROM_CODE_POINT',
1762
+ 'FUNCTION_19_LF',
1749
1763
  'GENERIC_ARRAY_TO_STRING',
1750
1764
  'GLOBAL_UNDEFINED',
1751
1765
  'GMT',
@@ -1812,17 +1826,17 @@
1812
1826
  CHROME_PREV:
1813
1827
  {
1814
1828
  description: describeEngine('the previous to current versions of Chrome and Edge'),
1815
- aliasFor: 'CHROME_92',
1829
+ aliasFor: 'CHROME_122',
1816
1830
  },
1817
1831
  CHROME:
1818
1832
  {
1819
1833
  description: describeEngine('the current stable versions of Chrome, Edge and Opera'),
1820
- aliasFor: 'CHROME_92',
1834
+ aliasFor: 'CHROME_122',
1821
1835
  },
1822
- CHROME_92:
1836
+ CHROME_122:
1823
1837
  {
1824
1838
  families: ['Chrome', 'Edge', 'Opera'],
1825
- versions: [['92'], ['92'], ['78']],
1839
+ versions: [['122'], ['122'], ['108']],
1826
1840
  includes:
1827
1841
  [
1828
1842
  'ARROW',
@@ -1901,6 +1915,7 @@
1901
1915
  'LOCATION',
1902
1916
  'NAME',
1903
1917
  'NO_OLD_SAFARI_ARRAY_ITERATOR',
1918
+ 'OBJECT_ARRAY_ENTRIES_CTOR',
1904
1919
  'REGEXP_STRING_ITERATOR',
1905
1920
  'SHORT_LOCALES',
1906
1921
  'STATUS',
@@ -1987,6 +2002,7 @@
1987
2002
  ESC_HTML_QUOT_ONLY: true,
1988
2003
  LOCALE_INFINITY: true,
1989
2004
  NO_OLD_SAFARI_ARRAY_ITERATOR: true,
2005
+ OBJECT_ARRAY_ENTRIES_CTOR: true,
1990
2006
  PLAIN_INTL: true,
1991
2007
  },
1992
2008
  },
@@ -2097,6 +2113,7 @@
2097
2113
  FROM_CODE_POINT: true,
2098
2114
  FUNCTION_22_LF: true,
2099
2115
  NO_OLD_SAFARI_ARRAY_ITERATOR: true,
2116
+ OBJECT_ARRAY_ENTRIES_CTOR: true,
2100
2117
  },
2101
2118
  },
2102
2119
  SAFARI_10:
@@ -2141,16 +2158,22 @@
2141
2158
  versions: [['14.1',, '15.3']],
2142
2159
  includes: { CONSOLE: false },
2143
2160
  },
2161
+ SAFARI_15_4:
2162
+ {
2163
+ inherits: 'SAFARI_14_1',
2164
+ versions: [['15.4',, '17.3']],
2165
+ includes: { AT: true },
2166
+ },
2144
2167
  SAFARI:
2145
2168
  {
2146
2169
  description: describeEngine('the current stable version of Safari'),
2147
- aliasFor: 'SAFARI_15_4',
2170
+ aliasFor: 'SAFARI_17_4',
2148
2171
  },
2149
- SAFARI_15_4:
2172
+ SAFARI_17_4:
2150
2173
  {
2151
- inherits: 'SAFARI_14_1',
2152
- versions: [['15.4']],
2153
- includes: { AT: true },
2174
+ inherits: 'SAFARI_15_4',
2175
+ versions: [['17.4']],
2176
+ includes: { FUNCTION_19_LF: true, FUNCTION_22_LF: false },
2154
2177
  },
2155
2178
  };
2156
2179
  (function ()
@@ -2332,6 +2355,7 @@
2332
2355
 
2333
2356
  // ~solution – https://github.com/fasttime/JScrewIt/tree/master/packages/~solution
2334
2357
 
2358
+
2335
2359
  var INVALID_EXPR = {};
2336
2360
  function evalExpr$1(expr) {
2337
2361
  var value = tryEvalExpr(expr);
@@ -2726,6 +2750,7 @@
2726
2750
  // Compared to generic purpose encoding, definition encoding differs mainly in that every identifier
2727
2751
  // used must be defined itself, too, in a constant definition.
2728
2752
 
2753
+
2729
2754
  var AMENDINGS = ['true', 'undefined', 'NaN'];
2730
2755
 
2731
2756
  var JSFUCK_INFINITY = '1e1000';
@@ -3103,6 +3128,7 @@
3103
3128
  var NO_IE_SRC = Feature.NO_IE_SRC;
3104
3129
  var NO_OLD_SAFARI_ARRAY_ITERATOR = Feature.NO_OLD_SAFARI_ARRAY_ITERATOR;
3105
3130
  var NO_V8_SRC = Feature.NO_V8_SRC;
3131
+ var OBJECT_ARRAY_ENTRIES_CTOR = Feature.OBJECT_ARRAY_ENTRIES_CTOR;
3106
3132
  var OBJECT_L_LOCATION_CTOR = Feature.OBJECT_L_LOCATION_CTOR;
3107
3133
  var OBJECT_UNDEFINED = Feature.OBJECT_UNDEFINED;
3108
3134
  var OBJECT_W_CTOR = Feature.OBJECT_W_CTOR;
@@ -4064,7 +4090,7 @@
4064
4090
  [
4065
4091
  define('PLAIN_OBJECT.constructor'),
4066
4092
  define('Intl.constructor', INTL),
4067
- define('[].entries().constructor', NO_OLD_SAFARI_ARRAY_ITERATOR),
4093
+ define('[].entries().constructor', OBJECT_ARRAY_ENTRIES_CTOR),
4068
4094
  ],
4069
4095
  RegExp:
4070
4096
  [
@@ -5242,7 +5268,7 @@
5242
5268
  ConstIdentifier: 'Infinity|NaN|false|true|undefined',
5243
5269
  DecimalLiteral: '(?:(?:0|[1-9]\\d*)(?:\\.\\d*)?|\\.\\d+)(?:[Ee][+-]?\\d+)?',
5244
5270
  DoubleQuotedString: '"(?:#EscapeSequence|(?!["\\\\]).)*"',
5245
- EscapeSequence: '\\\\(?:u#HexDigit{4}|x#HexDigit{2}|0(?![0-7])|\r\n|[^0-7ux])',
5271
+ EscapeSequence: '\\\\(?:u#HexDigit{4}|x#HexDigit{2}|0(?!\\d)|\r\n|[^\\dux])',
5246
5272
  HexDigit: '[0-9A-Fa-f]',
5247
5273
  HexIntegerLiteral: '0[Xx]#HexDigit+',
5248
5274
  NumericLiteral: '#HexIntegerLiteral|#DecimalLiteral',
@@ -5266,6 +5292,7 @@
5266
5292
  var UNRETURNABLE_WORDS =
5267
5293
  [
5268
5294
  'arguments', // shadowed in function body
5295
+ 'await', // may be an identifier in non-strict mode
5269
5296
  'debugger', // : debugger;
5270
5297
  'delete', // : delete(x);
5271
5298
  'if', // : if(x);
@@ -8298,6 +8325,7 @@
8298
8325
  //
8299
8326
  // The leading append plus is omitted when the optimized cluster is the first element of a group.
8300
8327
 
8328
+
8301
8329
  var BOND_EXTRA_LENGTH = 2; // Extra length of bonding parentheses "(" and ")".
8302
8330
  var CLUSTER_EXTRA_LENGTHS = [];
8303
8331
  var DECIMAL_DIGIT_MAX_COUNTS = [];