re2js 2.2.1 → 2.2.2

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/LICENSE CHANGED
@@ -1,6 +1,6 @@
1
1
  MIT License
2
2
 
3
- Copyright (c) 2023 Alexey Vasiliev
3
+ Copyright (c) 2023 Oleksii Vasyliev
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  of this software and associated documentation files (the "Software"), to deal
@@ -2,8 +2,8 @@
2
2
  * re2js
3
3
  * RE2JS is the JavaScript port of RE2, a regular expression engine that provides linear time matching
4
4
  *
5
- * @version v2.2.1
6
- * @author Alexey Vasiliev
5
+ * @version v2.2.2
6
+ * @author Oleksii Vasyliev
7
7
  * @homepage https://github.com/le0pard/re2js#readme
8
8
  * @repository github:le0pard/re2js
9
9
  * @license MIT
@@ -3343,7 +3343,9 @@ const makeOnePass = p => {
3343
3343
  }
3344
3344
  runes.sort((a, b) => a - b);
3345
3345
  } else {
3346
- runes.push(...inst.runes);
3346
+ for (let j = 0; j < inst.runes.length; j++) {
3347
+ runes.push(inst.runes[j]);
3348
+ }
3347
3349
  }
3348
3350
  onePassRunes[pc] = runes;
3349
3351
  inst.next = new Uint32Array(Math.floor(runes.length / 2) + 1).fill(inst.out);
@@ -4170,7 +4172,9 @@ class PrefilterTree {
4170
4172
  return new Prefilter(Prefilter.Type.NONE);
4171
4173
  }
4172
4174
  if (s.type === Prefilter.Type.OR) {
4173
- newSubs.push(...s.subs);
4175
+ for (let j = 0; j < s.subs.length; j++) {
4176
+ newSubs.push(s.subs[j]);
4177
+ }
4174
4178
  } else {
4175
4179
  newSubs.push(s);
4176
4180
  }