@calcit/procs 0.7.3 → 0.7.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.
@@ -1,6 +1,6 @@
1
1
  var _a;
2
2
  // CALCIT VERSION
3
- export const calcit_version = "0.7.3";
3
+ export const calcit_version = "0.7.5";
4
4
  import { parse } from "@cirru/parser.ts";
5
5
  import { writeCirruCode } from "@cirru/writer.ts";
6
6
  import { CalcitSymbol, CalcitTag, CalcitRef, CalcitRecur, newTag, refsRegistry, toString, getStringName, _$n__$e_, hashFunction, } from "./calcit-data.mjs";
package/lib/js-cirru.mjs CHANGED
@@ -127,8 +127,11 @@ export let to_cirru_edn = (x) => {
127
127
  // turn `x.snd` with CalcitList into raw Cirru nodes, which is in plain Array
128
128
  return ["quote", toWriterNode(x.get(1))];
129
129
  }
130
+ else if (x.tag instanceof CalcitTag) {
131
+ return ["::", x.tag.toString(), ...x.extra.map(to_cirru_edn)];
132
+ }
130
133
  else if (x.tag instanceof CalcitRecord) {
131
- return ["::", x.tag.name.toString(), to_cirru_edn(x.get(1))];
134
+ return ["::", x.tag.name.toString(), ...x.extra.map(to_cirru_edn)];
132
135
  }
133
136
  else {
134
137
  throw new Error(`Unsupported tag for EDN: ${x.tag}`);
package/lib/js-tuple.mjs CHANGED
@@ -56,6 +56,6 @@ export class CalcitTuple {
56
56
  }
57
57
  content += toString(args[i], false, disableJsDataWarning);
58
58
  }
59
- return `(&tuple ${content})`;
59
+ return `(:: ${content})`;
60
60
  }
61
61
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@calcit/procs",
3
- "version": "0.7.3",
3
+ "version": "0.7.5",
4
4
  "main": "./lib/calcit.procs.mjs",
5
5
  "devDependencies": {
6
6
  "@types/node": "^20.3.2",
@@ -1,5 +1,5 @@
1
1
  // CALCIT VERSION
2
- export const calcit_version = "0.7.3";
2
+ export const calcit_version = "0.7.5";
3
3
 
4
4
  import { parse, ICirruNode } from "@cirru/parser.ts";
5
5
  import { writeCirruCode } from "@cirru/writer.ts";
@@ -129,8 +129,10 @@ export let to_cirru_edn = (x: CalcitValue): CirruEdnFormat => {
129
129
  if (x.tag instanceof CalcitSymbol && x.tag.value === "quote") {
130
130
  // turn `x.snd` with CalcitList into raw Cirru nodes, which is in plain Array
131
131
  return ["quote", toWriterNode(x.get(1) as any)] as CirruEdnFormat;
132
+ } else if (x.tag instanceof CalcitTag) {
133
+ return ["::", x.tag.toString(), ...x.extra.map(to_cirru_edn)];
132
134
  } else if (x.tag instanceof CalcitRecord) {
133
- return ["::", x.tag.name.toString(), to_cirru_edn(x.get(1))];
135
+ return ["::", x.tag.name.toString(), ...x.extra.map(to_cirru_edn)];
134
136
  } else {
135
137
  throw new Error(`Unsupported tag for EDN: ${x.tag}`);
136
138
  }
@@ -61,6 +61,6 @@ export class CalcitTuple {
61
61
  }
62
62
  content += toString(args[i], false, disableJsDataWarning);
63
63
  }
64
- return `(&tuple ${content})`;
64
+ return `(:: ${content})`;
65
65
  }
66
66
  }