@calcit/procs 0.11.4 → 0.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/.yarn/install-state.gz +0 -0
- package/lib/js-record.mjs +8 -0
- package/lib/package.json +1 -1
- package/package.json +1 -1
- package/ts-src/js-record.mts +8 -0
package/.yarn/install-state.gz
CHANGED
|
Binary file
|
package/lib/js-record.mjs
CHANGED
|
@@ -199,6 +199,14 @@ export let _$n_record_$o_get_name = (x) => {
|
|
|
199
199
|
throw new Error("Expected a record");
|
|
200
200
|
}
|
|
201
201
|
};
|
|
202
|
+
export let _$n_record_$o_struct = (x) => {
|
|
203
|
+
if (x instanceof CalcitRecord) {
|
|
204
|
+
return x.structRef ?? null;
|
|
205
|
+
}
|
|
206
|
+
else {
|
|
207
|
+
throw new Error("Expected a record");
|
|
208
|
+
}
|
|
209
|
+
};
|
|
202
210
|
export let _$n_record_$o_from_map = (proto, data) => {
|
|
203
211
|
if (!(proto instanceof CalcitRecord))
|
|
204
212
|
throw new Error("Expected prototype to be record");
|
package/lib/package.json
CHANGED
package/package.json
CHANGED
package/ts-src/js-record.mts
CHANGED
|
@@ -206,6 +206,14 @@ export let _$n_record_$o_get_name = (x: CalcitRecord): CalcitTag => {
|
|
|
206
206
|
}
|
|
207
207
|
};
|
|
208
208
|
|
|
209
|
+
export let _$n_record_$o_struct = (x: CalcitRecord): CalcitValue => {
|
|
210
|
+
if (x instanceof CalcitRecord) {
|
|
211
|
+
return x.structRef ?? null;
|
|
212
|
+
} else {
|
|
213
|
+
throw new Error("Expected a record");
|
|
214
|
+
}
|
|
215
|
+
};
|
|
216
|
+
|
|
209
217
|
export let _$n_record_$o_from_map = (proto: CalcitValue, data: CalcitValue): CalcitValue => {
|
|
210
218
|
if (!(proto instanceof CalcitRecord)) throw new Error("Expected prototype to be record");
|
|
211
219
|
|