@wireweave/core 3.0.0 → 3.0.1-beta.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.
package/dist/parser.cjs CHANGED
@@ -6526,9 +6526,10 @@ function peg$parse(input, options) {
6526
6526
  }
6527
6527
 
6528
6528
  // src/parser/index.ts
6529
+ var peggyParse = peg$parse;
6529
6530
  function parse(source, options) {
6530
6531
  try {
6531
- return peg$parse(source, options);
6532
+ return peggyParse(source, options);
6532
6533
  } catch (error) {
6533
6534
  throw enhanceError(error);
6534
6535
  }
@@ -6550,7 +6551,7 @@ function tryParse(source, options) {
6550
6551
  column: parseError.location.start.column,
6551
6552
  offset: parseError.location.start.offset
6552
6553
  } : null,
6553
- expected: parseError.expected?.map((e) => e.description || e.text || String(e)),
6554
+ expected: parseError.expected?.map((e) => e.description || e.text || JSON.stringify(e)),
6554
6555
  found: parseError.found
6555
6556
  }
6556
6557
  ]
@@ -6575,7 +6576,7 @@ function formatErrorMessage(error) {
6575
6576
  const column = location?.start?.column ?? "?";
6576
6577
  let expectedDesc = "something";
6577
6578
  if (expected && expected.length > 0) {
6578
- const descriptions = expected.map((e) => e.description || e.text || String(e)).filter((d, i, arr) => arr.indexOf(d) === i).slice(0, 5);
6579
+ const descriptions = expected.map((e) => e.description || e.text || JSON.stringify(e)).filter((d, i, arr) => arr.indexOf(d) === i).slice(0, 5);
6579
6580
  if (descriptions.length === 1) {
6580
6581
  expectedDesc = descriptions[0];
6581
6582
  } else if (descriptions.length === 2) {
package/dist/parser.js CHANGED
@@ -6497,9 +6497,10 @@ function peg$parse(input, options) {
6497
6497
  }
6498
6498
 
6499
6499
  // src/parser/index.ts
6500
+ var peggyParse = peg$parse;
6500
6501
  function parse(source, options) {
6501
6502
  try {
6502
- return peg$parse(source, options);
6503
+ return peggyParse(source, options);
6503
6504
  } catch (error) {
6504
6505
  throw enhanceError(error);
6505
6506
  }
@@ -6521,7 +6522,7 @@ function tryParse(source, options) {
6521
6522
  column: parseError.location.start.column,
6522
6523
  offset: parseError.location.start.offset
6523
6524
  } : null,
6524
- expected: parseError.expected?.map((e) => e.description || e.text || String(e)),
6525
+ expected: parseError.expected?.map((e) => e.description || e.text || JSON.stringify(e)),
6525
6526
  found: parseError.found
6526
6527
  }
6527
6528
  ]
@@ -6546,7 +6547,7 @@ function formatErrorMessage(error) {
6546
6547
  const column = location?.start?.column ?? "?";
6547
6548
  let expectedDesc = "something";
6548
6549
  if (expected && expected.length > 0) {
6549
- const descriptions = expected.map((e) => e.description || e.text || String(e)).filter((d, i, arr) => arr.indexOf(d) === i).slice(0, 5);
6550
+ const descriptions = expected.map((e) => e.description || e.text || JSON.stringify(e)).filter((d, i, arr) => arr.indexOf(d) === i).slice(0, 5);
6550
6551
  if (descriptions.length === 1) {
6551
6552
  expectedDesc = descriptions[0];
6552
6553
  } else if (descriptions.length === 2) {