@danielx/civet 0.8.12 → 0.8.14
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/CHANGELOG.md +17 -0
- package/dist/browser.js +216 -91
- package/dist/config.js +7253 -1
- package/dist/config.mjs +7276 -1
- package/dist/main.js +216 -91
- package/dist/main.mjs +216 -91
- package/dist/types.d.ts +13 -1
- package/dist/unplugin/unplugin.js +156 -112
- package/dist/unplugin/unplugin.mjs +157 -113
- package/package.json +1 -1
package/dist/main.mjs
CHANGED
|
@@ -28,9 +28,9 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
|
|
|
28
28
|
mod
|
|
29
29
|
));
|
|
30
30
|
|
|
31
|
-
// node_modules/@danielx/hera/dist/machine.js
|
|
31
|
+
// node_modules/.pnpm/@danielx+hera@0.8.16/node_modules/@danielx/hera/dist/machine.js
|
|
32
32
|
var require_machine = __commonJS({
|
|
33
|
-
"node_modules/@danielx/hera/dist/machine.js"(exports, module) {
|
|
33
|
+
"node_modules/.pnpm/@danielx+hera@0.8.16/node_modules/@danielx/hera/dist/machine.js"(exports, module) {
|
|
34
34
|
"use strict";
|
|
35
35
|
var __defProp2 = Object.defineProperty;
|
|
36
36
|
var __getOwnPropDesc2 = Object.getOwnPropertyDescriptor;
|
|
@@ -1829,8 +1829,8 @@ var declareHelper = {
|
|
|
1829
1829
|
ts(": <T>(object: T, prop: PropertyKey) => boolean"),
|
|
1830
1830
|
" = ({}.constructor",
|
|
1831
1831
|
asAny,
|
|
1832
|
-
").hasOwn
|
|
1833
|
-
]]);
|
|
1832
|
+
").hasOwn"
|
|
1833
|
+
], ";\n"]);
|
|
1834
1834
|
},
|
|
1835
1835
|
is(isRef) {
|
|
1836
1836
|
state.prelude.push(["", [
|
|
@@ -1839,9 +1839,8 @@ var declareHelper = {
|
|
|
1839
1839
|
isRef,
|
|
1840
1840
|
ts(": { <B, A extends B> (a: A, b: B): b is A, <A, B> (a: A, b: B): a is A & B }"),
|
|
1841
1841
|
" = Object.is",
|
|
1842
|
-
asAny
|
|
1843
|
-
|
|
1844
|
-
]]);
|
|
1842
|
+
asAny
|
|
1843
|
+
], ";\n"]);
|
|
1845
1844
|
},
|
|
1846
1845
|
/**
|
|
1847
1846
|
* Array length check with type guard.
|
|
@@ -1859,8 +1858,11 @@ var declareHelper = {
|
|
|
1859
1858
|
},
|
|
1860
1859
|
rslice(rsliceRef) {
|
|
1861
1860
|
const RSliceable = makeRef("RSliceable");
|
|
1861
|
+
state.prelude.push([
|
|
1862
|
+
"",
|
|
1863
|
+
ts(["type ", RSliceable, "<R> = string | {length: number; slice(start: number, end: number): {reverse(): R}}\n"])
|
|
1864
|
+
]);
|
|
1862
1865
|
state.prelude.push(["", [
|
|
1863
|
-
ts(["type ", RSliceable, "<R> = string | {length: number; slice(start: number, end: number): {reverse(): R}}\n"]),
|
|
1864
1866
|
preludeVar,
|
|
1865
1867
|
rsliceRef,
|
|
1866
1868
|
ts([": <R, T extends string | ", RSliceable, "<R>>(a: T, start?: number, end?: number) => T extends string ? string : T extends ", RSliceable, "<infer R> ? R : never"]),
|
|
@@ -1879,8 +1881,8 @@ var declareHelper = {
|
|
|
1879
1881
|
" } else {\n",
|
|
1880
1882
|
" return a.slice(end, start + 1).reverse()\n",
|
|
1881
1883
|
" }\n",
|
|
1882
|
-
"})
|
|
1883
|
-
]]);
|
|
1884
|
+
"})"
|
|
1885
|
+
], ";\n"]);
|
|
1884
1886
|
},
|
|
1885
1887
|
div(divRef) {
|
|
1886
1888
|
state.prelude.push(["", [
|
|
@@ -1888,8 +1890,8 @@ var declareHelper = {
|
|
|
1888
1890
|
preludeVar,
|
|
1889
1891
|
divRef,
|
|
1890
1892
|
ts(": (a: number, b: number) => number"),
|
|
1891
|
-
" = (a, b) => Math.floor(a / b)
|
|
1892
|
-
]]);
|
|
1893
|
+
" = (a, b) => Math.floor(a / b)"
|
|
1894
|
+
], ";\n"]);
|
|
1893
1895
|
},
|
|
1894
1896
|
modulo(moduloRef) {
|
|
1895
1897
|
state.prelude.push(["", [
|
|
@@ -1897,14 +1899,15 @@ var declareHelper = {
|
|
|
1897
1899
|
preludeVar,
|
|
1898
1900
|
moduloRef,
|
|
1899
1901
|
ts(": (a: number, b: number) => number"),
|
|
1900
|
-
" = (a, b) => (a % b + b) % b
|
|
1901
|
-
]]);
|
|
1902
|
+
" = (a, b) => (a % b + b) % b"
|
|
1903
|
+
], ";\n"]);
|
|
1902
1904
|
},
|
|
1903
1905
|
Falsy(FalsyRef) {
|
|
1904
1906
|
state.prelude.push([
|
|
1905
1907
|
"",
|
|
1906
1908
|
// [indent, statement]
|
|
1907
|
-
ts(["type ", FalsyRef, " = false | 0 | '' | 0n | null | undefined
|
|
1909
|
+
ts(["type ", FalsyRef, " = false | 0 | '' | 0n | null | undefined"]),
|
|
1910
|
+
";\n"
|
|
1908
1911
|
]);
|
|
1909
1912
|
},
|
|
1910
1913
|
xor(xorRef) {
|
|
@@ -1925,9 +1928,8 @@ var declareHelper = {
|
|
|
1925
1928
|
" extends never ? never : A))"
|
|
1926
1929
|
]),
|
|
1927
1930
|
" = (a, b) => (a ? !b && a : b)",
|
|
1928
|
-
asAny
|
|
1929
|
-
|
|
1930
|
-
]]);
|
|
1931
|
+
asAny
|
|
1932
|
+
], ";\n"]);
|
|
1931
1933
|
},
|
|
1932
1934
|
xnor(xnorRef) {
|
|
1933
1935
|
const Falsy = getHelperRef("Falsy");
|
|
@@ -1945,9 +1947,8 @@ var declareHelper = {
|
|
|
1945
1947
|
" ? never : B))"
|
|
1946
1948
|
]),
|
|
1947
1949
|
" = (a, b) => (a ? b : !b || a)",
|
|
1948
|
-
asAny
|
|
1949
|
-
|
|
1950
|
-
]]);
|
|
1950
|
+
asAny
|
|
1951
|
+
], ";\n"]);
|
|
1951
1952
|
},
|
|
1952
1953
|
concatAssign(ref) {
|
|
1953
1954
|
state.prelude.push(["", [
|
|
@@ -1965,8 +1966,8 @@ var declareHelper = {
|
|
|
1965
1966
|
asAny,
|
|
1966
1967
|
") : (lhs",
|
|
1967
1968
|
asAny,
|
|
1968
|
-
").push(rhs), lhs)
|
|
1969
|
-
]]);
|
|
1969
|
+
").push(rhs), lhs)"
|
|
1970
|
+
], ";\n"]);
|
|
1970
1971
|
},
|
|
1971
1972
|
AutoPromise(ref) {
|
|
1972
1973
|
state.prelude.push([
|
|
@@ -3101,6 +3102,8 @@ function iterationDeclaration(statement) {
|
|
|
3101
3102
|
}
|
|
3102
3103
|
}
|
|
3103
3104
|
})());
|
|
3105
|
+
} else if (statement.object) {
|
|
3106
|
+
declaration.children.push("={}");
|
|
3104
3107
|
} else {
|
|
3105
3108
|
if (decl === "const") {
|
|
3106
3109
|
declaration.children.push("=[]");
|
|
@@ -3116,6 +3119,9 @@ function iterationDeclaration(statement) {
|
|
|
3116
3119
|
}
|
|
3117
3120
|
if (!block.empty) {
|
|
3118
3121
|
assignResults(block, (node) => {
|
|
3122
|
+
if (statement.object) {
|
|
3123
|
+
return ["Object.assign(", resultsRef, ",", node, ")"];
|
|
3124
|
+
}
|
|
3119
3125
|
if (!reduction) {
|
|
3120
3126
|
return [resultsRef, ".push(", node, ")"];
|
|
3121
3127
|
}
|
|
@@ -4674,7 +4680,7 @@ function processDeclarationCondition(condition, rootCondition, parent) {
|
|
|
4674
4680
|
const simple = ref === expression;
|
|
4675
4681
|
let children;
|
|
4676
4682
|
if (simple) {
|
|
4677
|
-
ref =
|
|
4683
|
+
ref = trimFirstSpace(ref);
|
|
4678
4684
|
children = [ref];
|
|
4679
4685
|
} else {
|
|
4680
4686
|
children = [ref, initializer];
|
|
@@ -4720,8 +4726,8 @@ function processDeclarationConditionStatement(s) {
|
|
|
4720
4726
|
return;
|
|
4721
4727
|
}
|
|
4722
4728
|
let { expression } = condition;
|
|
4723
|
-
if (expression && typeof expression === "object" && "type" in expression && expression.type === "UnaryExpression" && "children" in expression && Array.isArray(expression.children) && len2(expression.children, 2) && expression.children[0] === "!" && typeof expression.children[1] === "object" && expression.children[1] != null && "type" in expression.children[1] && expression.children[1].type === "ParenthesizedExpression" && "expression" in expression.children[1]) {
|
|
4724
|
-
const { type: type1, children: [, { type: type2, expression: expression2 }] } = expression;
|
|
4729
|
+
if (expression && typeof expression === "object" && "type" in expression && expression.type === "UnaryExpression" && "children" in expression && Array.isArray(expression.children) && len2(expression.children, 2) && Array.isArray(expression.children[0]) && len2(expression.children[0], 1) && expression.children[0][0] === "!" && typeof expression.children[1] === "object" && expression.children[1] != null && "type" in expression.children[1] && expression.children[1].type === "ParenthesizedExpression" && "expression" in expression.children[1]) {
|
|
4730
|
+
const { type: type1, children: [[], { type: type2, expression: expression2 }] } = expression;
|
|
4725
4731
|
const type = [type1, type2];
|
|
4726
4732
|
expression = expression2;
|
|
4727
4733
|
}
|
|
@@ -4740,7 +4746,7 @@ function processDeclarationConditionStatement(s) {
|
|
|
4740
4746
|
let children = condition.children;
|
|
4741
4747
|
if (s.negated) {
|
|
4742
4748
|
let m;
|
|
4743
|
-
if (!(m = condition.expression, typeof m === "object" && m != null && "type" in m && m.type === "UnaryExpression" && "children" in m && Array.isArray(m.children) && len2(m.children, 2) && m.children[0] === "!" && typeof m.children[1] === "object" && m.children[1] != null && "type" in m.children[1] && m.children[1].type === "ParenthesizedExpression")) {
|
|
4749
|
+
if (!(m = condition.expression, typeof m === "object" && m != null && "type" in m && m.type === "UnaryExpression" && "children" in m && Array.isArray(m.children) && len2(m.children, 2) && Array.isArray(m.children[0]) && len2(m.children[0], 1) && m.children[0][0] === "!" && typeof m.children[1] === "object" && m.children[1] != null && "type" in m.children[1] && m.children[1].type === "ParenthesizedExpression")) {
|
|
4744
4750
|
throw new Error("Unsupported negated condition");
|
|
4745
4751
|
}
|
|
4746
4752
|
;
|
|
@@ -4864,9 +4870,12 @@ function processDeclarationConditionStatement(s) {
|
|
|
4864
4870
|
}
|
|
4865
4871
|
function dynamizeFromClause(from) {
|
|
4866
4872
|
from = from.slice(1);
|
|
4867
|
-
from =
|
|
4868
|
-
|
|
4869
|
-
|
|
4873
|
+
from = trimFirstSpace(from);
|
|
4874
|
+
let ref2;
|
|
4875
|
+
if (ref2 = from[from.length - 1]?.assertion) {
|
|
4876
|
+
const assert2 = ref2;
|
|
4877
|
+
let ref3;
|
|
4878
|
+
ref3 = from[from.length - 1], ref3.children = ref3.children.filter((a2) => a2 !== assert2);
|
|
4870
4879
|
from.push(", {", assert2.keyword, ":", assert2.object, "}");
|
|
4871
4880
|
}
|
|
4872
4881
|
return ["(", ...from, ")"];
|
|
@@ -4875,20 +4884,20 @@ function dynamizeImportDeclaration(decl) {
|
|
|
4875
4884
|
const { imports } = decl;
|
|
4876
4885
|
let { star, binding, specifiers } = imports;
|
|
4877
4886
|
const justDefault = binding && !specifiers && !star;
|
|
4878
|
-
let
|
|
4887
|
+
let ref4;
|
|
4879
4888
|
{
|
|
4880
4889
|
if (binding) {
|
|
4881
4890
|
if (specifiers) {
|
|
4882
|
-
|
|
4891
|
+
ref4 = makeRef();
|
|
4883
4892
|
} else {
|
|
4884
|
-
|
|
4893
|
+
ref4 = binding;
|
|
4885
4894
|
}
|
|
4886
4895
|
} else {
|
|
4887
|
-
|
|
4896
|
+
ref4 = convertNamedImportsToObject(imports, true);
|
|
4888
4897
|
}
|
|
4889
4898
|
}
|
|
4890
4899
|
;
|
|
4891
|
-
const pattern =
|
|
4900
|
+
const pattern = ref4;
|
|
4892
4901
|
const c = "const";
|
|
4893
4902
|
const expression = [
|
|
4894
4903
|
justDefault ? "(" : void 0,
|
|
@@ -4965,7 +4974,7 @@ function dynamizeImportDeclarationExpression($0) {
|
|
|
4965
4974
|
{ type: "Await", children: "await" },
|
|
4966
4975
|
" ",
|
|
4967
4976
|
imp,
|
|
4968
|
-
|
|
4977
|
+
trimFirstSpace(ws2),
|
|
4969
4978
|
dynamizeFromClause(from),
|
|
4970
4979
|
{
|
|
4971
4980
|
type: "PropertyGlob",
|
|
@@ -5041,7 +5050,9 @@ function processUnaryExpression(pre, exp, post) {
|
|
|
5041
5050
|
if (pre.length) {
|
|
5042
5051
|
return {
|
|
5043
5052
|
type: "UnaryExpression",
|
|
5044
|
-
children: [
|
|
5053
|
+
children: [pre, exp],
|
|
5054
|
+
pre,
|
|
5055
|
+
expression: exp
|
|
5045
5056
|
};
|
|
5046
5057
|
}
|
|
5047
5058
|
return exp;
|
|
@@ -5093,7 +5104,10 @@ function processUnaryExpression(pre, exp, post) {
|
|
|
5093
5104
|
}
|
|
5094
5105
|
return {
|
|
5095
5106
|
type: "UnaryExpression",
|
|
5096
|
-
children: [
|
|
5107
|
+
children: [pre, exp, post],
|
|
5108
|
+
pre,
|
|
5109
|
+
expression: exp,
|
|
5110
|
+
post
|
|
5097
5111
|
};
|
|
5098
5112
|
}
|
|
5099
5113
|
function processUnaryNestedExpression(pre, args, post) {
|
|
@@ -6133,12 +6147,16 @@ function negateCondition(condition) {
|
|
|
6133
6147
|
if (i < 0) {
|
|
6134
6148
|
throw new Error(`Could not find expression in condition`);
|
|
6135
6149
|
}
|
|
6150
|
+
const pre = ["!"];
|
|
6151
|
+
expression = makeLeftHandSideExpression(expression);
|
|
6136
6152
|
children[i] = expression = {
|
|
6137
6153
|
type: "UnaryExpression",
|
|
6138
6154
|
children: [
|
|
6139
|
-
|
|
6140
|
-
|
|
6141
|
-
]
|
|
6155
|
+
pre,
|
|
6156
|
+
expression
|
|
6157
|
+
],
|
|
6158
|
+
pre,
|
|
6159
|
+
expression
|
|
6142
6160
|
};
|
|
6143
6161
|
return { ...condition, expression, children };
|
|
6144
6162
|
}
|
|
@@ -6616,19 +6634,23 @@ function processCallMemberExpression(node) {
|
|
|
6616
6634
|
assert.notEqual(i, 0, "Index access must be preceded by an expression");
|
|
6617
6635
|
const prefix = i === 1 ? children[0] : children.slice(0, i);
|
|
6618
6636
|
const { ref, refAssignment } = maybeRefAssignment(prefix);
|
|
6637
|
+
const args = [
|
|
6638
|
+
glob.children.slice(0 + 1, -1),
|
|
6639
|
+
// between "[" and "]" tokens
|
|
6640
|
+
",",
|
|
6641
|
+
[" ", ref, ".length"]
|
|
6642
|
+
];
|
|
6619
6643
|
const call = makeNode({
|
|
6620
6644
|
type: "CallExpression",
|
|
6645
|
+
implicit: true,
|
|
6621
6646
|
children: [
|
|
6622
6647
|
getHelperRef("modulo"),
|
|
6623
6648
|
makeNode({
|
|
6624
6649
|
type: "Call",
|
|
6650
|
+
args,
|
|
6625
6651
|
children: [
|
|
6626
6652
|
"(",
|
|
6627
|
-
|
|
6628
|
-
// between "[" and "]" tokens
|
|
6629
|
-
", ",
|
|
6630
|
-
ref,
|
|
6631
|
-
".length",
|
|
6653
|
+
args,
|
|
6632
6654
|
")"
|
|
6633
6655
|
]
|
|
6634
6656
|
})
|
|
@@ -6640,7 +6662,7 @@ function processCallMemberExpression(node) {
|
|
|
6640
6662
|
...node,
|
|
6641
6663
|
children: [
|
|
6642
6664
|
makeLeftHandSideExpression(refAssignment ?? prefix),
|
|
6643
|
-
{
|
|
6665
|
+
makeNode({
|
|
6644
6666
|
...glob,
|
|
6645
6667
|
mod: false,
|
|
6646
6668
|
expression: call,
|
|
@@ -6651,7 +6673,7 @@ function processCallMemberExpression(node) {
|
|
|
6651
6673
|
(ref3 = glob.children)[ref3.length - 1]
|
|
6652
6674
|
// "]" token
|
|
6653
6675
|
]
|
|
6654
|
-
},
|
|
6676
|
+
}),
|
|
6655
6677
|
...children.slice(i + 1)
|
|
6656
6678
|
]
|
|
6657
6679
|
});
|
|
@@ -6701,7 +6723,7 @@ function makeExpressionStatement(expression) {
|
|
|
6701
6723
|
return [comma, makeExpressionStatement(exp)];
|
|
6702
6724
|
})
|
|
6703
6725
|
];
|
|
6704
|
-
} else if (expression?.type === "ObjectExpression" || expression?.type === "FunctionExpression" && !expression.id) {
|
|
6726
|
+
} else if (expression?.type === "ObjectExpression" || expression?.type === "FunctionExpression" && !expression.id || expression?.type === "UnaryExpression" && !expression.pre?.length && expression.expression !== makeExpressionStatement(expression.expression)) {
|
|
6705
6727
|
return makeLeftHandSideExpression(expression);
|
|
6706
6728
|
} else {
|
|
6707
6729
|
return expression;
|
|
@@ -7414,12 +7436,12 @@ function processProgram(root) {
|
|
|
7414
7436
|
} else if (config2.autoVar) {
|
|
7415
7437
|
createVarDecs(root, []);
|
|
7416
7438
|
}
|
|
7417
|
-
processBlocks(statements);
|
|
7418
|
-
populateRefs(statements);
|
|
7419
|
-
adjustAtBindings(statements);
|
|
7420
7439
|
if (config2.repl) {
|
|
7421
7440
|
processRepl(root, rootIIFE);
|
|
7422
7441
|
}
|
|
7442
|
+
processBlocks(statements);
|
|
7443
|
+
populateRefs(statements);
|
|
7444
|
+
adjustAtBindings(statements);
|
|
7423
7445
|
if (getSync()) {
|
|
7424
7446
|
processComptime(statements);
|
|
7425
7447
|
}
|
|
@@ -7438,7 +7460,11 @@ function processRepl(root, rootIIFE) {
|
|
|
7438
7460
|
}
|
|
7439
7461
|
if (decl.parent === topBlock || decl.decl === "var") {
|
|
7440
7462
|
decl.children.shift();
|
|
7441
|
-
|
|
7463
|
+
if (decl.bindings[0]?.pattern?.type === "ObjectBindingPattern") {
|
|
7464
|
+
decl.children.unshift("(");
|
|
7465
|
+
decl.children.push(")");
|
|
7466
|
+
}
|
|
7467
|
+
root.expressions.splice(i++, 0, ["", `var ${decl.names.join(",")}`, ";"]);
|
|
7442
7468
|
}
|
|
7443
7469
|
}
|
|
7444
7470
|
for (let ref27 = gatherRecursive(topBlock, ($15) => $15.type === "FunctionExpression"), i10 = 0, len9 = ref27.length; i10 < len9; i10++) {
|
|
@@ -7450,7 +7476,7 @@ function processRepl(root, rootIIFE) {
|
|
|
7450
7476
|
func.parent = root;
|
|
7451
7477
|
} else {
|
|
7452
7478
|
func.children.unshift(func.name, "=");
|
|
7453
|
-
root.expressions.splice(i++, 0, ["", `var ${func.name}
|
|
7479
|
+
root.expressions.splice(i++, 0, ["", `var ${func.name}`, ";"]);
|
|
7454
7480
|
}
|
|
7455
7481
|
}
|
|
7456
7482
|
}
|
|
@@ -7459,7 +7485,7 @@ function processRepl(root, rootIIFE) {
|
|
|
7459
7485
|
let m5;
|
|
7460
7486
|
if (classExp.name && classExp.parent === topBlock || (m5 = classExp.parent, typeof m5 === "object" && m5 != null && "type" in m5 && m5.type === "ReturnStatement" && "parent" in m5 && m5.parent === topBlock)) {
|
|
7461
7487
|
classExp.children.unshift(classExp.name, "=");
|
|
7462
|
-
root.expressions.splice(i++, 0, ["", `var ${classExp.name}
|
|
7488
|
+
root.expressions.splice(i++, 0, ["", `var ${classExp.name}`, ";"]);
|
|
7463
7489
|
}
|
|
7464
7490
|
}
|
|
7465
7491
|
}
|
|
@@ -8001,6 +8027,7 @@ var grammar = {
|
|
|
8001
8027
|
ArrayElementDelimiter,
|
|
8002
8028
|
ElementListWithIndentedApplicationForbidden,
|
|
8003
8029
|
ElementList,
|
|
8030
|
+
SingleLineElementList,
|
|
8004
8031
|
ElementListRest,
|
|
8005
8032
|
ArrayElementExpression,
|
|
8006
8033
|
NestedBulletedArray,
|
|
@@ -8013,6 +8040,7 @@ var grammar = {
|
|
|
8013
8040
|
BulletedArrayWithTrailing,
|
|
8014
8041
|
ObjectLiteral,
|
|
8015
8042
|
BracedObjectLiteral,
|
|
8043
|
+
SingleLineObjectProperties,
|
|
8016
8044
|
BracedObjectLiteralContent,
|
|
8017
8045
|
NestedImplicitObjectLiteral,
|
|
8018
8046
|
NestedImplicitPropertyDefinitions,
|
|
@@ -8293,6 +8321,7 @@ var grammar = {
|
|
|
8293
8321
|
Dot,
|
|
8294
8322
|
DotDot,
|
|
8295
8323
|
DotDotDot,
|
|
8324
|
+
InsertDotDotDot,
|
|
8296
8325
|
DoubleColon,
|
|
8297
8326
|
DoubleColonAsColon,
|
|
8298
8327
|
DoubleQuote,
|
|
@@ -8853,7 +8882,7 @@ var $R11 = (0, import_lib2.$R)(new RegExp("%%?", "suy"));
|
|
|
8853
8882
|
var $R12 = (0, import_lib2.$R)(new RegExp("[.\\s]", "suy"));
|
|
8854
8883
|
var $R13 = (0, import_lib2.$R)(new RegExp("[)}]", "suy"));
|
|
8855
8884
|
var $R14 = (0, import_lib2.$R)(new RegExp("[+-]", "suy"));
|
|
8856
|
-
var $R15 = (0, import_lib2.$R)(new RegExp("
|
|
8885
|
+
var $R15 = (0, import_lib2.$R)(new RegExp("\\+\\+|--|\u29FA|\u2014|[\\+\\-&]\\S", "suy"));
|
|
8857
8886
|
var $R16 = (0, import_lib2.$R)(new RegExp(`(?=[0-9.'"tfyno])`, "suy"));
|
|
8858
8887
|
var $R17 = (0, import_lib2.$R)(new RegExp("(?=true|false|yes|no|on|off)", "suy"));
|
|
8859
8888
|
var $R18 = (0, import_lib2.$R)(new RegExp("(?=\\p{ID_Start}|[_$])", "suy"));
|
|
@@ -9715,9 +9744,7 @@ function TrailingPostfix(ctx, state2) {
|
|
|
9715
9744
|
}
|
|
9716
9745
|
var FatArrowBody$0 = (0, import_lib2.$TS)((0, import_lib2.$S)((0, import_lib2.$N)(EOS), (0, import_lib2.$N)((0, import_lib2.$S)((0, import_lib2.$E)(_), ExpressionizedStatement)), NonPipelineExpression, (0, import_lib2.$N)(TrailingDeclaration), (0, import_lib2.$N)(TrailingPipe), (0, import_lib2.$N)(TrailingPostfix), (0, import_lib2.$N)(SemicolonDelimiter)), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6, $7) {
|
|
9717
9746
|
var exp = $3;
|
|
9718
|
-
|
|
9719
|
-
exp = makeLeftHandSideExpression(exp);
|
|
9720
|
-
}
|
|
9747
|
+
exp = makeExpressionStatement(exp);
|
|
9721
9748
|
const expressions = [["", exp]];
|
|
9722
9749
|
return {
|
|
9723
9750
|
type: "BlockStatement",
|
|
@@ -11651,13 +11678,13 @@ var FunctionExpression$4 = (0, import_lib2.$TS)((0, import_lib2.$S)(OpenParen, _
|
|
|
11651
11678
|
expression: fn
|
|
11652
11679
|
};
|
|
11653
11680
|
});
|
|
11654
|
-
var FunctionExpression$5 = (0, import_lib2.$TS)((0, import_lib2.$S)(OpenParen, __, (0, import_lib2.$N)((0, import_lib2.$EXPECT)($R15, "FunctionExpression
|
|
11681
|
+
var FunctionExpression$5 = (0, import_lib2.$TS)((0, import_lib2.$S)(OpenParen, __, (0, import_lib2.$N)((0, import_lib2.$EXPECT)($R15, "FunctionExpression /\\+\\+|--|\u29FA|\u2014|[\\+\\-&]\\S/")), (0, import_lib2.$N)((0, import_lib2.$S)(Placeholder, (0, import_lib2.$C)(TypePostfix, BinaryOpRHS))), BinaryOp, __, NonPipelineAssignmentExpression, CloseParen), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6, $7, $8) {
|
|
11655
11682
|
var open = $1;
|
|
11656
11683
|
var ws1 = $2;
|
|
11657
|
-
var op = $
|
|
11658
|
-
var ws2 = $
|
|
11659
|
-
var rhs = $
|
|
11660
|
-
var close = $
|
|
11684
|
+
var op = $5;
|
|
11685
|
+
var ws2 = $6;
|
|
11686
|
+
var rhs = $7;
|
|
11687
|
+
var close = $8;
|
|
11661
11688
|
const refA = makeRef("a");
|
|
11662
11689
|
const fn = makeAmpersandFunction({
|
|
11663
11690
|
ref: refA,
|
|
@@ -12359,7 +12386,30 @@ function ArrayLiteral(ctx, state2) {
|
|
|
12359
12386
|
var _ArrayLiteral$0 = (0, import_lib2.$T)((0, import_lib2.$S)(ArrayBindingPattern, UpcomingAssignment), function(value) {
|
|
12360
12387
|
return value[0];
|
|
12361
12388
|
});
|
|
12362
|
-
var _ArrayLiteral$1 = (0, import_lib2.$TS)((0, import_lib2.$S)(OpenBracket, AllowAll, (0, import_lib2.$E)((0, import_lib2.$
|
|
12389
|
+
var _ArrayLiteral$1 = (0, import_lib2.$TS)((0, import_lib2.$S)(OpenBracket, CloseBracket, ApplicationStart, AllowAll, (0, import_lib2.$E)((0, import_lib2.$C)(NestedElementList, SingleLineElementList)), RestoreAll), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6) {
|
|
12390
|
+
var open = $1;
|
|
12391
|
+
var close = $2;
|
|
12392
|
+
var content = $5;
|
|
12393
|
+
if (!content)
|
|
12394
|
+
return $skip;
|
|
12395
|
+
let last = content[content.length - 1];
|
|
12396
|
+
let lastArray = Array.isArray(last) ? last : last.children;
|
|
12397
|
+
if (isComma(lastArray[lastArray.length - 1])) {
|
|
12398
|
+
lastArray = lastArray.slice(0, -1);
|
|
12399
|
+
if (Array.isArray(last)) {
|
|
12400
|
+
last = lastArray;
|
|
12401
|
+
} else {
|
|
12402
|
+
last = { ...last, children: lastArray };
|
|
12403
|
+
}
|
|
12404
|
+
content = [...content.slice(0, -1), last];
|
|
12405
|
+
}
|
|
12406
|
+
return {
|
|
12407
|
+
type: "ArrayExpression",
|
|
12408
|
+
children: [open, ...content, close],
|
|
12409
|
+
names: content.flatMap((c) => c?.names || [])
|
|
12410
|
+
};
|
|
12411
|
+
});
|
|
12412
|
+
var _ArrayLiteral$2 = (0, import_lib2.$TS)((0, import_lib2.$S)(OpenBracket, AllowAll, (0, import_lib2.$E)((0, import_lib2.$S)(ArrayLiteralContent, __, CloseBracket)), RestoreAll), function($skip, $loc, $0, $1, $2, $3, $4) {
|
|
12363
12413
|
var open = $1;
|
|
12364
12414
|
if (!$3)
|
|
12365
12415
|
return $skip;
|
|
@@ -12380,8 +12430,8 @@ var _ArrayLiteral$1 = (0, import_lib2.$TS)((0, import_lib2.$S)(OpenBracket, Allo
|
|
|
12380
12430
|
names
|
|
12381
12431
|
};
|
|
12382
12432
|
});
|
|
12383
|
-
var _ArrayLiteral$
|
|
12384
|
-
var _ArrayLiteral$$ = [_ArrayLiteral$0, _ArrayLiteral$1, _ArrayLiteral$2];
|
|
12433
|
+
var _ArrayLiteral$3 = NestedBulletedArray;
|
|
12434
|
+
var _ArrayLiteral$$ = [_ArrayLiteral$0, _ArrayLiteral$1, _ArrayLiteral$2, _ArrayLiteral$3];
|
|
12385
12435
|
function _ArrayLiteral(ctx, state2) {
|
|
12386
12436
|
return (0, import_lib2.$EVENT_C)(ctx, state2, "_ArrayLiteral", _ArrayLiteral$$);
|
|
12387
12437
|
}
|
|
@@ -12554,7 +12604,12 @@ function ElementListWithIndentedApplicationForbidden(ctx, state2) {
|
|
|
12554
12604
|
var ElementList$0 = (0, import_lib2.$T)((0, import_lib2.$S)(BulletedArray), function(value) {
|
|
12555
12605
|
return [value[0]];
|
|
12556
12606
|
});
|
|
12557
|
-
var ElementList$1 =
|
|
12607
|
+
var ElementList$1 = SingleLineElementList;
|
|
12608
|
+
var ElementList$$ = [ElementList$0, ElementList$1];
|
|
12609
|
+
function ElementList(ctx, state2) {
|
|
12610
|
+
return (0, import_lib2.$EVENT_C)(ctx, state2, "ElementList", ElementList$$);
|
|
12611
|
+
}
|
|
12612
|
+
var SingleLineElementList$0 = (0, import_lib2.$TS)((0, import_lib2.$S)((0, import_lib2.$N)(EOS), ArrayElementExpression, (0, import_lib2.$Q)(ElementListRest)), function($skip, $loc, $0, $1, $2, $3) {
|
|
12558
12613
|
var first = $2;
|
|
12559
12614
|
var rest = $3;
|
|
12560
12615
|
if (!rest.length)
|
|
@@ -12565,9 +12620,8 @@ var ElementList$1 = (0, import_lib2.$TS)((0, import_lib2.$S)((0, import_lib2.$N)
|
|
|
12565
12620
|
rest.map(([_2, e], i) => append(e, rest[i + 1]?.[0]))
|
|
12566
12621
|
);
|
|
12567
12622
|
});
|
|
12568
|
-
|
|
12569
|
-
|
|
12570
|
-
return (0, import_lib2.$EVENT_C)(ctx, state2, "ElementList", ElementList$$);
|
|
12623
|
+
function SingleLineElementList(ctx, state2) {
|
|
12624
|
+
return (0, import_lib2.$EVENT)(ctx, state2, "SingleLineElementList", SingleLineElementList$0);
|
|
12571
12625
|
}
|
|
12572
12626
|
var ElementListRest$0 = (0, import_lib2.$S)((0, import_lib2.$S)((0, import_lib2.$E)(_), Comma, (0, import_lib2.$N)(EOS)), ArrayElementExpression);
|
|
12573
12627
|
function ElementListRest(ctx, state2) {
|
|
@@ -12746,7 +12800,29 @@ var ObjectLiteral$$ = [ObjectLiteral$0, ObjectLiteral$1, ObjectLiteral$2, Object
|
|
|
12746
12800
|
function ObjectLiteral(ctx, state2) {
|
|
12747
12801
|
return (0, import_lib2.$EVENT_C)(ctx, state2, "ObjectLiteral", ObjectLiteral$$);
|
|
12748
12802
|
}
|
|
12749
|
-
var BracedObjectLiteral$0 = (0, import_lib2.$TS)((0, import_lib2.$S)(OpenBrace, AllowAll, (0, import_lib2.$E)((0, import_lib2.$
|
|
12803
|
+
var BracedObjectLiteral$0 = (0, import_lib2.$TS)((0, import_lib2.$S)(OpenBrace, CloseBrace, ApplicationStart, AllowAll, (0, import_lib2.$E)((0, import_lib2.$C)(NestedPropertyDefinitions, SingleLineObjectProperties)), RestoreAll), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6) {
|
|
12804
|
+
var open = $1;
|
|
12805
|
+
var close = $2;
|
|
12806
|
+
var properties = $5;
|
|
12807
|
+
if (!properties?.length)
|
|
12808
|
+
return $skip;
|
|
12809
|
+
let last = properties[properties.length - 1];
|
|
12810
|
+
if (last.delim?.implicit) {
|
|
12811
|
+
last = {
|
|
12812
|
+
...last,
|
|
12813
|
+
delim: void 0,
|
|
12814
|
+
children: last.children.filter((c) => c !== last.delim)
|
|
12815
|
+
};
|
|
12816
|
+
properties = [...properties.slice(0, properties.length - 1), last];
|
|
12817
|
+
}
|
|
12818
|
+
return {
|
|
12819
|
+
type: "ObjectExpression",
|
|
12820
|
+
children: [open, properties, close],
|
|
12821
|
+
names: properties.flatMap((c) => c.names || []),
|
|
12822
|
+
properties
|
|
12823
|
+
};
|
|
12824
|
+
});
|
|
12825
|
+
var BracedObjectLiteral$1 = (0, import_lib2.$TS)((0, import_lib2.$S)(OpenBrace, AllowAll, (0, import_lib2.$E)((0, import_lib2.$S)(BracedObjectLiteralContent, __, CloseBrace)), RestoreAll), function($skip, $loc, $0, $1, $2, $3, $4) {
|
|
12750
12826
|
var open = $1;
|
|
12751
12827
|
if (!$3)
|
|
12752
12828
|
return $skip;
|
|
@@ -12758,13 +12834,13 @@ var BracedObjectLiteral$0 = (0, import_lib2.$TS)((0, import_lib2.$S)(OpenBrace,
|
|
|
12758
12834
|
properties
|
|
12759
12835
|
};
|
|
12760
12836
|
});
|
|
12837
|
+
var BracedObjectLiteral$$ = [BracedObjectLiteral$0, BracedObjectLiteral$1];
|
|
12761
12838
|
function BracedObjectLiteral(ctx, state2) {
|
|
12762
|
-
return (0, import_lib2.$
|
|
12839
|
+
return (0, import_lib2.$EVENT_C)(ctx, state2, "BracedObjectLiteral", BracedObjectLiteral$$);
|
|
12763
12840
|
}
|
|
12764
|
-
var
|
|
12765
|
-
var line = $
|
|
12766
|
-
|
|
12767
|
-
line = line.flatMap(([prop, delim]) => {
|
|
12841
|
+
var SingleLineObjectProperties$0 = (0, import_lib2.$TV)((0, import_lib2.$Q)((0, import_lib2.$S)(PropertyDefinition, ObjectPropertyDelimiter)), function($skip, $loc, $0, $1) {
|
|
12842
|
+
var line = $0;
|
|
12843
|
+
return line.flatMap(([prop, delim]) => {
|
|
12768
12844
|
prop = Array.isArray(prop) ? prop : [prop];
|
|
12769
12845
|
let last = prop[prop.length - 1];
|
|
12770
12846
|
if (!last)
|
|
@@ -12776,6 +12852,13 @@ var BracedObjectLiteralContent$0 = (0, import_lib2.$TS)((0, import_lib2.$S)((0,
|
|
|
12776
12852
|
};
|
|
12777
12853
|
return [...prop.slice(0, prop.length - 1), last];
|
|
12778
12854
|
});
|
|
12855
|
+
});
|
|
12856
|
+
function SingleLineObjectProperties(ctx, state2) {
|
|
12857
|
+
return (0, import_lib2.$EVENT)(ctx, state2, "SingleLineObjectProperties", SingleLineObjectProperties$0);
|
|
12858
|
+
}
|
|
12859
|
+
var BracedObjectLiteralContent$0 = (0, import_lib2.$TS)((0, import_lib2.$S)(SingleLineObjectProperties, (0, import_lib2.$E)(NestedPropertyDefinitions)), function($skip, $loc, $0, $1, $2) {
|
|
12860
|
+
var line = $1;
|
|
12861
|
+
var nested = $2;
|
|
12779
12862
|
return line.concat(nested || []);
|
|
12780
12863
|
});
|
|
12781
12864
|
var BracedObjectLiteralContent$1 = (0, import_lib2.$TV)((0, import_lib2.$P)((0, import_lib2.$S)(__, PropertyDefinition, ObjectPropertyDelimiter)), function($skip, $loc, $0, $1) {
|
|
@@ -12907,19 +12990,48 @@ function InlineObjectPropertyDelimiter(ctx, state2) {
|
|
|
12907
12990
|
}
|
|
12908
12991
|
var ObjectPropertyDelimiter$0 = (0, import_lib2.$S)((0, import_lib2.$E)(_), Comma);
|
|
12909
12992
|
var ObjectPropertyDelimiter$1 = (0, import_lib2.$Y)((0, import_lib2.$S)(__, (0, import_lib2.$EXPECT)($L37, 'ObjectPropertyDelimiter "}"')));
|
|
12910
|
-
var ObjectPropertyDelimiter$2 = (0, import_lib2.$
|
|
12911
|
-
return
|
|
12993
|
+
var ObjectPropertyDelimiter$2 = (0, import_lib2.$TS)((0, import_lib2.$S)((0, import_lib2.$Y)(EOS), InsertComma), function($skip, $loc, $0, $1, $2) {
|
|
12994
|
+
return { ...$2, implicit: true };
|
|
12912
12995
|
});
|
|
12913
12996
|
var ObjectPropertyDelimiter$$ = [ObjectPropertyDelimiter$0, ObjectPropertyDelimiter$1, ObjectPropertyDelimiter$2];
|
|
12914
12997
|
function ObjectPropertyDelimiter(ctx, state2) {
|
|
12915
12998
|
return (0, import_lib2.$EVENT_C)(ctx, state2, "ObjectPropertyDelimiter", ObjectPropertyDelimiter$$);
|
|
12916
12999
|
}
|
|
12917
|
-
var PropertyDefinition$0 = (0, import_lib2.$TS)((0, import_lib2.$S)((0, import_lib2.$E)(_),
|
|
13000
|
+
var PropertyDefinition$0 = (0, import_lib2.$TS)((0, import_lib2.$S)((0, import_lib2.$E)(_), InsertDotDotDot, IterationExpression), function($skip, $loc, $0, $1, $2, $3) {
|
|
13001
|
+
var ws = $1;
|
|
13002
|
+
var dots = $2;
|
|
13003
|
+
var exp = $3;
|
|
13004
|
+
let { statement } = exp;
|
|
13005
|
+
if (exp.block.implicit && (statement.type === "DoStatement" || statement.subtype === "loop")) {
|
|
13006
|
+
return $skip;
|
|
13007
|
+
}
|
|
13008
|
+
statement = { ...statement, object: true };
|
|
13009
|
+
exp = {
|
|
13010
|
+
...exp,
|
|
13011
|
+
statement,
|
|
13012
|
+
children: exp.children.map(($) => $ === exp.statement ? statement : $)
|
|
13013
|
+
};
|
|
13014
|
+
const children = [ws, dots, exp];
|
|
13015
|
+
if (statement.reduction) {
|
|
13016
|
+
children.unshift({
|
|
13017
|
+
type: "Error",
|
|
13018
|
+
message: "Reduction loops are forbidden in object literals"
|
|
13019
|
+
});
|
|
13020
|
+
}
|
|
13021
|
+
return {
|
|
13022
|
+
type: "SpreadProperty",
|
|
13023
|
+
children,
|
|
13024
|
+
names: exp.names,
|
|
13025
|
+
dots,
|
|
13026
|
+
value: exp
|
|
13027
|
+
};
|
|
13028
|
+
});
|
|
13029
|
+
var PropertyDefinition$1 = (0, import_lib2.$TS)((0, import_lib2.$S)((0, import_lib2.$E)(_), NamedProperty), function($skip, $loc, $0, $1, $2) {
|
|
12918
13030
|
var ws = $1;
|
|
12919
13031
|
var prop = $2;
|
|
12920
13032
|
return prepend(ws, prop);
|
|
12921
13033
|
});
|
|
12922
|
-
var PropertyDefinition$
|
|
13034
|
+
var PropertyDefinition$2 = (0, import_lib2.$TS)((0, import_lib2.$S)((0, import_lib2.$E)(_), (0, import_lib2.$TEXT)((0, import_lib2.$EXPECT)($R24, "PropertyDefinition /[!+-]?/")), PropertyName, (0, import_lib2.$Y)(ObjectPropertyDelimiter)), function($skip, $loc, $0, $1, $2, $3, $4) {
|
|
12923
13035
|
var ws = $1;
|
|
12924
13036
|
var toggle = $2;
|
|
12925
13037
|
var id = $3;
|
|
@@ -12941,7 +13053,7 @@ var PropertyDefinition$1 = (0, import_lib2.$TS)((0, import_lib2.$S)((0, import_l
|
|
|
12941
13053
|
value: id
|
|
12942
13054
|
};
|
|
12943
13055
|
});
|
|
12944
|
-
var PropertyDefinition$
|
|
13056
|
+
var PropertyDefinition$3 = (0, import_lib2.$TS)((0, import_lib2.$S)((0, import_lib2.$E)(_), MethodDefinition), function($skip, $loc, $0, $1, $2) {
|
|
12945
13057
|
var ws = $1;
|
|
12946
13058
|
var def = $2;
|
|
12947
13059
|
if (def.type === "MultiMethodDefinition") {
|
|
@@ -12953,7 +13065,7 @@ var PropertyDefinition$2 = (0, import_lib2.$TS)((0, import_lib2.$S)((0, import_l
|
|
|
12953
13065
|
return $skip;
|
|
12954
13066
|
return prepend(ws, def);
|
|
12955
13067
|
});
|
|
12956
|
-
var PropertyDefinition$
|
|
13068
|
+
var PropertyDefinition$4 = (0, import_lib2.$TS)((0, import_lib2.$S)((0, import_lib2.$E)(_), DotDotDot, Expression), function($skip, $loc, $0, $1, $2, $3) {
|
|
12957
13069
|
var ws = $1;
|
|
12958
13070
|
var dots = $2;
|
|
12959
13071
|
var exp = $3;
|
|
@@ -12965,7 +13077,7 @@ var PropertyDefinition$3 = (0, import_lib2.$TS)((0, import_lib2.$S)((0, import_l
|
|
|
12965
13077
|
value: exp
|
|
12966
13078
|
};
|
|
12967
13079
|
});
|
|
12968
|
-
var PropertyDefinition$
|
|
13080
|
+
var PropertyDefinition$5 = (0, import_lib2.$TS)((0, import_lib2.$S)((0, import_lib2.$E)(_), (0, import_lib2.$N)((0, import_lib2.$C)(EOS, (0, import_lib2.$EXPECT)($L7, 'PropertyDefinition "."'))), (0, import_lib2.$Q)(UnaryOp), CallExpression, (0, import_lib2.$E)(UnaryPostfix)), function($skip, $loc, $0, $1, $2, $3, $4, $5) {
|
|
12969
13081
|
var ws = $1;
|
|
12970
13082
|
var pre = $3;
|
|
12971
13083
|
var value = $4;
|
|
@@ -13030,7 +13142,7 @@ var PropertyDefinition$4 = (0, import_lib2.$TS)((0, import_lib2.$S)((0, import_l
|
|
|
13030
13142
|
value
|
|
13031
13143
|
};
|
|
13032
13144
|
});
|
|
13033
|
-
var PropertyDefinition$$ = [PropertyDefinition$0, PropertyDefinition$1, PropertyDefinition$2, PropertyDefinition$3, PropertyDefinition$4];
|
|
13145
|
+
var PropertyDefinition$$ = [PropertyDefinition$0, PropertyDefinition$1, PropertyDefinition$2, PropertyDefinition$3, PropertyDefinition$4, PropertyDefinition$5];
|
|
13034
13146
|
function PropertyDefinition(ctx, state2) {
|
|
13035
13147
|
return (0, import_lib2.$EVENT_C)(ctx, state2, "PropertyDefinition", PropertyDefinition$$);
|
|
13036
13148
|
}
|
|
@@ -15687,8 +15799,9 @@ function ModuleExportName(ctx, state2) {
|
|
|
15687
15799
|
return (0, import_lib2.$EVENT_C)(ctx, state2, "ModuleExportName", ModuleExportName$$);
|
|
15688
15800
|
}
|
|
15689
15801
|
var ModuleSpecifier$0 = (0, import_lib2.$TS)((0, import_lib2.$S)(UnprocessedModuleSpecifier, (0, import_lib2.$E)(ImportAssertion)), function($skip, $loc, $0, $1, $2) {
|
|
15690
|
-
var
|
|
15691
|
-
|
|
15802
|
+
var module = $1;
|
|
15803
|
+
var assertion = $2;
|
|
15804
|
+
let { token } = module;
|
|
15692
15805
|
if (config.rewriteTsImports) {
|
|
15693
15806
|
token = token.replace(/\.([mc])?ts(['"])$/, ".$1js$2");
|
|
15694
15807
|
}
|
|
@@ -15698,9 +15811,15 @@ var ModuleSpecifier$0 = (0, import_lib2.$TS)((0, import_lib2.$S)(UnprocessedModu
|
|
|
15698
15811
|
`${config.rewriteCivetImports.replace(/\$/g, "$$")}$1`
|
|
15699
15812
|
);
|
|
15700
15813
|
}
|
|
15701
|
-
if (
|
|
15702
|
-
|
|
15703
|
-
|
|
15814
|
+
if (token !== module.token) {
|
|
15815
|
+
module = { ...module, token, input: module.token };
|
|
15816
|
+
}
|
|
15817
|
+
return {
|
|
15818
|
+
type: "ModuleSpecifier",
|
|
15819
|
+
module,
|
|
15820
|
+
assertion,
|
|
15821
|
+
children: [module, assertion]
|
|
15822
|
+
};
|
|
15704
15823
|
});
|
|
15705
15824
|
function ModuleSpecifier(ctx, state2) {
|
|
15706
15825
|
return (0, import_lib2.$EVENT)(ctx, state2, "ModuleSpecifier", ModuleSpecifier$0);
|
|
@@ -16004,7 +16123,7 @@ var DecimalBigIntegerLiteral$0 = (0, import_lib2.$R$0)((0, import_lib2.$EXPECT)(
|
|
|
16004
16123
|
function DecimalBigIntegerLiteral(ctx, state2) {
|
|
16005
16124
|
return (0, import_lib2.$EVENT)(ctx, state2, "DecimalBigIntegerLiteral", DecimalBigIntegerLiteral$0);
|
|
16006
16125
|
}
|
|
16007
|
-
var DecimalLiteral$0 = (0, import_lib2.$
|
|
16126
|
+
var DecimalLiteral$0 = (0, import_lib2.$TS)((0, import_lib2.$S)((0, import_lib2.$TEXT)((0, import_lib2.$EXPECT)($R36, "DecimalLiteral /(?:0|[1-9](?:_[0-9]|[0-9])*)(?=\\.(?:\\p{ID_Start}|[_$]))/")), (0, import_lib2.$N)((0, import_lib2.$S)((0, import_lib2.$EXPECT)($L7, 'DecimalLiteral "."'), ExponentPart))), function($skip, $loc, $0, $1, $2) {
|
|
16008
16127
|
return $1 + ".";
|
|
16009
16128
|
});
|
|
16010
16129
|
var DecimalLiteral$1 = (0, import_lib2.$TEXT)((0, import_lib2.$S)((0, import_lib2.$EXPECT)($R37, "DecimalLiteral /(?:0|[1-9](?:_[0-9]|[0-9])*)(?:\\.(?:[0-9](?:_[0-9]|[0-9])*))?/"), (0, import_lib2.$E)(ExponentPart)));
|
|
@@ -16643,6 +16762,12 @@ var DotDotDot$$ = [DotDotDot$0, DotDotDot$1];
|
|
|
16643
16762
|
function DotDotDot(ctx, state2) {
|
|
16644
16763
|
return (0, import_lib2.$EVENT_C)(ctx, state2, "DotDotDot", DotDotDot$$);
|
|
16645
16764
|
}
|
|
16765
|
+
var InsertDotDotDot$0 = (0, import_lib2.$TV)((0, import_lib2.$EXPECT)($L0, 'InsertDotDotDot ""'), function($skip, $loc, $0, $1) {
|
|
16766
|
+
return { $loc, token: "..." };
|
|
16767
|
+
});
|
|
16768
|
+
function InsertDotDotDot(ctx, state2) {
|
|
16769
|
+
return (0, import_lib2.$EVENT)(ctx, state2, "InsertDotDotDot", InsertDotDotDot$0);
|
|
16770
|
+
}
|
|
16646
16771
|
var DoubleColon$0 = (0, import_lib2.$TV)((0, import_lib2.$EXPECT)($L162, 'DoubleColon "::"'), function($skip, $loc, $0, $1) {
|
|
16647
16772
|
return { $loc, token: $1 };
|
|
16648
16773
|
});
|