@ax-llm/ax 9.0.19 → 9.0.21
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/package.json +33 -85
- package/CHANGELOG.md +0 -184
- package/LICENSE +0 -201
- package/README.md +0 -569
- package/build/module/docs/assets/icons.d.ts +0 -1
- package/build/module/docs/assets/icons.js +0 -19
- package/build/module/docs/assets/icons.js.map +0 -1
- package/build/module/docs/assets/main.d.ts +0 -1
- package/build/module/docs/assets/main.js +0 -629
- package/build/module/docs/assets/main.js.map +0 -1
- package/build/module/docs/assets/navigation.d.ts +0 -1
- package/build/module/docs/assets/navigation.js +0 -3
- package/build/module/docs/assets/navigation.js.map +0 -1
- package/build/module/docs/assets/search.d.ts +0 -1
- package/build/module/docs/assets/search.js +0 -3
- package/build/module/docs/assets/search.js.map +0 -1
- package/build/module/src/ai/anthropic/api.d.ts +0 -19
- package/build/module/src/ai/anthropic/api.js +0 -326
- package/build/module/src/ai/anthropic/api.js.map +0 -1
- package/build/module/src/ai/anthropic/index.d.ts +0 -2
- package/build/module/src/ai/anthropic/index.js +0 -3
- package/build/module/src/ai/anthropic/index.js.map +0 -1
- package/build/module/src/ai/anthropic/info.d.ts +0 -2
- package/build/module/src/ai/anthropic/info.js +0 -40
- package/build/module/src/ai/anthropic/info.js.map +0 -1
- package/build/module/src/ai/anthropic/types.d.ts +0 -171
- package/build/module/src/ai/anthropic/types.js +0 -10
- package/build/module/src/ai/anthropic/types.js.map +0 -1
- package/build/module/src/ai/azure-openai/api.d.ts +0 -19
- package/build/module/src/ai/azure-openai/api.js +0 -30
- package/build/module/src/ai/azure-openai/api.js.map +0 -1
- package/build/module/src/ai/azure-openai/index.d.ts +0 -1
- package/build/module/src/ai/azure-openai/index.js +0 -2
- package/build/module/src/ai/azure-openai/index.js.map +0 -1
- package/build/module/src/ai/balance.d.ts +0 -23
- package/build/module/src/ai/balance.js +0 -87
- package/build/module/src/ai/balance.js.map +0 -1
- package/build/module/src/ai/base.d.ts +0 -55
- package/build/module/src/ai/base.js +0 -343
- package/build/module/src/ai/base.js.map +0 -1
- package/build/module/src/ai/cohere/api.d.ts +0 -22
- package/build/module/src/ai/cohere/api.js +0 -264
- package/build/module/src/ai/cohere/api.js.map +0 -1
- package/build/module/src/ai/cohere/index.d.ts +0 -2
- package/build/module/src/ai/cohere/index.js +0 -3
- package/build/module/src/ai/cohere/index.js.map +0 -1
- package/build/module/src/ai/cohere/info.d.ts +0 -2
- package/build/module/src/ai/cohere/info.js +0 -52
- package/build/module/src/ai/cohere/info.js.map +0 -1
- package/build/module/src/ai/cohere/types.d.ts +0 -102
- package/build/module/src/ai/cohere/types.js +0 -23
- package/build/module/src/ai/cohere/types.js.map +0 -1
- package/build/module/src/ai/deepseek/api.d.ts +0 -16
- package/build/module/src/ai/deepseek/api.js +0 -32
- package/build/module/src/ai/deepseek/api.js.map +0 -1
- package/build/module/src/ai/deepseek/index.d.ts +0 -2
- package/build/module/src/ai/deepseek/index.js +0 -3
- package/build/module/src/ai/deepseek/index.js.map +0 -1
- package/build/module/src/ai/deepseek/info.d.ts +0 -2
- package/build/module/src/ai/deepseek/info.js +0 -16
- package/build/module/src/ai/deepseek/info.js.map +0 -1
- package/build/module/src/ai/deepseek/types.d.ts +0 -8
- package/build/module/src/ai/deepseek/types.js +0 -10
- package/build/module/src/ai/deepseek/types.js.map +0 -1
- package/build/module/src/ai/google-gemini/api.d.ts +0 -36
- package/build/module/src/ai/google-gemini/api.js +0 -299
- package/build/module/src/ai/google-gemini/api.js.map +0 -1
- package/build/module/src/ai/google-gemini/index.d.ts +0 -2
- package/build/module/src/ai/google-gemini/index.js +0 -3
- package/build/module/src/ai/google-gemini/index.js.map +0 -1
- package/build/module/src/ai/google-gemini/info.d.ts +0 -6
- package/build/module/src/ai/google-gemini/info.js +0 -29
- package/build/module/src/ai/google-gemini/info.js.map +0 -1
- package/build/module/src/ai/google-gemini/types.d.ts +0 -146
- package/build/module/src/ai/google-gemini/types.js +0 -27
- package/build/module/src/ai/google-gemini/types.js.map +0 -1
- package/build/module/src/ai/groq/api.d.ts +0 -18
- package/build/module/src/ai/groq/api.js +0 -52
- package/build/module/src/ai/groq/api.js.map +0 -1
- package/build/module/src/ai/groq/index.d.ts +0 -1
- package/build/module/src/ai/groq/index.js +0 -2
- package/build/module/src/ai/groq/index.js.map +0 -1
- package/build/module/src/ai/groq/types.d.ts +0 -6
- package/build/module/src/ai/groq/types.js +0 -8
- package/build/module/src/ai/groq/types.js.map +0 -1
- package/build/module/src/ai/huggingface/api.d.ts +0 -19
- package/build/module/src/ai/huggingface/api.js +0 -115
- package/build/module/src/ai/huggingface/api.js.map +0 -1
- package/build/module/src/ai/huggingface/index.d.ts +0 -2
- package/build/module/src/ai/huggingface/index.js +0 -3
- package/build/module/src/ai/huggingface/index.js.map +0 -1
- package/build/module/src/ai/huggingface/info.d.ts +0 -6
- package/build/module/src/ai/huggingface/info.js +0 -6
- package/build/module/src/ai/huggingface/info.js.map +0 -1
- package/build/module/src/ai/huggingface/types.d.ts +0 -34
- package/build/module/src/ai/huggingface/types.js +0 -5
- package/build/module/src/ai/huggingface/types.js.map +0 -1
- package/build/module/src/ai/index.d.ts +0 -16
- package/build/module/src/ai/index.js +0 -16
- package/build/module/src/ai/index.js.map +0 -1
- package/build/module/src/ai/mistral/api.d.ts +0 -16
- package/build/module/src/ai/mistral/api.js +0 -32
- package/build/module/src/ai/mistral/api.js.map +0 -1
- package/build/module/src/ai/mistral/index.d.ts +0 -2
- package/build/module/src/ai/mistral/index.js +0 -3
- package/build/module/src/ai/mistral/index.js.map +0 -1
- package/build/module/src/ai/mistral/info.d.ts +0 -2
- package/build/module/src/ai/mistral/info.js +0 -34
- package/build/module/src/ai/mistral/info.js.map +0 -1
- package/build/module/src/ai/mistral/types.d.ts +0 -10
- package/build/module/src/ai/mistral/types.js +0 -13
- package/build/module/src/ai/mistral/types.js.map +0 -1
- package/build/module/src/ai/ollama/api.d.ts +0 -22
- package/build/module/src/ai/ollama/api.js +0 -32
- package/build/module/src/ai/ollama/api.js.map +0 -1
- package/build/module/src/ai/ollama/index.d.ts +0 -1
- package/build/module/src/ai/ollama/index.js +0 -2
- package/build/module/src/ai/ollama/index.js.map +0 -1
- package/build/module/src/ai/openai/api.d.ts +0 -29
- package/build/module/src/ai/openai/api.js +0 -283
- package/build/module/src/ai/openai/api.js.map +0 -1
- package/build/module/src/ai/openai/index.d.ts +0 -2
- package/build/module/src/ai/openai/index.js +0 -3
- package/build/module/src/ai/openai/index.js.map +0 -1
- package/build/module/src/ai/openai/info.d.ts +0 -6
- package/build/module/src/ai/openai/info.js +0 -50
- package/build/module/src/ai/openai/info.js.map +0 -1
- package/build/module/src/ai/openai/types.d.ts +0 -165
- package/build/module/src/ai/openai/types.js +0 -18
- package/build/module/src/ai/openai/types.js.map +0 -1
- package/build/module/src/ai/together/api.d.ts +0 -15
- package/build/module/src/ai/together/api.js +0 -28
- package/build/module/src/ai/together/api.js.map +0 -1
- package/build/module/src/ai/together/index.d.ts +0 -1
- package/build/module/src/ai/together/index.js +0 -2
- package/build/module/src/ai/together/index.js.map +0 -1
- package/build/module/src/ai/together/info.d.ts +0 -2
- package/build/module/src/ai/together/info.js +0 -2
- package/build/module/src/ai/together/info.js.map +0 -1
- package/build/module/src/ai/types.d.ts +0 -159
- package/build/module/src/ai/types.js +0 -2
- package/build/module/src/ai/types.js.map +0 -1
- package/build/module/src/ai/util.d.ts +0 -12
- package/build/module/src/ai/util.js +0 -63
- package/build/module/src/ai/util.js.map +0 -1
- package/build/module/src/ai/wrap.d.ts +0 -47
- package/build/module/src/ai/wrap.js +0 -95
- package/build/module/src/ai/wrap.js.map +0 -1
- package/build/module/src/db/base.d.ts +0 -23
- package/build/module/src/db/base.js +0 -87
- package/build/module/src/db/base.js.map +0 -1
- package/build/module/src/db/cloudflare.d.ts +0 -21
- package/build/module/src/db/cloudflare.js +0 -98
- package/build/module/src/db/cloudflare.js.map +0 -1
- package/build/module/src/db/index.d.ts +0 -6
- package/build/module/src/db/index.js +0 -7
- package/build/module/src/db/index.js.map +0 -1
- package/build/module/src/db/memory.d.ts +0 -21
- package/build/module/src/db/memory.js +0 -99
- package/build/module/src/db/memory.js.map +0 -1
- package/build/module/src/db/pinecone.d.ts +0 -21
- package/build/module/src/db/pinecone.js +0 -71
- package/build/module/src/db/pinecone.js.map +0 -1
- package/build/module/src/db/types.d.ts +0 -35
- package/build/module/src/db/types.js +0 -3
- package/build/module/src/db/types.js.map +0 -1
- package/build/module/src/db/weaviate.d.ts +0 -21
- package/build/module/src/db/weaviate.js +0 -127
- package/build/module/src/db/weaviate.js.map +0 -1
- package/build/module/src/db/wrap.d.ts +0 -13
- package/build/module/src/db/wrap.js +0 -35
- package/build/module/src/db/wrap.js.map +0 -1
- package/build/module/src/docs/index.d.ts +0 -4
- package/build/module/src/docs/index.js +0 -5
- package/build/module/src/docs/index.js.map +0 -1
- package/build/module/src/docs/manager.d.ts +0 -45
- package/build/module/src/docs/manager.js +0 -159
- package/build/module/src/docs/manager.js.map +0 -1
- package/build/module/src/docs/reranker.d.ts +0 -7
- package/build/module/src/docs/reranker.js +0 -26
- package/build/module/src/docs/reranker.js.map +0 -1
- package/build/module/src/docs/rewriter.d.ts +0 -4
- package/build/module/src/docs/rewriter.js +0 -9
- package/build/module/src/docs/rewriter.js.map +0 -1
- package/build/module/src/docs/tika.d.ts +0 -18
- package/build/module/src/docs/tika.js +0 -46
- package/build/module/src/docs/tika.js.map +0 -1
- package/build/module/src/dsp/asserts.d.ts +0 -32
- package/build/module/src/dsp/asserts.js +0 -91
- package/build/module/src/dsp/asserts.js.map +0 -1
- package/build/module/src/dsp/eval.d.ts +0 -43
- package/build/module/src/dsp/eval.js +0 -125
- package/build/module/src/dsp/eval.js.map +0 -1
- package/build/module/src/dsp/evaluate.d.ts +0 -12
- package/build/module/src/dsp/evaluate.js +0 -32
- package/build/module/src/dsp/evaluate.js.map +0 -1
- package/build/module/src/dsp/extract.d.ts +0 -25
- package/build/module/src/dsp/extract.js +0 -153
- package/build/module/src/dsp/extract.js.map +0 -1
- package/build/module/src/dsp/generate.d.ts +0 -55
- package/build/module/src/dsp/generate.js +0 -314
- package/build/module/src/dsp/generate.js.map +0 -1
- package/build/module/src/dsp/generate.test.d.ts +0 -1
- package/build/module/src/dsp/generate.test.js +0 -41
- package/build/module/src/dsp/generate.test.js.map +0 -1
- package/build/module/src/dsp/index.d.ts +0 -15
- package/build/module/src/dsp/index.js +0 -11
- package/build/module/src/dsp/index.js.map +0 -1
- package/build/module/src/dsp/loader.d.ts +0 -30
- package/build/module/src/dsp/loader.js +0 -81
- package/build/module/src/dsp/loader.js.map +0 -1
- package/build/module/src/dsp/optimize.d.ts +0 -27
- package/build/module/src/dsp/optimize.js +0 -95
- package/build/module/src/dsp/optimize.js.map +0 -1
- package/build/module/src/dsp/parser.d.ts +0 -87
- package/build/module/src/dsp/parser.js +0 -1542
- package/build/module/src/dsp/parser.js.map +0 -1
- package/build/module/src/dsp/program.d.ts +0 -73
- package/build/module/src/dsp/program.js +0 -116
- package/build/module/src/dsp/program.js.map +0 -1
- package/build/module/src/dsp/prompt.d.ts +0 -48
- package/build/module/src/dsp/prompt.js +0 -260
- package/build/module/src/dsp/prompt.js.map +0 -1
- package/build/module/src/dsp/registry.d.ts +0 -6
- package/build/module/src/dsp/registry.js +0 -15
- package/build/module/src/dsp/registry.js.map +0 -1
- package/build/module/src/dsp/router.d.ts +0 -26
- package/build/module/src/dsp/router.js +0 -71
- package/build/module/src/dsp/router.js.map +0 -1
- package/build/module/src/dsp/sig.d.ts +0 -37
- package/build/module/src/dsp/sig.js +0 -194
- package/build/module/src/dsp/sig.js.map +0 -1
- package/build/module/src/dsp/sig.test.d.ts +0 -1
- package/build/module/src/dsp/sig.test.js +0 -28
- package/build/module/src/dsp/sig.test.js.map +0 -1
- package/build/module/src/dsp/stopwords.d.ts +0 -1
- package/build/module/src/dsp/stopwords.js +0 -1164
- package/build/module/src/dsp/stopwords.js.map +0 -1
- package/build/module/src/dsp/strutil.d.ts +0 -11
- package/build/module/src/dsp/strutil.js +0 -60
- package/build/module/src/dsp/strutil.js.map +0 -1
- package/build/module/src/dsp/util.d.ts +0 -5
- package/build/module/src/dsp/util.js +0 -76
- package/build/module/src/dsp/util.js.map +0 -1
- package/build/module/src/funcs/code.d.ts +0 -9
- package/build/module/src/funcs/code.js +0 -63
- package/build/module/src/funcs/code.js.map +0 -1
- package/build/module/src/funcs/embed.d.ts +0 -6
- package/build/module/src/funcs/embed.js +0 -29
- package/build/module/src/funcs/embed.js.map +0 -1
- package/build/module/src/funcs/functions.d.ts +0 -16
- package/build/module/src/funcs/functions.js +0 -55
- package/build/module/src/funcs/functions.js.map +0 -1
- package/build/module/src/funcs/index.d.ts +0 -3
- package/build/module/src/funcs/index.js +0 -4
- package/build/module/src/funcs/index.js.map +0 -1
- package/build/module/src/funcs/jsonschema.d.ts +0 -2
- package/build/module/src/funcs/jsonschema.js +0 -97
- package/build/module/src/funcs/jsonschema.js.map +0 -1
- package/build/module/src/index.d.ts +0 -9
- package/build/module/src/index.js.map +0 -1
- package/build/module/src/mem/index.d.ts +0 -2
- package/build/module/src/mem/index.js +0 -3
- package/build/module/src/mem/index.js.map +0 -1
- package/build/module/src/mem/memory.d.ts +0 -16
- package/build/module/src/mem/memory.js +0 -77
- package/build/module/src/mem/memory.js.map +0 -1
- package/build/module/src/mem/types.d.ts +0 -10
- package/build/module/src/mem/types.js +0 -2
- package/build/module/src/mem/types.js.map +0 -1
- package/build/module/src/prompts/agent.d.ts +0 -34
- package/build/module/src/prompts/agent.js +0 -108
- package/build/module/src/prompts/agent.js.map +0 -1
- package/build/module/src/prompts/cot.d.ts +0 -9
- package/build/module/src/prompts/cot.js +0 -17
- package/build/module/src/prompts/cot.js.map +0 -1
- package/build/module/src/prompts/index.d.ts +0 -4
- package/build/module/src/prompts/index.js +0 -5
- package/build/module/src/prompts/index.js.map +0 -1
- package/build/module/src/prompts/prompts.test.d.ts +0 -1
- package/build/module/src/prompts/prompts.test.js +0 -54
- package/build/module/src/prompts/prompts.test.js.map +0 -1
- package/build/module/src/prompts/rag.d.ts +0 -23
- package/build/module/src/prompts/rag.js +0 -30
- package/build/module/src/prompts/rag.js.map +0 -1
- package/build/module/src/prompts/react.d.ts +0 -8
- package/build/module/src/prompts/react.js +0 -22
- package/build/module/src/prompts/react.js.map +0 -1
- package/build/module/src/trace/index.d.ts +0 -171
- package/build/module/src/trace/index.js +0 -67
- package/build/module/src/trace/index.js.map +0 -1
- package/build/module/src/util/apicall.d.ts +0 -18
- package/build/module/src/util/apicall.js +0 -50
- package/build/module/src/util/apicall.js.map +0 -1
- package/build/module/src/util/log.d.ts +0 -14
- package/build/module/src/util/log.js +0 -31
- package/build/module/src/util/log.js.map +0 -1
- package/build/module/src/util/other.d.ts +0 -1
- package/build/module/src/util/other.js +0 -5
- package/build/module/src/util/other.js.map +0 -1
- package/build/module/src/util/rate-limit.d.ts +0 -24
- package/build/module/src/util/rate-limit.js +0 -49
- package/build/module/src/util/rate-limit.js.map +0 -1
- package/build/module/src/util/stream.d.ts +0 -9
- package/build/module/src/util/stream.js +0 -29
- package/build/module/src/util/stream.js.map +0 -1
- package/build/module/src/util/transform.d.ts +0 -7
- package/build/module/src/util/transform.js +0 -59
- package/build/module/src/util/transform.js.map +0 -1
- /package/{build/module/src/index.js → index.js} +0 -0
|
@@ -1,1542 +0,0 @@
|
|
|
1
|
-
/* eslint-disable */
|
|
2
|
-
const peggyParser = // Generated by Peggy 3.0.2.
|
|
3
|
-
|
|
4
|
-
//
|
|
5
|
-
// https://peggyjs.org/
|
|
6
|
-
// @ts-ignore
|
|
7
|
-
(function () {
|
|
8
|
-
// @ts-ignore
|
|
9
|
-
"use strict";
|
|
10
|
-
// @ts-ignore
|
|
11
|
-
function peg$subclass(child, parent) {
|
|
12
|
-
// @ts-ignore
|
|
13
|
-
function C() { this.constructor = child; }
|
|
14
|
-
// @ts-ignore
|
|
15
|
-
C.prototype = parent.prototype;
|
|
16
|
-
// @ts-ignore
|
|
17
|
-
child.prototype = new C();
|
|
18
|
-
}
|
|
19
|
-
// @ts-ignore
|
|
20
|
-
function peg$SyntaxError(message, expected, found, location) {
|
|
21
|
-
// @ts-ignore
|
|
22
|
-
var self = Error.call(this, message);
|
|
23
|
-
// istanbul ignore next Check is a necessary evil to support older environments
|
|
24
|
-
// @ts-ignore
|
|
25
|
-
if (Object.setPrototypeOf) {
|
|
26
|
-
// @ts-ignore
|
|
27
|
-
Object.setPrototypeOf(self, peg$SyntaxError.prototype);
|
|
28
|
-
}
|
|
29
|
-
// @ts-ignore
|
|
30
|
-
self.expected = expected;
|
|
31
|
-
// @ts-ignore
|
|
32
|
-
self.found = found;
|
|
33
|
-
// @ts-ignore
|
|
34
|
-
self.location = location;
|
|
35
|
-
// @ts-ignore
|
|
36
|
-
self.name = "SyntaxError";
|
|
37
|
-
// @ts-ignore
|
|
38
|
-
return self;
|
|
39
|
-
}
|
|
40
|
-
// @ts-ignore
|
|
41
|
-
peg$subclass(peg$SyntaxError, Error);
|
|
42
|
-
// @ts-ignore
|
|
43
|
-
function peg$padEnd(str, targetLength, padString) {
|
|
44
|
-
// @ts-ignore
|
|
45
|
-
padString = padString || " ";
|
|
46
|
-
// @ts-ignore
|
|
47
|
-
if (str.length > targetLength) {
|
|
48
|
-
return str;
|
|
49
|
-
}
|
|
50
|
-
// @ts-ignore
|
|
51
|
-
targetLength -= str.length;
|
|
52
|
-
// @ts-ignore
|
|
53
|
-
padString += padString.repeat(targetLength);
|
|
54
|
-
// @ts-ignore
|
|
55
|
-
return str + padString.slice(0, targetLength);
|
|
56
|
-
}
|
|
57
|
-
// @ts-ignore
|
|
58
|
-
peg$SyntaxError.prototype.format = function (sources) {
|
|
59
|
-
// @ts-ignore
|
|
60
|
-
var str = "Error: " + this.message;
|
|
61
|
-
// @ts-ignore
|
|
62
|
-
if (this.location) {
|
|
63
|
-
// @ts-ignore
|
|
64
|
-
var src = null;
|
|
65
|
-
// @ts-ignore
|
|
66
|
-
var k;
|
|
67
|
-
// @ts-ignore
|
|
68
|
-
for (k = 0; k < sources.length; k++) {
|
|
69
|
-
// @ts-ignore
|
|
70
|
-
if (sources[k].source === this.location.source) {
|
|
71
|
-
// @ts-ignore
|
|
72
|
-
src = sources[k].text.split(/\r\n|\n|\r/g);
|
|
73
|
-
// @ts-ignore
|
|
74
|
-
break;
|
|
75
|
-
}
|
|
76
|
-
}
|
|
77
|
-
// @ts-ignore
|
|
78
|
-
var s = this.location.start;
|
|
79
|
-
// @ts-ignore
|
|
80
|
-
var offset_s = (this.location.source && (typeof this.location.source.offset === "function"))
|
|
81
|
-
// @ts-ignore
|
|
82
|
-
? this.location.source.offset(s)
|
|
83
|
-
// @ts-ignore
|
|
84
|
-
: s;
|
|
85
|
-
// @ts-ignore
|
|
86
|
-
var loc = this.location.source + ":" + offset_s.line + ":" + offset_s.column;
|
|
87
|
-
// @ts-ignore
|
|
88
|
-
if (src) {
|
|
89
|
-
// @ts-ignore
|
|
90
|
-
var e = this.location.end;
|
|
91
|
-
// @ts-ignore
|
|
92
|
-
var filler = peg$padEnd("", offset_s.line.toString().length, ' ');
|
|
93
|
-
// @ts-ignore
|
|
94
|
-
var line = src[s.line - 1];
|
|
95
|
-
// @ts-ignore
|
|
96
|
-
var last = s.line === e.line ? e.column : line.length + 1;
|
|
97
|
-
// @ts-ignore
|
|
98
|
-
var hatLen = (last - s.column) || 1;
|
|
99
|
-
// @ts-ignore
|
|
100
|
-
str += "\n --> " + loc + "\n"
|
|
101
|
-
// @ts-ignore
|
|
102
|
-
+ filler + " |\n"
|
|
103
|
-
// @ts-ignore
|
|
104
|
-
+ offset_s.line + " | " + line + "\n"
|
|
105
|
-
// @ts-ignore
|
|
106
|
-
+ filler + " | " + peg$padEnd("", s.column - 1, ' ')
|
|
107
|
-
// @ts-ignore
|
|
108
|
-
+ peg$padEnd("", hatLen, "^");
|
|
109
|
-
// @ts-ignore
|
|
110
|
-
}
|
|
111
|
-
else {
|
|
112
|
-
// @ts-ignore
|
|
113
|
-
str += "\n at " + loc;
|
|
114
|
-
}
|
|
115
|
-
}
|
|
116
|
-
// @ts-ignore
|
|
117
|
-
return str;
|
|
118
|
-
};
|
|
119
|
-
// @ts-ignore
|
|
120
|
-
peg$SyntaxError.buildMessage = function (expected, found) {
|
|
121
|
-
// @ts-ignore
|
|
122
|
-
var DESCRIBE_EXPECTATION_FNS = {
|
|
123
|
-
// @ts-ignore
|
|
124
|
-
literal: function (expectation) {
|
|
125
|
-
// @ts-ignore
|
|
126
|
-
return "\"" + literalEscape(expectation.text) + "\"";
|
|
127
|
-
},
|
|
128
|
-
// @ts-ignore
|
|
129
|
-
class: function (expectation) {
|
|
130
|
-
// @ts-ignore
|
|
131
|
-
var escapedParts = expectation.parts.map(function (part) {
|
|
132
|
-
// @ts-ignore
|
|
133
|
-
return Array.isArray(part)
|
|
134
|
-
// @ts-ignore
|
|
135
|
-
? classEscape(part[0]) + "-" + classEscape(part[1])
|
|
136
|
-
// @ts-ignore
|
|
137
|
-
: classEscape(part);
|
|
138
|
-
});
|
|
139
|
-
// @ts-ignore
|
|
140
|
-
return "[" + (expectation.inverted ? "^" : "") + escapedParts.join("") + "]";
|
|
141
|
-
},
|
|
142
|
-
// @ts-ignore
|
|
143
|
-
any: function () {
|
|
144
|
-
// @ts-ignore
|
|
145
|
-
return "any character";
|
|
146
|
-
},
|
|
147
|
-
// @ts-ignore
|
|
148
|
-
end: function () {
|
|
149
|
-
// @ts-ignore
|
|
150
|
-
return "end of input";
|
|
151
|
-
},
|
|
152
|
-
// @ts-ignore
|
|
153
|
-
other: function (expectation) {
|
|
154
|
-
// @ts-ignore
|
|
155
|
-
return expectation.description;
|
|
156
|
-
}
|
|
157
|
-
};
|
|
158
|
-
// @ts-ignore
|
|
159
|
-
function hex(ch) {
|
|
160
|
-
// @ts-ignore
|
|
161
|
-
return ch.charCodeAt(0).toString(16).toUpperCase();
|
|
162
|
-
}
|
|
163
|
-
// @ts-ignore
|
|
164
|
-
function literalEscape(s) {
|
|
165
|
-
// @ts-ignore
|
|
166
|
-
return s
|
|
167
|
-
// @ts-ignore
|
|
168
|
-
.replace(/\\/g, "\\\\")
|
|
169
|
-
// @ts-ignore
|
|
170
|
-
.replace(/"/g, "\\\"")
|
|
171
|
-
// @ts-ignore
|
|
172
|
-
.replace(/\0/g, "\\0")
|
|
173
|
-
// @ts-ignore
|
|
174
|
-
.replace(/\t/g, "\\t")
|
|
175
|
-
// @ts-ignore
|
|
176
|
-
.replace(/\n/g, "\\n")
|
|
177
|
-
// @ts-ignore
|
|
178
|
-
.replace(/\r/g, "\\r")
|
|
179
|
-
// @ts-ignore
|
|
180
|
-
.replace(/[\x00-\x0F]/g, function (ch) { return "\\x0" + hex(ch); })
|
|
181
|
-
// @ts-ignore
|
|
182
|
-
.replace(/[\x10-\x1F\x7F-\x9F]/g, function (ch) { return "\\x" + hex(ch); });
|
|
183
|
-
}
|
|
184
|
-
// @ts-ignore
|
|
185
|
-
function classEscape(s) {
|
|
186
|
-
// @ts-ignore
|
|
187
|
-
return s
|
|
188
|
-
// @ts-ignore
|
|
189
|
-
.replace(/\\/g, "\\\\")
|
|
190
|
-
// @ts-ignore
|
|
191
|
-
.replace(/\]/g, "\\]")
|
|
192
|
-
// @ts-ignore
|
|
193
|
-
.replace(/\^/g, "\\^")
|
|
194
|
-
// @ts-ignore
|
|
195
|
-
.replace(/-/g, "\\-")
|
|
196
|
-
// @ts-ignore
|
|
197
|
-
.replace(/\0/g, "\\0")
|
|
198
|
-
// @ts-ignore
|
|
199
|
-
.replace(/\t/g, "\\t")
|
|
200
|
-
// @ts-ignore
|
|
201
|
-
.replace(/\n/g, "\\n")
|
|
202
|
-
// @ts-ignore
|
|
203
|
-
.replace(/\r/g, "\\r")
|
|
204
|
-
// @ts-ignore
|
|
205
|
-
.replace(/[\x00-\x0F]/g, function (ch) { return "\\x0" + hex(ch); })
|
|
206
|
-
// @ts-ignore
|
|
207
|
-
.replace(/[\x10-\x1F\x7F-\x9F]/g, function (ch) { return "\\x" + hex(ch); });
|
|
208
|
-
}
|
|
209
|
-
// @ts-ignore
|
|
210
|
-
function describeExpectation(expectation) {
|
|
211
|
-
// @ts-ignore
|
|
212
|
-
return DESCRIBE_EXPECTATION_FNS[expectation.type](expectation);
|
|
213
|
-
}
|
|
214
|
-
// @ts-ignore
|
|
215
|
-
function describeExpected(expected) {
|
|
216
|
-
// @ts-ignore
|
|
217
|
-
var descriptions = expected.map(describeExpectation);
|
|
218
|
-
// @ts-ignore
|
|
219
|
-
var i, j;
|
|
220
|
-
// @ts-ignore
|
|
221
|
-
descriptions.sort();
|
|
222
|
-
// @ts-ignore
|
|
223
|
-
if (descriptions.length > 0) {
|
|
224
|
-
// @ts-ignore
|
|
225
|
-
for (i = 1, j = 1; i < descriptions.length; i++) {
|
|
226
|
-
// @ts-ignore
|
|
227
|
-
if (descriptions[i - 1] !== descriptions[i]) {
|
|
228
|
-
// @ts-ignore
|
|
229
|
-
descriptions[j] = descriptions[i];
|
|
230
|
-
// @ts-ignore
|
|
231
|
-
j++;
|
|
232
|
-
}
|
|
233
|
-
}
|
|
234
|
-
// @ts-ignore
|
|
235
|
-
descriptions.length = j;
|
|
236
|
-
}
|
|
237
|
-
// @ts-ignore
|
|
238
|
-
switch (descriptions.length) {
|
|
239
|
-
// @ts-ignore
|
|
240
|
-
case 1:
|
|
241
|
-
// @ts-ignore
|
|
242
|
-
return descriptions[0];
|
|
243
|
-
// @ts-ignore
|
|
244
|
-
case 2:
|
|
245
|
-
// @ts-ignore
|
|
246
|
-
return descriptions[0] + " or " + descriptions[1];
|
|
247
|
-
// @ts-ignore
|
|
248
|
-
default:
|
|
249
|
-
// @ts-ignore
|
|
250
|
-
return descriptions.slice(0, -1).join(", ")
|
|
251
|
-
// @ts-ignore
|
|
252
|
-
+ ", or "
|
|
253
|
-
// @ts-ignore
|
|
254
|
-
+ descriptions[descriptions.length - 1];
|
|
255
|
-
}
|
|
256
|
-
}
|
|
257
|
-
// @ts-ignore
|
|
258
|
-
function describeFound(found) {
|
|
259
|
-
// @ts-ignore
|
|
260
|
-
return found ? "\"" + literalEscape(found) + "\"" : "end of input";
|
|
261
|
-
}
|
|
262
|
-
// @ts-ignore
|
|
263
|
-
return "Expected " + describeExpected(expected) + " but " + describeFound(found) + " found.";
|
|
264
|
-
};
|
|
265
|
-
// @ts-ignore
|
|
266
|
-
function peg$parse(input, options) {
|
|
267
|
-
// @ts-ignore
|
|
268
|
-
options = options !== undefined ? options : {};
|
|
269
|
-
// @ts-ignore
|
|
270
|
-
var peg$FAILED = {};
|
|
271
|
-
// @ts-ignore
|
|
272
|
-
var peg$source = options.grammarSource;
|
|
273
|
-
// @ts-ignore
|
|
274
|
-
var peg$startRuleFunctions = { ParsedSignature: peg$parseParsedSignature };
|
|
275
|
-
// @ts-ignore
|
|
276
|
-
var peg$startRuleFunction = peg$parseParsedSignature;
|
|
277
|
-
// @ts-ignore
|
|
278
|
-
var peg$c0 = "->";
|
|
279
|
-
var peg$c1 = ",";
|
|
280
|
-
var peg$c2 = "?";
|
|
281
|
-
var peg$c3 = ":";
|
|
282
|
-
var peg$c4 = "[]";
|
|
283
|
-
var peg$c5 = "string";
|
|
284
|
-
var peg$c6 = "number";
|
|
285
|
-
var peg$c7 = "boolean";
|
|
286
|
-
var peg$c8 = "json";
|
|
287
|
-
var peg$c9 = "image";
|
|
288
|
-
var peg$c10 = "'";
|
|
289
|
-
var peg$c11 = "\"";
|
|
290
|
-
var peg$r0 = /^[a-zA-Z_0-9]/;
|
|
291
|
-
var peg$r1 = /^[^']/;
|
|
292
|
-
var peg$r2 = /^[^"]/;
|
|
293
|
-
var peg$r3 = /^[ \t\r\n]/;
|
|
294
|
-
var peg$e0 = peg$literalExpectation("->", false);
|
|
295
|
-
var peg$e1 = peg$literalExpectation(",", false);
|
|
296
|
-
var peg$e2 = peg$literalExpectation("?", false);
|
|
297
|
-
var peg$e3 = peg$literalExpectation(":", false);
|
|
298
|
-
var peg$e4 = peg$literalExpectation("[]", false);
|
|
299
|
-
var peg$e5 = peg$literalExpectation("string", false);
|
|
300
|
-
var peg$e6 = peg$literalExpectation("number", false);
|
|
301
|
-
var peg$e7 = peg$literalExpectation("boolean", false);
|
|
302
|
-
var peg$e8 = peg$literalExpectation("json", false);
|
|
303
|
-
var peg$e9 = peg$literalExpectation("image", false);
|
|
304
|
-
var peg$e10 = peg$classExpectation([["a", "z"], ["A", "Z"], "_", ["0", "9"]], false, false);
|
|
305
|
-
var peg$e11 = peg$literalExpectation("'", false);
|
|
306
|
-
var peg$e12 = peg$classExpectation(["'"], true, false);
|
|
307
|
-
var peg$e13 = peg$literalExpectation("\"", false);
|
|
308
|
-
var peg$e14 = peg$classExpectation(["\""], true, false);
|
|
309
|
-
var peg$e15 = peg$classExpectation([" ", "\t", "\r", "\n"], false, false);
|
|
310
|
-
// @ts-ignore
|
|
311
|
-
var peg$f0 = function (optionalDesc, inputs, outputs) {
|
|
312
|
-
// @ts-ignore
|
|
313
|
-
return {
|
|
314
|
-
// @ts-ignore
|
|
315
|
-
desc: optionalDesc ? optionalDesc.join("").trim() : undefined,
|
|
316
|
-
// @ts-ignore
|
|
317
|
-
inputs,
|
|
318
|
-
// @ts-ignore
|
|
319
|
-
outputs
|
|
320
|
-
};
|
|
321
|
-
}; // @ts-ignore
|
|
322
|
-
var peg$f1 = function (name, isOptional, optionalType, optionalDesc) {
|
|
323
|
-
// @ts-ignore
|
|
324
|
-
return {
|
|
325
|
-
// @ts-ignore
|
|
326
|
-
name,
|
|
327
|
-
// @ts-ignore
|
|
328
|
-
desc: optionalDesc ? optionalDesc.join("").trim() : undefined,
|
|
329
|
-
// @ts-ignore
|
|
330
|
-
type: optionalType ? optionalType.at(-1) : undefined,
|
|
331
|
-
// @ts-ignore
|
|
332
|
-
isOptional: isOptional ? true : undefined
|
|
333
|
-
};
|
|
334
|
-
}; // @ts-ignore
|
|
335
|
-
var peg$f2 = function (type, isArray) {
|
|
336
|
-
// @ts-ignore
|
|
337
|
-
return { name: type, isArray: isArray ? true : false };
|
|
338
|
-
}; // @ts-ignore
|
|
339
|
-
var peg$f3 = function (chars) {
|
|
340
|
-
// @ts-ignore
|
|
341
|
-
return chars.join("");
|
|
342
|
-
}; // @ts-ignore
|
|
343
|
-
var peg$f4 = function (content) {
|
|
344
|
-
return content.join("");
|
|
345
|
-
}; // @ts-ignore
|
|
346
|
-
var peg$f5 = function (content) {
|
|
347
|
-
return content.join("");
|
|
348
|
-
}; // @ts-ignore
|
|
349
|
-
var peg$f6 = function () {
|
|
350
|
-
// @ts-ignore
|
|
351
|
-
return "";
|
|
352
|
-
}; // @ts-ignore
|
|
353
|
-
var peg$f7 = function () {
|
|
354
|
-
// @ts-ignore
|
|
355
|
-
return "";
|
|
356
|
-
};
|
|
357
|
-
// @ts-ignore
|
|
358
|
-
var peg$currPos = 0;
|
|
359
|
-
// @ts-ignore
|
|
360
|
-
var peg$savedPos = 0;
|
|
361
|
-
// @ts-ignore
|
|
362
|
-
var peg$posDetailsCache = [{ line: 1, column: 1 }];
|
|
363
|
-
// @ts-ignore
|
|
364
|
-
var peg$maxFailPos = 0;
|
|
365
|
-
// @ts-ignore
|
|
366
|
-
var peg$maxFailExpected = [];
|
|
367
|
-
// @ts-ignore
|
|
368
|
-
var peg$silentFails = 0;
|
|
369
|
-
// @ts-ignore
|
|
370
|
-
var peg$resultsCache = {};
|
|
371
|
-
// @ts-ignore
|
|
372
|
-
var peg$result;
|
|
373
|
-
// @ts-ignore
|
|
374
|
-
if ("startRule" in options) {
|
|
375
|
-
// @ts-ignore
|
|
376
|
-
if (!(options.startRule in peg$startRuleFunctions)) {
|
|
377
|
-
// @ts-ignore
|
|
378
|
-
throw new Error("Can't start parsing from rule \"" + options.startRule + "\".");
|
|
379
|
-
}
|
|
380
|
-
// @ts-ignore
|
|
381
|
-
peg$startRuleFunction = peg$startRuleFunctions[options.startRule];
|
|
382
|
-
}
|
|
383
|
-
// @ts-ignore
|
|
384
|
-
function text() {
|
|
385
|
-
// @ts-ignore
|
|
386
|
-
return input.substring(peg$savedPos, peg$currPos);
|
|
387
|
-
}
|
|
388
|
-
// @ts-ignore
|
|
389
|
-
function offset() {
|
|
390
|
-
// @ts-ignore
|
|
391
|
-
return peg$savedPos;
|
|
392
|
-
}
|
|
393
|
-
// @ts-ignore
|
|
394
|
-
function range() {
|
|
395
|
-
// @ts-ignore
|
|
396
|
-
return {
|
|
397
|
-
// @ts-ignore
|
|
398
|
-
source: peg$source,
|
|
399
|
-
// @ts-ignore
|
|
400
|
-
start: peg$savedPos,
|
|
401
|
-
// @ts-ignore
|
|
402
|
-
end: peg$currPos
|
|
403
|
-
};
|
|
404
|
-
}
|
|
405
|
-
// @ts-ignore
|
|
406
|
-
function location() {
|
|
407
|
-
// @ts-ignore
|
|
408
|
-
return peg$computeLocation(peg$savedPos, peg$currPos);
|
|
409
|
-
}
|
|
410
|
-
// @ts-ignore
|
|
411
|
-
function expected(description, location) {
|
|
412
|
-
// @ts-ignore
|
|
413
|
-
location = location !== undefined
|
|
414
|
-
// @ts-ignore
|
|
415
|
-
? location
|
|
416
|
-
// @ts-ignore
|
|
417
|
-
: peg$computeLocation(peg$savedPos, peg$currPos);
|
|
418
|
-
// @ts-ignore
|
|
419
|
-
throw peg$buildStructuredError(
|
|
420
|
-
// @ts-ignore
|
|
421
|
-
[peg$otherExpectation(description)],
|
|
422
|
-
// @ts-ignore
|
|
423
|
-
input.substring(peg$savedPos, peg$currPos),
|
|
424
|
-
// @ts-ignore
|
|
425
|
-
location);
|
|
426
|
-
}
|
|
427
|
-
// @ts-ignore
|
|
428
|
-
function error(message, location) {
|
|
429
|
-
// @ts-ignore
|
|
430
|
-
location = location !== undefined
|
|
431
|
-
// @ts-ignore
|
|
432
|
-
? location
|
|
433
|
-
// @ts-ignore
|
|
434
|
-
: peg$computeLocation(peg$savedPos, peg$currPos);
|
|
435
|
-
// @ts-ignore
|
|
436
|
-
throw peg$buildSimpleError(message, location);
|
|
437
|
-
}
|
|
438
|
-
// @ts-ignore
|
|
439
|
-
function peg$literalExpectation(text, ignoreCase) {
|
|
440
|
-
// @ts-ignore
|
|
441
|
-
return { type: "literal", text: text, ignoreCase: ignoreCase };
|
|
442
|
-
}
|
|
443
|
-
// @ts-ignore
|
|
444
|
-
function peg$classExpectation(parts, inverted, ignoreCase) {
|
|
445
|
-
// @ts-ignore
|
|
446
|
-
return { type: "class", parts: parts, inverted: inverted, ignoreCase: ignoreCase };
|
|
447
|
-
}
|
|
448
|
-
// @ts-ignore
|
|
449
|
-
function peg$anyExpectation() {
|
|
450
|
-
// @ts-ignore
|
|
451
|
-
return { type: "any" };
|
|
452
|
-
}
|
|
453
|
-
// @ts-ignore
|
|
454
|
-
function peg$endExpectation() {
|
|
455
|
-
// @ts-ignore
|
|
456
|
-
return { type: "end" };
|
|
457
|
-
}
|
|
458
|
-
// @ts-ignore
|
|
459
|
-
function peg$otherExpectation(description) {
|
|
460
|
-
// @ts-ignore
|
|
461
|
-
return { type: "other", description: description };
|
|
462
|
-
}
|
|
463
|
-
// @ts-ignore
|
|
464
|
-
function peg$computePosDetails(pos) {
|
|
465
|
-
// @ts-ignore
|
|
466
|
-
var details = peg$posDetailsCache[pos];
|
|
467
|
-
// @ts-ignore
|
|
468
|
-
var p;
|
|
469
|
-
// @ts-ignore
|
|
470
|
-
if (details) {
|
|
471
|
-
// @ts-ignore
|
|
472
|
-
return details;
|
|
473
|
-
// @ts-ignore
|
|
474
|
-
}
|
|
475
|
-
else {
|
|
476
|
-
// @ts-ignore
|
|
477
|
-
p = pos - 1;
|
|
478
|
-
// @ts-ignore
|
|
479
|
-
while (!peg$posDetailsCache[p]) {
|
|
480
|
-
// @ts-ignore
|
|
481
|
-
p--;
|
|
482
|
-
}
|
|
483
|
-
// @ts-ignore
|
|
484
|
-
details = peg$posDetailsCache[p];
|
|
485
|
-
// @ts-ignore
|
|
486
|
-
details = {
|
|
487
|
-
// @ts-ignore
|
|
488
|
-
line: details.line,
|
|
489
|
-
// @ts-ignore
|
|
490
|
-
column: details.column
|
|
491
|
-
};
|
|
492
|
-
// @ts-ignore
|
|
493
|
-
while (p < pos) {
|
|
494
|
-
// @ts-ignore
|
|
495
|
-
if (input.charCodeAt(p) === 10) {
|
|
496
|
-
// @ts-ignore
|
|
497
|
-
details.line++;
|
|
498
|
-
// @ts-ignore
|
|
499
|
-
details.column = 1;
|
|
500
|
-
// @ts-ignore
|
|
501
|
-
}
|
|
502
|
-
else {
|
|
503
|
-
// @ts-ignore
|
|
504
|
-
details.column++;
|
|
505
|
-
}
|
|
506
|
-
// @ts-ignore
|
|
507
|
-
p++;
|
|
508
|
-
}
|
|
509
|
-
// @ts-ignore
|
|
510
|
-
peg$posDetailsCache[pos] = details;
|
|
511
|
-
// @ts-ignore
|
|
512
|
-
return details;
|
|
513
|
-
}
|
|
514
|
-
}
|
|
515
|
-
// @ts-ignore
|
|
516
|
-
function peg$computeLocation(startPos, endPos, offset) {
|
|
517
|
-
// @ts-ignore
|
|
518
|
-
var startPosDetails = peg$computePosDetails(startPos);
|
|
519
|
-
// @ts-ignore
|
|
520
|
-
var endPosDetails = peg$computePosDetails(endPos);
|
|
521
|
-
// @ts-ignore
|
|
522
|
-
var res = {
|
|
523
|
-
// @ts-ignore
|
|
524
|
-
source: peg$source,
|
|
525
|
-
// @ts-ignore
|
|
526
|
-
start: {
|
|
527
|
-
// @ts-ignore
|
|
528
|
-
offset: startPos,
|
|
529
|
-
// @ts-ignore
|
|
530
|
-
line: startPosDetails.line,
|
|
531
|
-
// @ts-ignore
|
|
532
|
-
column: startPosDetails.column
|
|
533
|
-
},
|
|
534
|
-
// @ts-ignore
|
|
535
|
-
end: {
|
|
536
|
-
// @ts-ignore
|
|
537
|
-
offset: endPos,
|
|
538
|
-
// @ts-ignore
|
|
539
|
-
line: endPosDetails.line,
|
|
540
|
-
// @ts-ignore
|
|
541
|
-
column: endPosDetails.column
|
|
542
|
-
}
|
|
543
|
-
};
|
|
544
|
-
// @ts-ignore
|
|
545
|
-
if (offset && peg$source && (typeof peg$source.offset === "function")) {
|
|
546
|
-
// @ts-ignore
|
|
547
|
-
res.start = peg$source.offset(res.start);
|
|
548
|
-
// @ts-ignore
|
|
549
|
-
res.end = peg$source.offset(res.end);
|
|
550
|
-
}
|
|
551
|
-
// @ts-ignore
|
|
552
|
-
return res;
|
|
553
|
-
}
|
|
554
|
-
// @ts-ignore
|
|
555
|
-
function peg$fail(expected) {
|
|
556
|
-
// @ts-ignore
|
|
557
|
-
if (peg$currPos < peg$maxFailPos) {
|
|
558
|
-
return;
|
|
559
|
-
}
|
|
560
|
-
// @ts-ignore
|
|
561
|
-
if (peg$currPos > peg$maxFailPos) {
|
|
562
|
-
// @ts-ignore
|
|
563
|
-
peg$maxFailPos = peg$currPos;
|
|
564
|
-
// @ts-ignore
|
|
565
|
-
peg$maxFailExpected = [];
|
|
566
|
-
}
|
|
567
|
-
// @ts-ignore
|
|
568
|
-
peg$maxFailExpected.push(expected);
|
|
569
|
-
}
|
|
570
|
-
// @ts-ignore
|
|
571
|
-
function peg$buildSimpleError(message, location) {
|
|
572
|
-
// @ts-ignore
|
|
573
|
-
return new peg$SyntaxError(message, null, null, location);
|
|
574
|
-
}
|
|
575
|
-
// @ts-ignore
|
|
576
|
-
function peg$buildStructuredError(expected, found, location) {
|
|
577
|
-
// @ts-ignore
|
|
578
|
-
return new peg$SyntaxError(
|
|
579
|
-
// @ts-ignore
|
|
580
|
-
peg$SyntaxError.buildMessage(expected, found),
|
|
581
|
-
// @ts-ignore
|
|
582
|
-
expected,
|
|
583
|
-
// @ts-ignore
|
|
584
|
-
found,
|
|
585
|
-
// @ts-ignore
|
|
586
|
-
location);
|
|
587
|
-
}
|
|
588
|
-
// @ts-ignore
|
|
589
|
-
function peg$parseParsedSignature() {
|
|
590
|
-
// @ts-ignore
|
|
591
|
-
var s0, s1, s2, s3, s4, s5, s6, s7;
|
|
592
|
-
// @ts-ignore
|
|
593
|
-
var key = peg$currPos * 9 + 0;
|
|
594
|
-
// @ts-ignore
|
|
595
|
-
var cached = peg$resultsCache[key];
|
|
596
|
-
// @ts-ignore
|
|
597
|
-
if (cached) {
|
|
598
|
-
// @ts-ignore
|
|
599
|
-
peg$currPos = cached.nextPos;
|
|
600
|
-
// @ts-ignore
|
|
601
|
-
return cached.result;
|
|
602
|
-
}
|
|
603
|
-
// @ts-ignore
|
|
604
|
-
s0 = peg$currPos;
|
|
605
|
-
// @ts-ignore
|
|
606
|
-
s1 = peg$currPos;
|
|
607
|
-
// @ts-ignore
|
|
608
|
-
s2 = peg$parse_();
|
|
609
|
-
// @ts-ignore
|
|
610
|
-
s3 = peg$parseParsedString();
|
|
611
|
-
// @ts-ignore
|
|
612
|
-
if (s3 !== peg$FAILED) {
|
|
613
|
-
// @ts-ignore
|
|
614
|
-
s4 = peg$parse_();
|
|
615
|
-
// @ts-ignore
|
|
616
|
-
s2 = [s2, s3, s4];
|
|
617
|
-
// @ts-ignore
|
|
618
|
-
s1 = s2;
|
|
619
|
-
// @ts-ignore
|
|
620
|
-
}
|
|
621
|
-
else {
|
|
622
|
-
// @ts-ignore
|
|
623
|
-
peg$currPos = s1;
|
|
624
|
-
// @ts-ignore
|
|
625
|
-
s1 = peg$FAILED;
|
|
626
|
-
}
|
|
627
|
-
// @ts-ignore
|
|
628
|
-
if (s1 === peg$FAILED) {
|
|
629
|
-
// @ts-ignore
|
|
630
|
-
s1 = null;
|
|
631
|
-
}
|
|
632
|
-
// @ts-ignore
|
|
633
|
-
s2 = peg$parseParsedFieldList();
|
|
634
|
-
// @ts-ignore
|
|
635
|
-
s3 = peg$parse__();
|
|
636
|
-
// @ts-ignore
|
|
637
|
-
if (s3 !== peg$FAILED) {
|
|
638
|
-
// @ts-ignore
|
|
639
|
-
if (input.substr(peg$currPos, 2) === peg$c0) {
|
|
640
|
-
// @ts-ignore
|
|
641
|
-
s4 = peg$c0;
|
|
642
|
-
// @ts-ignore
|
|
643
|
-
peg$currPos += 2;
|
|
644
|
-
// @ts-ignore
|
|
645
|
-
}
|
|
646
|
-
else {
|
|
647
|
-
// @ts-ignore
|
|
648
|
-
s4 = peg$FAILED;
|
|
649
|
-
// @ts-ignore
|
|
650
|
-
if (peg$silentFails === 0) {
|
|
651
|
-
peg$fail(peg$e0);
|
|
652
|
-
}
|
|
653
|
-
}
|
|
654
|
-
// @ts-ignore
|
|
655
|
-
if (s4 !== peg$FAILED) {
|
|
656
|
-
// @ts-ignore
|
|
657
|
-
s5 = peg$parse__();
|
|
658
|
-
// @ts-ignore
|
|
659
|
-
if (s5 !== peg$FAILED) {
|
|
660
|
-
// @ts-ignore
|
|
661
|
-
s6 = peg$parseParsedFieldList();
|
|
662
|
-
// @ts-ignore
|
|
663
|
-
s7 = peg$parse_();
|
|
664
|
-
// @ts-ignore
|
|
665
|
-
peg$savedPos = s0;
|
|
666
|
-
// @ts-ignore
|
|
667
|
-
s0 = peg$f0(s1, s2, s6);
|
|
668
|
-
// @ts-ignore
|
|
669
|
-
}
|
|
670
|
-
else {
|
|
671
|
-
// @ts-ignore
|
|
672
|
-
peg$currPos = s0;
|
|
673
|
-
// @ts-ignore
|
|
674
|
-
s0 = peg$FAILED;
|
|
675
|
-
}
|
|
676
|
-
// @ts-ignore
|
|
677
|
-
}
|
|
678
|
-
else {
|
|
679
|
-
// @ts-ignore
|
|
680
|
-
peg$currPos = s0;
|
|
681
|
-
// @ts-ignore
|
|
682
|
-
s0 = peg$FAILED;
|
|
683
|
-
}
|
|
684
|
-
// @ts-ignore
|
|
685
|
-
}
|
|
686
|
-
else {
|
|
687
|
-
// @ts-ignore
|
|
688
|
-
peg$currPos = s0;
|
|
689
|
-
// @ts-ignore
|
|
690
|
-
s0 = peg$FAILED;
|
|
691
|
-
}
|
|
692
|
-
// @ts-ignore
|
|
693
|
-
peg$resultsCache[key] = { nextPos: peg$currPos, result: s0 };
|
|
694
|
-
// @ts-ignore
|
|
695
|
-
return s0;
|
|
696
|
-
}
|
|
697
|
-
// @ts-ignore
|
|
698
|
-
function peg$parseParsedFieldList() {
|
|
699
|
-
// @ts-ignore
|
|
700
|
-
var s0, s1, s2, s3, s4, s5;
|
|
701
|
-
// @ts-ignore
|
|
702
|
-
var key = peg$currPos * 9 + 1;
|
|
703
|
-
// @ts-ignore
|
|
704
|
-
var cached = peg$resultsCache[key];
|
|
705
|
-
// @ts-ignore
|
|
706
|
-
if (cached) {
|
|
707
|
-
// @ts-ignore
|
|
708
|
-
peg$currPos = cached.nextPos;
|
|
709
|
-
// @ts-ignore
|
|
710
|
-
return cached.result;
|
|
711
|
-
}
|
|
712
|
-
// @ts-ignore
|
|
713
|
-
s0 = [];
|
|
714
|
-
// @ts-ignore
|
|
715
|
-
s1 = peg$parseParsedField();
|
|
716
|
-
// @ts-ignore
|
|
717
|
-
while (s1 !== peg$FAILED) {
|
|
718
|
-
// @ts-ignore
|
|
719
|
-
s0.push(s1);
|
|
720
|
-
// @ts-ignore
|
|
721
|
-
s1 = peg$currPos;
|
|
722
|
-
// @ts-ignore
|
|
723
|
-
s2 = peg$currPos;
|
|
724
|
-
// @ts-ignore
|
|
725
|
-
s3 = peg$parse_();
|
|
726
|
-
// @ts-ignore
|
|
727
|
-
if (input.charCodeAt(peg$currPos) === 44) {
|
|
728
|
-
// @ts-ignore
|
|
729
|
-
s4 = peg$c1;
|
|
730
|
-
// @ts-ignore
|
|
731
|
-
peg$currPos++;
|
|
732
|
-
// @ts-ignore
|
|
733
|
-
}
|
|
734
|
-
else {
|
|
735
|
-
// @ts-ignore
|
|
736
|
-
s4 = peg$FAILED;
|
|
737
|
-
// @ts-ignore
|
|
738
|
-
if (peg$silentFails === 0) {
|
|
739
|
-
peg$fail(peg$e1);
|
|
740
|
-
}
|
|
741
|
-
}
|
|
742
|
-
// @ts-ignore
|
|
743
|
-
if (s4 !== peg$FAILED) {
|
|
744
|
-
// @ts-ignore
|
|
745
|
-
s5 = peg$parse_();
|
|
746
|
-
// @ts-ignore
|
|
747
|
-
s3 = [s3, s4, s5];
|
|
748
|
-
// @ts-ignore
|
|
749
|
-
s2 = s3;
|
|
750
|
-
// @ts-ignore
|
|
751
|
-
}
|
|
752
|
-
else {
|
|
753
|
-
// @ts-ignore
|
|
754
|
-
peg$currPos = s2;
|
|
755
|
-
// @ts-ignore
|
|
756
|
-
s2 = peg$FAILED;
|
|
757
|
-
}
|
|
758
|
-
// @ts-ignore
|
|
759
|
-
if (s2 !== peg$FAILED) {
|
|
760
|
-
// @ts-ignore
|
|
761
|
-
s2 = peg$parseParsedField();
|
|
762
|
-
// @ts-ignore
|
|
763
|
-
s1 = s2;
|
|
764
|
-
// @ts-ignore
|
|
765
|
-
}
|
|
766
|
-
else {
|
|
767
|
-
// @ts-ignore
|
|
768
|
-
s1 = s2;
|
|
769
|
-
}
|
|
770
|
-
}
|
|
771
|
-
// @ts-ignore
|
|
772
|
-
peg$resultsCache[key] = { nextPos: peg$currPos, result: s0 };
|
|
773
|
-
// @ts-ignore
|
|
774
|
-
return s0;
|
|
775
|
-
}
|
|
776
|
-
// @ts-ignore
|
|
777
|
-
function peg$parseParsedField() {
|
|
778
|
-
// @ts-ignore
|
|
779
|
-
var s0, s1, s2, s3, s4, s5, s6, s7, s8;
|
|
780
|
-
// @ts-ignore
|
|
781
|
-
var key = peg$currPos * 9 + 2;
|
|
782
|
-
// @ts-ignore
|
|
783
|
-
var cached = peg$resultsCache[key];
|
|
784
|
-
// @ts-ignore
|
|
785
|
-
if (cached) {
|
|
786
|
-
// @ts-ignore
|
|
787
|
-
peg$currPos = cached.nextPos;
|
|
788
|
-
// @ts-ignore
|
|
789
|
-
return cached.result;
|
|
790
|
-
}
|
|
791
|
-
// @ts-ignore
|
|
792
|
-
s0 = peg$currPos;
|
|
793
|
-
// @ts-ignore
|
|
794
|
-
s1 = peg$parse_();
|
|
795
|
-
// @ts-ignore
|
|
796
|
-
s2 = peg$parseParsedIdentifier();
|
|
797
|
-
// @ts-ignore
|
|
798
|
-
if (input.charCodeAt(peg$currPos) === 63) {
|
|
799
|
-
// @ts-ignore
|
|
800
|
-
s3 = peg$c2;
|
|
801
|
-
// @ts-ignore
|
|
802
|
-
peg$currPos++;
|
|
803
|
-
// @ts-ignore
|
|
804
|
-
}
|
|
805
|
-
else {
|
|
806
|
-
// @ts-ignore
|
|
807
|
-
s3 = peg$FAILED;
|
|
808
|
-
// @ts-ignore
|
|
809
|
-
if (peg$silentFails === 0) {
|
|
810
|
-
peg$fail(peg$e2);
|
|
811
|
-
}
|
|
812
|
-
}
|
|
813
|
-
// @ts-ignore
|
|
814
|
-
if (s3 === peg$FAILED) {
|
|
815
|
-
// @ts-ignore
|
|
816
|
-
s3 = null;
|
|
817
|
-
}
|
|
818
|
-
// @ts-ignore
|
|
819
|
-
s4 = peg$currPos;
|
|
820
|
-
// @ts-ignore
|
|
821
|
-
s5 = peg$parse_();
|
|
822
|
-
// @ts-ignore
|
|
823
|
-
if (input.charCodeAt(peg$currPos) === 58) {
|
|
824
|
-
// @ts-ignore
|
|
825
|
-
s6 = peg$c3;
|
|
826
|
-
// @ts-ignore
|
|
827
|
-
peg$currPos++;
|
|
828
|
-
// @ts-ignore
|
|
829
|
-
}
|
|
830
|
-
else {
|
|
831
|
-
// @ts-ignore
|
|
832
|
-
s6 = peg$FAILED;
|
|
833
|
-
// @ts-ignore
|
|
834
|
-
if (peg$silentFails === 0) {
|
|
835
|
-
peg$fail(peg$e3);
|
|
836
|
-
}
|
|
837
|
-
}
|
|
838
|
-
// @ts-ignore
|
|
839
|
-
if (s6 !== peg$FAILED) {
|
|
840
|
-
// @ts-ignore
|
|
841
|
-
s7 = peg$parse_();
|
|
842
|
-
// @ts-ignore
|
|
843
|
-
s8 = peg$parseParsedType();
|
|
844
|
-
// @ts-ignore
|
|
845
|
-
if (s8 !== peg$FAILED) {
|
|
846
|
-
// @ts-ignore
|
|
847
|
-
s5 = [s5, s6, s7, s8];
|
|
848
|
-
// @ts-ignore
|
|
849
|
-
s4 = s5;
|
|
850
|
-
// @ts-ignore
|
|
851
|
-
}
|
|
852
|
-
else {
|
|
853
|
-
// @ts-ignore
|
|
854
|
-
peg$currPos = s4;
|
|
855
|
-
// @ts-ignore
|
|
856
|
-
s4 = peg$FAILED;
|
|
857
|
-
}
|
|
858
|
-
// @ts-ignore
|
|
859
|
-
}
|
|
860
|
-
else {
|
|
861
|
-
// @ts-ignore
|
|
862
|
-
peg$currPos = s4;
|
|
863
|
-
// @ts-ignore
|
|
864
|
-
s4 = peg$FAILED;
|
|
865
|
-
}
|
|
866
|
-
// @ts-ignore
|
|
867
|
-
if (s4 === peg$FAILED) {
|
|
868
|
-
// @ts-ignore
|
|
869
|
-
s4 = null;
|
|
870
|
-
}
|
|
871
|
-
// @ts-ignore
|
|
872
|
-
s5 = peg$currPos;
|
|
873
|
-
// @ts-ignore
|
|
874
|
-
s6 = peg$parse_();
|
|
875
|
-
// @ts-ignore
|
|
876
|
-
s7 = peg$parseParsedString();
|
|
877
|
-
// @ts-ignore
|
|
878
|
-
if (s7 !== peg$FAILED) {
|
|
879
|
-
// @ts-ignore
|
|
880
|
-
s6 = [s6, s7];
|
|
881
|
-
// @ts-ignore
|
|
882
|
-
s5 = s6;
|
|
883
|
-
// @ts-ignore
|
|
884
|
-
}
|
|
885
|
-
else {
|
|
886
|
-
// @ts-ignore
|
|
887
|
-
peg$currPos = s5;
|
|
888
|
-
// @ts-ignore
|
|
889
|
-
s5 = peg$FAILED;
|
|
890
|
-
}
|
|
891
|
-
// @ts-ignore
|
|
892
|
-
if (s5 === peg$FAILED) {
|
|
893
|
-
// @ts-ignore
|
|
894
|
-
s5 = null;
|
|
895
|
-
}
|
|
896
|
-
// @ts-ignore
|
|
897
|
-
peg$savedPos = s0;
|
|
898
|
-
// @ts-ignore
|
|
899
|
-
s0 = peg$f1(s2, s3, s4, s5);
|
|
900
|
-
// @ts-ignore
|
|
901
|
-
peg$resultsCache[key] = { nextPos: peg$currPos, result: s0 };
|
|
902
|
-
// @ts-ignore
|
|
903
|
-
return s0;
|
|
904
|
-
}
|
|
905
|
-
// @ts-ignore
|
|
906
|
-
function peg$parseParsedType() {
|
|
907
|
-
// @ts-ignore
|
|
908
|
-
var s0, s1, s2;
|
|
909
|
-
// @ts-ignore
|
|
910
|
-
var key = peg$currPos * 9 + 3;
|
|
911
|
-
// @ts-ignore
|
|
912
|
-
var cached = peg$resultsCache[key];
|
|
913
|
-
// @ts-ignore
|
|
914
|
-
if (cached) {
|
|
915
|
-
// @ts-ignore
|
|
916
|
-
peg$currPos = cached.nextPos;
|
|
917
|
-
// @ts-ignore
|
|
918
|
-
return cached.result;
|
|
919
|
-
}
|
|
920
|
-
// @ts-ignore
|
|
921
|
-
s0 = peg$currPos;
|
|
922
|
-
// @ts-ignore
|
|
923
|
-
s1 = peg$parseType();
|
|
924
|
-
// @ts-ignore
|
|
925
|
-
if (s1 !== peg$FAILED) {
|
|
926
|
-
// @ts-ignore
|
|
927
|
-
if (input.substr(peg$currPos, 2) === peg$c4) {
|
|
928
|
-
// @ts-ignore
|
|
929
|
-
s2 = peg$c4;
|
|
930
|
-
// @ts-ignore
|
|
931
|
-
peg$currPos += 2;
|
|
932
|
-
// @ts-ignore
|
|
933
|
-
}
|
|
934
|
-
else {
|
|
935
|
-
// @ts-ignore
|
|
936
|
-
s2 = peg$FAILED;
|
|
937
|
-
// @ts-ignore
|
|
938
|
-
if (peg$silentFails === 0) {
|
|
939
|
-
peg$fail(peg$e4);
|
|
940
|
-
}
|
|
941
|
-
}
|
|
942
|
-
// @ts-ignore
|
|
943
|
-
if (s2 === peg$FAILED) {
|
|
944
|
-
// @ts-ignore
|
|
945
|
-
s2 = null;
|
|
946
|
-
}
|
|
947
|
-
// @ts-ignore
|
|
948
|
-
peg$savedPos = s0;
|
|
949
|
-
// @ts-ignore
|
|
950
|
-
s0 = peg$f2(s1, s2);
|
|
951
|
-
// @ts-ignore
|
|
952
|
-
}
|
|
953
|
-
else {
|
|
954
|
-
// @ts-ignore
|
|
955
|
-
peg$currPos = s0;
|
|
956
|
-
// @ts-ignore
|
|
957
|
-
s0 = peg$FAILED;
|
|
958
|
-
}
|
|
959
|
-
// @ts-ignore
|
|
960
|
-
peg$resultsCache[key] = { nextPos: peg$currPos, result: s0 };
|
|
961
|
-
// @ts-ignore
|
|
962
|
-
return s0;
|
|
963
|
-
}
|
|
964
|
-
// @ts-ignore
|
|
965
|
-
function peg$parseType() {
|
|
966
|
-
// @ts-ignore
|
|
967
|
-
var s0;
|
|
968
|
-
// @ts-ignore
|
|
969
|
-
var key = peg$currPos * 9 + 4;
|
|
970
|
-
// @ts-ignore
|
|
971
|
-
var cached = peg$resultsCache[key];
|
|
972
|
-
// @ts-ignore
|
|
973
|
-
if (cached) {
|
|
974
|
-
// @ts-ignore
|
|
975
|
-
peg$currPos = cached.nextPos;
|
|
976
|
-
// @ts-ignore
|
|
977
|
-
return cached.result;
|
|
978
|
-
}
|
|
979
|
-
// @ts-ignore
|
|
980
|
-
if (input.substr(peg$currPos, 6) === peg$c5) {
|
|
981
|
-
// @ts-ignore
|
|
982
|
-
s0 = peg$c5;
|
|
983
|
-
// @ts-ignore
|
|
984
|
-
peg$currPos += 6;
|
|
985
|
-
// @ts-ignore
|
|
986
|
-
}
|
|
987
|
-
else {
|
|
988
|
-
// @ts-ignore
|
|
989
|
-
s0 = peg$FAILED;
|
|
990
|
-
// @ts-ignore
|
|
991
|
-
if (peg$silentFails === 0) {
|
|
992
|
-
peg$fail(peg$e5);
|
|
993
|
-
}
|
|
994
|
-
}
|
|
995
|
-
// @ts-ignore
|
|
996
|
-
if (s0 === peg$FAILED) {
|
|
997
|
-
// @ts-ignore
|
|
998
|
-
if (input.substr(peg$currPos, 6) === peg$c6) {
|
|
999
|
-
// @ts-ignore
|
|
1000
|
-
s0 = peg$c6;
|
|
1001
|
-
// @ts-ignore
|
|
1002
|
-
peg$currPos += 6;
|
|
1003
|
-
// @ts-ignore
|
|
1004
|
-
}
|
|
1005
|
-
else {
|
|
1006
|
-
// @ts-ignore
|
|
1007
|
-
s0 = peg$FAILED;
|
|
1008
|
-
// @ts-ignore
|
|
1009
|
-
if (peg$silentFails === 0) {
|
|
1010
|
-
peg$fail(peg$e6);
|
|
1011
|
-
}
|
|
1012
|
-
}
|
|
1013
|
-
// @ts-ignore
|
|
1014
|
-
if (s0 === peg$FAILED) {
|
|
1015
|
-
// @ts-ignore
|
|
1016
|
-
if (input.substr(peg$currPos, 7) === peg$c7) {
|
|
1017
|
-
// @ts-ignore
|
|
1018
|
-
s0 = peg$c7;
|
|
1019
|
-
// @ts-ignore
|
|
1020
|
-
peg$currPos += 7;
|
|
1021
|
-
// @ts-ignore
|
|
1022
|
-
}
|
|
1023
|
-
else {
|
|
1024
|
-
// @ts-ignore
|
|
1025
|
-
s0 = peg$FAILED;
|
|
1026
|
-
// @ts-ignore
|
|
1027
|
-
if (peg$silentFails === 0) {
|
|
1028
|
-
peg$fail(peg$e7);
|
|
1029
|
-
}
|
|
1030
|
-
}
|
|
1031
|
-
// @ts-ignore
|
|
1032
|
-
if (s0 === peg$FAILED) {
|
|
1033
|
-
// @ts-ignore
|
|
1034
|
-
if (input.substr(peg$currPos, 4) === peg$c8) {
|
|
1035
|
-
// @ts-ignore
|
|
1036
|
-
s0 = peg$c8;
|
|
1037
|
-
// @ts-ignore
|
|
1038
|
-
peg$currPos += 4;
|
|
1039
|
-
// @ts-ignore
|
|
1040
|
-
}
|
|
1041
|
-
else {
|
|
1042
|
-
// @ts-ignore
|
|
1043
|
-
s0 = peg$FAILED;
|
|
1044
|
-
// @ts-ignore
|
|
1045
|
-
if (peg$silentFails === 0) {
|
|
1046
|
-
peg$fail(peg$e8);
|
|
1047
|
-
}
|
|
1048
|
-
}
|
|
1049
|
-
// @ts-ignore
|
|
1050
|
-
if (s0 === peg$FAILED) {
|
|
1051
|
-
// @ts-ignore
|
|
1052
|
-
if (input.substr(peg$currPos, 5) === peg$c9) {
|
|
1053
|
-
// @ts-ignore
|
|
1054
|
-
s0 = peg$c9;
|
|
1055
|
-
// @ts-ignore
|
|
1056
|
-
peg$currPos += 5;
|
|
1057
|
-
// @ts-ignore
|
|
1058
|
-
}
|
|
1059
|
-
else {
|
|
1060
|
-
// @ts-ignore
|
|
1061
|
-
s0 = peg$FAILED;
|
|
1062
|
-
// @ts-ignore
|
|
1063
|
-
if (peg$silentFails === 0) {
|
|
1064
|
-
peg$fail(peg$e9);
|
|
1065
|
-
}
|
|
1066
|
-
}
|
|
1067
|
-
}
|
|
1068
|
-
}
|
|
1069
|
-
}
|
|
1070
|
-
}
|
|
1071
|
-
// @ts-ignore
|
|
1072
|
-
peg$resultsCache[key] = { nextPos: peg$currPos, result: s0 };
|
|
1073
|
-
// @ts-ignore
|
|
1074
|
-
return s0;
|
|
1075
|
-
}
|
|
1076
|
-
// @ts-ignore
|
|
1077
|
-
function peg$parseParsedIdentifier() {
|
|
1078
|
-
// @ts-ignore
|
|
1079
|
-
var s0, s1, s2;
|
|
1080
|
-
// @ts-ignore
|
|
1081
|
-
var key = peg$currPos * 9 + 5;
|
|
1082
|
-
// @ts-ignore
|
|
1083
|
-
var cached = peg$resultsCache[key];
|
|
1084
|
-
// @ts-ignore
|
|
1085
|
-
if (cached) {
|
|
1086
|
-
// @ts-ignore
|
|
1087
|
-
peg$currPos = cached.nextPos;
|
|
1088
|
-
// @ts-ignore
|
|
1089
|
-
return cached.result;
|
|
1090
|
-
}
|
|
1091
|
-
// @ts-ignore
|
|
1092
|
-
s0 = peg$currPos;
|
|
1093
|
-
// @ts-ignore
|
|
1094
|
-
s1 = [];
|
|
1095
|
-
// @ts-ignore
|
|
1096
|
-
if (peg$r0.test(input.charAt(peg$currPos))) {
|
|
1097
|
-
// @ts-ignore
|
|
1098
|
-
s2 = input.charAt(peg$currPos);
|
|
1099
|
-
// @ts-ignore
|
|
1100
|
-
peg$currPos++;
|
|
1101
|
-
// @ts-ignore
|
|
1102
|
-
}
|
|
1103
|
-
else {
|
|
1104
|
-
// @ts-ignore
|
|
1105
|
-
s2 = peg$FAILED;
|
|
1106
|
-
// @ts-ignore
|
|
1107
|
-
if (peg$silentFails === 0) {
|
|
1108
|
-
peg$fail(peg$e10);
|
|
1109
|
-
}
|
|
1110
|
-
}
|
|
1111
|
-
// @ts-ignore
|
|
1112
|
-
while (s2 !== peg$FAILED) {
|
|
1113
|
-
// @ts-ignore
|
|
1114
|
-
s1.push(s2);
|
|
1115
|
-
// @ts-ignore
|
|
1116
|
-
if (peg$r0.test(input.charAt(peg$currPos))) {
|
|
1117
|
-
// @ts-ignore
|
|
1118
|
-
s2 = input.charAt(peg$currPos);
|
|
1119
|
-
// @ts-ignore
|
|
1120
|
-
peg$currPos++;
|
|
1121
|
-
// @ts-ignore
|
|
1122
|
-
}
|
|
1123
|
-
else {
|
|
1124
|
-
// @ts-ignore
|
|
1125
|
-
s2 = peg$FAILED;
|
|
1126
|
-
// @ts-ignore
|
|
1127
|
-
if (peg$silentFails === 0) {
|
|
1128
|
-
peg$fail(peg$e10);
|
|
1129
|
-
}
|
|
1130
|
-
}
|
|
1131
|
-
}
|
|
1132
|
-
// @ts-ignore
|
|
1133
|
-
peg$savedPos = s0;
|
|
1134
|
-
// @ts-ignore
|
|
1135
|
-
s1 = peg$f3(s1);
|
|
1136
|
-
// @ts-ignore
|
|
1137
|
-
s0 = s1;
|
|
1138
|
-
// @ts-ignore
|
|
1139
|
-
peg$resultsCache[key] = { nextPos: peg$currPos, result: s0 };
|
|
1140
|
-
// @ts-ignore
|
|
1141
|
-
return s0;
|
|
1142
|
-
}
|
|
1143
|
-
// @ts-ignore
|
|
1144
|
-
function peg$parseParsedString() {
|
|
1145
|
-
// @ts-ignore
|
|
1146
|
-
var s0, s1, s2, s3;
|
|
1147
|
-
// @ts-ignore
|
|
1148
|
-
var key = peg$currPos * 9 + 6;
|
|
1149
|
-
// @ts-ignore
|
|
1150
|
-
var cached = peg$resultsCache[key];
|
|
1151
|
-
// @ts-ignore
|
|
1152
|
-
if (cached) {
|
|
1153
|
-
// @ts-ignore
|
|
1154
|
-
peg$currPos = cached.nextPos;
|
|
1155
|
-
// @ts-ignore
|
|
1156
|
-
return cached.result;
|
|
1157
|
-
}
|
|
1158
|
-
// @ts-ignore
|
|
1159
|
-
s0 = peg$currPos;
|
|
1160
|
-
// @ts-ignore
|
|
1161
|
-
if (input.charCodeAt(peg$currPos) === 39) {
|
|
1162
|
-
// @ts-ignore
|
|
1163
|
-
s1 = peg$c10;
|
|
1164
|
-
// @ts-ignore
|
|
1165
|
-
peg$currPos++;
|
|
1166
|
-
// @ts-ignore
|
|
1167
|
-
}
|
|
1168
|
-
else {
|
|
1169
|
-
// @ts-ignore
|
|
1170
|
-
s1 = peg$FAILED;
|
|
1171
|
-
// @ts-ignore
|
|
1172
|
-
if (peg$silentFails === 0) {
|
|
1173
|
-
peg$fail(peg$e11);
|
|
1174
|
-
}
|
|
1175
|
-
}
|
|
1176
|
-
// @ts-ignore
|
|
1177
|
-
if (s1 !== peg$FAILED) {
|
|
1178
|
-
// @ts-ignore
|
|
1179
|
-
s2 = [];
|
|
1180
|
-
// @ts-ignore
|
|
1181
|
-
if (peg$r1.test(input.charAt(peg$currPos))) {
|
|
1182
|
-
// @ts-ignore
|
|
1183
|
-
s3 = input.charAt(peg$currPos);
|
|
1184
|
-
// @ts-ignore
|
|
1185
|
-
peg$currPos++;
|
|
1186
|
-
// @ts-ignore
|
|
1187
|
-
}
|
|
1188
|
-
else {
|
|
1189
|
-
// @ts-ignore
|
|
1190
|
-
s3 = peg$FAILED;
|
|
1191
|
-
// @ts-ignore
|
|
1192
|
-
if (peg$silentFails === 0) {
|
|
1193
|
-
peg$fail(peg$e12);
|
|
1194
|
-
}
|
|
1195
|
-
}
|
|
1196
|
-
// @ts-ignore
|
|
1197
|
-
while (s3 !== peg$FAILED) {
|
|
1198
|
-
// @ts-ignore
|
|
1199
|
-
s2.push(s3);
|
|
1200
|
-
// @ts-ignore
|
|
1201
|
-
if (peg$r1.test(input.charAt(peg$currPos))) {
|
|
1202
|
-
// @ts-ignore
|
|
1203
|
-
s3 = input.charAt(peg$currPos);
|
|
1204
|
-
// @ts-ignore
|
|
1205
|
-
peg$currPos++;
|
|
1206
|
-
// @ts-ignore
|
|
1207
|
-
}
|
|
1208
|
-
else {
|
|
1209
|
-
// @ts-ignore
|
|
1210
|
-
s3 = peg$FAILED;
|
|
1211
|
-
// @ts-ignore
|
|
1212
|
-
if (peg$silentFails === 0) {
|
|
1213
|
-
peg$fail(peg$e12);
|
|
1214
|
-
}
|
|
1215
|
-
}
|
|
1216
|
-
}
|
|
1217
|
-
// @ts-ignore
|
|
1218
|
-
if (input.charCodeAt(peg$currPos) === 39) {
|
|
1219
|
-
// @ts-ignore
|
|
1220
|
-
s3 = peg$c10;
|
|
1221
|
-
// @ts-ignore
|
|
1222
|
-
peg$currPos++;
|
|
1223
|
-
// @ts-ignore
|
|
1224
|
-
}
|
|
1225
|
-
else {
|
|
1226
|
-
// @ts-ignore
|
|
1227
|
-
s3 = peg$FAILED;
|
|
1228
|
-
// @ts-ignore
|
|
1229
|
-
if (peg$silentFails === 0) {
|
|
1230
|
-
peg$fail(peg$e11);
|
|
1231
|
-
}
|
|
1232
|
-
}
|
|
1233
|
-
// @ts-ignore
|
|
1234
|
-
if (s3 !== peg$FAILED) {
|
|
1235
|
-
// @ts-ignore
|
|
1236
|
-
peg$savedPos = s0;
|
|
1237
|
-
// @ts-ignore
|
|
1238
|
-
s0 = peg$f4(s2);
|
|
1239
|
-
// @ts-ignore
|
|
1240
|
-
}
|
|
1241
|
-
else {
|
|
1242
|
-
// @ts-ignore
|
|
1243
|
-
peg$currPos = s0;
|
|
1244
|
-
// @ts-ignore
|
|
1245
|
-
s0 = peg$FAILED;
|
|
1246
|
-
}
|
|
1247
|
-
// @ts-ignore
|
|
1248
|
-
}
|
|
1249
|
-
else {
|
|
1250
|
-
// @ts-ignore
|
|
1251
|
-
peg$currPos = s0;
|
|
1252
|
-
// @ts-ignore
|
|
1253
|
-
s0 = peg$FAILED;
|
|
1254
|
-
}
|
|
1255
|
-
// @ts-ignore
|
|
1256
|
-
if (s0 === peg$FAILED) {
|
|
1257
|
-
// @ts-ignore
|
|
1258
|
-
s0 = peg$currPos;
|
|
1259
|
-
// @ts-ignore
|
|
1260
|
-
if (input.charCodeAt(peg$currPos) === 34) {
|
|
1261
|
-
// @ts-ignore
|
|
1262
|
-
s1 = peg$c11;
|
|
1263
|
-
// @ts-ignore
|
|
1264
|
-
peg$currPos++;
|
|
1265
|
-
// @ts-ignore
|
|
1266
|
-
}
|
|
1267
|
-
else {
|
|
1268
|
-
// @ts-ignore
|
|
1269
|
-
s1 = peg$FAILED;
|
|
1270
|
-
// @ts-ignore
|
|
1271
|
-
if (peg$silentFails === 0) {
|
|
1272
|
-
peg$fail(peg$e13);
|
|
1273
|
-
}
|
|
1274
|
-
}
|
|
1275
|
-
// @ts-ignore
|
|
1276
|
-
if (s1 !== peg$FAILED) {
|
|
1277
|
-
// @ts-ignore
|
|
1278
|
-
s2 = [];
|
|
1279
|
-
// @ts-ignore
|
|
1280
|
-
if (peg$r2.test(input.charAt(peg$currPos))) {
|
|
1281
|
-
// @ts-ignore
|
|
1282
|
-
s3 = input.charAt(peg$currPos);
|
|
1283
|
-
// @ts-ignore
|
|
1284
|
-
peg$currPos++;
|
|
1285
|
-
// @ts-ignore
|
|
1286
|
-
}
|
|
1287
|
-
else {
|
|
1288
|
-
// @ts-ignore
|
|
1289
|
-
s3 = peg$FAILED;
|
|
1290
|
-
// @ts-ignore
|
|
1291
|
-
if (peg$silentFails === 0) {
|
|
1292
|
-
peg$fail(peg$e14);
|
|
1293
|
-
}
|
|
1294
|
-
}
|
|
1295
|
-
// @ts-ignore
|
|
1296
|
-
while (s3 !== peg$FAILED) {
|
|
1297
|
-
// @ts-ignore
|
|
1298
|
-
s2.push(s3);
|
|
1299
|
-
// @ts-ignore
|
|
1300
|
-
if (peg$r2.test(input.charAt(peg$currPos))) {
|
|
1301
|
-
// @ts-ignore
|
|
1302
|
-
s3 = input.charAt(peg$currPos);
|
|
1303
|
-
// @ts-ignore
|
|
1304
|
-
peg$currPos++;
|
|
1305
|
-
// @ts-ignore
|
|
1306
|
-
}
|
|
1307
|
-
else {
|
|
1308
|
-
// @ts-ignore
|
|
1309
|
-
s3 = peg$FAILED;
|
|
1310
|
-
// @ts-ignore
|
|
1311
|
-
if (peg$silentFails === 0) {
|
|
1312
|
-
peg$fail(peg$e14);
|
|
1313
|
-
}
|
|
1314
|
-
}
|
|
1315
|
-
}
|
|
1316
|
-
// @ts-ignore
|
|
1317
|
-
if (input.charCodeAt(peg$currPos) === 34) {
|
|
1318
|
-
// @ts-ignore
|
|
1319
|
-
s3 = peg$c11;
|
|
1320
|
-
// @ts-ignore
|
|
1321
|
-
peg$currPos++;
|
|
1322
|
-
// @ts-ignore
|
|
1323
|
-
}
|
|
1324
|
-
else {
|
|
1325
|
-
// @ts-ignore
|
|
1326
|
-
s3 = peg$FAILED;
|
|
1327
|
-
// @ts-ignore
|
|
1328
|
-
if (peg$silentFails === 0) {
|
|
1329
|
-
peg$fail(peg$e13);
|
|
1330
|
-
}
|
|
1331
|
-
}
|
|
1332
|
-
// @ts-ignore
|
|
1333
|
-
if (s3 !== peg$FAILED) {
|
|
1334
|
-
// @ts-ignore
|
|
1335
|
-
peg$savedPos = s0;
|
|
1336
|
-
// @ts-ignore
|
|
1337
|
-
s0 = peg$f5(s2);
|
|
1338
|
-
// @ts-ignore
|
|
1339
|
-
}
|
|
1340
|
-
else {
|
|
1341
|
-
// @ts-ignore
|
|
1342
|
-
peg$currPos = s0;
|
|
1343
|
-
// @ts-ignore
|
|
1344
|
-
s0 = peg$FAILED;
|
|
1345
|
-
}
|
|
1346
|
-
// @ts-ignore
|
|
1347
|
-
}
|
|
1348
|
-
else {
|
|
1349
|
-
// @ts-ignore
|
|
1350
|
-
peg$currPos = s0;
|
|
1351
|
-
// @ts-ignore
|
|
1352
|
-
s0 = peg$FAILED;
|
|
1353
|
-
}
|
|
1354
|
-
}
|
|
1355
|
-
// @ts-ignore
|
|
1356
|
-
peg$resultsCache[key] = { nextPos: peg$currPos, result: s0 };
|
|
1357
|
-
// @ts-ignore
|
|
1358
|
-
return s0;
|
|
1359
|
-
}
|
|
1360
|
-
// @ts-ignore
|
|
1361
|
-
function peg$parse_() {
|
|
1362
|
-
// @ts-ignore
|
|
1363
|
-
var s0, s1, s2;
|
|
1364
|
-
// @ts-ignore
|
|
1365
|
-
var key = peg$currPos * 9 + 7;
|
|
1366
|
-
// @ts-ignore
|
|
1367
|
-
var cached = peg$resultsCache[key];
|
|
1368
|
-
// @ts-ignore
|
|
1369
|
-
if (cached) {
|
|
1370
|
-
// @ts-ignore
|
|
1371
|
-
peg$currPos = cached.nextPos;
|
|
1372
|
-
// @ts-ignore
|
|
1373
|
-
return cached.result;
|
|
1374
|
-
}
|
|
1375
|
-
// @ts-ignore
|
|
1376
|
-
s0 = peg$currPos;
|
|
1377
|
-
// @ts-ignore
|
|
1378
|
-
s1 = [];
|
|
1379
|
-
// @ts-ignore
|
|
1380
|
-
if (peg$r3.test(input.charAt(peg$currPos))) {
|
|
1381
|
-
// @ts-ignore
|
|
1382
|
-
s2 = input.charAt(peg$currPos);
|
|
1383
|
-
// @ts-ignore
|
|
1384
|
-
peg$currPos++;
|
|
1385
|
-
// @ts-ignore
|
|
1386
|
-
}
|
|
1387
|
-
else {
|
|
1388
|
-
// @ts-ignore
|
|
1389
|
-
s2 = peg$FAILED;
|
|
1390
|
-
// @ts-ignore
|
|
1391
|
-
if (peg$silentFails === 0) {
|
|
1392
|
-
peg$fail(peg$e15);
|
|
1393
|
-
}
|
|
1394
|
-
}
|
|
1395
|
-
// @ts-ignore
|
|
1396
|
-
while (s2 !== peg$FAILED) {
|
|
1397
|
-
// @ts-ignore
|
|
1398
|
-
s1.push(s2);
|
|
1399
|
-
// @ts-ignore
|
|
1400
|
-
if (peg$r3.test(input.charAt(peg$currPos))) {
|
|
1401
|
-
// @ts-ignore
|
|
1402
|
-
s2 = input.charAt(peg$currPos);
|
|
1403
|
-
// @ts-ignore
|
|
1404
|
-
peg$currPos++;
|
|
1405
|
-
// @ts-ignore
|
|
1406
|
-
}
|
|
1407
|
-
else {
|
|
1408
|
-
// @ts-ignore
|
|
1409
|
-
s2 = peg$FAILED;
|
|
1410
|
-
// @ts-ignore
|
|
1411
|
-
if (peg$silentFails === 0) {
|
|
1412
|
-
peg$fail(peg$e15);
|
|
1413
|
-
}
|
|
1414
|
-
}
|
|
1415
|
-
}
|
|
1416
|
-
// @ts-ignore
|
|
1417
|
-
peg$savedPos = s0;
|
|
1418
|
-
// @ts-ignore
|
|
1419
|
-
s1 = peg$f6();
|
|
1420
|
-
// @ts-ignore
|
|
1421
|
-
s0 = s1;
|
|
1422
|
-
// @ts-ignore
|
|
1423
|
-
peg$resultsCache[key] = { nextPos: peg$currPos, result: s0 };
|
|
1424
|
-
// @ts-ignore
|
|
1425
|
-
return s0;
|
|
1426
|
-
}
|
|
1427
|
-
// @ts-ignore
|
|
1428
|
-
function peg$parse__() {
|
|
1429
|
-
// @ts-ignore
|
|
1430
|
-
var s0, s1, s2;
|
|
1431
|
-
// @ts-ignore
|
|
1432
|
-
var key = peg$currPos * 9 + 8;
|
|
1433
|
-
// @ts-ignore
|
|
1434
|
-
var cached = peg$resultsCache[key];
|
|
1435
|
-
// @ts-ignore
|
|
1436
|
-
if (cached) {
|
|
1437
|
-
// @ts-ignore
|
|
1438
|
-
peg$currPos = cached.nextPos;
|
|
1439
|
-
// @ts-ignore
|
|
1440
|
-
return cached.result;
|
|
1441
|
-
}
|
|
1442
|
-
// @ts-ignore
|
|
1443
|
-
s0 = peg$currPos;
|
|
1444
|
-
// @ts-ignore
|
|
1445
|
-
s1 = [];
|
|
1446
|
-
// @ts-ignore
|
|
1447
|
-
if (peg$r3.test(input.charAt(peg$currPos))) {
|
|
1448
|
-
// @ts-ignore
|
|
1449
|
-
s2 = input.charAt(peg$currPos);
|
|
1450
|
-
// @ts-ignore
|
|
1451
|
-
peg$currPos++;
|
|
1452
|
-
// @ts-ignore
|
|
1453
|
-
}
|
|
1454
|
-
else {
|
|
1455
|
-
// @ts-ignore
|
|
1456
|
-
s2 = peg$FAILED;
|
|
1457
|
-
// @ts-ignore
|
|
1458
|
-
if (peg$silentFails === 0) {
|
|
1459
|
-
peg$fail(peg$e15);
|
|
1460
|
-
}
|
|
1461
|
-
}
|
|
1462
|
-
// @ts-ignore
|
|
1463
|
-
if (s2 !== peg$FAILED) {
|
|
1464
|
-
// @ts-ignore
|
|
1465
|
-
while (s2 !== peg$FAILED) {
|
|
1466
|
-
// @ts-ignore
|
|
1467
|
-
s1.push(s2);
|
|
1468
|
-
// @ts-ignore
|
|
1469
|
-
if (peg$r3.test(input.charAt(peg$currPos))) {
|
|
1470
|
-
// @ts-ignore
|
|
1471
|
-
s2 = input.charAt(peg$currPos);
|
|
1472
|
-
// @ts-ignore
|
|
1473
|
-
peg$currPos++;
|
|
1474
|
-
// @ts-ignore
|
|
1475
|
-
}
|
|
1476
|
-
else {
|
|
1477
|
-
// @ts-ignore
|
|
1478
|
-
s2 = peg$FAILED;
|
|
1479
|
-
// @ts-ignore
|
|
1480
|
-
if (peg$silentFails === 0) {
|
|
1481
|
-
peg$fail(peg$e15);
|
|
1482
|
-
}
|
|
1483
|
-
}
|
|
1484
|
-
}
|
|
1485
|
-
// @ts-ignore
|
|
1486
|
-
}
|
|
1487
|
-
else {
|
|
1488
|
-
// @ts-ignore
|
|
1489
|
-
s1 = peg$FAILED;
|
|
1490
|
-
}
|
|
1491
|
-
// @ts-ignore
|
|
1492
|
-
if (s1 !== peg$FAILED) {
|
|
1493
|
-
// @ts-ignore
|
|
1494
|
-
peg$savedPos = s0;
|
|
1495
|
-
// @ts-ignore
|
|
1496
|
-
s1 = peg$f7();
|
|
1497
|
-
}
|
|
1498
|
-
// @ts-ignore
|
|
1499
|
-
s0 = s1;
|
|
1500
|
-
// @ts-ignore
|
|
1501
|
-
peg$resultsCache[key] = { nextPos: peg$currPos, result: s0 };
|
|
1502
|
-
// @ts-ignore
|
|
1503
|
-
return s0;
|
|
1504
|
-
}
|
|
1505
|
-
// @ts-ignore
|
|
1506
|
-
peg$result = peg$startRuleFunction();
|
|
1507
|
-
// @ts-ignore
|
|
1508
|
-
if (peg$result !== peg$FAILED && peg$currPos === input.length) {
|
|
1509
|
-
// @ts-ignore
|
|
1510
|
-
return peg$result;
|
|
1511
|
-
// @ts-ignore
|
|
1512
|
-
}
|
|
1513
|
-
else {
|
|
1514
|
-
// @ts-ignore
|
|
1515
|
-
if (peg$result !== peg$FAILED && peg$currPos < input.length) {
|
|
1516
|
-
// @ts-ignore
|
|
1517
|
-
peg$fail(peg$endExpectation());
|
|
1518
|
-
}
|
|
1519
|
-
// @ts-ignore
|
|
1520
|
-
throw peg$buildStructuredError(
|
|
1521
|
-
// @ts-ignore
|
|
1522
|
-
peg$maxFailExpected,
|
|
1523
|
-
// @ts-ignore
|
|
1524
|
-
peg$maxFailPos < input.length ? input.charAt(peg$maxFailPos) : null,
|
|
1525
|
-
// @ts-ignore
|
|
1526
|
-
peg$maxFailPos < input.length
|
|
1527
|
-
// @ts-ignore
|
|
1528
|
-
? peg$computeLocation(peg$maxFailPos, peg$maxFailPos + 1)
|
|
1529
|
-
// @ts-ignore
|
|
1530
|
-
: peg$computeLocation(peg$maxFailPos, peg$maxFailPos));
|
|
1531
|
-
}
|
|
1532
|
-
}
|
|
1533
|
-
// @ts-ignore
|
|
1534
|
-
return {
|
|
1535
|
-
SyntaxError: peg$SyntaxError,
|
|
1536
|
-
parse: peg$parse
|
|
1537
|
-
};
|
|
1538
|
-
})();
|
|
1539
|
-
peggyParser.SyntaxError.prototype.name = "PeggySyntaxError";
|
|
1540
|
-
export const parse = peggyParser.parse;
|
|
1541
|
-
export const PeggySyntaxError = peggyParser.SyntaxError;
|
|
1542
|
-
//# sourceMappingURL=parser.js.map
|