msgpackr 1.11.3 → 1.11.5

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/dist/index.js CHANGED
@@ -1698,10 +1698,11 @@
1698
1698
  if (value >> BigInt(0x10000) === empty) {
1699
1699
  let mask = BigInt(0x10000000000000000) - BigInt(1); // literal would overflow
1700
1700
  let chunks = [];
1701
- do {
1701
+ while (true) {
1702
1702
  chunks.push(value & mask);
1703
+ if ((value >> BigInt(63)) === empty) break
1703
1704
  value >>= BigInt(64);
1704
- } while (value !== empty)
1705
+ }
1705
1706
 
1706
1707
  array = new Uint8Array(new BigUint64Array(chunks).buffer);
1707
1708
  array.reverse();
@@ -2018,6 +2019,7 @@
2018
2019
  // this means we are finished using our own buffer and we can write over it safely
2019
2020
  target = buffer;
2020
2021
  target.dataView || (target.dataView = new DataView(target.buffer, target.byteOffset, target.byteLength));
2022
+ targetView = target.dataView;
2021
2023
  position = 0;
2022
2024
  }
2023
2025
  set position (value) {