simple-graph-query 3.1.0 → 3.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -71,58 +71,47 @@ export declare class ForgeParser extends Parser {
71
71
  static readonly IMP_TOK = 60;
72
72
  static readonly ELSE_TOK = 61;
73
73
  static readonly AND_TOK = 62;
74
- static readonly UNTIL_TOK = 63;
75
- static readonly RELEASE_TOK = 64;
76
- static readonly SINCE_TOK = 65;
77
- static readonly TRIGGERED_TOK = 66;
78
- static readonly NEG_TOK = 67;
79
- static readonly ALWAYS_TOK = 68;
80
- static readonly EVENTUALLY_TOK = 69;
81
- static readonly AFTER_TOK = 70;
82
- static readonly BEFORE_TOK = 71;
83
- static readonly ONCE_TOK = 72;
84
- static readonly HISTORICALLY_TOK = 73;
85
- static readonly CARD_TOK = 74;
86
- static readonly PPLUS_TOK = 75;
87
- static readonly AMP_TOK = 76;
88
- static readonly SUBT_TOK = 77;
89
- static readonly SUPT_TOK = 78;
90
- static readonly PRIME_TOK = 79;
91
- static readonly TILDE_TOK = 80;
92
- static readonly EXP_TOK = 81;
93
- static readonly STAR_TOK = 82;
94
- static readonly AT_TOK = 83;
95
- static readonly BACKQUOTE_TOK = 84;
96
- static readonly THIS_TOK = 85;
97
- static readonly SEXPR_TOK = 86;
98
- static readonly INST_TOK = 87;
99
- static readonly EVAL_TOK = 88;
100
- static readonly EXAMPLE_TOK = 89;
101
- static readonly ARROW_TOK = 90;
102
- static readonly GET_LABEL_TOK = 91;
103
- static readonly GET_LABEL_STR_TOK = 92;
104
- static readonly GET_LABEL_BOOL_TOK = 93;
105
- static readonly GET_LABEL_NUM_TOK = 94;
106
- static readonly EQ_TOK = 95;
107
- static readonly LT_TOK = 96;
108
- static readonly GT_TOK = 97;
109
- static readonly LEQ_TOK = 98;
110
- static readonly GEQ_TOK = 99;
111
- static readonly NI_TOK = 100;
112
- static readonly NO_TOK = 101;
113
- static readonly SUM_TOK = 102;
114
- static readonly INT_TOK = 103;
115
- static readonly OPTION_TOK = 104;
116
- static readonly COMMA_TOK = 105;
117
- static readonly SLASH_TOK = 106;
118
- static readonly NUM_CONST_TOK = 107;
119
- static readonly QUOTED_IDENTIFIER_TOK = 108;
120
- static readonly IDENTIFIER_TOK = 109;
121
- static readonly WS = 110;
122
- static readonly CCOMMENT = 111;
123
- static readonly COMMENT = 112;
124
- static readonly MULTCOMMENT = 113;
125
- static readonly LANG_DECL = 114;
74
+ static readonly NEG_TOK = 63;
75
+ static readonly CARD_TOK = 64;
76
+ static readonly PPLUS_TOK = 65;
77
+ static readonly AMP_TOK = 66;
78
+ static readonly SUBT_TOK = 67;
79
+ static readonly SUPT_TOK = 68;
80
+ static readonly TILDE_TOK = 69;
81
+ static readonly EXP_TOK = 70;
82
+ static readonly STAR_TOK = 71;
83
+ static readonly AT_TOK = 72;
84
+ static readonly BACKQUOTE_TOK = 73;
85
+ static readonly THIS_TOK = 74;
86
+ static readonly SEXPR_TOK = 75;
87
+ static readonly INST_TOK = 76;
88
+ static readonly EVAL_TOK = 77;
89
+ static readonly EXAMPLE_TOK = 78;
90
+ static readonly ARROW_TOK = 79;
91
+ static readonly GET_LABEL_TOK = 80;
92
+ static readonly GET_LABEL_STR_TOK = 81;
93
+ static readonly GET_LABEL_BOOL_TOK = 82;
94
+ static readonly GET_LABEL_NUM_TOK = 83;
95
+ static readonly EQ_TOK = 84;
96
+ static readonly LT_TOK = 85;
97
+ static readonly GT_TOK = 86;
98
+ static readonly LEQ_TOK = 87;
99
+ static readonly GEQ_TOK = 88;
100
+ static readonly NI_TOK = 89;
101
+ static readonly NO_TOK = 90;
102
+ static readonly SUM_TOK = 91;
103
+ static readonly INT_TOK = 92;
104
+ static readonly OPTION_TOK = 93;
105
+ static readonly COMMA_TOK = 94;
106
+ static readonly SLASH_TOK = 95;
107
+ static readonly NUM_CONST_TOK = 96;
108
+ static readonly QUOTED_IDENTIFIER_TOK = 97;
109
+ static readonly IDENTIFIER_TOK = 98;
110
+ static readonly WS = 99;
111
+ static readonly CCOMMENT = 100;
112
+ static readonly COMMENT = 101;
113
+ static readonly MULTCOMMENT = 102;
114
+ static readonly LANG_DECL = 103;
126
115
  static readonly RULE_predDecl = 0;
127
116
  static readonly RULE_parseExpr = 1;
128
117
  static readonly RULE_alloyModule = 2;
@@ -176,38 +165,36 @@ export declare class ForgeParser extends Parser {
176
165
  static readonly RULE_expr2 = 50;
177
166
  static readonly RULE_expr3 = 51;
178
167
  static readonly RULE_expr4 = 52;
179
- static readonly RULE_expr4_5 = 53;
180
- static readonly RULE_expr5 = 54;
181
- static readonly RULE_expr6 = 55;
182
- static readonly RULE_expr7 = 56;
183
- static readonly RULE_expr8 = 57;
184
- static readonly RULE_expr9 = 58;
185
- static readonly RULE_expr10 = 59;
186
- static readonly RULE_expr11 = 60;
187
- static readonly RULE_expr12 = 61;
188
- static readonly RULE_expr13 = 62;
189
- static readonly RULE_expr14 = 63;
190
- static readonly RULE_expr15 = 64;
191
- static readonly RULE_expr16 = 65;
192
- static readonly RULE_expr17 = 66;
193
- static readonly RULE_expr18 = 67;
194
- static readonly RULE_arrowExpr = 68;
195
- static readonly RULE_sexprDecl = 69;
196
- static readonly RULE_sexpr = 70;
197
- static readonly RULE_instDecl = 71;
198
- static readonly RULE_evalRelDecl = 72;
199
- static readonly RULE_evalDecl = 73;
200
- static readonly RULE_exampleDecl = 74;
201
- static readonly RULE_queryDecl = 75;
202
- static readonly RULE_numberList = 76;
203
- static readonly RULE_number = 77;
204
- static readonly RULE_bounds = 78;
205
- static readonly RULE_atomNameOrNumber = 79;
206
- static readonly RULE_bound = 80;
207
- static readonly RULE_boundLHS = 81;
208
- static readonly RULE_bindRHSUnion = 82;
209
- static readonly RULE_bindRHSProduct = 83;
210
- static readonly RULE_bindRHSProductBase = 84;
168
+ static readonly RULE_expr5 = 53;
169
+ static readonly RULE_expr6 = 54;
170
+ static readonly RULE_expr7 = 55;
171
+ static readonly RULE_expr8 = 56;
172
+ static readonly RULE_expr9 = 57;
173
+ static readonly RULE_expr10 = 58;
174
+ static readonly RULE_expr11 = 59;
175
+ static readonly RULE_expr12 = 60;
176
+ static readonly RULE_expr13 = 61;
177
+ static readonly RULE_expr14 = 62;
178
+ static readonly RULE_expr15 = 63;
179
+ static readonly RULE_expr17 = 64;
180
+ static readonly RULE_expr18 = 65;
181
+ static readonly RULE_arrowExpr = 66;
182
+ static readonly RULE_sexprDecl = 67;
183
+ static readonly RULE_sexpr = 68;
184
+ static readonly RULE_instDecl = 69;
185
+ static readonly RULE_evalRelDecl = 70;
186
+ static readonly RULE_evalDecl = 71;
187
+ static readonly RULE_exampleDecl = 72;
188
+ static readonly RULE_queryDecl = 73;
189
+ static readonly RULE_numberList = 74;
190
+ static readonly RULE_number = 75;
191
+ static readonly RULE_bounds = 76;
192
+ static readonly RULE_atomNameOrNumber = 77;
193
+ static readonly RULE_bound = 78;
194
+ static readonly RULE_boundLHS = 79;
195
+ static readonly RULE_bindRHSUnion = 80;
196
+ static readonly RULE_bindRHSProduct = 81;
197
+ static readonly RULE_bindRHSProductBase = 82;
211
198
  static readonly ruleNames: string[];
212
199
  private static readonly _LITERAL_NAMES;
213
200
  private static readonly _SYMBOLIC_NAMES;
@@ -275,7 +262,6 @@ export declare class ForgeParser extends Parser {
275
262
  expr3(): Expr3Context;
276
263
  expr4(): Expr4Context;
277
264
  expr4(_p: number): Expr4Context;
278
- expr4_5(): Expr4_5Context;
279
265
  expr5(): Expr5Context;
280
266
  expr6(): Expr6Context;
281
267
  expr6(_p: number): Expr6Context;
@@ -295,8 +281,6 @@ export declare class ForgeParser extends Parser {
295
281
  expr14(_p: number): Expr14Context;
296
282
  expr15(): Expr15Context;
297
283
  expr15(_p: number): Expr15Context;
298
- expr16(): Expr16Context;
299
- expr16(_p: number): Expr16Context;
300
284
  expr17(): Expr17Context;
301
285
  expr18(): Expr18Context;
302
286
  arrowExpr(): ArrowExprContext;
@@ -331,7 +315,6 @@ export declare class ForgeParser extends Parser {
331
315
  private expr13_sempred;
332
316
  private expr14_sempred;
333
317
  private expr15_sempred;
334
- private expr16_sempred;
335
318
  private bindRHSUnion_sempred;
336
319
  private bindRHSProduct_sempred;
337
320
  private static readonly _serializedATNSegments;
@@ -1003,7 +986,7 @@ export declare class Expr3Context extends ParserRuleContext {
1003
986
  accept<Result>(visitor: ForgeVisitor<Result>): Result;
1004
987
  }
1005
988
  export declare class Expr4Context extends ParserRuleContext {
1006
- expr4_5(): Expr4_5Context;
989
+ expr5(): Expr5Context;
1007
990
  expr4(): Expr4Context | undefined;
1008
991
  AND_TOK(): TerminalNode | undefined;
1009
992
  constructor(parent: ParserRuleContext | undefined, invokingState: number);
@@ -1012,29 +995,10 @@ export declare class Expr4Context extends ParserRuleContext {
1012
995
  exitRule(listener: ForgeListener): void;
1013
996
  accept<Result>(visitor: ForgeVisitor<Result>): Result;
1014
997
  }
1015
- export declare class Expr4_5Context extends ParserRuleContext {
1016
- expr5(): Expr5Context[];
1017
- expr5(i: number): Expr5Context;
1018
- UNTIL_TOK(): TerminalNode | undefined;
1019
- RELEASE_TOK(): TerminalNode | undefined;
1020
- SINCE_TOK(): TerminalNode | undefined;
1021
- TRIGGERED_TOK(): TerminalNode | undefined;
1022
- constructor(parent: ParserRuleContext | undefined, invokingState: number);
1023
- get ruleIndex(): number;
1024
- enterRule(listener: ForgeListener): void;
1025
- exitRule(listener: ForgeListener): void;
1026
- accept<Result>(visitor: ForgeVisitor<Result>): Result;
1027
- }
1028
998
  export declare class Expr5Context extends ParserRuleContext {
1029
999
  expr6(): Expr6Context | undefined;
1030
1000
  NEG_TOK(): TerminalNode | undefined;
1031
1001
  expr5(): Expr5Context | undefined;
1032
- ALWAYS_TOK(): TerminalNode | undefined;
1033
- EVENTUALLY_TOK(): TerminalNode | undefined;
1034
- AFTER_TOK(): TerminalNode | undefined;
1035
- BEFORE_TOK(): TerminalNode | undefined;
1036
- ONCE_TOK(): TerminalNode | undefined;
1037
- HISTORICALLY_TOK(): TerminalNode | undefined;
1038
1002
  constructor(parent: ParserRuleContext | undefined, invokingState: number);
1039
1003
  get ruleIndex(): number;
1040
1004
  enterRule(listener: ForgeListener): void;
@@ -1142,7 +1106,7 @@ export declare class Expr14Context extends ParserRuleContext {
1142
1106
  accept<Result>(visitor: ForgeVisitor<Result>): Result;
1143
1107
  }
1144
1108
  export declare class Expr15Context extends ParserRuleContext {
1145
- expr16(): Expr16Context | undefined;
1109
+ expr17(): Expr17Context | undefined;
1146
1110
  expr15(): Expr15Context | undefined;
1147
1111
  DOT_TOK(): TerminalNode | undefined;
1148
1112
  name(): NameContext | undefined;
@@ -1155,16 +1119,6 @@ export declare class Expr15Context extends ParserRuleContext {
1155
1119
  exitRule(listener: ForgeListener): void;
1156
1120
  accept<Result>(visitor: ForgeVisitor<Result>): Result;
1157
1121
  }
1158
- export declare class Expr16Context extends ParserRuleContext {
1159
- expr17(): Expr17Context | undefined;
1160
- expr16(): Expr16Context | undefined;
1161
- PRIME_TOK(): TerminalNode | undefined;
1162
- constructor(parent: ParserRuleContext | undefined, invokingState: number);
1163
- get ruleIndex(): number;
1164
- enterRule(listener: ForgeListener): void;
1165
- exitRule(listener: ForgeListener): void;
1166
- accept<Result>(visitor: ForgeVisitor<Result>): Result;
1167
- }
1168
1122
  export declare class Expr17Context extends ParserRuleContext {
1169
1123
  expr18(): Expr18Context | undefined;
1170
1124
  expr17(): Expr17Context | undefined;
@@ -52,7 +52,6 @@ import { Expr1_5Context } from "./ForgeParser";
52
52
  import { Expr2Context } from "./ForgeParser";
53
53
  import { Expr3Context } from "./ForgeParser";
54
54
  import { Expr4Context } from "./ForgeParser";
55
- import { Expr4_5Context } from "./ForgeParser";
56
55
  import { Expr5Context } from "./ForgeParser";
57
56
  import { Expr6Context } from "./ForgeParser";
58
57
  import { Expr7Context } from "./ForgeParser";
@@ -64,7 +63,6 @@ import { Expr12Context } from "./ForgeParser";
64
63
  import { Expr13Context } from "./ForgeParser";
65
64
  import { Expr14Context } from "./ForgeParser";
66
65
  import { Expr15Context } from "./ForgeParser";
67
- import { Expr16Context } from "./ForgeParser";
68
66
  import { Expr17Context } from "./ForgeParser";
69
67
  import { Expr18Context } from "./ForgeParser";
70
68
  import { ArrowExprContext } from "./ForgeParser";
@@ -410,12 +408,6 @@ export interface ForgeVisitor<Result> extends ParseTreeVisitor<Result> {
410
408
  * @return the visitor result
411
409
  */
412
410
  visitExpr4?: (ctx: Expr4Context) => Result;
413
- /**
414
- * Visit a parse tree produced by `ForgeParser.expr4_5`.
415
- * @param ctx the parse tree
416
- * @return the visitor result
417
- */
418
- visitExpr4_5?: (ctx: Expr4_5Context) => Result;
419
411
  /**
420
412
  * Visit a parse tree produced by `ForgeParser.expr5`.
421
413
  * @param ctx the parse tree
@@ -482,12 +474,6 @@ export interface ForgeVisitor<Result> extends ParseTreeVisitor<Result> {
482
474
  * @return the visitor result
483
475
  */
484
476
  visitExpr15?: (ctx: Expr15Context) => Result;
485
- /**
486
- * Visit a parse tree produced by `ForgeParser.expr16`.
487
- * @param ctx the parse tree
488
- * @return the visitor result
489
- */
490
- visitExpr16?: (ctx: Expr16Context) => Result;
491
477
  /**
492
478
  * Visit a parse tree produced by `ForgeParser.expr17`.
493
479
  * @param ctx the parse tree
@@ -22,7 +22,8 @@ export declare function getIdentifierName(ctx: NameContext): string;
22
22
  */
23
23
  export declare function quoteIfReserved(identifier: string, reservedKeywords: Set<string>): string;
24
24
  /**
25
- * Set of all reserved keywords in Forge.
25
+ * Every spelling a bare name cannot carry: the keywords, and `/`, which matches
26
+ * the identifier pattern but is claimed by SLASH_TOK.
26
27
  * Use with quoteIfReserved() when generating Forge expressions.
27
28
  */
28
29
  export declare const FORGE_RESERVED_KEYWORDS: Set<string>;