@pgtyped/parser
Advanced tools
Comparing version 2.1.0 to 2.3.0
@@ -7,3 +7,3 @@ // Generated from src/loader/sql/grammar/SQLLexer.g4 by ANTLR 4.9.0-SNAPSHOT | ||
import * as Utils from "antlr4ts/misc/Utils.js"; | ||
export class SQLLexer extends Lexer { | ||
class SQLLexer extends Lexer { | ||
// @Override | ||
@@ -176,2 +176,3 @@ // @NotNull | ||
"\xA0\xC3\x07\x04\x03\x02\t\x03\x02\t\x07\x02\b\x02\x02\x04\x02\x02"; | ||
export { SQLLexer }; | ||
//# sourceMappingURL=SQLLexer.js.map |
@@ -41,14 +41,15 @@ import { ATN } from "antlr4ts/atn/ATN.js"; | ||
static readonly RULE_word = 6; | ||
static readonly RULE_param = 7; | ||
static readonly RULE_paramId = 8; | ||
static readonly RULE_nameTag = 9; | ||
static readonly RULE_paramTag = 10; | ||
static readonly RULE_paramTransform = 11; | ||
static readonly RULE_transformRule = 12; | ||
static readonly RULE_spreadTransform = 13; | ||
static readonly RULE_pickTransform = 14; | ||
static readonly RULE_spreadPickTransform = 15; | ||
static readonly RULE_key = 16; | ||
static readonly RULE_queryName = 17; | ||
static readonly RULE_paramName = 18; | ||
static readonly RULE_range = 7; | ||
static readonly RULE_param = 8; | ||
static readonly RULE_paramId = 9; | ||
static readonly RULE_nameTag = 10; | ||
static readonly RULE_paramTag = 11; | ||
static readonly RULE_paramTransform = 12; | ||
static readonly RULE_transformRule = 13; | ||
static readonly RULE_spreadTransform = 14; | ||
static readonly RULE_pickTransform = 15; | ||
static readonly RULE_spreadPickTransform = 16; | ||
static readonly RULE_key = 17; | ||
static readonly RULE_queryName = 18; | ||
static readonly RULE_paramName = 19; | ||
static readonly ruleNames: string[]; | ||
@@ -71,2 +72,3 @@ private static readonly _LITERAL_NAMES; | ||
word(): WordContext; | ||
range(): RangeContext; | ||
param(): ParamContext; | ||
@@ -149,2 +151,4 @@ paramId(): ParamIdContext; | ||
word(i: number): WordContext; | ||
range(): RangeContext[]; | ||
range(i: number): RangeContext; | ||
constructor(parent: ParserRuleContext | undefined, invokingState: number); | ||
@@ -168,2 +172,11 @@ get ruleIndex(): number; | ||
} | ||
export declare class RangeContext extends ParserRuleContext { | ||
PARAM_MARK(): TerminalNode; | ||
word(): WordContext; | ||
constructor(parent: ParserRuleContext | undefined, invokingState: number); | ||
get ruleIndex(): number; | ||
enterRule(listener: SQLParserListener): void; | ||
exitRule(listener: SQLParserListener): void; | ||
accept<Result>(visitor: SQLParserVisitor<Result>): Result; | ||
} | ||
export declare class ParamContext extends ParserRuleContext { | ||
@@ -170,0 +183,0 @@ PARAM_MARK(): TerminalNode; |
@@ -5,3 +5,2 @@ // Generated from src/loader/sql/grammar/SQLParser.g4 by ANTLR 4.9.0-SNAPSHOT | ||
import { FailedPredicateException } from "antlr4ts/FailedPredicateException.js"; | ||
import { NoViableAltException } from "antlr4ts/NoViableAltException.js"; | ||
import { Parser } from "antlr4ts/Parser.js"; | ||
@@ -14,3 +13,3 @@ import { ParserRuleContext } from "antlr4ts/ParserRuleContext.js"; | ||
import * as Utils from "antlr4ts/misc/Utils.js"; | ||
export class SQLParser extends Parser { | ||
class SQLParser extends Parser { | ||
// @Override | ||
@@ -44,3 +43,3 @@ // @NotNull | ||
{ | ||
this.state = 45; | ||
this.state = 47; | ||
this._errHandler.sync(this); | ||
@@ -51,3 +50,3 @@ _la = this._input.LA(1); | ||
{ | ||
this.state = 41; | ||
this.state = 43; | ||
this._errHandler.sync(this); | ||
@@ -59,3 +58,3 @@ _alt = this.interpreter.adaptivePredict(this._input, 0, this._ctx); | ||
{ | ||
this.state = 38; | ||
this.state = 40; | ||
this.ignoredComment(); | ||
@@ -65,15 +64,15 @@ } | ||
} | ||
this.state = 43; | ||
this.state = 45; | ||
this._errHandler.sync(this); | ||
_alt = this.interpreter.adaptivePredict(this._input, 0, this._ctx); | ||
} | ||
this.state = 44; | ||
this.state = 46; | ||
this.query(); | ||
} | ||
} | ||
this.state = 47; | ||
this.state = 49; | ||
this._errHandler.sync(this); | ||
_la = this._input.LA(1); | ||
} while (_la === SQLParser.OPEN_COMMENT); | ||
this.state = 49; | ||
this.state = 51; | ||
this.match(SQLParser.EOF); | ||
@@ -104,5 +103,5 @@ } | ||
{ | ||
this.state = 51; | ||
this.state = 53; | ||
this.queryDef(); | ||
this.state = 52; | ||
this.state = 54; | ||
this.statement(); | ||
@@ -134,7 +133,7 @@ } | ||
{ | ||
this.state = 54; | ||
this.state = 56; | ||
this.match(SQLParser.OPEN_COMMENT); | ||
this.state = 55; | ||
this.state = 57; | ||
this.nameTag(); | ||
this.state = 59; | ||
this.state = 61; | ||
this._errHandler.sync(this); | ||
@@ -145,11 +144,11 @@ _la = this._input.LA(1); | ||
{ | ||
this.state = 56; | ||
this.state = 58; | ||
this.paramTag(); | ||
} | ||
} | ||
this.state = 61; | ||
this.state = 63; | ||
this._errHandler.sync(this); | ||
_la = this._input.LA(1); | ||
} | ||
this.state = 62; | ||
this.state = 64; | ||
this.match(SQLParser.CLOSE_COMMENT); | ||
@@ -181,5 +180,5 @@ } | ||
{ | ||
this.state = 64; | ||
this.state = 66; | ||
this.match(SQLParser.OPEN_COMMENT); | ||
this.state = 68; | ||
this.state = 70; | ||
this._errHandler.sync(this); | ||
@@ -190,3 +189,3 @@ _la = this._input.LA(1); | ||
{ | ||
this.state = 65; | ||
this.state = 67; | ||
_la = this._input.LA(1); | ||
@@ -205,7 +204,7 @@ if (_la <= 0 || (_la === SQLParser.CLOSE_COMMENT)) { | ||
} | ||
this.state = 70; | ||
this.state = 72; | ||
this._errHandler.sync(this); | ||
_la = this._input.LA(1); | ||
} | ||
this.state = 71; | ||
this.state = 73; | ||
this.match(SQLParser.CLOSE_COMMENT); | ||
@@ -236,5 +235,5 @@ } | ||
{ | ||
this.state = 73; | ||
this.state = 75; | ||
this.statementBody(); | ||
this.state = 74; | ||
this.state = 76; | ||
this.match(SQLParser.EOF_STATEMENT); | ||
@@ -266,3 +265,3 @@ } | ||
{ | ||
this.state = 82; | ||
this.state = 85; | ||
this._errHandler.sync(this); | ||
@@ -272,38 +271,38 @@ _la = this._input.LA(1); | ||
{ | ||
this.state = 80; | ||
this.state = 83; | ||
this._errHandler.sync(this); | ||
switch (this._input.LA(1)) { | ||
case SQLParser.LINE_COMMENT: | ||
switch (this.interpreter.adaptivePredict(this._input, 4, this._ctx)) { | ||
case 1: | ||
{ | ||
this.state = 76; | ||
this.state = 78; | ||
this.match(SQLParser.LINE_COMMENT); | ||
} | ||
break; | ||
case SQLParser.OPEN_COMMENT: | ||
case 2: | ||
{ | ||
this.state = 77; | ||
this.state = 79; | ||
this.ignoredComment(); | ||
} | ||
break; | ||
case SQLParser.PARAM_MARK: | ||
case 3: | ||
{ | ||
this.state = 78; | ||
this.state = 80; | ||
this.param(); | ||
} | ||
break; | ||
case SQLParser.ID: | ||
case SQLParser.S_REQUIRED_MARK: | ||
case SQLParser.WORD: | ||
case SQLParser.STRING: | ||
case SQLParser.DOLLAR_STRING: | ||
case 4: | ||
{ | ||
this.state = 79; | ||
this.state = 81; | ||
this.word(); | ||
} | ||
break; | ||
default: | ||
throw new NoViableAltException(this); | ||
case 5: | ||
{ | ||
this.state = 82; | ||
this.range(); | ||
} | ||
break; | ||
} | ||
} | ||
this.state = 84; | ||
this.state = 87; | ||
this._errHandler.sync(this); | ||
@@ -337,3 +336,3 @@ _la = this._input.LA(1); | ||
{ | ||
this.state = 85; | ||
this.state = 88; | ||
_la = this._input.LA(1); | ||
@@ -368,11 +367,39 @@ if (!((((_la) & ~0x1F) === 0 && ((1 << _la) & ((1 << SQLParser.ID) | (1 << SQLParser.S_REQUIRED_MARK) | (1 << SQLParser.WORD) | (1 << SQLParser.STRING) | (1 << SQLParser.DOLLAR_STRING))) !== 0))) { | ||
// @RuleVersion(0) | ||
range() { | ||
let _localctx = new RangeContext(this._ctx, this.state); | ||
this.enterRule(_localctx, 14, SQLParser.RULE_range); | ||
try { | ||
this.enterOuterAlt(_localctx, 1); | ||
{ | ||
this.state = 90; | ||
this.match(SQLParser.PARAM_MARK); | ||
this.state = 91; | ||
this.word(); | ||
} | ||
} | ||
catch (re) { | ||
if (re instanceof RecognitionException) { | ||
_localctx.exception = re; | ||
this._errHandler.reportError(this, re); | ||
this._errHandler.recover(this, re); | ||
} | ||
else { | ||
throw re; | ||
} | ||
} | ||
finally { | ||
this.exitRule(); | ||
} | ||
return _localctx; | ||
} | ||
// @RuleVersion(0) | ||
param() { | ||
let _localctx = new ParamContext(this._ctx, this.state); | ||
this.enterRule(_localctx, 14, SQLParser.RULE_param); | ||
this.enterRule(_localctx, 16, SQLParser.RULE_param); | ||
try { | ||
this.enterOuterAlt(_localctx, 1); | ||
{ | ||
this.state = 87; | ||
this.state = 93; | ||
this.match(SQLParser.PARAM_MARK); | ||
this.state = 88; | ||
this.state = 94; | ||
this.paramId(); | ||
@@ -399,9 +426,9 @@ } | ||
let _localctx = new ParamIdContext(this._ctx, this.state); | ||
this.enterRule(_localctx, 16, SQLParser.RULE_paramId); | ||
this.enterRule(_localctx, 18, SQLParser.RULE_paramId); | ||
try { | ||
this.enterOuterAlt(_localctx, 1); | ||
{ | ||
this.state = 90; | ||
this.state = 96; | ||
this.match(SQLParser.ID); | ||
this.state = 92; | ||
this.state = 98; | ||
this._errHandler.sync(this); | ||
@@ -411,3 +438,3 @@ switch (this.interpreter.adaptivePredict(this._input, 6, this._ctx)) { | ||
{ | ||
this.state = 91; | ||
this.state = 97; | ||
this.match(SQLParser.S_REQUIRED_MARK); | ||
@@ -437,9 +464,9 @@ } | ||
let _localctx = new NameTagContext(this._ctx, this.state); | ||
this.enterRule(_localctx, 18, SQLParser.RULE_nameTag); | ||
this.enterRule(_localctx, 20, SQLParser.RULE_nameTag); | ||
try { | ||
this.enterOuterAlt(_localctx, 1); | ||
{ | ||
this.state = 94; | ||
this.state = 100; | ||
this.match(SQLParser.NAME_TAG); | ||
this.state = 95; | ||
this.state = 101; | ||
this.queryName(); | ||
@@ -466,11 +493,11 @@ } | ||
let _localctx = new ParamTagContext(this._ctx, this.state); | ||
this.enterRule(_localctx, 20, SQLParser.RULE_paramTag); | ||
this.enterRule(_localctx, 22, SQLParser.RULE_paramTag); | ||
try { | ||
this.enterOuterAlt(_localctx, 1); | ||
{ | ||
this.state = 97; | ||
this.state = 103; | ||
this.match(SQLParser.TYPE_TAG); | ||
this.state = 98; | ||
this.state = 104; | ||
this.paramName(); | ||
this.state = 99; | ||
this.state = 105; | ||
this.paramTransform(); | ||
@@ -497,9 +524,9 @@ } | ||
let _localctx = new ParamTransformContext(this._ctx, this.state); | ||
this.enterRule(_localctx, 22, SQLParser.RULE_paramTransform); | ||
this.enterRule(_localctx, 24, SQLParser.RULE_paramTransform); | ||
try { | ||
this.enterOuterAlt(_localctx, 1); | ||
{ | ||
this.state = 101; | ||
this.state = 107; | ||
this.match(SQLParser.TRANSFORM_ARROW); | ||
this.state = 102; | ||
this.state = 108; | ||
this.transformRule(); | ||
@@ -526,5 +553,5 @@ } | ||
let _localctx = new TransformRuleContext(this._ctx, this.state); | ||
this.enterRule(_localctx, 24, SQLParser.RULE_transformRule); | ||
this.enterRule(_localctx, 26, SQLParser.RULE_transformRule); | ||
try { | ||
this.state = 107; | ||
this.state = 113; | ||
this._errHandler.sync(this); | ||
@@ -535,3 +562,3 @@ switch (this.interpreter.adaptivePredict(this._input, 7, this._ctx)) { | ||
{ | ||
this.state = 104; | ||
this.state = 110; | ||
this.spreadTransform(); | ||
@@ -543,3 +570,3 @@ } | ||
{ | ||
this.state = 105; | ||
this.state = 111; | ||
this.pickTransform(); | ||
@@ -551,3 +578,3 @@ } | ||
{ | ||
this.state = 106; | ||
this.state = 112; | ||
this.spreadPickTransform(); | ||
@@ -576,11 +603,11 @@ } | ||
let _localctx = new SpreadTransformContext(this._ctx, this.state); | ||
this.enterRule(_localctx, 26, SQLParser.RULE_spreadTransform); | ||
this.enterRule(_localctx, 28, SQLParser.RULE_spreadTransform); | ||
try { | ||
this.enterOuterAlt(_localctx, 1); | ||
{ | ||
this.state = 109; | ||
this.state = 115; | ||
this.match(SQLParser.OB); | ||
this.state = 110; | ||
this.state = 116; | ||
this.match(SQLParser.SPREAD); | ||
this.state = 111; | ||
this.state = 117; | ||
this.match(SQLParser.CB); | ||
@@ -607,3 +634,3 @@ } | ||
let _localctx = new PickTransformContext(this._ctx, this.state); | ||
this.enterRule(_localctx, 28, SQLParser.RULE_pickTransform); | ||
this.enterRule(_localctx, 30, SQLParser.RULE_pickTransform); | ||
let _la; | ||
@@ -614,7 +641,7 @@ try { | ||
{ | ||
this.state = 113; | ||
this.state = 119; | ||
this.match(SQLParser.OB); | ||
this.state = 114; | ||
this.state = 120; | ||
this.key(); | ||
this.state = 119; | ||
this.state = 125; | ||
this._errHandler.sync(this); | ||
@@ -626,5 +653,5 @@ _alt = this.interpreter.adaptivePredict(this._input, 8, this._ctx); | ||
{ | ||
this.state = 115; | ||
this.state = 121; | ||
this.match(SQLParser.COMMA); | ||
this.state = 116; | ||
this.state = 122; | ||
this.key(); | ||
@@ -634,7 +661,7 @@ } | ||
} | ||
this.state = 121; | ||
this.state = 127; | ||
this._errHandler.sync(this); | ||
_alt = this.interpreter.adaptivePredict(this._input, 8, this._ctx); | ||
} | ||
this.state = 123; | ||
this.state = 129; | ||
this._errHandler.sync(this); | ||
@@ -644,7 +671,7 @@ _la = this._input.LA(1); | ||
{ | ||
this.state = 122; | ||
this.state = 128; | ||
this.match(SQLParser.COMMA); | ||
} | ||
} | ||
this.state = 125; | ||
this.state = 131; | ||
this.match(SQLParser.CB); | ||
@@ -671,13 +698,13 @@ } | ||
let _localctx = new SpreadPickTransformContext(this._ctx, this.state); | ||
this.enterRule(_localctx, 30, SQLParser.RULE_spreadPickTransform); | ||
this.enterRule(_localctx, 32, SQLParser.RULE_spreadPickTransform); | ||
try { | ||
this.enterOuterAlt(_localctx, 1); | ||
{ | ||
this.state = 127; | ||
this.state = 133; | ||
this.match(SQLParser.OB); | ||
this.state = 128; | ||
this.state = 134; | ||
this.pickTransform(); | ||
this.state = 129; | ||
this.state = 135; | ||
this.match(SQLParser.SPREAD); | ||
this.state = 130; | ||
this.state = 136; | ||
this.match(SQLParser.CB); | ||
@@ -704,3 +731,3 @@ } | ||
let _localctx = new KeyContext(this._ctx, this.state); | ||
this.enterRule(_localctx, 32, SQLParser.RULE_key); | ||
this.enterRule(_localctx, 34, SQLParser.RULE_key); | ||
let _la; | ||
@@ -710,5 +737,5 @@ try { | ||
{ | ||
this.state = 132; | ||
this.state = 138; | ||
this.match(SQLParser.ID); | ||
this.state = 134; | ||
this.state = 140; | ||
this._errHandler.sync(this); | ||
@@ -718,3 +745,3 @@ _la = this._input.LA(1); | ||
{ | ||
this.state = 133; | ||
this.state = 139; | ||
this.match(SQLParser.C_REQUIRED_MARK); | ||
@@ -743,7 +770,7 @@ } | ||
let _localctx = new QueryNameContext(this._ctx, this.state); | ||
this.enterRule(_localctx, 34, SQLParser.RULE_queryName); | ||
this.enterRule(_localctx, 36, SQLParser.RULE_queryName); | ||
try { | ||
this.enterOuterAlt(_localctx, 1); | ||
{ | ||
this.state = 136; | ||
this.state = 142; | ||
this.match(SQLParser.ID); | ||
@@ -770,7 +797,7 @@ } | ||
let _localctx = new ParamNameContext(this._ctx, this.state); | ||
this.enterRule(_localctx, 36, SQLParser.RULE_paramName); | ||
this.enterRule(_localctx, 38, SQLParser.RULE_paramName); | ||
try { | ||
this.enterOuterAlt(_localctx, 1); | ||
{ | ||
this.state = 138; | ||
this.state = 144; | ||
this.match(SQLParser.ID); | ||
@@ -831,20 +858,21 @@ } | ||
SQLParser.RULE_word = 6; | ||
SQLParser.RULE_param = 7; | ||
SQLParser.RULE_paramId = 8; | ||
SQLParser.RULE_nameTag = 9; | ||
SQLParser.RULE_paramTag = 10; | ||
SQLParser.RULE_paramTransform = 11; | ||
SQLParser.RULE_transformRule = 12; | ||
SQLParser.RULE_spreadTransform = 13; | ||
SQLParser.RULE_pickTransform = 14; | ||
SQLParser.RULE_spreadPickTransform = 15; | ||
SQLParser.RULE_key = 16; | ||
SQLParser.RULE_queryName = 17; | ||
SQLParser.RULE_paramName = 18; | ||
SQLParser.RULE_range = 7; | ||
SQLParser.RULE_param = 8; | ||
SQLParser.RULE_paramId = 9; | ||
SQLParser.RULE_nameTag = 10; | ||
SQLParser.RULE_paramTag = 11; | ||
SQLParser.RULE_paramTransform = 12; | ||
SQLParser.RULE_transformRule = 13; | ||
SQLParser.RULE_spreadTransform = 14; | ||
SQLParser.RULE_pickTransform = 15; | ||
SQLParser.RULE_spreadPickTransform = 16; | ||
SQLParser.RULE_key = 17; | ||
SQLParser.RULE_queryName = 18; | ||
SQLParser.RULE_paramName = 19; | ||
// tslint:disable:no-trailing-whitespace | ||
SQLParser.ruleNames = [ | ||
"input", "query", "queryDef", "ignoredComment", "statement", "statementBody", | ||
"word", "param", "paramId", "nameTag", "paramTag", "paramTransform", "transformRule", | ||
"spreadTransform", "pickTransform", "spreadPickTransform", "key", "queryName", | ||
"paramName", | ||
"word", "range", "param", "paramId", "nameTag", "paramTag", "paramTransform", | ||
"transformRule", "spreadTransform", "pickTransform", "spreadPickTransform", | ||
"key", "queryName", "paramName", | ||
]; | ||
@@ -864,57 +892,61 @@ SQLParser._LITERAL_NAMES = [ | ||
SQLParser.VOCABULARY = new VocabularyImpl(SQLParser._LITERAL_NAMES, SQLParser._SYMBOLIC_NAMES, []); | ||
SQLParser._serializedATN = "\x03\uC91D\uCABA\u058D\uAFBA\u4F53\u0607\uEA8B\uC241\x03\x19\x8F\x04\x02" + | ||
SQLParser._serializedATN = "\x03\uC91D\uCABA\u058D\uAFBA\u4F53\u0607\uEA8B\uC241\x03\x19\x95\x04\x02" + | ||
"\t\x02\x04\x03\t\x03\x04\x04\t\x04\x04\x05\t\x05\x04\x06\t\x06\x04\x07" + | ||
"\t\x07\x04\b\t\b\x04\t\t\t\x04\n\t\n\x04\v\t\v\x04\f\t\f\x04\r\t\r\x04" + | ||
"\x0E\t\x0E\x04\x0F\t\x0F\x04\x10\t\x10\x04\x11\t\x11\x04\x12\t\x12\x04" + | ||
"\x13\t\x13\x04\x14\t\x14\x03\x02\x07\x02*\n\x02\f\x02\x0E\x02-\v\x02\x03" + | ||
"\x02\x06\x020\n\x02\r\x02\x0E\x021\x03\x02\x03\x02\x03\x03\x03\x03\x03" + | ||
"\x03\x03\x04\x03\x04\x03\x04\x07\x04<\n\x04\f\x04\x0E\x04?\v\x04\x03\x04" + | ||
"\x03\x04\x03\x05\x03\x05\x07\x05E\n\x05\f\x05\x0E\x05H\v\x05\x03\x05\x03" + | ||
"\x05\x03\x06\x03\x06\x03\x06\x03\x07\x03\x07\x03\x07\x03\x07\x07\x07S" + | ||
"\n\x07\f\x07\x0E\x07V\v\x07\x03\b\x03\b\x03\t\x03\t\x03\t\x03\n\x03\n" + | ||
"\x05\n_\n\n\x03\v\x03\v\x03\v\x03\f\x03\f\x03\f\x03\f\x03\r\x03\r\x03" + | ||
"\r\x03\x0E\x03\x0E\x03\x0E\x05\x0En\n\x0E\x03\x0F\x03\x0F\x03\x0F\x03" + | ||
"\x0F\x03\x10\x03\x10\x03\x10\x03\x10\x07\x10x\n\x10\f\x10\x0E\x10{\v\x10" + | ||
"\x03\x10\x05\x10~\n\x10\x03\x10\x03\x10\x03\x11\x03\x11\x03\x11\x03\x11" + | ||
"\x03\x11\x03\x12\x03\x12\x05\x12\x89\n\x12\x03\x13\x03\x13\x03\x14\x03" + | ||
"\x14\x03\x14\x02\x02\x02\x15\x02\x02\x04\x02\x06\x02\b\x02\n\x02\f\x02" + | ||
"\x0E\x02\x10\x02\x12\x02\x14\x02\x16\x02\x18\x02\x1A\x02\x1C\x02\x1E\x02" + | ||
" \x02\"\x02$\x02&\x02\x02\x04\x03\x02\x17\x17\x05\x02\x03\x03\x06\x07" + | ||
"\n\v\x02\x89\x02/\x03\x02\x02\x02\x045\x03\x02\x02\x02\x068\x03\x02\x02" + | ||
"\x02\bB\x03\x02\x02\x02\nK\x03\x02\x02\x02\fT\x03\x02\x02\x02\x0EW\x03" + | ||
"\x02\x02\x02\x10Y\x03\x02\x02\x02\x12\\\x03\x02\x02\x02\x14`\x03\x02\x02" + | ||
"\x02\x16c\x03\x02\x02\x02\x18g\x03\x02\x02\x02\x1Am\x03\x02\x02\x02\x1C" + | ||
"o\x03\x02\x02\x02\x1Es\x03\x02\x02\x02 \x81\x03\x02\x02\x02\"\x86\x03" + | ||
"\x02\x02\x02$\x8A\x03\x02\x02\x02&\x8C\x03\x02\x02\x02(*\x05\b\x05\x02" + | ||
")(\x03\x02\x02\x02*-\x03\x02\x02\x02+)\x03\x02\x02\x02+,\x03\x02\x02\x02" + | ||
",.\x03\x02\x02\x02-+\x03\x02\x02\x02.0\x05\x04\x03\x02/+\x03\x02\x02\x02" + | ||
"01\x03\x02\x02\x021/\x03\x02\x02\x0212\x03\x02\x02\x0223\x03\x02\x02\x02" + | ||
"34\x07\x02\x02\x034\x03\x03\x02\x02\x0256\x05\x06\x04\x0267\x05\n\x06" + | ||
"\x027\x05\x03\x02\x02\x0289\x07\x05\x02\x029=\x05\x14\v\x02:<\x05\x16" + | ||
"\f\x02;:\x03\x02\x02\x02<?\x03\x02\x02\x02=;\x03\x02\x02\x02=>\x03\x02" + | ||
"\x02\x02>@\x03\x02\x02\x02?=\x03\x02\x02\x02@A\x07\x17\x02\x02A\x07\x03" + | ||
"\x02\x02\x02BF\x07\x05\x02\x02CE\n\x02\x02\x02DC\x03\x02\x02\x02EH\x03" + | ||
"\x02\x02\x02FD\x03\x02\x02\x02FG\x03\x02\x02\x02GI\x03\x02\x02\x02HF\x03" + | ||
"\x02\x02\x02IJ\x07\x17\x02\x02J\t\x03\x02\x02\x02KL\x05\f\x07\x02LM\x07" + | ||
"\b\x02\x02M\v\x03\x02\x02\x02NS\x07\x04\x02\x02OS\x05\b\x05\x02PS\x05" + | ||
"\x10\t\x02QS\x05\x0E\b\x02RN\x03\x02\x02\x02RO\x03\x02\x02\x02RP\x03\x02" + | ||
"\x02\x02RQ\x03\x02\x02\x02SV\x03\x02\x02\x02TR\x03\x02\x02\x02TU\x03\x02" + | ||
"\x02\x02U\r\x03\x02\x02\x02VT\x03\x02\x02\x02WX\t\x03\x02\x02X\x0F\x03" + | ||
"\x02\x02\x02YZ\x07\f\x02\x02Z[\x05\x12\n\x02[\x11\x03\x02\x02\x02\\^\x07" + | ||
"\x03\x02\x02]_\x07\x06\x02\x02^]\x03\x02\x02\x02^_\x03\x02\x02\x02_\x13" + | ||
"\x03\x02\x02\x02`a\x07\x10\x02\x02ab\x05$\x13\x02b\x15\x03\x02\x02\x02" + | ||
"cd\x07\x11\x02\x02de\x05&\x14\x02ef\x05\x18\r\x02f\x17\x03\x02\x02\x02" + | ||
"gh\x07\x0E\x02\x02hi\x05\x1A\x0E\x02i\x19\x03\x02\x02\x02jn\x05\x1C\x0F" + | ||
"\x02kn\x05\x1E\x10\x02ln\x05 \x11\x02mj\x03\x02\x02\x02mk\x03\x02\x02" + | ||
"\x02ml\x03\x02\x02\x02n\x1B\x03\x02\x02\x02op\x07\x12\x02\x02pq\x07\x0F" + | ||
"\x02\x02qr\x07\x13\x02\x02r\x1D\x03\x02\x02\x02st\x07\x12\x02\x02ty\x05" + | ||
"\"\x12\x02uv\x07\x14\x02\x02vx\x05\"\x12\x02wu\x03\x02\x02\x02x{\x03\x02" + | ||
"\x02\x02yw\x03\x02\x02\x02yz\x03\x02\x02\x02z}\x03\x02\x02\x02{y\x03\x02" + | ||
"\x02\x02|~\x07\x14\x02\x02}|\x03\x02\x02\x02}~\x03\x02\x02\x02~\x7F\x03" + | ||
"\x02\x02\x02\x7F\x80\x07\x13\x02\x02\x80\x1F\x03\x02\x02\x02\x81\x82\x07" + | ||
"\x12\x02\x02\x82\x83\x05\x1E\x10\x02\x83\x84\x07\x0F\x02\x02\x84\x85\x07" + | ||
"\x13\x02\x02\x85!\x03\x02\x02\x02\x86\x88\x07\x03\x02\x02\x87\x89\x07" + | ||
"\x15\x02\x02\x88\x87\x03\x02\x02\x02\x88\x89\x03\x02\x02\x02\x89#\x03" + | ||
"\x02\x02\x02\x8A\x8B\x07\x03\x02\x02\x8B%\x03\x02\x02\x02\x8C\x8D\x07" + | ||
"\x03\x02\x02\x8D\'\x03\x02\x02\x02\r+1=FRT^my}\x88"; | ||
"\x13\t\x13\x04\x14\t\x14\x04\x15\t\x15\x03\x02\x07\x02,\n\x02\f\x02\x0E" + | ||
"\x02/\v\x02\x03\x02\x06\x022\n\x02\r\x02\x0E\x023\x03\x02\x03\x02\x03" + | ||
"\x03\x03\x03\x03\x03\x03\x04\x03\x04\x03\x04\x07\x04>\n\x04\f\x04\x0E" + | ||
"\x04A\v\x04\x03\x04\x03\x04\x03\x05\x03\x05\x07\x05G\n\x05\f\x05\x0E\x05" + | ||
"J\v\x05\x03\x05\x03\x05\x03\x06\x03\x06\x03\x06\x03\x07\x03\x07\x03\x07" + | ||
"\x03\x07\x03\x07\x07\x07V\n\x07\f\x07\x0E\x07Y\v\x07\x03\b\x03\b\x03\t" + | ||
"\x03\t\x03\t\x03\n\x03\n\x03\n\x03\v\x03\v\x05\ve\n\v\x03\f\x03\f\x03" + | ||
"\f\x03\r\x03\r\x03\r\x03\r\x03\x0E\x03\x0E\x03\x0E\x03\x0F\x03\x0F\x03" + | ||
"\x0F\x05\x0Ft\n\x0F\x03\x10\x03\x10\x03\x10\x03\x10\x03\x11\x03\x11\x03" + | ||
"\x11\x03\x11\x07\x11~\n\x11\f\x11\x0E\x11\x81\v\x11\x03\x11\x05\x11\x84" + | ||
"\n\x11\x03\x11\x03\x11\x03\x12\x03\x12\x03\x12\x03\x12\x03\x12\x03\x13" + | ||
"\x03\x13\x05\x13\x8F\n\x13\x03\x14\x03\x14\x03\x15\x03\x15\x03\x15\x02" + | ||
"\x02\x02\x16\x02\x02\x04\x02\x06\x02\b\x02\n\x02\f\x02\x0E\x02\x10\x02" + | ||
"\x12\x02\x14\x02\x16\x02\x18\x02\x1A\x02\x1C\x02\x1E\x02 \x02\"\x02$\x02" + | ||
"&\x02(\x02\x02\x04\x03\x02\x17\x17\x05\x02\x03\x03\x06\x07\n\v\x02\x8F" + | ||
"\x021\x03\x02\x02\x02\x047\x03\x02\x02\x02\x06:\x03\x02\x02\x02\bD\x03" + | ||
"\x02\x02\x02\nM\x03\x02\x02\x02\fW\x03\x02\x02\x02\x0EZ\x03\x02\x02\x02" + | ||
"\x10\\\x03\x02\x02\x02\x12_\x03\x02\x02\x02\x14b\x03\x02\x02\x02\x16f" + | ||
"\x03\x02\x02\x02\x18i\x03\x02\x02\x02\x1Am\x03\x02\x02\x02\x1Cs\x03\x02" + | ||
"\x02\x02\x1Eu\x03\x02\x02\x02 y\x03\x02\x02\x02\"\x87\x03\x02\x02\x02" + | ||
"$\x8C\x03\x02\x02\x02&\x90\x03\x02\x02\x02(\x92\x03\x02\x02\x02*,\x05" + | ||
"\b\x05\x02+*\x03\x02\x02\x02,/\x03\x02\x02\x02-+\x03\x02\x02\x02-.\x03" + | ||
"\x02\x02\x02.0\x03\x02\x02\x02/-\x03\x02\x02\x0202\x05\x04\x03\x021-\x03" + | ||
"\x02\x02\x0223\x03\x02\x02\x0231\x03\x02\x02\x0234\x03\x02\x02\x0245\x03" + | ||
"\x02\x02\x0256\x07\x02\x02\x036\x03\x03\x02\x02\x0278\x05\x06\x04\x02" + | ||
"89\x05\n\x06\x029\x05\x03\x02\x02\x02:;\x07\x05\x02\x02;?\x05\x16\f\x02" + | ||
"<>\x05\x18\r\x02=<\x03\x02\x02\x02>A\x03\x02\x02\x02?=\x03\x02\x02\x02" + | ||
"?@\x03\x02\x02\x02@B\x03\x02\x02\x02A?\x03\x02\x02\x02BC\x07\x17\x02\x02" + | ||
"C\x07\x03\x02\x02\x02DH\x07\x05\x02\x02EG\n\x02\x02\x02FE\x03\x02\x02" + | ||
"\x02GJ\x03\x02\x02\x02HF\x03\x02\x02\x02HI\x03\x02\x02\x02IK\x03\x02\x02" + | ||
"\x02JH\x03\x02\x02\x02KL\x07\x17\x02\x02L\t\x03\x02\x02\x02MN\x05\f\x07" + | ||
"\x02NO\x07\b\x02\x02O\v\x03\x02\x02\x02PV\x07\x04\x02\x02QV\x05\b\x05" + | ||
"\x02RV\x05\x12\n\x02SV\x05\x0E\b\x02TV\x05\x10\t\x02UP\x03\x02\x02\x02" + | ||
"UQ\x03\x02\x02\x02UR\x03\x02\x02\x02US\x03\x02\x02\x02UT\x03\x02\x02\x02" + | ||
"VY\x03\x02\x02\x02WU\x03\x02\x02\x02WX\x03\x02\x02\x02X\r\x03\x02\x02" + | ||
"\x02YW\x03\x02\x02\x02Z[\t\x03\x02\x02[\x0F\x03\x02\x02\x02\\]\x07\f\x02" + | ||
"\x02]^\x05\x0E\b\x02^\x11\x03\x02\x02\x02_`\x07\f\x02\x02`a\x05\x14\v" + | ||
"\x02a\x13\x03\x02\x02\x02bd\x07\x03\x02\x02ce\x07\x06\x02\x02dc\x03\x02" + | ||
"\x02\x02de\x03\x02\x02\x02e\x15\x03\x02\x02\x02fg\x07\x10\x02\x02gh\x05" + | ||
"&\x14\x02h\x17\x03\x02\x02\x02ij\x07\x11\x02\x02jk\x05(\x15\x02kl\x05" + | ||
"\x1A\x0E\x02l\x19\x03\x02\x02\x02mn\x07\x0E\x02\x02no\x05\x1C\x0F\x02" + | ||
"o\x1B\x03\x02\x02\x02pt\x05\x1E\x10\x02qt\x05 \x11\x02rt\x05\"\x12\x02" + | ||
"sp\x03\x02\x02\x02sq\x03\x02\x02\x02sr\x03\x02\x02\x02t\x1D\x03\x02\x02" + | ||
"\x02uv\x07\x12\x02\x02vw\x07\x0F\x02\x02wx\x07\x13\x02\x02x\x1F\x03\x02" + | ||
"\x02\x02yz\x07\x12\x02\x02z\x7F\x05$\x13\x02{|\x07\x14\x02\x02|~\x05$" + | ||
"\x13\x02}{\x03\x02\x02\x02~\x81\x03\x02\x02\x02\x7F}\x03\x02\x02\x02\x7F" + | ||
"\x80\x03\x02\x02\x02\x80\x83\x03\x02\x02\x02\x81\x7F\x03\x02\x02\x02\x82" + | ||
"\x84\x07\x14\x02\x02\x83\x82\x03\x02\x02\x02\x83\x84\x03\x02\x02\x02\x84" + | ||
"\x85\x03\x02\x02\x02\x85\x86\x07\x13\x02\x02\x86!\x03\x02\x02\x02\x87" + | ||
"\x88\x07\x12\x02\x02\x88\x89\x05 \x11\x02\x89\x8A\x07\x0F\x02\x02\x8A" + | ||
"\x8B\x07\x13\x02\x02\x8B#\x03\x02\x02\x02\x8C\x8E\x07\x03\x02\x02\x8D" + | ||
"\x8F\x07\x15\x02\x02\x8E\x8D\x03\x02\x02\x02\x8E\x8F\x03\x02\x02\x02\x8F" + | ||
"%\x03\x02\x02\x02\x90\x91\x07\x03\x02\x02\x91\'\x03\x02\x02\x02\x92\x93" + | ||
"\x07\x03\x02\x02\x93)\x03\x02\x02\x02\r-3?HUWds\x7F\x83\x8E"; | ||
export { SQLParser }; | ||
export class InputContext extends ParserRuleContext { | ||
@@ -1142,2 +1174,10 @@ EOF() { return this.getToken(SQLParser.EOF, 0); } | ||
} | ||
range(i) { | ||
if (i === undefined) { | ||
return this.getRuleContexts(RangeContext); | ||
} | ||
else { | ||
return this.getRuleContext(i, RangeContext); | ||
} | ||
} | ||
constructor(parent, invokingState) { | ||
@@ -1203,2 +1243,34 @@ super(parent, invokingState); | ||
} | ||
export class RangeContext extends ParserRuleContext { | ||
PARAM_MARK() { return this.getToken(SQLParser.PARAM_MARK, 0); } | ||
word() { | ||
return this.getRuleContext(0, WordContext); | ||
} | ||
constructor(parent, invokingState) { | ||
super(parent, invokingState); | ||
} | ||
// @Override | ||
get ruleIndex() { return SQLParser.RULE_range; } | ||
// @Override | ||
enterRule(listener) { | ||
if (listener.enterRange) { | ||
listener.enterRange(this); | ||
} | ||
} | ||
// @Override | ||
exitRule(listener) { | ||
if (listener.exitRange) { | ||
listener.exitRange(this); | ||
} | ||
} | ||
// @Override | ||
accept(visitor) { | ||
if (visitor.visitRange) { | ||
return visitor.visitRange(this); | ||
} | ||
else { | ||
return visitor.visitChildren(this); | ||
} | ||
} | ||
} | ||
export class ParamContext extends ParserRuleContext { | ||
@@ -1205,0 +1277,0 @@ PARAM_MARK() { return this.getToken(SQLParser.PARAM_MARK, 0); } |
import { ParseTreeListener } from "antlr4ts/tree/ParseTreeListener.js"; | ||
import { InputContext } from "./SQLParser.js"; | ||
import { InputContext, RangeContext } from "./SQLParser.js"; | ||
import { QueryContext } from "./SQLParser.js"; | ||
@@ -97,2 +97,12 @@ import { QueryDefContext } from "./SQLParser.js"; | ||
/** | ||
* Enter a parse tree produced by `SQLParser.range`. | ||
* @param ctx the parse tree | ||
*/ | ||
enterRange?: (ctx: RangeContext) => void; | ||
/** | ||
* Exit a parse tree produced by `SQLParser.range`. | ||
* @param ctx the parse tree | ||
*/ | ||
exitRange?: (ctx: RangeContext) => void; | ||
/** | ||
* Enter a parse tree produced by `SQLParser.param`. | ||
@@ -99,0 +109,0 @@ * @param ctx the parse tree |
import { ParseTreeVisitor } from "antlr4ts/tree/ParseTreeVisitor.js"; | ||
import { InputContext } from "./SQLParser.js"; | ||
import { InputContext, RangeContext } from "./SQLParser.js"; | ||
import { QueryContext } from "./SQLParser.js"; | ||
@@ -72,2 +72,8 @@ import { QueryDefContext } from "./SQLParser.js"; | ||
/** | ||
* Visit a parse tree produced by `SQLParser.range`. | ||
* @param ctx the parse tree | ||
* @return the visitor result | ||
*/ | ||
visitRange?: (ctx: RangeContext) => Result; | ||
/** | ||
* Visit a parse tree produced by `SQLParser.param`. | ||
@@ -74,0 +80,0 @@ * @param ctx the parse tree |
@@ -7,3 +7,3 @@ // Generated from src/loader/typescript/grammar/QueryLexer.g4 by ANTLR 4.9.0-SNAPSHOT | ||
import * as Utils from "antlr4ts/misc/Utils.js"; | ||
export class QueryLexer extends Lexer { | ||
class QueryLexer extends Lexer { | ||
// @Override | ||
@@ -109,2 +109,3 @@ // @NotNull | ||
"\x03\x02\x02\x02\t\x02%:AHQV\x04\t\x03\x02\b\x02\x02"; | ||
export { QueryLexer }; | ||
//# sourceMappingURL=QueryLexer.js.map |
@@ -13,3 +13,3 @@ // Generated from src/loader/typescript/grammar/QueryParser.g4 by ANTLR 4.9.0-SNAPSHOT | ||
import * as Utils from "antlr4ts/misc/Utils.js"; | ||
export class QueryParser extends Parser { | ||
class QueryParser extends Parser { | ||
// @Override | ||
@@ -615,2 +615,3 @@ // @NotNull | ||
"i\x03\x02\x02\x02i\x17\x03\x02\x02\x02\x0E\x1A!\',38EIUYbh"; | ||
export { QueryParser }; | ||
export class InputContext extends ParserRuleContext { | ||
@@ -617,0 +618,0 @@ query() { |
{ | ||
"name": "@pgtyped/parser", | ||
"version": "2.1.0", | ||
"version": "2.3.0", | ||
"type": "module", | ||
@@ -46,3 +46,3 @@ "exports": { | ||
}, | ||
"gitHead": "b358eaa01072939735f3d9432403b6d6c454ca06" | ||
"gitHead": "1c6c9b29a9cc483a501321c4335a8d397e3fe4ad" | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
AI-detected potential code anomaly
Supply chain riskAI has identified unusual behaviors that may pose a security risk.
Found 4 instances in 1 package
AI-detected potential code anomaly
Supply chain riskAI has identified unusual behaviors that may pose a security risk.
Found 3 instances in 1 package
266362
4722
4