cariboujs 2.0.5 → 2.0.7
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/README.md +7 -2
- package/abnf/AbnfLexer.js +51 -50
- package/c/CLexer.js +332 -333
- package/c/CParser.js +4 -4
- package/c/CParserBase.js +27 -1
- package/c/SymbolTable.js +6 -1
- package/cpp/CPP14Parser.js +415 -404
- package/csharp/v8-spec/CSharpParser.js +3943 -3932
- package/csharp/v8-spec/CSharpParserBase.js +19 -1
- package/cypher/CypherParser.js +1171 -780
- package/cypher/CypherParserListener.js +27 -0
- package/cypher/CypherParserVisitor.js +18 -0
- package/gql/GQLLexer.js +2203 -0
- package/gql/GQLListener.js +5499 -0
- package/gql/GQLParser.js +58653 -0
- package/gql/GQLVisitor.js +3670 -0
- package/maml/MAMLLexer.js +116 -0
- package/maml/MAMLListener.js +72 -0
- package/maml/MAMLParser.js +935 -0
- package/maml/MAMLVisitor.js +52 -0
- package/miniscript/MiniscriptLexer.js +199 -0
- package/miniscript/MiniscriptListener.js +180 -0
- package/miniscript/MiniscriptParser.js +2620 -0
- package/miniscript/MiniscriptVisitor.js +124 -0
- package/odin/odinLexer.js +739 -0
- package/odin/odinListener.js +882 -0
- package/odin/odinParser.js +12189 -0
- package/odin/odinVisitor.js +592 -0
- package/package.json +1 -1
- package/sql/mysql/Oracle/MySQLLexer.js +3689 -3668
- package/sql/mysql/Oracle/MySQLParser.js +4383 -4399
- package/sql/plsql/PlSqlLexer.js +13604 -13587
- package/sql/plsql/PlSqlParser.js +43442 -40169
- package/sql/plsql/PlSqlParserListener.js +36 -0
- package/sql/plsql/PlSqlParserVisitor.js +24 -0
- package/sql/postgresql/PostgreSQLParser.js +91 -91
- package/sql/snowflake/SnowflakeParser.js +1556 -1536
- package/sql/sqlite/SQLiteParser.js +2074 -1737
- package/turtle/TURTLELexer.js +155 -156
- package/vba/vba7_1/vbaLexer.js +1689 -0
- package/vba/vba7_1/vbaParser.js +42797 -0
- package/vba/vba7_1/vbaParserListener.js +3267 -0
- package/vba/vba7_1/vbaParserVisitor.js +2182 -0
- package/vhdl/vhdl2008/vhdl2008Listener.js +9 -0
- package/vhdl/vhdl2008/vhdl2008Parser.js +2840 -2705
- package/vhdl/vhdl2008/vhdl2008Visitor.js +6 -0
- package/wkt/wktLexer.js +177 -148
- package/wkt/wktListener.js +123 -60
- package/wkt/wktParser.js +1802 -1125
- package/wkt/wktVisitor.js +72 -30
- /package/scala/{ScalaLexer.js → scala2/ScalaLexer.js} +0 -0
- /package/scala/{ScalaListener.js → scala2/ScalaListener.js} +0 -0
- /package/scala/{ScalaParser.js → scala2/ScalaParser.js} +0 -0
- /package/scala/{ScalaVisitor.js → scala2/ScalaVisitor.js} +0 -0
|
@@ -322,7 +322,25 @@ export default class CSharpParserBase extends antlr4.Parser {
|
|
|
322
322
|
return tok2 !== null && (tok2.type === CSharpLexer.Simple_Identifier || tok2.text === '_');
|
|
323
323
|
}
|
|
324
324
|
|
|
325
|
-
IsConstantPatternAhead() {
|
|
325
|
+
IsConstantPatternAhead() {
|
|
326
|
+
if (this.IsDeclarationPatternAhead()) return false;
|
|
327
|
+
if (this._input.LT(1)?.type === CSharpLexer.TK_LPAREN) {
|
|
328
|
+
let depth = 0, i = 1;
|
|
329
|
+
while (true) {
|
|
330
|
+
const tok = this._input.LT(i++);
|
|
331
|
+
if (!tok || tok.type < 0) break;
|
|
332
|
+
if (tok.type === CSharpLexer.TK_LPAREN) depth++;
|
|
333
|
+
else if (tok.type === CSharpLexer.TK_RPAREN) { depth--; if (depth === 0) break; }
|
|
334
|
+
else if (tok.type === CSharpLexer.TK_COMMA && depth === 1) return false;
|
|
335
|
+
}
|
|
336
|
+
}
|
|
337
|
+
// Identifier followed immediately by '(' → type-headed positional pattern.
|
|
338
|
+
if (this._input.LT(1)?.type === CSharpLexer.Simple_Identifier
|
|
339
|
+
&& this._input.LT(2)?.type === CSharpLexer.TK_LPAREN) return false;
|
|
340
|
+
return true;
|
|
341
|
+
}
|
|
342
|
+
|
|
343
|
+
IsPositionalPatternAhead() { return !this.IsConstantPatternAhead(); }
|
|
326
344
|
|
|
327
345
|
IsImplicitlyTypedLocalVariable() {
|
|
328
346
|
const tok = this._input.LT(1);
|