@zwave-js/config 13.4.0 → 13.6.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.
@@ -3,1493 +3,2359 @@
3
3
  /* eslint-disable */
4
4
  // @ts-nocheck
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.parse = exports.SyntaxError = void 0;
7
- class SyntaxError extends Error {
8
- static buildMessage(expected, found) {
6
+ exports.PeggySyntaxError = exports.parse = void 0;
7
+ /* eslint-disable */
8
+ const peggyParser = // Generated by Peggy 3.0.2.
9
+
10
+ //
11
+ // https://peggyjs.org/
12
+ // @ts-ignore
13
+ (function () {
14
+ // @ts-ignore
15
+ "use strict";
16
+ // @ts-ignore
17
+ function peg$subclass(child, parent) {
18
+ // @ts-ignore
19
+ function C() {
20
+ this.constructor = child;
21
+ }
22
+ // @ts-ignore
23
+ C.prototype = parent.prototype;
24
+ // @ts-ignore
25
+ child.prototype = new C();
26
+ }
27
+ // @ts-ignore
28
+ function peg$SyntaxError(message, expected, found, location) {
29
+ // @ts-ignore
30
+ var self = Error.call(this, message);
31
+ // istanbul ignore next Check is a necessary evil to support older environments
32
+ // @ts-ignore
33
+ if (Object.setPrototypeOf) {
34
+ // @ts-ignore
35
+ Object.setPrototypeOf(self, peg$SyntaxError.prototype);
36
+ }
37
+ // @ts-ignore
38
+ self.expected = expected;
39
+ // @ts-ignore
40
+ self.found = found;
41
+ // @ts-ignore
42
+ self.location = location;
43
+ // @ts-ignore
44
+ self.name = "SyntaxError";
45
+ // @ts-ignore
46
+ return self;
47
+ }
48
+ // @ts-ignore
49
+ peg$subclass(peg$SyntaxError, Error);
50
+ // @ts-ignore
51
+ function peg$padEnd(str, targetLength, padString) {
52
+ // @ts-ignore
53
+ padString = padString || " ";
54
+ // @ts-ignore
55
+ if (str.length > targetLength)
56
+ return str;
57
+ // @ts-ignore
58
+ targetLength -= str.length;
59
+ // @ts-ignore
60
+ padString += padString.repeat(targetLength);
61
+ // @ts-ignore
62
+ return str + padString.slice(0, targetLength);
63
+ }
64
+ // @ts-ignore
65
+ peg$SyntaxError.prototype.format = function (sources) {
66
+ // @ts-ignore
67
+ var str = "Error: " + this.message;
68
+ // @ts-ignore
69
+ if (this.location) {
70
+ // @ts-ignore
71
+ var src = null;
72
+ // @ts-ignore
73
+ var k;
74
+ // @ts-ignore
75
+ for (k = 0; k < sources.length; k++) {
76
+ // @ts-ignore
77
+ if (sources[k].source === this.location.source) {
78
+ // @ts-ignore
79
+ src = sources[k].text.split(/\r\n|\n|\r/g);
80
+ // @ts-ignore
81
+ break;
82
+ }
83
+ }
84
+ // @ts-ignore
85
+ var s = this.location.start;
86
+ // @ts-ignore
87
+ var offset_s = (this.location.source
88
+ && (typeof this.location.source.offset
89
+ === "function"))
90
+ // @ts-ignore
91
+ ? this.location.source.offset(s)
92
+ // @ts-ignore
93
+ : s;
94
+ // @ts-ignore
95
+ var loc = this.location.source
96
+ + ":"
97
+ + offset_s.line
98
+ + ":"
99
+ + offset_s.column;
100
+ // @ts-ignore
101
+ if (src) {
102
+ // @ts-ignore
103
+ var e = this.location.end;
104
+ // @ts-ignore
105
+ var filler = peg$padEnd("", offset_s.line.toString().length, " ");
106
+ // @ts-ignore
107
+ var line = src[s.line - 1];
108
+ // @ts-ignore
109
+ var last = s.line === e.line ? e.column : line.length + 1;
110
+ // @ts-ignore
111
+ var hatLen = (last - s.column) || 1;
112
+ // @ts-ignore
113
+ str += "\n --> " + loc + "\n" // @ts-ignore
114
+ + filler + " |\n" // @ts-ignore
115
+ + offset_s.line + " | " + line + "\n" // @ts-ignore
116
+ + filler + " | " + peg$padEnd("", s.column - 1, " ") // @ts-ignore
117
+ + peg$padEnd("", hatLen, "^");
118
+ // @ts-ignore
119
+ }
120
+ else {
121
+ // @ts-ignore
122
+ str += "\n at " + loc;
123
+ }
124
+ }
125
+ // @ts-ignore
126
+ return str;
127
+ };
128
+ // @ts-ignore
129
+ peg$SyntaxError.buildMessage = function (expected, found) {
130
+ // @ts-ignore
131
+ var DESCRIBE_EXPECTATION_FNS = {
132
+ // @ts-ignore
133
+ literal: function (expectation) {
134
+ // @ts-ignore
135
+ return "\"" + literalEscape(expectation.text) + "\"";
136
+ },
137
+ // @ts-ignore
138
+ class: function (expectation) {
139
+ // @ts-ignore
140
+ var escapedParts = expectation.parts.map(function (part) {
141
+ // @ts-ignore
142
+ return Array.isArray(part)
143
+ // @ts-ignore
144
+ ? classEscape(part[0]) + "-" + classEscape(part[1])
145
+ // @ts-ignore
146
+ : classEscape(part);
147
+ });
148
+ // @ts-ignore
149
+ return "["
150
+ + (expectation.inverted ? "^" : "")
151
+ + escapedParts.join("")
152
+ + "]";
153
+ },
154
+ // @ts-ignore
155
+ any: function () {
156
+ // @ts-ignore
157
+ return "any character";
158
+ },
159
+ // @ts-ignore
160
+ end: function () {
161
+ // @ts-ignore
162
+ return "end of input";
163
+ },
164
+ // @ts-ignore
165
+ other: function (expectation) {
166
+ // @ts-ignore
167
+ return expectation.description;
168
+ },
169
+ };
170
+ // @ts-ignore
9
171
  function hex(ch) {
172
+ // @ts-ignore
10
173
  return ch.charCodeAt(0).toString(16).toUpperCase();
11
174
  }
175
+ // @ts-ignore
12
176
  function literalEscape(s) {
177
+ // @ts-ignore
13
178
  return s
179
+ // @ts-ignore
14
180
  .replace(/\\/g, "\\\\")
181
+ // @ts-ignore
15
182
  .replace(/"/g, "\\\"")
183
+ // @ts-ignore
16
184
  .replace(/\0/g, "\\0")
185
+ // @ts-ignore
17
186
  .replace(/\t/g, "\\t")
187
+ // @ts-ignore
18
188
  .replace(/\n/g, "\\n")
189
+ // @ts-ignore
19
190
  .replace(/\r/g, "\\r")
20
- .replace(/[\x00-\x0F]/g, (ch) => "\\x0" + hex(ch))
21
- .replace(/[\x10-\x1F\x7F-\x9F]/g, (ch) => "\\x" + hex(ch));
191
+ // @ts-ignore
192
+ .replace(/[\x00-\x0F]/g, function (ch) {
193
+ return "\\x0" + hex(ch);
194
+ })
195
+ // @ts-ignore
196
+ .replace(/[\x10-\x1F\x7F-\x9F]/g, function (ch) {
197
+ return "\\x" + hex(ch);
198
+ });
22
199
  }
200
+ // @ts-ignore
23
201
  function classEscape(s) {
202
+ // @ts-ignore
24
203
  return s
204
+ // @ts-ignore
25
205
  .replace(/\\/g, "\\\\")
206
+ // @ts-ignore
26
207
  .replace(/\]/g, "\\]")
208
+ // @ts-ignore
27
209
  .replace(/\^/g, "\\^")
210
+ // @ts-ignore
28
211
  .replace(/-/g, "\\-")
212
+ // @ts-ignore
29
213
  .replace(/\0/g, "\\0")
214
+ // @ts-ignore
30
215
  .replace(/\t/g, "\\t")
216
+ // @ts-ignore
31
217
  .replace(/\n/g, "\\n")
218
+ // @ts-ignore
32
219
  .replace(/\r/g, "\\r")
33
- .replace(/[\x00-\x0F]/g, (ch) => "\\x0" + hex(ch))
34
- .replace(/[\x10-\x1F\x7F-\x9F]/g, (ch) => "\\x" + hex(ch));
220
+ // @ts-ignore
221
+ .replace(/[\x00-\x0F]/g, function (ch) {
222
+ return "\\x0" + hex(ch);
223
+ })
224
+ // @ts-ignore
225
+ .replace(/[\x10-\x1F\x7F-\x9F]/g, function (ch) {
226
+ return "\\x" + hex(ch);
227
+ });
35
228
  }
229
+ // @ts-ignore
36
230
  function describeExpectation(expectation) {
37
- switch (expectation.type) {
38
- case "literal":
39
- return "\"" + literalEscape(expectation.text) + "\"";
40
- case "class":
41
- const escapedParts = expectation.parts.map((part) => {
42
- return Array.isArray(part)
43
- ? classEscape(part[0])
44
- + "-"
45
- + classEscape(part[1])
46
- : classEscape(part);
47
- });
48
- return "["
49
- + (expectation.inverted ? "^" : "")
50
- + escapedParts
51
- + "]";
52
- case "any":
53
- return "any character";
54
- case "end":
55
- return "end of input";
56
- case "other":
57
- return expectation.description;
58
- }
231
+ // @ts-ignore
232
+ return DESCRIBE_EXPECTATION_FNS[expectation.type](expectation);
59
233
  }
60
- function describeExpected(expected1) {
61
- const descriptions = expected1.map(describeExpectation);
62
- let i;
63
- let j;
234
+ // @ts-ignore
235
+ function describeExpected(expected) {
236
+ // @ts-ignore
237
+ var descriptions = expected.map(describeExpectation);
238
+ // @ts-ignore
239
+ var i, j;
240
+ // @ts-ignore
64
241
  descriptions.sort();
242
+ // @ts-ignore
65
243
  if (descriptions.length > 0) {
244
+ // @ts-ignore
66
245
  for (i = 1, j = 1; i < descriptions.length; i++) {
246
+ // @ts-ignore
67
247
  if (descriptions[i - 1] !== descriptions[i]) {
248
+ // @ts-ignore
68
249
  descriptions[j] = descriptions[i];
250
+ // @ts-ignore
69
251
  j++;
70
252
  }
71
253
  }
254
+ // @ts-ignore
72
255
  descriptions.length = j;
73
256
  }
257
+ // @ts-ignore
74
258
  switch (descriptions.length) {
259
+ // @ts-ignore
75
260
  case 1:
261
+ // @ts-ignore
76
262
  return descriptions[0];
263
+ // @ts-ignore
77
264
  case 2:
265
+ // @ts-ignore
78
266
  return descriptions[0] + " or " + descriptions[1];
267
+ // @ts-ignore
79
268
  default:
269
+ // @ts-ignore
80
270
  return descriptions.slice(0, -1).join(", ")
271
+ // @ts-ignore
81
272
  + ", or "
273
+ // @ts-ignore
82
274
  + descriptions[descriptions.length - 1];
83
275
  }
84
276
  }
85
- function describeFound(found1) {
86
- return found1
87
- ? "\"" + literalEscape(found1) + "\""
277
+ // @ts-ignore
278
+ function describeFound(found) {
279
+ // @ts-ignore
280
+ return found
281
+ ? "\"" + literalEscape(found) + "\""
88
282
  : "end of input";
89
283
  }
284
+ // @ts-ignore
90
285
  return "Expected "
91
286
  + describeExpected(expected)
92
287
  + " but "
93
288
  + describeFound(found)
94
289
  + " found.";
95
- }
96
- message;
97
- expected;
98
- found;
99
- location;
100
- name;
101
- constructor(message, expected, found, location) {
102
- super();
103
- this.message = message;
104
- this.expected = expected;
105
- this.found = found;
106
- this.location = location;
107
- this.name = "SyntaxError";
108
- if (typeof Error.captureStackTrace === "function") {
109
- Error.captureStackTrace(this, SyntaxError);
110
- }
111
- }
112
- }
113
- exports.SyntaxError = SyntaxError;
114
- function peg$parse(input, options) {
115
- options = options !== undefined ? options : {};
116
- const peg$FAILED = {};
117
- const peg$startRuleFunctions = {
118
- start: peg$parsestart,
119
- };
120
- let peg$startRuleFunction = peg$parsestart;
121
- const peg$c0 = peg$otherExpectation("grouped expression");
122
- const peg$c1 = "(";
123
- const peg$c2 = peg$literalExpectation("(", false);
124
- const peg$c3 = ")";
125
- const peg$c4 = peg$literalExpectation(")", false);
126
- const peg$c5 = function (group) {
127
- return group;
128
- };
129
- const peg$c6 = peg$otherExpectation("logical OR");
130
- const peg$c7 = function (head, tails) {
131
- return { or: [head, ...tails] };
132
- };
133
- const peg$c8 = "||";
134
- const peg$c9 = peg$literalExpectation("||", false);
135
- const peg$c10 = function (tail) {
136
- return tail;
137
- };
138
- const peg$c11 = peg$otherExpectation("logical AND");
139
- const peg$c12 = function (head, tails) {
140
- return { and: [head, ...tails] };
141
- };
142
- const peg$c13 = "&&";
143
- const peg$c14 = peg$literalExpectation("&&", false);
144
- const peg$c15 = peg$otherExpectation("numeric comparison");
145
- const peg$c16 = ">=";
146
- const peg$c17 = peg$literalExpectation(">=", false);
147
- const peg$c18 = ">";
148
- const peg$c19 = peg$literalExpectation(">", false);
149
- const peg$c20 = "<=";
150
- const peg$c21 = peg$literalExpectation("<=", false);
151
- const peg$c22 = "<";
152
- const peg$c23 = peg$literalExpectation("<", false);
153
- const peg$c24 = "===";
154
- const peg$c25 = peg$literalExpectation("===", false);
155
- const peg$c26 = function (head, expr, tail) {
156
- return { [expr]: [head, tail] };
157
- };
158
- const peg$c27 = peg$otherExpectation("version comparison");
159
- const peg$c28 = function (head, expr, tail) {
160
- return { ["ver " + expr]: [head, tail] };
161
290
  };
162
- const peg$c29 = peg$otherExpectation("variable");
163
- const peg$c30 = /^[a-zA-Z]/;
164
- const peg$c31 = peg$classExpectation([["a", "z"], ["A", "Z"]], false, false);
165
- const peg$c32 = /^[a-zA-Z0-9]/;
166
- const peg$c33 = peg$classExpectation([["a", "z"], ["A", "Z"], ["0", "9"]], false, false);
167
- const peg$c34 = function (variable) {
168
- return { var: variable[1].join("") };
169
- };
170
- const peg$c35 = peg$otherExpectation("number");
171
- const peg$c36 = "-";
172
- const peg$c37 = peg$literalExpectation("-", false);
173
- const peg$c38 = /^[0-9]/;
174
- const peg$c39 = peg$classExpectation([["0", "9"]], false, false);
175
- const peg$c40 = function () {
176
- return parseInt(text(), 10);
177
- };
178
- const peg$c41 = peg$otherExpectation("hex number");
179
- const peg$c42 = "0x";
180
- const peg$c43 = peg$literalExpectation("0x", false);
181
- const peg$c44 = /^[0-9a-f]/i;
182
- const peg$c45 = peg$classExpectation([["0", "9"], ["a", "f"]], false, true);
183
- const peg$c46 = function () {
184
- return parseInt(text(), 16);
185
- };
186
- const peg$c47 = peg$otherExpectation("version string");
187
- const peg$c48 = ".";
188
- const peg$c49 = peg$literalExpectation(".", false);
189
- const peg$c50 = function (version) {
190
- return text();
191
- };
192
- const peg$c51 = peg$otherExpectation("string");
193
- const peg$c52 = "\"";
194
- const peg$c53 = peg$literalExpectation("\"", false);
195
- const peg$c54 = /^[^"]/;
196
- const peg$c55 = peg$classExpectation(["\""], true, false);
197
- const peg$c56 = function () {
198
- return text();
199
- };
200
- const peg$c57 = "'";
201
- const peg$c58 = peg$literalExpectation("'", false);
202
- const peg$c59 = /^[^']/;
203
- const peg$c60 = peg$classExpectation(["'"], true, false);
204
- const peg$c61 = peg$otherExpectation("whitespace");
205
- const peg$c62 = /^[ \t\n\r]/;
206
- const peg$c63 = peg$classExpectation([" ", "\t", "\n", "\r"], false, false);
207
- let peg$currPos = 0;
208
- let peg$savedPos = 0;
209
- const peg$posDetailsCache = [{ line: 1, column: 1 }];
210
- let peg$maxFailPos = 0;
211
- let peg$maxFailExpected = [];
212
- let peg$silentFails = 0;
213
- let peg$result;
214
- if (options.startRule !== undefined) {
215
- if (!(options.startRule in peg$startRuleFunctions)) {
216
- throw new Error("Can't start parsing from rule \"" + options.startRule + "\".");
217
- }
218
- peg$startRuleFunction = peg$startRuleFunctions[options.startRule];
219
- }
220
- function text() {
221
- return input.substring(peg$savedPos, peg$currPos);
222
- }
223
- function location() {
224
- return peg$computeLocation(peg$savedPos, peg$currPos);
225
- }
226
- function expected(description, location1) {
227
- location1 = location1 !== undefined
228
- ? location1
229
- : peg$computeLocation(peg$savedPos, peg$currPos);
230
- throw peg$buildStructuredError([peg$otherExpectation(description)], input.substring(peg$savedPos, peg$currPos), location1);
231
- }
232
- function error(message, location1) {
233
- location1 = location1 !== undefined
234
- ? location1
235
- : peg$computeLocation(peg$savedPos, peg$currPos);
236
- throw peg$buildSimpleError(message, location1);
237
- }
238
- function peg$literalExpectation(text1, ignoreCase) {
239
- return { type: "literal", text: text1, ignoreCase: ignoreCase };
240
- }
241
- function peg$classExpectation(parts, inverted, ignoreCase) {
242
- return {
243
- type: "class",
244
- parts: parts,
245
- inverted: inverted,
246
- ignoreCase: ignoreCase,
291
+ // @ts-ignore
292
+ function peg$parse(input, options) {
293
+ // @ts-ignore
294
+ options = options !== undefined ? options : {};
295
+ // @ts-ignore
296
+ var peg$FAILED = {};
297
+ // @ts-ignore
298
+ var peg$source = options.grammarSource;
299
+ // @ts-ignore
300
+ var peg$startRuleFunctions = { start: peg$parsestart };
301
+ // @ts-ignore
302
+ var peg$startRuleFunction = peg$parsestart;
303
+ // @ts-ignore
304
+ var peg$c0 = "(";
305
+ var peg$c1 = ")";
306
+ var peg$c2 = "||";
307
+ var peg$c3 = "&&";
308
+ var peg$c4 = ">=";
309
+ var peg$c5 = ">";
310
+ var peg$c6 = "<=";
311
+ var peg$c7 = "<";
312
+ var peg$c8 = "===";
313
+ var peg$c9 = "-";
314
+ var peg$c10 = "0x";
315
+ var peg$c11 = ".";
316
+ var peg$c12 = "\"";
317
+ var peg$c13 = "'";
318
+ var peg$r0 = /^[a-zA-Z]/;
319
+ var peg$r1 = /^[a-zA-Z0-9]/;
320
+ var peg$r2 = /^[0-9]/;
321
+ var peg$r3 = /^[0-9a-f]/i;
322
+ var peg$r4 = /^[^"]/;
323
+ var peg$r5 = /^[^']/;
324
+ var peg$r6 = /^[ \t\n\r]/;
325
+ var peg$e0 = peg$otherExpectation("grouped expression");
326
+ var peg$e1 = peg$literalExpectation("(", false);
327
+ var peg$e2 = peg$literalExpectation(")", false);
328
+ var peg$e3 = peg$otherExpectation("logical OR");
329
+ var peg$e4 = peg$literalExpectation("||", false);
330
+ var peg$e5 = peg$otherExpectation("logical AND");
331
+ var peg$e6 = peg$literalExpectation("&&", false);
332
+ var peg$e7 = peg$otherExpectation("numeric comparison");
333
+ var peg$e8 = peg$literalExpectation(">=", false);
334
+ var peg$e9 = peg$literalExpectation(">", false);
335
+ var peg$e10 = peg$literalExpectation("<=", false);
336
+ var peg$e11 = peg$literalExpectation("<", false);
337
+ var peg$e12 = peg$literalExpectation("===", false);
338
+ var peg$e13 = peg$otherExpectation("version comparison");
339
+ var peg$e14 = peg$otherExpectation("variable");
340
+ var peg$e15 = peg$classExpectation([["a", "z"], ["A", "Z"]], false, false);
341
+ var peg$e16 = peg$classExpectation([["a", "z"], ["A", "Z"], ["0", "9"]], false, false);
342
+ var peg$e17 = peg$otherExpectation("number");
343
+ var peg$e18 = peg$literalExpectation("-", false);
344
+ var peg$e19 = peg$classExpectation([["0", "9"]], false, false);
345
+ var peg$e20 = peg$otherExpectation("hex number");
346
+ var peg$e21 = peg$literalExpectation("0x", false);
347
+ var peg$e22 = peg$classExpectation([["0", "9"], ["a", "f"]], false, true);
348
+ var peg$e23 = peg$otherExpectation("version string");
349
+ var peg$e24 = peg$literalExpectation(".", false);
350
+ var peg$e25 = peg$otherExpectation("string");
351
+ var peg$e26 = peg$literalExpectation("\"", false);
352
+ var peg$e27 = peg$classExpectation(["\""], true, false);
353
+ var peg$e28 = peg$literalExpectation("'", false);
354
+ var peg$e29 = peg$classExpectation(["'"], true, false);
355
+ var peg$e30 = peg$otherExpectation("whitespace");
356
+ var peg$e31 = peg$classExpectation([" ", "\t", "\n", "\r"], false, false);
357
+ // @ts-ignore
358
+ var peg$f0 = function (group) {
359
+ return group;
360
+ }; // @ts-ignore
361
+ var peg$f1 = function (head, tails) {
362
+ // @ts-ignore
363
+ return { or: [head, ...tails] };
364
+ }; // @ts-ignore
365
+ var peg$f2 = function (tail) {
366
+ return tail;
367
+ }; // @ts-ignore
368
+ var peg$f3 = function (head, tails) {
369
+ // @ts-ignore
370
+ return { and: [head, ...tails] };
371
+ }; // @ts-ignore
372
+ var peg$f4 = function (tail) {
373
+ return tail;
374
+ }; // @ts-ignore
375
+ var peg$f5 = function (head, expr, tail) {
376
+ // @ts-ignore
377
+ return { [expr]: [head, tail] };
378
+ }; // @ts-ignore
379
+ var peg$f6 = function (head, expr, tail) {
380
+ // @ts-ignore
381
+ return { ["ver " + expr]: [head, tail] };
382
+ }; // @ts-ignore
383
+ var peg$f7 = function (variable) {
384
+ return { var: variable[1].join("") };
385
+ }; // @ts-ignore
386
+ var peg$f8 = function () {
387
+ return parseInt(text(), 10);
388
+ }; // @ts-ignore
389
+ var peg$f9 = function () {
390
+ return parseInt(text(), 16);
391
+ }; // @ts-ignore
392
+ var peg$f10 = function (version) {
393
+ return text();
394
+ }; // @ts-ignore
395
+ var peg$f11 = function () {
396
+ return text();
397
+ }; // @ts-ignore
398
+ var peg$f12 = function () {
399
+ return text();
247
400
  };
248
- }
249
- function peg$anyExpectation() {
250
- return { type: "any" };
251
- }
252
- function peg$endExpectation() {
253
- return { type: "end" };
254
- }
255
- function peg$otherExpectation(description) {
256
- return { type: "other", description: description };
257
- }
258
- function peg$computePosDetails(pos) {
259
- let details = peg$posDetailsCache[pos];
260
- let p;
261
- if (details) {
262
- return details;
401
+ // @ts-ignore
402
+ var peg$currPos = 0;
403
+ // @ts-ignore
404
+ var peg$savedPos = 0;
405
+ // @ts-ignore
406
+ var peg$posDetailsCache = [{ line: 1, column: 1 }];
407
+ // @ts-ignore
408
+ var peg$maxFailPos = 0;
409
+ // @ts-ignore
410
+ var peg$maxFailExpected = [];
411
+ // @ts-ignore
412
+ var peg$silentFails = 0;
413
+ // @ts-ignore
414
+ var peg$result;
415
+ // @ts-ignore
416
+ if ("startRule" in options) {
417
+ // @ts-ignore
418
+ if (!(options.startRule in peg$startRuleFunctions)) {
419
+ // @ts-ignore
420
+ throw new Error("Can't start parsing from rule \""
421
+ + options.startRule
422
+ + "\".");
423
+ }
424
+ // @ts-ignore
425
+ peg$startRuleFunction =
426
+ peg$startRuleFunctions[options.startRule];
263
427
  }
264
- else {
265
- p = pos - 1;
266
- while (!peg$posDetailsCache[p]) {
267
- p--;
268
- }
269
- details = peg$posDetailsCache[p];
270
- details = {
271
- line: details.line,
272
- column: details.column,
428
+ // @ts-ignore
429
+ function text() {
430
+ // @ts-ignore
431
+ return input.substring(peg$savedPos, peg$currPos);
432
+ }
433
+ // @ts-ignore
434
+ function offset() {
435
+ // @ts-ignore
436
+ return peg$savedPos;
437
+ }
438
+ // @ts-ignore
439
+ function range() {
440
+ // @ts-ignore
441
+ return {
442
+ // @ts-ignore
443
+ source: peg$source,
444
+ // @ts-ignore
445
+ start: peg$savedPos,
446
+ // @ts-ignore
447
+ end: peg$currPos,
448
+ };
449
+ }
450
+ // @ts-ignore
451
+ function location() {
452
+ // @ts-ignore
453
+ return peg$computeLocation(peg$savedPos, peg$currPos);
454
+ }
455
+ // @ts-ignore
456
+ function expected(description, location) {
457
+ // @ts-ignore
458
+ location = location !== undefined
459
+ // @ts-ignore
460
+ ? location
461
+ // @ts-ignore
462
+ : peg$computeLocation(peg$savedPos, peg$currPos);
463
+ // @ts-ignore
464
+ throw peg$buildStructuredError(
465
+ // @ts-ignore
466
+ [peg$otherExpectation(description)],
467
+ // @ts-ignore
468
+ input.substring(peg$savedPos, peg$currPos),
469
+ // @ts-ignore
470
+ location);
471
+ }
472
+ // @ts-ignore
473
+ function error(message, location) {
474
+ // @ts-ignore
475
+ location = location !== undefined
476
+ // @ts-ignore
477
+ ? location
478
+ // @ts-ignore
479
+ : peg$computeLocation(peg$savedPos, peg$currPos);
480
+ // @ts-ignore
481
+ throw peg$buildSimpleError(message, location);
482
+ }
483
+ // @ts-ignore
484
+ function peg$literalExpectation(text, ignoreCase) {
485
+ // @ts-ignore
486
+ return { type: "literal", text: text, ignoreCase: ignoreCase };
487
+ }
488
+ // @ts-ignore
489
+ function peg$classExpectation(parts, inverted, ignoreCase) {
490
+ // @ts-ignore
491
+ return {
492
+ type: "class",
493
+ parts: parts,
494
+ inverted: inverted,
495
+ ignoreCase: ignoreCase,
273
496
  };
274
- while (p < pos) {
275
- if (input.charCodeAt(p) === 10) {
276
- details.line++;
277
- details.column = 1;
497
+ }
498
+ // @ts-ignore
499
+ function peg$anyExpectation() {
500
+ // @ts-ignore
501
+ return { type: "any" };
502
+ }
503
+ // @ts-ignore
504
+ function peg$endExpectation() {
505
+ // @ts-ignore
506
+ return { type: "end" };
507
+ }
508
+ // @ts-ignore
509
+ function peg$otherExpectation(description) {
510
+ // @ts-ignore
511
+ return { type: "other", description: description };
512
+ }
513
+ // @ts-ignore
514
+ function peg$computePosDetails(pos) {
515
+ // @ts-ignore
516
+ var details = peg$posDetailsCache[pos];
517
+ // @ts-ignore
518
+ var p;
519
+ // @ts-ignore
520
+ if (details) {
521
+ // @ts-ignore
522
+ return details;
523
+ // @ts-ignore
524
+ }
525
+ else {
526
+ // @ts-ignore
527
+ p = pos - 1;
528
+ // @ts-ignore
529
+ while (!peg$posDetailsCache[p]) {
530
+ // @ts-ignore
531
+ p--;
278
532
  }
279
- else {
280
- details.column++;
533
+ // @ts-ignore
534
+ details = peg$posDetailsCache[p];
535
+ // @ts-ignore
536
+ details = {
537
+ // @ts-ignore
538
+ line: details.line,
539
+ // @ts-ignore
540
+ column: details.column,
541
+ };
542
+ // @ts-ignore
543
+ while (p < pos) {
544
+ // @ts-ignore
545
+ if (input.charCodeAt(p) === 10) {
546
+ // @ts-ignore
547
+ details.line++;
548
+ // @ts-ignore
549
+ details.column = 1;
550
+ // @ts-ignore
551
+ }
552
+ else {
553
+ // @ts-ignore
554
+ details.column++;
555
+ }
556
+ // @ts-ignore
557
+ p++;
281
558
  }
282
- p++;
559
+ // @ts-ignore
560
+ peg$posDetailsCache[pos] = details;
561
+ // @ts-ignore
562
+ return details;
283
563
  }
284
- peg$posDetailsCache[pos] = details;
285
- return details;
286
564
  }
287
- }
288
- function peg$computeLocation(startPos, endPos) {
289
- const startPosDetails = peg$computePosDetails(startPos);
290
- const endPosDetails = peg$computePosDetails(endPos);
291
- return {
292
- start: {
293
- offset: startPos,
294
- line: startPosDetails.line,
295
- column: startPosDetails.column,
296
- },
297
- end: {
298
- offset: endPos,
299
- line: endPosDetails.line,
300
- column: endPosDetails.column,
301
- },
302
- };
303
- }
304
- function peg$fail(expected1) {
305
- if (peg$currPos < peg$maxFailPos)
306
- return;
307
- if (peg$currPos > peg$maxFailPos) {
308
- peg$maxFailPos = peg$currPos;
309
- peg$maxFailExpected = [];
565
+ // @ts-ignore
566
+ function peg$computeLocation(startPos, endPos, offset) {
567
+ // @ts-ignore
568
+ var startPosDetails = peg$computePosDetails(startPos);
569
+ // @ts-ignore
570
+ var endPosDetails = peg$computePosDetails(endPos);
571
+ // @ts-ignore
572
+ var res = {
573
+ // @ts-ignore
574
+ source: peg$source,
575
+ // @ts-ignore
576
+ start: {
577
+ // @ts-ignore
578
+ offset: startPos,
579
+ // @ts-ignore
580
+ line: startPosDetails.line,
581
+ // @ts-ignore
582
+ column: startPosDetails.column,
583
+ },
584
+ // @ts-ignore
585
+ end: {
586
+ // @ts-ignore
587
+ offset: endPos,
588
+ // @ts-ignore
589
+ line: endPosDetails.line,
590
+ // @ts-ignore
591
+ column: endPosDetails.column,
592
+ },
593
+ };
594
+ // @ts-ignore
595
+ if (offset
596
+ && peg$source
597
+ && (typeof peg$source.offset === "function")) {
598
+ // @ts-ignore
599
+ res.start = peg$source.offset(res.start);
600
+ // @ts-ignore
601
+ res.end = peg$source.offset(res.end);
602
+ }
603
+ // @ts-ignore
604
+ return res;
310
605
  }
311
- peg$maxFailExpected.push(expected1);
312
- }
313
- function peg$buildSimpleError(message, location1) {
314
- return new SyntaxError(message, [], "", location1);
315
- }
316
- function peg$buildStructuredError(expected1, found, location1) {
317
- return new SyntaxError(SyntaxError.buildMessage(expected1, found), expected1, found, location1);
318
- }
319
- function peg$parsestart() {
320
- let s0;
321
- s0 = peg$parsegroup();
322
- if (s0 === peg$FAILED) {
323
- s0 = peg$parseor();
606
+ // @ts-ignore
607
+ function peg$fail(expected) {
608
+ // @ts-ignore
609
+ if (peg$currPos < peg$maxFailPos)
610
+ return;
611
+ // @ts-ignore
612
+ if (peg$currPos > peg$maxFailPos) {
613
+ // @ts-ignore
614
+ peg$maxFailPos = peg$currPos;
615
+ // @ts-ignore
616
+ peg$maxFailExpected = [];
617
+ }
618
+ // @ts-ignore
619
+ peg$maxFailExpected.push(expected);
620
+ }
621
+ // @ts-ignore
622
+ function peg$buildSimpleError(message, location) {
623
+ // @ts-ignore
624
+ return new peg$SyntaxError(message, null, null, location);
625
+ }
626
+ // @ts-ignore
627
+ function peg$buildStructuredError(expected, found, location) {
628
+ // @ts-ignore
629
+ return new peg$SyntaxError(
630
+ // @ts-ignore
631
+ peg$SyntaxError.buildMessage(expected, found),
632
+ // @ts-ignore
633
+ expected,
634
+ // @ts-ignore
635
+ found,
636
+ // @ts-ignore
637
+ location);
638
+ }
639
+ // @ts-ignore
640
+ function peg$parsestart() {
641
+ // @ts-ignore
642
+ var s0;
643
+ // @ts-ignore
644
+ s0 = peg$parsegroup();
645
+ // @ts-ignore
324
646
  if (s0 === peg$FAILED) {
325
- s0 = peg$parseand();
647
+ // @ts-ignore
648
+ s0 = peg$parseor();
649
+ // @ts-ignore
326
650
  if (s0 === peg$FAILED) {
327
- s0 = peg$parsecomparison();
651
+ // @ts-ignore
652
+ s0 = peg$parseand();
653
+ // @ts-ignore
654
+ if (s0 === peg$FAILED) {
655
+ // @ts-ignore
656
+ s0 = peg$parsecomparison();
657
+ }
328
658
  }
329
659
  }
660
+ // @ts-ignore
661
+ return s0;
330
662
  }
331
- return s0;
332
- }
333
- function peg$parsegroup() {
334
- let s0, s1, s2, s3, s4, s5, s6;
335
- peg$silentFails++;
336
- s0 = peg$currPos;
337
- s1 = peg$parse_();
338
- if (s1 !== peg$FAILED) {
663
+ // @ts-ignore
664
+ function peg$parsegroup() {
665
+ // @ts-ignore
666
+ var s0, s1, s2, s3, s4, s5, s6;
667
+ // @ts-ignore
668
+ peg$silentFails++;
669
+ // @ts-ignore
670
+ s0 = peg$currPos;
671
+ // @ts-ignore
672
+ s1 = peg$parse_();
673
+ // @ts-ignore
339
674
  if (input.charCodeAt(peg$currPos) === 40) {
340
- s2 = peg$c1;
675
+ // @ts-ignore
676
+ s2 = peg$c0;
677
+ // @ts-ignore
341
678
  peg$currPos++;
679
+ // @ts-ignore
342
680
  }
343
681
  else {
682
+ // @ts-ignore
344
683
  s2 = peg$FAILED;
684
+ // @ts-ignore
345
685
  if (peg$silentFails === 0)
346
- peg$fail(peg$c2);
686
+ peg$fail(peg$e1);
347
687
  }
688
+ // @ts-ignore
348
689
  if (s2 !== peg$FAILED) {
690
+ // @ts-ignore
349
691
  s3 = peg$parse_();
350
- if (s3 !== peg$FAILED) {
351
- s4 = peg$parseor();
352
- if (s4 !== peg$FAILED) {
353
- s5 = peg$parse_();
354
- if (s5 !== peg$FAILED) {
355
- if (input.charCodeAt(peg$currPos) === 41) {
356
- s6 = peg$c3;
357
- peg$currPos++;
358
- }
359
- else {
360
- s6 = peg$FAILED;
361
- if (peg$silentFails === 0)
362
- peg$fail(peg$c4);
363
- }
364
- if (s6 !== peg$FAILED) {
365
- peg$savedPos = s0;
366
- s1 = peg$c5(s4);
367
- s0 = s1;
368
- }
369
- else {
370
- peg$currPos = s0;
371
- s0 = peg$FAILED;
372
- }
373
- }
374
- else {
375
- peg$currPos = s0;
376
- s0 = peg$FAILED;
377
- }
692
+ // @ts-ignore
693
+ s4 = peg$parseor();
694
+ // @ts-ignore
695
+ if (s4 !== peg$FAILED) {
696
+ // @ts-ignore
697
+ s5 = peg$parse_();
698
+ // @ts-ignore
699
+ if (input.charCodeAt(peg$currPos) === 41) {
700
+ // @ts-ignore
701
+ s6 = peg$c1;
702
+ // @ts-ignore
703
+ peg$currPos++;
704
+ // @ts-ignore
705
+ }
706
+ else {
707
+ // @ts-ignore
708
+ s6 = peg$FAILED;
709
+ // @ts-ignore
710
+ if (peg$silentFails === 0)
711
+ peg$fail(peg$e2);
712
+ }
713
+ // @ts-ignore
714
+ if (s6 !== peg$FAILED) {
715
+ // @ts-ignore
716
+ peg$savedPos = s0;
717
+ // @ts-ignore
718
+ s0 = peg$f0(s4);
719
+ // @ts-ignore
378
720
  }
379
721
  else {
722
+ // @ts-ignore
380
723
  peg$currPos = s0;
724
+ // @ts-ignore
381
725
  s0 = peg$FAILED;
382
726
  }
727
+ // @ts-ignore
383
728
  }
384
729
  else {
730
+ // @ts-ignore
385
731
  peg$currPos = s0;
732
+ // @ts-ignore
386
733
  s0 = peg$FAILED;
387
734
  }
735
+ // @ts-ignore
388
736
  }
389
737
  else {
738
+ // @ts-ignore
390
739
  peg$currPos = s0;
740
+ // @ts-ignore
391
741
  s0 = peg$FAILED;
392
742
  }
743
+ // @ts-ignore
744
+ peg$silentFails--;
745
+ // @ts-ignore
746
+ if (s0 === peg$FAILED) {
747
+ // @ts-ignore
748
+ s1 = peg$FAILED;
749
+ // @ts-ignore
750
+ if (peg$silentFails === 0)
751
+ peg$fail(peg$e0);
752
+ }
753
+ // @ts-ignore
754
+ return s0;
393
755
  }
394
- else {
395
- peg$currPos = s0;
396
- s0 = peg$FAILED;
397
- }
398
- peg$silentFails--;
399
- if (s0 === peg$FAILED) {
400
- s1 = peg$FAILED;
401
- if (peg$silentFails === 0)
402
- peg$fail(peg$c0);
403
- }
404
- return s0;
405
- }
406
- function peg$parseor() {
407
- let s0, s1, s2, s3, s4;
408
- peg$silentFails++;
409
- s0 = peg$currPos;
410
- s1 = peg$parse_();
411
- if (s1 !== peg$FAILED) {
756
+ // @ts-ignore
757
+ function peg$parseor() {
758
+ // @ts-ignore
759
+ var s0, s1, s2, s3, s4;
760
+ // @ts-ignore
761
+ peg$silentFails++;
762
+ // @ts-ignore
763
+ s0 = peg$currPos;
764
+ // @ts-ignore
765
+ s1 = peg$parse_();
766
+ // @ts-ignore
412
767
  s2 = peg$parseand();
768
+ // @ts-ignore
413
769
  if (s2 === peg$FAILED) {
770
+ // @ts-ignore
414
771
  s2 = peg$parsecomparison();
415
772
  }
773
+ // @ts-ignore
416
774
  if (s2 !== peg$FAILED) {
775
+ // @ts-ignore
417
776
  s3 = [];
777
+ // @ts-ignore
418
778
  s4 = peg$parseor_tails();
779
+ // @ts-ignore
419
780
  if (s4 !== peg$FAILED) {
781
+ // @ts-ignore
420
782
  while (s4 !== peg$FAILED) {
783
+ // @ts-ignore
421
784
  s3.push(s4);
785
+ // @ts-ignore
422
786
  s4 = peg$parseor_tails();
423
787
  }
788
+ // @ts-ignore
424
789
  }
425
790
  else {
791
+ // @ts-ignore
426
792
  s3 = peg$FAILED;
427
793
  }
794
+ // @ts-ignore
428
795
  if (s3 !== peg$FAILED) {
796
+ // @ts-ignore
429
797
  peg$savedPos = s0;
430
- s1 = peg$c7(s2, s3);
431
- s0 = s1;
798
+ // @ts-ignore
799
+ s0 = peg$f1(s2, s3);
800
+ // @ts-ignore
432
801
  }
433
802
  else {
803
+ // @ts-ignore
434
804
  peg$currPos = s0;
805
+ // @ts-ignore
435
806
  s0 = peg$FAILED;
436
807
  }
808
+ // @ts-ignore
437
809
  }
438
810
  else {
811
+ // @ts-ignore
439
812
  peg$currPos = s0;
813
+ // @ts-ignore
440
814
  s0 = peg$FAILED;
441
815
  }
816
+ // @ts-ignore
817
+ peg$silentFails--;
818
+ // @ts-ignore
819
+ if (s0 === peg$FAILED) {
820
+ // @ts-ignore
821
+ s1 = peg$FAILED;
822
+ // @ts-ignore
823
+ if (peg$silentFails === 0)
824
+ peg$fail(peg$e3);
825
+ }
826
+ // @ts-ignore
827
+ return s0;
442
828
  }
443
- else {
444
- peg$currPos = s0;
445
- s0 = peg$FAILED;
446
- }
447
- peg$silentFails--;
448
- if (s0 === peg$FAILED) {
449
- s1 = peg$FAILED;
450
- if (peg$silentFails === 0)
451
- peg$fail(peg$c6);
452
- }
453
- return s0;
454
- }
455
- function peg$parseor_tails() {
456
- let s0, s1, s2, s3, s4;
457
- s0 = peg$currPos;
458
- s1 = peg$parse_();
459
- if (s1 !== peg$FAILED) {
460
- if (input.substr(peg$currPos, 2) === peg$c8) {
461
- s2 = peg$c8;
829
+ // @ts-ignore
830
+ function peg$parseor_tails() {
831
+ // @ts-ignore
832
+ var s0, s1, s2, s3, s4;
833
+ // @ts-ignore
834
+ s0 = peg$currPos;
835
+ // @ts-ignore
836
+ s1 = peg$parse_();
837
+ // @ts-ignore
838
+ if (input.substr(peg$currPos, 2) === peg$c2) {
839
+ // @ts-ignore
840
+ s2 = peg$c2;
841
+ // @ts-ignore
462
842
  peg$currPos += 2;
843
+ // @ts-ignore
463
844
  }
464
845
  else {
846
+ // @ts-ignore
465
847
  s2 = peg$FAILED;
848
+ // @ts-ignore
466
849
  if (peg$silentFails === 0)
467
- peg$fail(peg$c9);
850
+ peg$fail(peg$e4);
468
851
  }
852
+ // @ts-ignore
469
853
  if (s2 !== peg$FAILED) {
854
+ // @ts-ignore
470
855
  s3 = peg$parse_();
471
- if (s3 !== peg$FAILED) {
472
- s4 = peg$parseand();
473
- if (s4 === peg$FAILED) {
474
- s4 = peg$parsecomparison();
475
- }
476
- if (s4 !== peg$FAILED) {
477
- peg$savedPos = s0;
478
- s1 = peg$c10(s4);
479
- s0 = s1;
480
- }
481
- else {
482
- peg$currPos = s0;
483
- s0 = peg$FAILED;
484
- }
856
+ // @ts-ignore
857
+ s4 = peg$parseand();
858
+ // @ts-ignore
859
+ if (s4 === peg$FAILED) {
860
+ // @ts-ignore
861
+ s4 = peg$parsecomparison();
862
+ }
863
+ // @ts-ignore
864
+ if (s4 !== peg$FAILED) {
865
+ // @ts-ignore
866
+ peg$savedPos = s0;
867
+ // @ts-ignore
868
+ s0 = peg$f2(s4);
869
+ // @ts-ignore
485
870
  }
486
871
  else {
872
+ // @ts-ignore
487
873
  peg$currPos = s0;
874
+ // @ts-ignore
488
875
  s0 = peg$FAILED;
489
876
  }
877
+ // @ts-ignore
490
878
  }
491
879
  else {
880
+ // @ts-ignore
492
881
  peg$currPos = s0;
882
+ // @ts-ignore
493
883
  s0 = peg$FAILED;
494
884
  }
885
+ // @ts-ignore
886
+ return s0;
495
887
  }
496
- else {
497
- peg$currPos = s0;
498
- s0 = peg$FAILED;
499
- }
500
- return s0;
501
- }
502
- function peg$parseand() {
503
- let s0, s1, s2, s3, s4;
504
- peg$silentFails++;
505
- s0 = peg$currPos;
506
- s1 = peg$parse_();
507
- if (s1 !== peg$FAILED) {
888
+ // @ts-ignore
889
+ function peg$parseand() {
890
+ // @ts-ignore
891
+ var s0, s1, s2, s3, s4;
892
+ // @ts-ignore
893
+ peg$silentFails++;
894
+ // @ts-ignore
895
+ s0 = peg$currPos;
896
+ // @ts-ignore
897
+ s1 = peg$parse_();
898
+ // @ts-ignore
508
899
  s2 = peg$parsegroup();
900
+ // @ts-ignore
509
901
  if (s2 === peg$FAILED) {
902
+ // @ts-ignore
510
903
  s2 = peg$parsecomparison();
511
904
  }
905
+ // @ts-ignore
512
906
  if (s2 !== peg$FAILED) {
907
+ // @ts-ignore
513
908
  s3 = [];
909
+ // @ts-ignore
514
910
  s4 = peg$parseand_tails();
911
+ // @ts-ignore
515
912
  if (s4 !== peg$FAILED) {
913
+ // @ts-ignore
516
914
  while (s4 !== peg$FAILED) {
915
+ // @ts-ignore
517
916
  s3.push(s4);
917
+ // @ts-ignore
518
918
  s4 = peg$parseand_tails();
519
919
  }
920
+ // @ts-ignore
520
921
  }
521
922
  else {
923
+ // @ts-ignore
522
924
  s3 = peg$FAILED;
523
925
  }
926
+ // @ts-ignore
524
927
  if (s3 !== peg$FAILED) {
928
+ // @ts-ignore
525
929
  peg$savedPos = s0;
526
- s1 = peg$c12(s2, s3);
527
- s0 = s1;
930
+ // @ts-ignore
931
+ s0 = peg$f3(s2, s3);
932
+ // @ts-ignore
528
933
  }
529
934
  else {
935
+ // @ts-ignore
530
936
  peg$currPos = s0;
937
+ // @ts-ignore
531
938
  s0 = peg$FAILED;
532
939
  }
940
+ // @ts-ignore
533
941
  }
534
942
  else {
943
+ // @ts-ignore
535
944
  peg$currPos = s0;
945
+ // @ts-ignore
536
946
  s0 = peg$FAILED;
537
947
  }
948
+ // @ts-ignore
949
+ peg$silentFails--;
950
+ // @ts-ignore
951
+ if (s0 === peg$FAILED) {
952
+ // @ts-ignore
953
+ s1 = peg$FAILED;
954
+ // @ts-ignore
955
+ if (peg$silentFails === 0)
956
+ peg$fail(peg$e5);
957
+ }
958
+ // @ts-ignore
959
+ return s0;
538
960
  }
539
- else {
540
- peg$currPos = s0;
541
- s0 = peg$FAILED;
542
- }
543
- peg$silentFails--;
544
- if (s0 === peg$FAILED) {
545
- s1 = peg$FAILED;
546
- if (peg$silentFails === 0)
547
- peg$fail(peg$c11);
548
- }
549
- return s0;
550
- }
551
- function peg$parseand_tails() {
552
- let s0, s1, s2, s3, s4;
553
- s0 = peg$currPos;
554
- s1 = peg$parse_();
555
- if (s1 !== peg$FAILED) {
556
- if (input.substr(peg$currPos, 2) === peg$c13) {
557
- s2 = peg$c13;
961
+ // @ts-ignore
962
+ function peg$parseand_tails() {
963
+ // @ts-ignore
964
+ var s0, s1, s2, s3, s4;
965
+ // @ts-ignore
966
+ s0 = peg$currPos;
967
+ // @ts-ignore
968
+ s1 = peg$parse_();
969
+ // @ts-ignore
970
+ if (input.substr(peg$currPos, 2) === peg$c3) {
971
+ // @ts-ignore
972
+ s2 = peg$c3;
973
+ // @ts-ignore
558
974
  peg$currPos += 2;
975
+ // @ts-ignore
559
976
  }
560
977
  else {
978
+ // @ts-ignore
561
979
  s2 = peg$FAILED;
980
+ // @ts-ignore
562
981
  if (peg$silentFails === 0)
563
- peg$fail(peg$c14);
982
+ peg$fail(peg$e6);
564
983
  }
984
+ // @ts-ignore
565
985
  if (s2 !== peg$FAILED) {
986
+ // @ts-ignore
566
987
  s3 = peg$parse_();
567
- if (s3 !== peg$FAILED) {
568
- s4 = peg$parsegroup();
569
- if (s4 === peg$FAILED) {
570
- s4 = peg$parsecomparison();
571
- }
572
- if (s4 !== peg$FAILED) {
573
- peg$savedPos = s0;
574
- s1 = peg$c10(s4);
575
- s0 = s1;
576
- }
577
- else {
578
- peg$currPos = s0;
579
- s0 = peg$FAILED;
580
- }
988
+ // @ts-ignore
989
+ s4 = peg$parsegroup();
990
+ // @ts-ignore
991
+ if (s4 === peg$FAILED) {
992
+ // @ts-ignore
993
+ s4 = peg$parsecomparison();
994
+ }
995
+ // @ts-ignore
996
+ if (s4 !== peg$FAILED) {
997
+ // @ts-ignore
998
+ peg$savedPos = s0;
999
+ // @ts-ignore
1000
+ s0 = peg$f4(s4);
1001
+ // @ts-ignore
581
1002
  }
582
1003
  else {
1004
+ // @ts-ignore
583
1005
  peg$currPos = s0;
1006
+ // @ts-ignore
584
1007
  s0 = peg$FAILED;
585
1008
  }
1009
+ // @ts-ignore
586
1010
  }
587
1011
  else {
1012
+ // @ts-ignore
588
1013
  peg$currPos = s0;
1014
+ // @ts-ignore
589
1015
  s0 = peg$FAILED;
590
1016
  }
1017
+ // @ts-ignore
1018
+ return s0;
591
1019
  }
592
- else {
593
- peg$currPos = s0;
594
- s0 = peg$FAILED;
595
- }
596
- return s0;
597
- }
598
- function peg$parsecomparison() {
599
- let s0;
600
- s0 = peg$parsever_comparison();
601
- if (s0 === peg$FAILED) {
602
- s0 = peg$parseint_comparison();
1020
+ // @ts-ignore
1021
+ function peg$parsecomparison() {
1022
+ // @ts-ignore
1023
+ var s0;
1024
+ // @ts-ignore
1025
+ s0 = peg$parsever_comparison();
1026
+ // @ts-ignore
1027
+ if (s0 === peg$FAILED) {
1028
+ // @ts-ignore
1029
+ s0 = peg$parseint_comparison();
1030
+ }
1031
+ // @ts-ignore
1032
+ return s0;
603
1033
  }
604
- return s0;
605
- }
606
- function peg$parseint_comparison() {
607
- let s0, s1, s2, s3, s4, s5, s6, s7;
608
- peg$silentFails++;
609
- s0 = peg$currPos;
610
- s1 = peg$parse_();
611
- if (s1 !== peg$FAILED) {
1034
+ // @ts-ignore
1035
+ function peg$parseint_comparison() {
1036
+ // @ts-ignore
1037
+ var s0, s1, s2, s3, s4, s5, s6, s7;
1038
+ // @ts-ignore
1039
+ peg$silentFails++;
1040
+ // @ts-ignore
1041
+ s0 = peg$currPos;
1042
+ // @ts-ignore
1043
+ s1 = peg$parse_();
1044
+ // @ts-ignore
612
1045
  s2 = peg$parseterm();
1046
+ // @ts-ignore
613
1047
  if (s2 !== peg$FAILED) {
1048
+ // @ts-ignore
614
1049
  s3 = peg$parse_();
615
- if (s3 !== peg$FAILED) {
616
- if (input.substr(peg$currPos, 2) === peg$c16) {
617
- s4 = peg$c16;
618
- peg$currPos += 2;
1050
+ // @ts-ignore
1051
+ if (input.substr(peg$currPos, 2) === peg$c4) {
1052
+ // @ts-ignore
1053
+ s4 = peg$c4;
1054
+ // @ts-ignore
1055
+ peg$currPos += 2;
1056
+ // @ts-ignore
1057
+ }
1058
+ else {
1059
+ // @ts-ignore
1060
+ s4 = peg$FAILED;
1061
+ // @ts-ignore
1062
+ if (peg$silentFails === 0)
1063
+ peg$fail(peg$e8);
1064
+ }
1065
+ // @ts-ignore
1066
+ if (s4 === peg$FAILED) {
1067
+ // @ts-ignore
1068
+ if (input.charCodeAt(peg$currPos) === 62) {
1069
+ // @ts-ignore
1070
+ s4 = peg$c5;
1071
+ // @ts-ignore
1072
+ peg$currPos++;
1073
+ // @ts-ignore
619
1074
  }
620
1075
  else {
1076
+ // @ts-ignore
621
1077
  s4 = peg$FAILED;
1078
+ // @ts-ignore
622
1079
  if (peg$silentFails === 0)
623
- peg$fail(peg$c17);
1080
+ peg$fail(peg$e9);
624
1081
  }
1082
+ // @ts-ignore
625
1083
  if (s4 === peg$FAILED) {
626
- if (input.charCodeAt(peg$currPos) === 62) {
627
- s4 = peg$c18;
628
- peg$currPos++;
1084
+ // @ts-ignore
1085
+ if (input.substr(peg$currPos, 2) === peg$c6) {
1086
+ // @ts-ignore
1087
+ s4 = peg$c6;
1088
+ // @ts-ignore
1089
+ peg$currPos += 2;
1090
+ // @ts-ignore
629
1091
  }
630
1092
  else {
1093
+ // @ts-ignore
631
1094
  s4 = peg$FAILED;
1095
+ // @ts-ignore
632
1096
  if (peg$silentFails === 0)
633
- peg$fail(peg$c19);
1097
+ peg$fail(peg$e10);
634
1098
  }
1099
+ // @ts-ignore
635
1100
  if (s4 === peg$FAILED) {
636
- if (input.substr(peg$currPos, 2) === peg$c20) {
637
- s4 = peg$c20;
638
- peg$currPos += 2;
1101
+ // @ts-ignore
1102
+ if (input.charCodeAt(peg$currPos) === 60) {
1103
+ // @ts-ignore
1104
+ s4 = peg$c7;
1105
+ // @ts-ignore
1106
+ peg$currPos++;
1107
+ // @ts-ignore
639
1108
  }
640
1109
  else {
1110
+ // @ts-ignore
641
1111
  s4 = peg$FAILED;
642
- if (peg$silentFails === 0)
643
- peg$fail(peg$c21);
1112
+ // @ts-ignore
1113
+ if (peg$silentFails === 0) {
1114
+ peg$fail(peg$e11);
1115
+ }
644
1116
  }
1117
+ // @ts-ignore
645
1118
  if (s4 === peg$FAILED) {
646
- if (input.charCodeAt(peg$currPos) === 60) {
647
- s4 = peg$c22;
648
- peg$currPos++;
1119
+ // @ts-ignore
1120
+ if (input.substr(peg$currPos, 3) === peg$c8) {
1121
+ // @ts-ignore
1122
+ s4 = peg$c8;
1123
+ // @ts-ignore
1124
+ peg$currPos += 3;
1125
+ // @ts-ignore
649
1126
  }
650
1127
  else {
1128
+ // @ts-ignore
651
1129
  s4 = peg$FAILED;
1130
+ // @ts-ignore
652
1131
  if (peg$silentFails === 0) {
653
- peg$fail(peg$c23);
654
- }
655
- }
656
- if (s4 === peg$FAILED) {
657
- if (input.substr(peg$currPos, 3) === peg$c24) {
658
- s4 = peg$c24;
659
- peg$currPos += 3;
660
- }
661
- else {
662
- s4 = peg$FAILED;
663
- if (peg$silentFails === 0) {
664
- peg$fail(peg$c25);
665
- }
1132
+ peg$fail(peg$e12);
666
1133
  }
667
1134
  }
668
1135
  }
669
1136
  }
670
1137
  }
671
- if (s4 !== peg$FAILED) {
672
- s5 = peg$parse_();
673
- if (s5 !== peg$FAILED) {
674
- s6 = peg$parseterm();
675
- if (s6 !== peg$FAILED) {
676
- s7 = peg$parse_();
677
- if (s7 !== peg$FAILED) {
678
- peg$savedPos = s0;
679
- s1 = peg$c26(s2, s4, s6);
680
- s0 = s1;
681
- }
682
- else {
683
- peg$currPos = s0;
684
- s0 = peg$FAILED;
685
- }
686
- }
687
- else {
688
- peg$currPos = s0;
689
- s0 = peg$FAILED;
690
- }
691
- }
692
- else {
693
- peg$currPos = s0;
694
- s0 = peg$FAILED;
695
- }
1138
+ }
1139
+ // @ts-ignore
1140
+ if (s4 !== peg$FAILED) {
1141
+ // @ts-ignore
1142
+ s5 = peg$parse_();
1143
+ // @ts-ignore
1144
+ s6 = peg$parseterm();
1145
+ // @ts-ignore
1146
+ if (s6 !== peg$FAILED) {
1147
+ // @ts-ignore
1148
+ s7 = peg$parse_();
1149
+ // @ts-ignore
1150
+ peg$savedPos = s0;
1151
+ // @ts-ignore
1152
+ s0 = peg$f5(s2, s4, s6);
1153
+ // @ts-ignore
696
1154
  }
697
1155
  else {
1156
+ // @ts-ignore
698
1157
  peg$currPos = s0;
1158
+ // @ts-ignore
699
1159
  s0 = peg$FAILED;
700
1160
  }
1161
+ // @ts-ignore
701
1162
  }
702
1163
  else {
1164
+ // @ts-ignore
703
1165
  peg$currPos = s0;
1166
+ // @ts-ignore
704
1167
  s0 = peg$FAILED;
705
1168
  }
1169
+ // @ts-ignore
706
1170
  }
707
1171
  else {
1172
+ // @ts-ignore
708
1173
  peg$currPos = s0;
1174
+ // @ts-ignore
709
1175
  s0 = peg$FAILED;
710
1176
  }
1177
+ // @ts-ignore
1178
+ peg$silentFails--;
1179
+ // @ts-ignore
1180
+ if (s0 === peg$FAILED) {
1181
+ // @ts-ignore
1182
+ s1 = peg$FAILED;
1183
+ // @ts-ignore
1184
+ if (peg$silentFails === 0)
1185
+ peg$fail(peg$e7);
1186
+ }
1187
+ // @ts-ignore
1188
+ return s0;
711
1189
  }
712
- else {
713
- peg$currPos = s0;
714
- s0 = peg$FAILED;
715
- }
716
- peg$silentFails--;
717
- if (s0 === peg$FAILED) {
718
- s1 = peg$FAILED;
719
- if (peg$silentFails === 0)
720
- peg$fail(peg$c15);
721
- }
722
- return s0;
723
- }
724
- function peg$parsever_comparison() {
725
- let s0, s1, s2, s3, s4, s5, s6, s7;
726
- peg$silentFails++;
727
- s0 = peg$currPos;
728
- s1 = peg$parse_();
729
- if (s1 !== peg$FAILED) {
1190
+ // @ts-ignore
1191
+ function peg$parsever_comparison() {
1192
+ // @ts-ignore
1193
+ var s0, s1, s2, s3, s4, s5, s6, s7;
1194
+ // @ts-ignore
1195
+ peg$silentFails++;
1196
+ // @ts-ignore
1197
+ s0 = peg$currPos;
1198
+ // @ts-ignore
1199
+ s1 = peg$parse_();
1200
+ // @ts-ignore
730
1201
  s2 = peg$parseterm();
1202
+ // @ts-ignore
731
1203
  if (s2 !== peg$FAILED) {
1204
+ // @ts-ignore
732
1205
  s3 = peg$parse_();
733
- if (s3 !== peg$FAILED) {
734
- if (input.substr(peg$currPos, 2) === peg$c16) {
735
- s4 = peg$c16;
736
- peg$currPos += 2;
1206
+ // @ts-ignore
1207
+ if (input.substr(peg$currPos, 2) === peg$c4) {
1208
+ // @ts-ignore
1209
+ s4 = peg$c4;
1210
+ // @ts-ignore
1211
+ peg$currPos += 2;
1212
+ // @ts-ignore
1213
+ }
1214
+ else {
1215
+ // @ts-ignore
1216
+ s4 = peg$FAILED;
1217
+ // @ts-ignore
1218
+ if (peg$silentFails === 0)
1219
+ peg$fail(peg$e8);
1220
+ }
1221
+ // @ts-ignore
1222
+ if (s4 === peg$FAILED) {
1223
+ // @ts-ignore
1224
+ if (input.charCodeAt(peg$currPos) === 62) {
1225
+ // @ts-ignore
1226
+ s4 = peg$c5;
1227
+ // @ts-ignore
1228
+ peg$currPos++;
1229
+ // @ts-ignore
737
1230
  }
738
1231
  else {
1232
+ // @ts-ignore
739
1233
  s4 = peg$FAILED;
1234
+ // @ts-ignore
740
1235
  if (peg$silentFails === 0)
741
- peg$fail(peg$c17);
1236
+ peg$fail(peg$e9);
742
1237
  }
1238
+ // @ts-ignore
743
1239
  if (s4 === peg$FAILED) {
744
- if (input.charCodeAt(peg$currPos) === 62) {
745
- s4 = peg$c18;
746
- peg$currPos++;
1240
+ // @ts-ignore
1241
+ if (input.substr(peg$currPos, 2) === peg$c6) {
1242
+ // @ts-ignore
1243
+ s4 = peg$c6;
1244
+ // @ts-ignore
1245
+ peg$currPos += 2;
1246
+ // @ts-ignore
747
1247
  }
748
1248
  else {
1249
+ // @ts-ignore
749
1250
  s4 = peg$FAILED;
1251
+ // @ts-ignore
750
1252
  if (peg$silentFails === 0)
751
- peg$fail(peg$c19);
1253
+ peg$fail(peg$e10);
752
1254
  }
1255
+ // @ts-ignore
753
1256
  if (s4 === peg$FAILED) {
754
- if (input.substr(peg$currPos, 2) === peg$c20) {
755
- s4 = peg$c20;
756
- peg$currPos += 2;
1257
+ // @ts-ignore
1258
+ if (input.charCodeAt(peg$currPos) === 60) {
1259
+ // @ts-ignore
1260
+ s4 = peg$c7;
1261
+ // @ts-ignore
1262
+ peg$currPos++;
1263
+ // @ts-ignore
757
1264
  }
758
1265
  else {
1266
+ // @ts-ignore
759
1267
  s4 = peg$FAILED;
760
- if (peg$silentFails === 0)
761
- peg$fail(peg$c21);
1268
+ // @ts-ignore
1269
+ if (peg$silentFails === 0) {
1270
+ peg$fail(peg$e11);
1271
+ }
762
1272
  }
1273
+ // @ts-ignore
763
1274
  if (s4 === peg$FAILED) {
764
- if (input.charCodeAt(peg$currPos) === 60) {
765
- s4 = peg$c22;
766
- peg$currPos++;
1275
+ // @ts-ignore
1276
+ if (input.substr(peg$currPos, 3) === peg$c8) {
1277
+ // @ts-ignore
1278
+ s4 = peg$c8;
1279
+ // @ts-ignore
1280
+ peg$currPos += 3;
1281
+ // @ts-ignore
767
1282
  }
768
1283
  else {
1284
+ // @ts-ignore
769
1285
  s4 = peg$FAILED;
1286
+ // @ts-ignore
770
1287
  if (peg$silentFails === 0) {
771
- peg$fail(peg$c23);
772
- }
773
- }
774
- if (s4 === peg$FAILED) {
775
- if (input.substr(peg$currPos, 3) === peg$c24) {
776
- s4 = peg$c24;
777
- peg$currPos += 3;
778
- }
779
- else {
780
- s4 = peg$FAILED;
781
- if (peg$silentFails === 0) {
782
- peg$fail(peg$c25);
783
- }
1288
+ peg$fail(peg$e12);
784
1289
  }
785
1290
  }
786
1291
  }
787
1292
  }
788
1293
  }
789
- if (s4 !== peg$FAILED) {
790
- s5 = peg$parse_();
791
- if (s5 !== peg$FAILED) {
792
- s6 = peg$parseversion();
793
- if (s6 !== peg$FAILED) {
794
- s7 = peg$parse_();
795
- if (s7 !== peg$FAILED) {
796
- peg$savedPos = s0;
797
- s1 = peg$c28(s2, s4, s6);
798
- s0 = s1;
799
- }
800
- else {
801
- peg$currPos = s0;
802
- s0 = peg$FAILED;
803
- }
804
- }
805
- else {
806
- peg$currPos = s0;
807
- s0 = peg$FAILED;
808
- }
809
- }
810
- else {
811
- peg$currPos = s0;
812
- s0 = peg$FAILED;
813
- }
1294
+ }
1295
+ // @ts-ignore
1296
+ if (s4 !== peg$FAILED) {
1297
+ // @ts-ignore
1298
+ s5 = peg$parse_();
1299
+ // @ts-ignore
1300
+ s6 = peg$parseversion();
1301
+ // @ts-ignore
1302
+ if (s6 !== peg$FAILED) {
1303
+ // @ts-ignore
1304
+ s7 = peg$parse_();
1305
+ // @ts-ignore
1306
+ peg$savedPos = s0;
1307
+ // @ts-ignore
1308
+ s0 = peg$f6(s2, s4, s6);
1309
+ // @ts-ignore
814
1310
  }
815
1311
  else {
1312
+ // @ts-ignore
816
1313
  peg$currPos = s0;
1314
+ // @ts-ignore
817
1315
  s0 = peg$FAILED;
818
1316
  }
1317
+ // @ts-ignore
819
1318
  }
820
1319
  else {
1320
+ // @ts-ignore
821
1321
  peg$currPos = s0;
1322
+ // @ts-ignore
822
1323
  s0 = peg$FAILED;
823
1324
  }
1325
+ // @ts-ignore
824
1326
  }
825
1327
  else {
1328
+ // @ts-ignore
826
1329
  peg$currPos = s0;
1330
+ // @ts-ignore
827
1331
  s0 = peg$FAILED;
828
1332
  }
1333
+ // @ts-ignore
1334
+ peg$silentFails--;
1335
+ // @ts-ignore
1336
+ if (s0 === peg$FAILED) {
1337
+ // @ts-ignore
1338
+ s1 = peg$FAILED;
1339
+ // @ts-ignore
1340
+ if (peg$silentFails === 0)
1341
+ peg$fail(peg$e13);
1342
+ }
1343
+ // @ts-ignore
1344
+ return s0;
829
1345
  }
830
- else {
831
- peg$currPos = s0;
832
- s0 = peg$FAILED;
833
- }
834
- peg$silentFails--;
835
- if (s0 === peg$FAILED) {
836
- s1 = peg$FAILED;
837
- if (peg$silentFails === 0)
838
- peg$fail(peg$c27);
839
- }
840
- return s0;
841
- }
842
- function peg$parseterm() {
843
- let s0;
844
- s0 = peg$parseconst();
845
- if (s0 === peg$FAILED) {
846
- s0 = peg$parsestring();
1346
+ // @ts-ignore
1347
+ function peg$parseterm() {
1348
+ // @ts-ignore
1349
+ var s0;
1350
+ // @ts-ignore
1351
+ s0 = peg$parseconst();
1352
+ // @ts-ignore
847
1353
  if (s0 === peg$FAILED) {
848
- s0 = peg$parsehex();
1354
+ // @ts-ignore
1355
+ s0 = peg$parsestring();
1356
+ // @ts-ignore
849
1357
  if (s0 === peg$FAILED) {
850
- s0 = peg$parseinteger();
1358
+ // @ts-ignore
1359
+ s0 = peg$parsehex();
1360
+ // @ts-ignore
1361
+ if (s0 === peg$FAILED) {
1362
+ // @ts-ignore
1363
+ s0 = peg$parseinteger();
1364
+ }
851
1365
  }
852
1366
  }
1367
+ // @ts-ignore
1368
+ return s0;
853
1369
  }
854
- return s0;
855
- }
856
- function peg$parseconst() {
857
- let s0, s1, s2, s3, s4, s5;
858
- peg$silentFails++;
859
- s0 = peg$currPos;
860
- s1 = peg$parse_();
861
- if (s1 !== peg$FAILED) {
1370
+ // @ts-ignore
1371
+ function peg$parseconst() {
1372
+ // @ts-ignore
1373
+ var s0, s1, s2, s3, s4, s5;
1374
+ // @ts-ignore
1375
+ peg$silentFails++;
1376
+ // @ts-ignore
1377
+ s0 = peg$currPos;
1378
+ // @ts-ignore
1379
+ s1 = peg$parse_();
1380
+ // @ts-ignore
862
1381
  s2 = peg$currPos;
1382
+ // @ts-ignore
863
1383
  s3 = peg$currPos;
1384
+ // @ts-ignore
864
1385
  peg$silentFails++;
865
- if (peg$c30.test(input.charAt(peg$currPos))) {
1386
+ // @ts-ignore
1387
+ if (peg$r0.test(input.charAt(peg$currPos))) {
1388
+ // @ts-ignore
866
1389
  s4 = input.charAt(peg$currPos);
1390
+ // @ts-ignore
867
1391
  peg$currPos++;
1392
+ // @ts-ignore
868
1393
  }
869
1394
  else {
1395
+ // @ts-ignore
870
1396
  s4 = peg$FAILED;
1397
+ // @ts-ignore
871
1398
  if (peg$silentFails === 0)
872
- peg$fail(peg$c31);
1399
+ peg$fail(peg$e15);
873
1400
  }
1401
+ // @ts-ignore
874
1402
  peg$silentFails--;
1403
+ // @ts-ignore
875
1404
  if (s4 !== peg$FAILED) {
1405
+ // @ts-ignore
876
1406
  peg$currPos = s3;
1407
+ // @ts-ignore
877
1408
  s3 = undefined;
1409
+ // @ts-ignore
878
1410
  }
879
1411
  else {
1412
+ // @ts-ignore
880
1413
  s3 = peg$FAILED;
881
1414
  }
1415
+ // @ts-ignore
882
1416
  if (s3 !== peg$FAILED) {
1417
+ // @ts-ignore
883
1418
  s4 = [];
884
- if (peg$c32.test(input.charAt(peg$currPos))) {
1419
+ // @ts-ignore
1420
+ if (peg$r1.test(input.charAt(peg$currPos))) {
1421
+ // @ts-ignore
885
1422
  s5 = input.charAt(peg$currPos);
1423
+ // @ts-ignore
886
1424
  peg$currPos++;
1425
+ // @ts-ignore
887
1426
  }
888
1427
  else {
1428
+ // @ts-ignore
889
1429
  s5 = peg$FAILED;
1430
+ // @ts-ignore
890
1431
  if (peg$silentFails === 0)
891
- peg$fail(peg$c33);
1432
+ peg$fail(peg$e16);
892
1433
  }
1434
+ // @ts-ignore
893
1435
  if (s5 !== peg$FAILED) {
1436
+ // @ts-ignore
894
1437
  while (s5 !== peg$FAILED) {
1438
+ // @ts-ignore
895
1439
  s4.push(s5);
896
- if (peg$c32.test(input.charAt(peg$currPos))) {
1440
+ // @ts-ignore
1441
+ if (peg$r1.test(input.charAt(peg$currPos))) {
1442
+ // @ts-ignore
897
1443
  s5 = input.charAt(peg$currPos);
1444
+ // @ts-ignore
898
1445
  peg$currPos++;
1446
+ // @ts-ignore
899
1447
  }
900
1448
  else {
1449
+ // @ts-ignore
901
1450
  s5 = peg$FAILED;
1451
+ // @ts-ignore
902
1452
  if (peg$silentFails === 0)
903
- peg$fail(peg$c33);
1453
+ peg$fail(peg$e16);
904
1454
  }
905
1455
  }
1456
+ // @ts-ignore
906
1457
  }
907
1458
  else {
1459
+ // @ts-ignore
908
1460
  s4 = peg$FAILED;
909
1461
  }
1462
+ // @ts-ignore
910
1463
  if (s4 !== peg$FAILED) {
1464
+ // @ts-ignore
911
1465
  s3 = [s3, s4];
1466
+ // @ts-ignore
912
1467
  s2 = s3;
1468
+ // @ts-ignore
913
1469
  }
914
1470
  else {
1471
+ // @ts-ignore
915
1472
  peg$currPos = s2;
1473
+ // @ts-ignore
916
1474
  s2 = peg$FAILED;
917
1475
  }
1476
+ // @ts-ignore
918
1477
  }
919
1478
  else {
1479
+ // @ts-ignore
920
1480
  peg$currPos = s2;
1481
+ // @ts-ignore
921
1482
  s2 = peg$FAILED;
922
1483
  }
1484
+ // @ts-ignore
923
1485
  if (s2 !== peg$FAILED) {
1486
+ // @ts-ignore
924
1487
  peg$savedPos = s0;
925
- s1 = peg$c34(s2);
926
- s0 = s1;
1488
+ // @ts-ignore
1489
+ s0 = peg$f7(s2);
1490
+ // @ts-ignore
927
1491
  }
928
1492
  else {
1493
+ // @ts-ignore
929
1494
  peg$currPos = s0;
1495
+ // @ts-ignore
930
1496
  s0 = peg$FAILED;
931
1497
  }
1498
+ // @ts-ignore
1499
+ peg$silentFails--;
1500
+ // @ts-ignore
1501
+ if (s0 === peg$FAILED) {
1502
+ // @ts-ignore
1503
+ s1 = peg$FAILED;
1504
+ // @ts-ignore
1505
+ if (peg$silentFails === 0)
1506
+ peg$fail(peg$e14);
1507
+ }
1508
+ // @ts-ignore
1509
+ return s0;
932
1510
  }
933
- else {
934
- peg$currPos = s0;
935
- s0 = peg$FAILED;
936
- }
937
- peg$silentFails--;
938
- if (s0 === peg$FAILED) {
939
- s1 = peg$FAILED;
940
- if (peg$silentFails === 0)
941
- peg$fail(peg$c29);
942
- }
943
- return s0;
944
- }
945
- function peg$parseinteger() {
946
- let s0, s1, s2, s3, s4, s5;
947
- peg$silentFails++;
948
- s0 = peg$currPos;
949
- s1 = peg$parse_();
950
- if (s1 !== peg$FAILED) {
1511
+ // @ts-ignore
1512
+ function peg$parseinteger() {
1513
+ // @ts-ignore
1514
+ var s0, s1, s2, s3, s4, s5;
1515
+ // @ts-ignore
1516
+ peg$silentFails++;
1517
+ // @ts-ignore
1518
+ s0 = peg$currPos;
1519
+ // @ts-ignore
1520
+ s1 = peg$parse_();
1521
+ // @ts-ignore
951
1522
  s2 = peg$currPos;
1523
+ // @ts-ignore
952
1524
  if (input.charCodeAt(peg$currPos) === 45) {
953
- s3 = peg$c36;
1525
+ // @ts-ignore
1526
+ s3 = peg$c9;
1527
+ // @ts-ignore
954
1528
  peg$currPos++;
1529
+ // @ts-ignore
955
1530
  }
956
1531
  else {
1532
+ // @ts-ignore
957
1533
  s3 = peg$FAILED;
1534
+ // @ts-ignore
958
1535
  if (peg$silentFails === 0)
959
- peg$fail(peg$c37);
1536
+ peg$fail(peg$e18);
960
1537
  }
1538
+ // @ts-ignore
961
1539
  if (s3 === peg$FAILED) {
1540
+ // @ts-ignore
962
1541
  s3 = null;
963
1542
  }
964
- if (s3 !== peg$FAILED) {
965
- s4 = [];
966
- if (peg$c38.test(input.charAt(peg$currPos))) {
967
- s5 = input.charAt(peg$currPos);
968
- peg$currPos++;
969
- }
970
- else {
971
- s5 = peg$FAILED;
972
- if (peg$silentFails === 0)
973
- peg$fail(peg$c39);
974
- }
975
- if (s5 !== peg$FAILED) {
976
- while (s5 !== peg$FAILED) {
977
- s4.push(s5);
978
- if (peg$c38.test(input.charAt(peg$currPos))) {
979
- s5 = input.charAt(peg$currPos);
980
- peg$currPos++;
981
- }
982
- else {
983
- s5 = peg$FAILED;
984
- if (peg$silentFails === 0)
985
- peg$fail(peg$c39);
986
- }
1543
+ // @ts-ignore
1544
+ s4 = [];
1545
+ // @ts-ignore
1546
+ if (peg$r2.test(input.charAt(peg$currPos))) {
1547
+ // @ts-ignore
1548
+ s5 = input.charAt(peg$currPos);
1549
+ // @ts-ignore
1550
+ peg$currPos++;
1551
+ // @ts-ignore
1552
+ }
1553
+ else {
1554
+ // @ts-ignore
1555
+ s5 = peg$FAILED;
1556
+ // @ts-ignore
1557
+ if (peg$silentFails === 0)
1558
+ peg$fail(peg$e19);
1559
+ }
1560
+ // @ts-ignore
1561
+ if (s5 !== peg$FAILED) {
1562
+ // @ts-ignore
1563
+ while (s5 !== peg$FAILED) {
1564
+ // @ts-ignore
1565
+ s4.push(s5);
1566
+ // @ts-ignore
1567
+ if (peg$r2.test(input.charAt(peg$currPos))) {
1568
+ // @ts-ignore
1569
+ s5 = input.charAt(peg$currPos);
1570
+ // @ts-ignore
1571
+ peg$currPos++;
1572
+ // @ts-ignore
1573
+ }
1574
+ else {
1575
+ // @ts-ignore
1576
+ s5 = peg$FAILED;
1577
+ // @ts-ignore
1578
+ if (peg$silentFails === 0)
1579
+ peg$fail(peg$e19);
987
1580
  }
988
1581
  }
989
- else {
990
- s4 = peg$FAILED;
991
- }
992
- if (s4 !== peg$FAILED) {
993
- s3 = [s3, s4];
994
- s2 = s3;
995
- }
996
- else {
997
- peg$currPos = s2;
998
- s2 = peg$FAILED;
999
- }
1582
+ // @ts-ignore
1583
+ }
1584
+ else {
1585
+ // @ts-ignore
1586
+ s4 = peg$FAILED;
1587
+ }
1588
+ // @ts-ignore
1589
+ if (s4 !== peg$FAILED) {
1590
+ // @ts-ignore
1591
+ s3 = [s3, s4];
1592
+ // @ts-ignore
1593
+ s2 = s3;
1594
+ // @ts-ignore
1000
1595
  }
1001
1596
  else {
1597
+ // @ts-ignore
1002
1598
  peg$currPos = s2;
1599
+ // @ts-ignore
1003
1600
  s2 = peg$FAILED;
1004
1601
  }
1602
+ // @ts-ignore
1005
1603
  if (s2 !== peg$FAILED) {
1604
+ // @ts-ignore
1006
1605
  peg$savedPos = s0;
1007
- s1 = peg$c40();
1008
- s0 = s1;
1606
+ // @ts-ignore
1607
+ s0 = peg$f8();
1608
+ // @ts-ignore
1009
1609
  }
1010
1610
  else {
1611
+ // @ts-ignore
1011
1612
  peg$currPos = s0;
1613
+ // @ts-ignore
1012
1614
  s0 = peg$FAILED;
1013
1615
  }
1616
+ // @ts-ignore
1617
+ peg$silentFails--;
1618
+ // @ts-ignore
1619
+ if (s0 === peg$FAILED) {
1620
+ // @ts-ignore
1621
+ s1 = peg$FAILED;
1622
+ // @ts-ignore
1623
+ if (peg$silentFails === 0)
1624
+ peg$fail(peg$e17);
1625
+ }
1626
+ // @ts-ignore
1627
+ return s0;
1014
1628
  }
1015
- else {
1016
- peg$currPos = s0;
1017
- s0 = peg$FAILED;
1018
- }
1019
- peg$silentFails--;
1020
- if (s0 === peg$FAILED) {
1021
- s1 = peg$FAILED;
1022
- if (peg$silentFails === 0)
1023
- peg$fail(peg$c35);
1024
- }
1025
- return s0;
1026
- }
1027
- function peg$parsehex() {
1028
- let s0, s1, s2, s3, s4, s5;
1029
- peg$silentFails++;
1030
- s0 = peg$currPos;
1031
- s1 = peg$parse_();
1032
- if (s1 !== peg$FAILED) {
1629
+ // @ts-ignore
1630
+ function peg$parsehex() {
1631
+ // @ts-ignore
1632
+ var s0, s1, s2, s3, s4, s5;
1633
+ // @ts-ignore
1634
+ peg$silentFails++;
1635
+ // @ts-ignore
1636
+ s0 = peg$currPos;
1637
+ // @ts-ignore
1638
+ s1 = peg$parse_();
1639
+ // @ts-ignore
1033
1640
  s2 = peg$currPos;
1034
- if (input.substr(peg$currPos, 2) === peg$c42) {
1035
- s3 = peg$c42;
1641
+ // @ts-ignore
1642
+ if (input.substr(peg$currPos, 2) === peg$c10) {
1643
+ // @ts-ignore
1644
+ s3 = peg$c10;
1645
+ // @ts-ignore
1036
1646
  peg$currPos += 2;
1647
+ // @ts-ignore
1037
1648
  }
1038
1649
  else {
1650
+ // @ts-ignore
1039
1651
  s3 = peg$FAILED;
1652
+ // @ts-ignore
1040
1653
  if (peg$silentFails === 0)
1041
- peg$fail(peg$c43);
1654
+ peg$fail(peg$e21);
1042
1655
  }
1656
+ // @ts-ignore
1043
1657
  if (s3 !== peg$FAILED) {
1658
+ // @ts-ignore
1044
1659
  s4 = [];
1045
- if (peg$c44.test(input.charAt(peg$currPos))) {
1660
+ // @ts-ignore
1661
+ if (peg$r3.test(input.charAt(peg$currPos))) {
1662
+ // @ts-ignore
1046
1663
  s5 = input.charAt(peg$currPos);
1664
+ // @ts-ignore
1047
1665
  peg$currPos++;
1666
+ // @ts-ignore
1048
1667
  }
1049
1668
  else {
1669
+ // @ts-ignore
1050
1670
  s5 = peg$FAILED;
1671
+ // @ts-ignore
1051
1672
  if (peg$silentFails === 0)
1052
- peg$fail(peg$c45);
1673
+ peg$fail(peg$e22);
1053
1674
  }
1675
+ // @ts-ignore
1054
1676
  if (s5 !== peg$FAILED) {
1677
+ // @ts-ignore
1055
1678
  while (s5 !== peg$FAILED) {
1679
+ // @ts-ignore
1056
1680
  s4.push(s5);
1057
- if (peg$c44.test(input.charAt(peg$currPos))) {
1681
+ // @ts-ignore
1682
+ if (peg$r3.test(input.charAt(peg$currPos))) {
1683
+ // @ts-ignore
1058
1684
  s5 = input.charAt(peg$currPos);
1685
+ // @ts-ignore
1059
1686
  peg$currPos++;
1687
+ // @ts-ignore
1060
1688
  }
1061
1689
  else {
1690
+ // @ts-ignore
1062
1691
  s5 = peg$FAILED;
1692
+ // @ts-ignore
1063
1693
  if (peg$silentFails === 0)
1064
- peg$fail(peg$c45);
1694
+ peg$fail(peg$e22);
1065
1695
  }
1066
1696
  }
1697
+ // @ts-ignore
1067
1698
  }
1068
1699
  else {
1700
+ // @ts-ignore
1069
1701
  s4 = peg$FAILED;
1070
1702
  }
1703
+ // @ts-ignore
1071
1704
  if (s4 !== peg$FAILED) {
1705
+ // @ts-ignore
1072
1706
  s3 = [s3, s4];
1707
+ // @ts-ignore
1073
1708
  s2 = s3;
1709
+ // @ts-ignore
1074
1710
  }
1075
1711
  else {
1712
+ // @ts-ignore
1076
1713
  peg$currPos = s2;
1714
+ // @ts-ignore
1077
1715
  s2 = peg$FAILED;
1078
1716
  }
1717
+ // @ts-ignore
1079
1718
  }
1080
1719
  else {
1720
+ // @ts-ignore
1081
1721
  peg$currPos = s2;
1722
+ // @ts-ignore
1082
1723
  s2 = peg$FAILED;
1083
1724
  }
1725
+ // @ts-ignore
1084
1726
  if (s2 !== peg$FAILED) {
1727
+ // @ts-ignore
1085
1728
  peg$savedPos = s0;
1086
- s1 = peg$c46();
1087
- s0 = s1;
1729
+ // @ts-ignore
1730
+ s0 = peg$f9();
1731
+ // @ts-ignore
1088
1732
  }
1089
1733
  else {
1734
+ // @ts-ignore
1090
1735
  peg$currPos = s0;
1736
+ // @ts-ignore
1091
1737
  s0 = peg$FAILED;
1092
1738
  }
1739
+ // @ts-ignore
1740
+ peg$silentFails--;
1741
+ // @ts-ignore
1742
+ if (s0 === peg$FAILED) {
1743
+ // @ts-ignore
1744
+ s1 = peg$FAILED;
1745
+ // @ts-ignore
1746
+ if (peg$silentFails === 0)
1747
+ peg$fail(peg$e20);
1748
+ }
1749
+ // @ts-ignore
1750
+ return s0;
1093
1751
  }
1094
- else {
1095
- peg$currPos = s0;
1096
- s0 = peg$FAILED;
1097
- }
1098
- peg$silentFails--;
1099
- if (s0 === peg$FAILED) {
1100
- s1 = peg$FAILED;
1101
- if (peg$silentFails === 0)
1102
- peg$fail(peg$c41);
1103
- }
1104
- return s0;
1105
- }
1106
- function peg$parseversion() {
1107
- let s0, s1, s2, s3, s4, s5, s6, s7, s8, s9;
1108
- peg$silentFails++;
1109
- s0 = peg$currPos;
1110
- s1 = peg$parse_();
1111
- if (s1 !== peg$FAILED) {
1752
+ // @ts-ignore
1753
+ function peg$parseversion() {
1754
+ // @ts-ignore
1755
+ var s0, s1, s2, s3, s4, s5, s6, s7, s8, s9;
1756
+ // @ts-ignore
1757
+ peg$silentFails++;
1758
+ // @ts-ignore
1759
+ s0 = peg$currPos;
1760
+ // @ts-ignore
1761
+ s1 = peg$parse_();
1762
+ // @ts-ignore
1112
1763
  s2 = peg$currPos;
1764
+ // @ts-ignore
1113
1765
  s3 = [];
1114
- if (peg$c38.test(input.charAt(peg$currPos))) {
1766
+ // @ts-ignore
1767
+ if (peg$r2.test(input.charAt(peg$currPos))) {
1768
+ // @ts-ignore
1115
1769
  s4 = input.charAt(peg$currPos);
1770
+ // @ts-ignore
1116
1771
  peg$currPos++;
1772
+ // @ts-ignore
1117
1773
  }
1118
1774
  else {
1775
+ // @ts-ignore
1119
1776
  s4 = peg$FAILED;
1777
+ // @ts-ignore
1120
1778
  if (peg$silentFails === 0)
1121
- peg$fail(peg$c39);
1779
+ peg$fail(peg$e19);
1122
1780
  }
1781
+ // @ts-ignore
1123
1782
  if (s4 !== peg$FAILED) {
1783
+ // @ts-ignore
1124
1784
  while (s4 !== peg$FAILED) {
1785
+ // @ts-ignore
1125
1786
  s3.push(s4);
1126
- if (peg$c38.test(input.charAt(peg$currPos))) {
1787
+ // @ts-ignore
1788
+ if (peg$r2.test(input.charAt(peg$currPos))) {
1789
+ // @ts-ignore
1127
1790
  s4 = input.charAt(peg$currPos);
1791
+ // @ts-ignore
1128
1792
  peg$currPos++;
1793
+ // @ts-ignore
1129
1794
  }
1130
1795
  else {
1796
+ // @ts-ignore
1131
1797
  s4 = peg$FAILED;
1798
+ // @ts-ignore
1132
1799
  if (peg$silentFails === 0)
1133
- peg$fail(peg$c39);
1800
+ peg$fail(peg$e19);
1134
1801
  }
1135
1802
  }
1803
+ // @ts-ignore
1136
1804
  }
1137
1805
  else {
1806
+ // @ts-ignore
1138
1807
  s3 = peg$FAILED;
1139
1808
  }
1809
+ // @ts-ignore
1140
1810
  if (s3 !== peg$FAILED) {
1811
+ // @ts-ignore
1141
1812
  if (input.charCodeAt(peg$currPos) === 46) {
1142
- s4 = peg$c48;
1813
+ // @ts-ignore
1814
+ s4 = peg$c11;
1815
+ // @ts-ignore
1143
1816
  peg$currPos++;
1817
+ // @ts-ignore
1144
1818
  }
1145
1819
  else {
1820
+ // @ts-ignore
1146
1821
  s4 = peg$FAILED;
1822
+ // @ts-ignore
1147
1823
  if (peg$silentFails === 0)
1148
- peg$fail(peg$c49);
1824
+ peg$fail(peg$e24);
1149
1825
  }
1826
+ // @ts-ignore
1150
1827
  if (s4 !== peg$FAILED) {
1828
+ // @ts-ignore
1151
1829
  s5 = [];
1152
- if (peg$c38.test(input.charAt(peg$currPos))) {
1830
+ // @ts-ignore
1831
+ if (peg$r2.test(input.charAt(peg$currPos))) {
1832
+ // @ts-ignore
1153
1833
  s6 = input.charAt(peg$currPos);
1834
+ // @ts-ignore
1154
1835
  peg$currPos++;
1836
+ // @ts-ignore
1155
1837
  }
1156
1838
  else {
1839
+ // @ts-ignore
1157
1840
  s6 = peg$FAILED;
1841
+ // @ts-ignore
1158
1842
  if (peg$silentFails === 0)
1159
- peg$fail(peg$c39);
1843
+ peg$fail(peg$e19);
1160
1844
  }
1845
+ // @ts-ignore
1161
1846
  if (s6 !== peg$FAILED) {
1847
+ // @ts-ignore
1162
1848
  while (s6 !== peg$FAILED) {
1849
+ // @ts-ignore
1163
1850
  s5.push(s6);
1164
- if (peg$c38.test(input.charAt(peg$currPos))) {
1851
+ // @ts-ignore
1852
+ if (peg$r2.test(input.charAt(peg$currPos))) {
1853
+ // @ts-ignore
1165
1854
  s6 = input.charAt(peg$currPos);
1855
+ // @ts-ignore
1166
1856
  peg$currPos++;
1857
+ // @ts-ignore
1167
1858
  }
1168
1859
  else {
1860
+ // @ts-ignore
1169
1861
  s6 = peg$FAILED;
1170
- if (peg$silentFails === 0)
1171
- peg$fail(peg$c39);
1862
+ // @ts-ignore
1863
+ if (peg$silentFails === 0) {
1864
+ peg$fail(peg$e19);
1865
+ }
1172
1866
  }
1173
1867
  }
1868
+ // @ts-ignore
1174
1869
  }
1175
1870
  else {
1871
+ // @ts-ignore
1176
1872
  s5 = peg$FAILED;
1177
1873
  }
1874
+ // @ts-ignore
1178
1875
  if (s5 !== peg$FAILED) {
1876
+ // @ts-ignore
1179
1877
  s6 = peg$currPos;
1878
+ // @ts-ignore
1180
1879
  if (input.charCodeAt(peg$currPos) === 46) {
1181
- s7 = peg$c48;
1880
+ // @ts-ignore
1881
+ s7 = peg$c11;
1882
+ // @ts-ignore
1182
1883
  peg$currPos++;
1884
+ // @ts-ignore
1183
1885
  }
1184
1886
  else {
1887
+ // @ts-ignore
1185
1888
  s7 = peg$FAILED;
1889
+ // @ts-ignore
1186
1890
  if (peg$silentFails === 0)
1187
- peg$fail(peg$c49);
1891
+ peg$fail(peg$e24);
1188
1892
  }
1893
+ // @ts-ignore
1189
1894
  if (s7 !== peg$FAILED) {
1895
+ // @ts-ignore
1190
1896
  s8 = [];
1191
- if (peg$c38.test(input.charAt(peg$currPos))) {
1897
+ // @ts-ignore
1898
+ if (peg$r2.test(input.charAt(peg$currPos))) {
1899
+ // @ts-ignore
1192
1900
  s9 = input.charAt(peg$currPos);
1901
+ // @ts-ignore
1193
1902
  peg$currPos++;
1903
+ // @ts-ignore
1194
1904
  }
1195
1905
  else {
1906
+ // @ts-ignore
1196
1907
  s9 = peg$FAILED;
1197
- if (peg$silentFails === 0)
1198
- peg$fail(peg$c39);
1908
+ // @ts-ignore
1909
+ if (peg$silentFails === 0) {
1910
+ peg$fail(peg$e19);
1911
+ }
1199
1912
  }
1913
+ // @ts-ignore
1200
1914
  if (s9 !== peg$FAILED) {
1915
+ // @ts-ignore
1201
1916
  while (s9 !== peg$FAILED) {
1917
+ // @ts-ignore
1202
1918
  s8.push(s9);
1203
- if (peg$c38.test(input.charAt(peg$currPos))) {
1919
+ // @ts-ignore
1920
+ if (peg$r2.test(input.charAt(peg$currPos))) {
1921
+ // @ts-ignore
1204
1922
  s9 = input.charAt(peg$currPos);
1923
+ // @ts-ignore
1205
1924
  peg$currPos++;
1925
+ // @ts-ignore
1206
1926
  }
1207
1927
  else {
1928
+ // @ts-ignore
1208
1929
  s9 = peg$FAILED;
1930
+ // @ts-ignore
1209
1931
  if (peg$silentFails === 0) {
1210
- peg$fail(peg$c39);
1932
+ peg$fail(peg$e19);
1211
1933
  }
1212
1934
  }
1213
1935
  }
1936
+ // @ts-ignore
1214
1937
  }
1215
1938
  else {
1939
+ // @ts-ignore
1216
1940
  s8 = peg$FAILED;
1217
1941
  }
1942
+ // @ts-ignore
1218
1943
  if (s8 !== peg$FAILED) {
1944
+ // @ts-ignore
1219
1945
  s7 = [s7, s8];
1946
+ // @ts-ignore
1220
1947
  s6 = s7;
1948
+ // @ts-ignore
1221
1949
  }
1222
1950
  else {
1951
+ // @ts-ignore
1223
1952
  peg$currPos = s6;
1953
+ // @ts-ignore
1224
1954
  s6 = peg$FAILED;
1225
1955
  }
1956
+ // @ts-ignore
1226
1957
  }
1227
1958
  else {
1959
+ // @ts-ignore
1228
1960
  peg$currPos = s6;
1961
+ // @ts-ignore
1229
1962
  s6 = peg$FAILED;
1230
1963
  }
1964
+ // @ts-ignore
1231
1965
  if (s6 === peg$FAILED) {
1966
+ // @ts-ignore
1232
1967
  s6 = null;
1233
1968
  }
1234
- if (s6 !== peg$FAILED) {
1235
- s3 = [s3, s4, s5, s6];
1236
- s2 = s3;
1237
- }
1238
- else {
1239
- peg$currPos = s2;
1240
- s2 = peg$FAILED;
1241
- }
1969
+ // @ts-ignore
1970
+ s3 = [s3, s4, s5, s6];
1971
+ // @ts-ignore
1972
+ s2 = s3;
1973
+ // @ts-ignore
1242
1974
  }
1243
1975
  else {
1976
+ // @ts-ignore
1244
1977
  peg$currPos = s2;
1978
+ // @ts-ignore
1245
1979
  s2 = peg$FAILED;
1246
1980
  }
1981
+ // @ts-ignore
1247
1982
  }
1248
1983
  else {
1984
+ // @ts-ignore
1249
1985
  peg$currPos = s2;
1986
+ // @ts-ignore
1250
1987
  s2 = peg$FAILED;
1251
1988
  }
1989
+ // @ts-ignore
1252
1990
  }
1253
1991
  else {
1992
+ // @ts-ignore
1254
1993
  peg$currPos = s2;
1994
+ // @ts-ignore
1255
1995
  s2 = peg$FAILED;
1256
1996
  }
1997
+ // @ts-ignore
1257
1998
  if (s2 !== peg$FAILED) {
1999
+ // @ts-ignore
1258
2000
  peg$savedPos = s0;
1259
- s1 = peg$c50(s2);
1260
- s0 = s1;
2001
+ // @ts-ignore
2002
+ s0 = peg$f10(s2);
2003
+ // @ts-ignore
1261
2004
  }
1262
2005
  else {
2006
+ // @ts-ignore
1263
2007
  peg$currPos = s0;
2008
+ // @ts-ignore
1264
2009
  s0 = peg$FAILED;
1265
2010
  }
2011
+ // @ts-ignore
2012
+ peg$silentFails--;
2013
+ // @ts-ignore
2014
+ if (s0 === peg$FAILED) {
2015
+ // @ts-ignore
2016
+ s1 = peg$FAILED;
2017
+ // @ts-ignore
2018
+ if (peg$silentFails === 0)
2019
+ peg$fail(peg$e23);
2020
+ }
2021
+ // @ts-ignore
2022
+ return s0;
1266
2023
  }
1267
- else {
1268
- peg$currPos = s0;
1269
- s0 = peg$FAILED;
1270
- }
1271
- peg$silentFails--;
1272
- if (s0 === peg$FAILED) {
1273
- s1 = peg$FAILED;
1274
- if (peg$silentFails === 0)
1275
- peg$fail(peg$c47);
1276
- }
1277
- return s0;
1278
- }
1279
- function peg$parsestring() {
1280
- let s0, s1, s2, s3, s4, s5;
1281
- peg$silentFails++;
1282
- s0 = peg$currPos;
1283
- s1 = peg$parse_();
1284
- if (s1 !== peg$FAILED) {
2024
+ // @ts-ignore
2025
+ function peg$parsestring() {
2026
+ // @ts-ignore
2027
+ var s0, s1, s2, s3, s4, s5;
2028
+ // @ts-ignore
2029
+ peg$silentFails++;
2030
+ // @ts-ignore
2031
+ s0 = peg$currPos;
2032
+ // @ts-ignore
2033
+ s1 = peg$parse_();
2034
+ // @ts-ignore
1285
2035
  s2 = peg$currPos;
2036
+ // @ts-ignore
1286
2037
  if (input.charCodeAt(peg$currPos) === 34) {
1287
- s3 = peg$c52;
2038
+ // @ts-ignore
2039
+ s3 = peg$c12;
2040
+ // @ts-ignore
1288
2041
  peg$currPos++;
2042
+ // @ts-ignore
1289
2043
  }
1290
2044
  else {
2045
+ // @ts-ignore
1291
2046
  s3 = peg$FAILED;
2047
+ // @ts-ignore
1292
2048
  if (peg$silentFails === 0)
1293
- peg$fail(peg$c53);
2049
+ peg$fail(peg$e26);
1294
2050
  }
2051
+ // @ts-ignore
1295
2052
  if (s3 !== peg$FAILED) {
2053
+ // @ts-ignore
1296
2054
  s4 = [];
1297
- if (peg$c54.test(input.charAt(peg$currPos))) {
2055
+ // @ts-ignore
2056
+ if (peg$r4.test(input.charAt(peg$currPos))) {
2057
+ // @ts-ignore
1298
2058
  s5 = input.charAt(peg$currPos);
2059
+ // @ts-ignore
1299
2060
  peg$currPos++;
2061
+ // @ts-ignore
1300
2062
  }
1301
2063
  else {
2064
+ // @ts-ignore
1302
2065
  s5 = peg$FAILED;
2066
+ // @ts-ignore
1303
2067
  if (peg$silentFails === 0)
1304
- peg$fail(peg$c55);
2068
+ peg$fail(peg$e27);
1305
2069
  }
2070
+ // @ts-ignore
1306
2071
  while (s5 !== peg$FAILED) {
2072
+ // @ts-ignore
1307
2073
  s4.push(s5);
1308
- if (peg$c54.test(input.charAt(peg$currPos))) {
2074
+ // @ts-ignore
2075
+ if (peg$r4.test(input.charAt(peg$currPos))) {
2076
+ // @ts-ignore
1309
2077
  s5 = input.charAt(peg$currPos);
2078
+ // @ts-ignore
1310
2079
  peg$currPos++;
2080
+ // @ts-ignore
1311
2081
  }
1312
2082
  else {
2083
+ // @ts-ignore
1313
2084
  s5 = peg$FAILED;
2085
+ // @ts-ignore
1314
2086
  if (peg$silentFails === 0)
1315
- peg$fail(peg$c55);
2087
+ peg$fail(peg$e27);
1316
2088
  }
1317
2089
  }
1318
- if (s4 !== peg$FAILED) {
1319
- if (input.charCodeAt(peg$currPos) === 34) {
1320
- s5 = peg$c52;
1321
- peg$currPos++;
1322
- }
1323
- else {
1324
- s5 = peg$FAILED;
1325
- if (peg$silentFails === 0)
1326
- peg$fail(peg$c53);
1327
- }
1328
- if (s5 !== peg$FAILED) {
1329
- s3 = [s3, s4, s5];
1330
- s2 = s3;
1331
- }
1332
- else {
1333
- peg$currPos = s2;
1334
- s2 = peg$FAILED;
1335
- }
2090
+ // @ts-ignore
2091
+ if (input.charCodeAt(peg$currPos) === 34) {
2092
+ // @ts-ignore
2093
+ s5 = peg$c12;
2094
+ // @ts-ignore
2095
+ peg$currPos++;
2096
+ // @ts-ignore
1336
2097
  }
1337
2098
  else {
2099
+ // @ts-ignore
2100
+ s5 = peg$FAILED;
2101
+ // @ts-ignore
2102
+ if (peg$silentFails === 0)
2103
+ peg$fail(peg$e26);
2104
+ }
2105
+ // @ts-ignore
2106
+ if (s5 !== peg$FAILED) {
2107
+ // @ts-ignore
2108
+ s3 = [s3, s4, s5];
2109
+ // @ts-ignore
2110
+ s2 = s3;
2111
+ // @ts-ignore
2112
+ }
2113
+ else {
2114
+ // @ts-ignore
1338
2115
  peg$currPos = s2;
2116
+ // @ts-ignore
1339
2117
  s2 = peg$FAILED;
1340
2118
  }
2119
+ // @ts-ignore
1341
2120
  }
1342
2121
  else {
2122
+ // @ts-ignore
1343
2123
  peg$currPos = s2;
2124
+ // @ts-ignore
1344
2125
  s2 = peg$FAILED;
1345
2126
  }
2127
+ // @ts-ignore
1346
2128
  if (s2 !== peg$FAILED) {
2129
+ // @ts-ignore
1347
2130
  peg$savedPos = s0;
1348
- s1 = peg$c56();
1349
- s0 = s1;
2131
+ // @ts-ignore
2132
+ s0 = peg$f11();
2133
+ // @ts-ignore
1350
2134
  }
1351
2135
  else {
2136
+ // @ts-ignore
1352
2137
  peg$currPos = s0;
2138
+ // @ts-ignore
1353
2139
  s0 = peg$FAILED;
1354
2140
  }
1355
- }
1356
- else {
1357
- peg$currPos = s0;
1358
- s0 = peg$FAILED;
1359
- }
1360
- if (s0 === peg$FAILED) {
1361
- s0 = peg$currPos;
1362
- s1 = peg$parse_();
1363
- if (s1 !== peg$FAILED) {
2141
+ // @ts-ignore
2142
+ if (s0 === peg$FAILED) {
2143
+ // @ts-ignore
2144
+ s0 = peg$currPos;
2145
+ // @ts-ignore
2146
+ s1 = peg$parse_();
2147
+ // @ts-ignore
1364
2148
  s2 = peg$currPos;
2149
+ // @ts-ignore
1365
2150
  if (input.charCodeAt(peg$currPos) === 39) {
1366
- s3 = peg$c57;
2151
+ // @ts-ignore
2152
+ s3 = peg$c13;
2153
+ // @ts-ignore
1367
2154
  peg$currPos++;
2155
+ // @ts-ignore
1368
2156
  }
1369
2157
  else {
2158
+ // @ts-ignore
1370
2159
  s3 = peg$FAILED;
2160
+ // @ts-ignore
1371
2161
  if (peg$silentFails === 0)
1372
- peg$fail(peg$c58);
2162
+ peg$fail(peg$e28);
1373
2163
  }
2164
+ // @ts-ignore
1374
2165
  if (s3 !== peg$FAILED) {
2166
+ // @ts-ignore
1375
2167
  s4 = [];
1376
- if (peg$c59.test(input.charAt(peg$currPos))) {
2168
+ // @ts-ignore
2169
+ if (peg$r5.test(input.charAt(peg$currPos))) {
2170
+ // @ts-ignore
1377
2171
  s5 = input.charAt(peg$currPos);
2172
+ // @ts-ignore
1378
2173
  peg$currPos++;
2174
+ // @ts-ignore
1379
2175
  }
1380
2176
  else {
2177
+ // @ts-ignore
1381
2178
  s5 = peg$FAILED;
2179
+ // @ts-ignore
1382
2180
  if (peg$silentFails === 0)
1383
- peg$fail(peg$c60);
2181
+ peg$fail(peg$e29);
1384
2182
  }
2183
+ // @ts-ignore
1385
2184
  while (s5 !== peg$FAILED) {
2185
+ // @ts-ignore
1386
2186
  s4.push(s5);
1387
- if (peg$c59.test(input.charAt(peg$currPos))) {
2187
+ // @ts-ignore
2188
+ if (peg$r5.test(input.charAt(peg$currPos))) {
2189
+ // @ts-ignore
1388
2190
  s5 = input.charAt(peg$currPos);
2191
+ // @ts-ignore
1389
2192
  peg$currPos++;
2193
+ // @ts-ignore
1390
2194
  }
1391
2195
  else {
2196
+ // @ts-ignore
1392
2197
  s5 = peg$FAILED;
2198
+ // @ts-ignore
1393
2199
  if (peg$silentFails === 0)
1394
- peg$fail(peg$c60);
2200
+ peg$fail(peg$e29);
1395
2201
  }
1396
2202
  }
1397
- if (s4 !== peg$FAILED) {
1398
- if (input.charCodeAt(peg$currPos) === 39) {
1399
- s5 = peg$c57;
1400
- peg$currPos++;
1401
- }
1402
- else {
1403
- s5 = peg$FAILED;
1404
- if (peg$silentFails === 0)
1405
- peg$fail(peg$c58);
1406
- }
1407
- if (s5 !== peg$FAILED) {
1408
- s3 = [s3, s4, s5];
1409
- s2 = s3;
1410
- }
1411
- else {
1412
- peg$currPos = s2;
1413
- s2 = peg$FAILED;
1414
- }
2203
+ // @ts-ignore
2204
+ if (input.charCodeAt(peg$currPos) === 39) {
2205
+ // @ts-ignore
2206
+ s5 = peg$c13;
2207
+ // @ts-ignore
2208
+ peg$currPos++;
2209
+ // @ts-ignore
2210
+ }
2211
+ else {
2212
+ // @ts-ignore
2213
+ s5 = peg$FAILED;
2214
+ // @ts-ignore
2215
+ if (peg$silentFails === 0)
2216
+ peg$fail(peg$e28);
2217
+ }
2218
+ // @ts-ignore
2219
+ if (s5 !== peg$FAILED) {
2220
+ // @ts-ignore
2221
+ s3 = [s3, s4, s5];
2222
+ // @ts-ignore
2223
+ s2 = s3;
2224
+ // @ts-ignore
1415
2225
  }
1416
2226
  else {
2227
+ // @ts-ignore
1417
2228
  peg$currPos = s2;
2229
+ // @ts-ignore
1418
2230
  s2 = peg$FAILED;
1419
2231
  }
2232
+ // @ts-ignore
1420
2233
  }
1421
2234
  else {
2235
+ // @ts-ignore
1422
2236
  peg$currPos = s2;
2237
+ // @ts-ignore
1423
2238
  s2 = peg$FAILED;
1424
2239
  }
2240
+ // @ts-ignore
1425
2241
  if (s2 !== peg$FAILED) {
2242
+ // @ts-ignore
1426
2243
  peg$savedPos = s0;
1427
- s1 = peg$c56();
1428
- s0 = s1;
2244
+ // @ts-ignore
2245
+ s0 = peg$f12();
2246
+ // @ts-ignore
1429
2247
  }
1430
2248
  else {
2249
+ // @ts-ignore
1431
2250
  peg$currPos = s0;
2251
+ // @ts-ignore
1432
2252
  s0 = peg$FAILED;
1433
2253
  }
1434
2254
  }
1435
- else {
1436
- peg$currPos = s0;
1437
- s0 = peg$FAILED;
2255
+ // @ts-ignore
2256
+ peg$silentFails--;
2257
+ // @ts-ignore
2258
+ if (s0 === peg$FAILED) {
2259
+ // @ts-ignore
2260
+ s1 = peg$FAILED;
2261
+ // @ts-ignore
2262
+ if (peg$silentFails === 0)
2263
+ peg$fail(peg$e25);
1438
2264
  }
2265
+ // @ts-ignore
2266
+ return s0;
1439
2267
  }
1440
- peg$silentFails--;
1441
- if (s0 === peg$FAILED) {
1442
- s1 = peg$FAILED;
1443
- if (peg$silentFails === 0)
1444
- peg$fail(peg$c51);
1445
- }
1446
- return s0;
1447
- }
1448
- function peg$parse_() {
1449
- let s0, s1;
1450
- peg$silentFails++;
1451
- s0 = [];
1452
- if (peg$c62.test(input.charAt(peg$currPos))) {
1453
- s1 = input.charAt(peg$currPos);
1454
- peg$currPos++;
1455
- }
1456
- else {
1457
- s1 = peg$FAILED;
1458
- if (peg$silentFails === 0)
1459
- peg$fail(peg$c63);
1460
- }
1461
- while (s1 !== peg$FAILED) {
1462
- s0.push(s1);
1463
- if (peg$c62.test(input.charAt(peg$currPos))) {
2268
+ // @ts-ignore
2269
+ function peg$parse_() {
2270
+ // @ts-ignore
2271
+ var s0, s1;
2272
+ // @ts-ignore
2273
+ peg$silentFails++;
2274
+ // @ts-ignore
2275
+ s0 = [];
2276
+ // @ts-ignore
2277
+ if (peg$r6.test(input.charAt(peg$currPos))) {
2278
+ // @ts-ignore
1464
2279
  s1 = input.charAt(peg$currPos);
2280
+ // @ts-ignore
1465
2281
  peg$currPos++;
2282
+ // @ts-ignore
1466
2283
  }
1467
2284
  else {
2285
+ // @ts-ignore
1468
2286
  s1 = peg$FAILED;
2287
+ // @ts-ignore
1469
2288
  if (peg$silentFails === 0)
1470
- peg$fail(peg$c63);
2289
+ peg$fail(peg$e31);
2290
+ }
2291
+ // @ts-ignore
2292
+ while (s1 !== peg$FAILED) {
2293
+ // @ts-ignore
2294
+ s0.push(s1);
2295
+ // @ts-ignore
2296
+ if (peg$r6.test(input.charAt(peg$currPos))) {
2297
+ // @ts-ignore
2298
+ s1 = input.charAt(peg$currPos);
2299
+ // @ts-ignore
2300
+ peg$currPos++;
2301
+ // @ts-ignore
2302
+ }
2303
+ else {
2304
+ // @ts-ignore
2305
+ s1 = peg$FAILED;
2306
+ // @ts-ignore
2307
+ if (peg$silentFails === 0)
2308
+ peg$fail(peg$e31);
2309
+ }
1471
2310
  }
1472
- }
1473
- peg$silentFails--;
1474
- if (s0 === peg$FAILED) {
2311
+ // @ts-ignore
2312
+ peg$silentFails--;
2313
+ // @ts-ignore
1475
2314
  s1 = peg$FAILED;
2315
+ // @ts-ignore
1476
2316
  if (peg$silentFails === 0)
1477
- peg$fail(peg$c61);
2317
+ peg$fail(peg$e30);
2318
+ // @ts-ignore
2319
+ return s0;
1478
2320
  }
1479
- return s0;
1480
- }
1481
- peg$result = peg$startRuleFunction();
1482
- if (peg$result !== peg$FAILED && peg$currPos === input.length) {
1483
- return peg$result;
1484
- }
1485
- else {
1486
- if (peg$result !== peg$FAILED && peg$currPos < input.length) {
1487
- peg$fail(peg$endExpectation());
2321
+ // @ts-ignore
2322
+ peg$result = peg$startRuleFunction();
2323
+ // @ts-ignore
2324
+ if (peg$result !== peg$FAILED && peg$currPos === input.length) {
2325
+ // @ts-ignore
2326
+ return peg$result;
2327
+ // @ts-ignore
2328
+ }
2329
+ else {
2330
+ // @ts-ignore
2331
+ if (peg$result !== peg$FAILED && peg$currPos < input.length) {
2332
+ // @ts-ignore
2333
+ peg$fail(peg$endExpectation());
2334
+ }
2335
+ // @ts-ignore
2336
+ throw peg$buildStructuredError(
2337
+ // @ts-ignore
2338
+ peg$maxFailExpected,
2339
+ // @ts-ignore
2340
+ peg$maxFailPos < input.length
2341
+ ? input.charAt(peg$maxFailPos)
2342
+ : null,
2343
+ // @ts-ignore
2344
+ peg$maxFailPos < input.length
2345
+ // @ts-ignore
2346
+ ? peg$computeLocation(peg$maxFailPos, peg$maxFailPos + 1)
2347
+ // @ts-ignore
2348
+ : peg$computeLocation(peg$maxFailPos, peg$maxFailPos));
1488
2349
  }
1489
- throw peg$buildStructuredError(peg$maxFailExpected, peg$maxFailPos < input.length ? input.charAt(peg$maxFailPos) : null, peg$maxFailPos < input.length
1490
- ? peg$computeLocation(peg$maxFailPos, peg$maxFailPos + 1)
1491
- : peg$computeLocation(peg$maxFailPos, peg$maxFailPos));
1492
2350
  }
1493
- }
1494
- exports.parse = peg$parse;
2351
+ // @ts-ignore
2352
+ return {
2353
+ SyntaxError: peg$SyntaxError,
2354
+ parse: peg$parse,
2355
+ };
2356
+ })();
2357
+ peggyParser.SyntaxError.prototype.name = "PeggySyntaxError";
2358
+ exports.parse = peggyParser.parse;
2359
+ exports.PeggySyntaxError = peggyParser
2360
+ .SyntaxError;
1495
2361
  //# sourceMappingURL=LogicParser.js.map