@bldrs-ai/conway 1.442.1321 → 1.444.1334

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.
Binary file
Binary file
@@ -30,7 +30,7 @@ var import_node_process = require("node:process");
30
30
  var readline = __toESM(require("node:readline"), 1);
31
31
 
32
32
  // compiled/src/version/version.js
33
- var versionString = "Conway v1.442.1321";
33
+ var versionString = "Conway v1.444.1334";
34
34
 
35
35
  // compiled/dependencies/conway-geom/interface/conway_geometry.js
36
36
  var wasmType = "";
@@ -1127,6 +1127,19 @@ function copyOutOfResizable(view) {
1127
1127
  function decodeUtf8(view) {
1128
1128
  return decoder.decode(decodeNeedsCopy(view.buffer) ? view.slice() : view);
1129
1129
  }
1130
+ var strictUtf8Decoder = new TextDecoder("utf-8", { fatal: true });
1131
+ function decodeStepString(view) {
1132
+ const bytes = decodeNeedsCopy(view.buffer) ? view.slice() : view;
1133
+ try {
1134
+ return strictUtf8Decoder.decode(bytes);
1135
+ } catch {
1136
+ let result = "";
1137
+ for (let where = 0; where < bytes.length; ++where) {
1138
+ result += String.fromCharCode(bytes[where]);
1139
+ }
1140
+ return result;
1141
+ }
1142
+ }
1130
1143
  var shimInstalled = false;
1131
1144
  function installResizableTextDecoderShim() {
1132
1145
  if (shimInstalled || typeof TextDecoder === "undefined") {
@@ -1814,14 +1827,14 @@ var StepStringParser = class extends ParsingDfa16Table {
1814
1827
  if (nextCursor < endCursor && input2[nextCursor] === QUOTE) {
1815
1828
  result ??= "";
1816
1829
  if (cursor > reificationIndex) {
1817
- result += decodeUtf8(input2.subarray(reificationIndex, cursor - 1));
1830
+ result += decodeStepString(input2.subarray(reificationIndex, cursor - 1));
1818
1831
  }
1819
1832
  result += "'";
1820
1833
  cursor = nextCursor + 1;
1821
1834
  reificationIndex = cursor;
1822
1835
  } else {
1823
1836
  result ??= "";
1824
- result += decodeUtf8(input2.subarray(reificationIndex, cursor));
1837
+ result += decodeStepString(input2.subarray(reificationIndex, cursor));
1825
1838
  return result;
1826
1839
  }
1827
1840
  }
@@ -1847,7 +1860,7 @@ var StepStringParser = class extends ParsingDfa16Table {
1847
1860
  const nextChar2 = input2[nextCursor2];
1848
1861
  if (nextChar2 !== BSLASH) {
1849
1862
  result ??= "";
1850
- result += decodeUtf8(input2.subarray(reificationIndex, cursor));
1863
+ result += decodeStepString(input2.subarray(reificationIndex, cursor));
1851
1864
  cursor = nextCursor2 + 1;
1852
1865
  break;
1853
1866
  }
@@ -1860,7 +1873,7 @@ var StepStringParser = class extends ParsingDfa16Table {
1860
1873
  return result;
1861
1874
  }
1862
1875
  result ??= "";
1863
- result += decodeUtf8(input2.subarray(reificationIndex, cursor));
1876
+ result += decodeStepString(input2.subarray(reificationIndex, cursor));
1864
1877
  codePage = nextChar3 - A2;
1865
1878
  cursor = nextCursor3 + 1;
1866
1879
  reificationIndex = cursor;
@@ -1874,7 +1887,7 @@ var StepStringParser = class extends ParsingDfa16Table {
1874
1887
  const nextChar2 = input2[nextCursor2];
1875
1888
  if (nextChar2 !== BSLASH) {
1876
1889
  result ??= "";
1877
- result += decodeUtf8(input2.subarray(reificationIndex, cursor));
1890
+ result += decodeStepString(input2.subarray(reificationIndex, cursor));
1878
1891
  cursor = nextCursor2 + 1;
1879
1892
  break;
1880
1893
  }
@@ -1884,7 +1897,7 @@ var StepStringParser = class extends ParsingDfa16Table {
1884
1897
  }
1885
1898
  const nextChar3 = input2[nextCursor3];
1886
1899
  result ??= "";
1887
- result += decodeUtf8(input2.subarray(reificationIndex, cursor));
1900
+ result += decodeStepString(input2.subarray(reificationIndex, cursor));
1888
1901
  if (nextChar3 < 127) {
1889
1902
  result += String.fromCharCode(nextChar3);
1890
1903
  } else if (nextChar >= 161 && nextChar <= 255) {
@@ -1903,7 +1916,7 @@ var StepStringParser = class extends ParsingDfa16Table {
1903
1916
  }
1904
1917
  const nextChar2 = input2[nextCursor2];
1905
1918
  result ??= "";
1906
- result += decodeUtf8(input2.subarray(reificationIndex, cursor));
1919
+ result += decodeStepString(input2.subarray(reificationIndex, cursor));
1907
1920
  const hexParserTil0 = (count) => {
1908
1921
  if (nextCursor2 + 1 >= endCursor || input2[nextCursor2 + 1] !== BSLASH) {
1909
1922
  return false;