@sap/cds-compiler 6.7.3 → 6.8.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.
Files changed (107) hide show
  1. package/CHANGELOG.md +28 -0
  2. package/bin/cdsc.js +5 -5
  3. package/bin/cdsse.js +1 -1
  4. package/lib/api/main.js +9 -8
  5. package/lib/api/options.js +2 -1
  6. package/lib/api/validate.js +1 -1
  7. package/lib/base/error.js +2 -0
  8. package/lib/base/message-registry.js +7 -2
  9. package/lib/base/messages.js +2 -2
  10. package/lib/{optionProcessor.js → base/optionProcessor.js} +3 -3
  11. package/lib/base/{model.js → specialOptions.js} +16 -39
  12. package/lib/checks/arrayOfs.js +1 -1
  13. package/lib/checks/elements.js +1 -1
  14. package/lib/checks/enricher.js +2 -2
  15. package/lib/checks/featureFlags.js +54 -24
  16. package/lib/checks/foreignKeys.js +1 -1
  17. package/lib/checks/invalidTarget.js +1 -1
  18. package/lib/checks/managedInType.js +1 -1
  19. package/lib/checks/onConditions.js +1 -1
  20. package/lib/checks/queryNoDbArtifacts.js +1 -1
  21. package/lib/checks/validator.js +10 -14
  22. package/lib/compiler/builtins.js +1 -1
  23. package/lib/compiler/checks.js +3 -3
  24. package/lib/compiler/define.js +5 -2
  25. package/lib/{base → compiler}/dictionaries.js +2 -0
  26. package/lib/compiler/extend.js +2 -2
  27. package/lib/compiler/generate.js +2 -2
  28. package/lib/compiler/index.js +11 -3
  29. package/lib/compiler/kick-start.js +1 -1
  30. package/lib/compiler/populate.js +2 -2
  31. package/lib/compiler/resolve.js +4 -2
  32. package/lib/compiler/shared.js +35 -6
  33. package/lib/compiler/utils.js +2 -4
  34. package/lib/compiler/xpr-rewrite.js +1 -1
  35. package/lib/edm/annotations/edmJson.js +2 -4
  36. package/lib/edm/annotations/genericTranslation.js +2 -1
  37. package/lib/edm/csn2edm.js +3 -2
  38. package/lib/edm/edmAnnoPreprocessor.js +1 -1
  39. package/lib/edm/edmInboundChecks.js +2 -1
  40. package/lib/edm/edmPreprocessor.js +3 -3
  41. package/lib/edm/edmUtils.js +2 -2
  42. package/lib/gen/BaseParser.js +1 -12
  43. package/lib/gen/CdlGrammar.checksum +1 -1
  44. package/lib/gen/CdlParser.js +1068 -1067
  45. package/lib/json/from-csn.js +7 -2
  46. package/lib/json/to-csn.js +17 -2
  47. package/lib/main.js +3 -3
  48. package/lib/model/csnUtils.js +2 -2
  49. package/lib/modelCompare/compare.js +1 -1
  50. package/lib/modelCompare/utils/filter.js +1 -0
  51. package/lib/parsers/AstBuildingParser.js +40 -3
  52. package/lib/parsers/index.js +1 -1
  53. package/lib/render/manageConstraints.js +1 -1
  54. package/lib/render/toCdl.js +3 -3
  55. package/lib/render/toHdbcds.js +2 -2
  56. package/lib/render/toSql.js +7 -7
  57. package/lib/render/utils/common.js +9 -2
  58. package/lib/render/utils/sql.js +14 -5
  59. package/lib/render/utils/standardDatabaseFunctions.js +108 -99
  60. package/lib/sql-identifier.js +9 -1
  61. package/lib/{model → tool-lib}/enrichCsn.js +2 -2
  62. package/lib/{model → tool-lib}/revealInternalProperties.js +2 -1
  63. package/lib/transform/addTenantFields.js +1 -1
  64. package/lib/transform/db/applyTransformations.js +1 -1
  65. package/lib/transform/db/assertUnique.js +1 -1
  66. package/lib/transform/db/assocsToQueries/transformExists.js +1 -1
  67. package/lib/transform/db/backlinks.js +2 -2
  68. package/lib/transform/db/expansion.js +2 -2
  69. package/lib/transform/db/flattening.js +3 -4
  70. package/lib/transform/db/killAnnotations.js +1 -0
  71. package/lib/transform/db/processSqlServices.js +2 -1
  72. package/lib/transform/db/rewriteCalculatedElements.js +2 -2
  73. package/lib/transform/db/temporal.js +30 -5
  74. package/lib/transform/db/views.js +16 -20
  75. package/lib/transform/draft/db.js +1 -2
  76. package/lib/transform/effective/associations.js +1 -1
  77. package/lib/transform/effective/flattening.js +1 -1
  78. package/lib/transform/effective/main.js +19 -4
  79. package/lib/transform/effective/types.js +1 -1
  80. package/lib/transform/{odata/fioriTreeViews.js → fioriTreeViews.js} +48 -25
  81. package/lib/transform/forOdata.js +5 -5
  82. package/lib/transform/forRelationalDB.js +41 -9
  83. package/lib/transform/localized.js +2 -2
  84. package/lib/transform/odata/createForeignKeys.js +1 -1
  85. package/lib/transform/odata/flattening.js +2 -2
  86. package/lib/transform/odata/toFinalBaseType.js +3 -2
  87. package/lib/transform/odata/typesExposure.js +3 -2
  88. package/lib/transform/transformUtils.js +2 -2
  89. package/lib/transform/translateAssocsToJoins.js +2 -1
  90. package/lib/transform/tupleExpansion.js +4 -4
  91. package/lib/transform/universalCsn/universalCsnEnricher.js +7 -3
  92. package/lib/transform/universalCsn/utils.js +1 -1
  93. package/lib/{base → utils}/lazyload.js +9 -0
  94. package/lib/{base → utils}/node-helpers.js +2 -0
  95. package/lib/utils/objectUtils.js +29 -6
  96. package/lib/{base → utils}/optionProcessorHelper.js +16 -6
  97. package/package.json +2 -2
  98. /package/lib/{model → base}/cloneCsn.js +0 -0
  99. /package/lib/{model → base}/csnRefs.js +0 -0
  100. /package/lib/{model/api.js → base/model-api.js} +0 -0
  101. /package/lib/{api → base}/trace.js +0 -0
  102. /package/lib/{model → base}/xprAsTree.js +0 -0
  103. /package/lib/{inspect → tool-lib}/index.js +0 -0
  104. /package/lib/{inspect → tool-lib}/inspectModelStatistics.js +0 -0
  105. /package/lib/{inspect → tool-lib}/inspectPropagation.js +0 -0
  106. /package/lib/{inspect → tool-lib}/inspectUtils.js +0 -0
  107. /package/lib/{base → utils}/shuffle.js +0 -0
@@ -1,4 +1,4 @@
1
- // Parser generated by redepage v0.3.2
1
+ // Parser generated by redepage v0.3.4
2
2
  'use strict;'
3
3
  const { XsnSource, XsnArtifact, XsnName } = require( '../compiler/xsn-model' )
4
4
  const { isValidEnumValue } = require( '../compiler/base' )
@@ -134,7 +134,7 @@ EOF:3,
134
134
  },
135
135
  ['m',0,'}',,,'afterBrace'],
136
136
  'artifactDefOrExtend',
137
- {'@':[10,769],'':11},
137
+ {'@':[10,767],'':11},
138
138
  {
139
139
  type:12,view:12,event:12,action:12,aspect:12,entity:12,context:12,service:12,abstract:12,function:12,annotation:12,
140
140
  define:['ck',12],
@@ -199,22 +199,22 @@ Id:[22,31],
199
199
  'serviceDef',
200
200
  ['mk',44,'service',,,'vocabularyRestriction'],
201
201
  [45,35],
202
- {'@':[45,775],'':46},
202
+ {'@':[45,773],'':46},
203
203
  {'{':[0,5],'':0},
204
204
  'contextDef',
205
205
  ['mk',49,'context',,,'vocabularyRestriction'],
206
206
  [50,35],
207
- {'@':[50,775],'':51},
207
+ {'@':[50,773],'':51},
208
208
  {'{':[0,5],'':0},
209
209
  'annotationDef',
210
210
  ['mk',54,'annotation'],
211
211
  [55,35],
212
- {'@':[55,775],'':56},
212
+ {'@':[55,773],'':56},
213
213
  [0,347],
214
214
  'typeDef',
215
215
  ['mk',59,'type'],
216
216
  [60,35],
217
- {'@':[60,775],'':61},
217
+ {'@':[60,773],'':61},
218
218
  [0,347],
219
219
  'aspectDef',
220
220
  {
@@ -223,7 +223,7 @@ abstract:['ck',64,,'hide_'],
223
223
  },
224
224
  ['mk',65,'entity'],
225
225
  [66,35],
226
- {'@':[66,775],'':67},
226
+ {'@':[66,773],'':67},
227
227
  {
228
228
  '{':[71,158],
229
229
  ':':['c',68],
@@ -240,7 +240,7 @@ abstract:['ck',64,,'hide_'],
240
240
  'entityDef',
241
241
  ['mk',74,'entity'],
242
242
  [75,35],
243
- {'@':[75,775],'':76},
243
+ {'@':[75,773],'':76},
244
244
  {'(':[77,142],'':77},
245
245
  {
246
246
  '{':81,
@@ -259,14 +259,14 @@ as:['ck',82],
259
259
  projection:['g',83,,,'sloppy','afterBrace'],
260
260
  },
261
261
  [84,445],
262
- {group:[85,605],where:'group',having:'group','':85},
263
- {limit:[86,617],order:'limit','':86},
262
+ {group:[85,604],where:'group',having:'group','':85},
263
+ {limit:[86,616],order:'limit','':86},
264
264
  ['g',87,,,'normal','afterBrace'],
265
265
  {actions:[0,125],'':0},
266
266
  'viewDef',
267
267
  ['mk',90,'view'],
268
268
  [91,35],
269
- {'@':[91,775],'':92},
269
+ {'@':[91,773],'':92},
270
270
  {
271
271
  '(':[98,142],
272
272
  with:['ck',93,,'hide_'],
@@ -282,7 +282,7 @@ with:['ck',93,,'hide_'],
282
282
  'eventDef',
283
283
  ['mk',102,'event'],
284
284
  [103,35],
285
- {'@':[103,775],'':104},
285
+ {'@':[103,773],'':104},
286
286
  {
287
287
  '{':[0,158],
288
288
  ':':['c',105],
@@ -300,17 +300,17 @@ projection:[0,445,1],
300
300
  '{':110,
301
301
  },
302
302
  [0,158],
303
- {'@':[111,769],'':0},
303
+ {'@':[111,767],'':0},
304
304
  'actionMainDef',
305
305
  ['mk',114,'action'],
306
306
  [115,35],
307
- {'@':[115,775],'':116},
307
+ {'@':[115,773],'':116},
308
308
  [117,142],
309
309
  {returns:[0,154],'':0},
310
310
  'functionMainDef',
311
311
  ['mk',120,'function'],
312
312
  [121,35],
313
- {'@':[121,775],'':122},
313
+ {'@':[121,773],'':122},
314
314
  [123,142],
315
315
  [0,154],
316
316
  'actionsBlock',
@@ -324,17 +324,17 @@ projection:[0,445,1],
324
324
  },
325
325
  ['m',0,'}',,,'afterBrace'],
326
326
  'boundActionFunctionDef',
327
- {'@':[131,769],'':132},
327
+ {'@':[131,767],'':132},
328
328
  {
329
329
  action:['ck',133],
330
330
  function:['ck',137],
331
331
  },
332
332
  ['mi',134],
333
- {'@':[134,775],'':135},
333
+ {'@':[134,773],'':135},
334
334
  [136,142],
335
335
  {returns:[0,154],'':0},
336
336
  ['mi',138],
337
- {'@':[138,775],'':139},
337
+ {'@':[138,773],'':139},
338
338
  [140,142],
339
339
  [0,154],
340
340
  'paramsList',
@@ -346,9 +346,9 @@ function:['ck',137],
346
346
  },
347
347
  ['m',0,')'],
348
348
  'paramDef',
349
- {'@':[147,769],'':148},
349
+ {'@':[147,767],'':148},
350
350
  ['miA',149],
351
- {'@':[149,775],'':150},
351
+ {'@':[149,773],'':150},
352
352
  {
353
353
  '{':[151,158],
354
354
  ':':['c',152],
@@ -357,7 +357,7 @@ function:['ck',137],
357
357
  [0,357],
358
358
  'returnsSpec',
359
359
  ['mk',155,'returns',,'default','elementRestriction'],
360
- {'@':[155,769],'':156},
360
+ {'@':[155,767],'':156},
361
361
  [0,357],
362
362
  'elementsBlock',
363
363
  ['m',159,'{'],
@@ -369,13 +369,13 @@ Id:['g',159,,'afterBrace'],'@':'Id',key:'Id',
369
369
  },
370
370
  ['m',0,'}',,,'afterBrace'],
371
371
  'elementDef',
372
- {'@':[163,769],'':164},
372
+ {'@':[163,767],'':164},
373
373
  {virtual:['ck',165,1],'':165},
374
374
  {key:['ck',166],'':166},
375
375
  {masked:['ck',167,1,'hide_'],'':167},
376
376
  {element:['ck',168,1,'hide_'],'':168},
377
377
  ['mi',169,,,'elem','elementRestriction'],
378
- {'@':[169,775],'':170},
378
+ {'@':[169,773],'':170},
379
379
  {
380
380
  '{':[171,158],
381
381
  ':':['c',172],
@@ -384,10 +384,10 @@ Id:['g',159,,'afterBrace'],'@':'Id',key:'Id',
384
384
  {not:[173,438],null:'not','':173},
385
385
  [173,357],
386
386
  {'=':['c',174,,'elementRestriction','calc'],'':0},
387
- [175,639],
387
+ [175,638],
388
388
  {stored:['ck',176],'':176},
389
389
  ['g',177],
390
- {'@':[177,769,,'elementRestriction','anno'],'':0},
390
+ {'@':[177,767,,'elementRestriction','anno'],'':0},
391
391
  'enumSymbolsBlock',
392
392
  ['mk',180,'enum'],
393
393
  ['m',181,'{'],
@@ -398,19 +398,19 @@ Id:['g',159,,'afterBrace'],'@':'Id',key:'Id',
398
398
  },
399
399
  ['m',0,'}',,,'afterBrace'],
400
400
  'enumSymbolDef',
401
- {'@':[185,769],'':186},
401
+ {'@':[185,767],'':186},
402
402
  ['mi',187],
403
- {'@':[187,769],'':188},
403
+ {'@':[187,767],'':188},
404
404
  {'=':['c',189],'':0},
405
405
  {
406
406
  String:['c',191],
407
407
  Number:['c',191],
408
408
  '+':['c',190],'-':'+',
409
- Id:[191,766,,'hide_'],'#':'Id',QuotedLiteral:'Id',
409
+ Id:[191,764,,'hide_'],'#':'Id',QuotedLiteral:'Id',
410
410
  },
411
411
  ['m',191,'Number'],
412
412
  ['g',192],
413
- {'@':[192,769],'':0},
413
+ {'@':[192,767],'':0},
414
414
  'foreignKeysBlock',
415
415
  ['m',195,'{'],
416
416
  {Id:[196,199],'@':'Id','':197},
@@ -420,7 +420,7 @@ Id:[191,766,,'hide_'],'#':'Id',QuotedLiteral:'Id',
420
420
  },
421
421
  ['m',0,'}'],
422
422
  'foreignKeyDef',
423
- {'@':[199,769],'':200},
423
+ {'@':[199,767],'':200},
424
424
  [201,39],
425
425
  {as:['ck',202],'':0},
426
426
  ['mi',0],
@@ -438,7 +438,7 @@ composition:['ck',209],
438
438
  {one:['ck',212,1,'noRepeatedCardinality'],many:'one','':212},
439
439
  [213,39],
440
440
  ['mk',214,'on'],
441
- [0,637],
441
+ [0,636],
442
442
  'annotateArtifact',
443
443
  [217,35],
444
444
  {
@@ -449,10 +449,10 @@ with:['ck',223],
449
449
  [219,35],
450
450
  {with:['ck',220],'':220},
451
451
  ['g',221],
452
- {'@':[221,769],'':222},
452
+ {'@':[221,767],'':222},
453
453
  {'{':[0,321],'':0},
454
454
  ['g',224],
455
- {'@':[224,769],'':225},
455
+ {'@':[224,767],'':225},
456
456
  {'(':[226,308],'':226},
457
457
  {
458
458
  returns:[0,317],
@@ -470,7 +470,7 @@ with:['ck',240],
470
470
  [232,35],
471
471
  {with:['ck',233],'':233},
472
472
  ['g',234],
473
- {'@':[234,769],'':235},
473
+ {'@':[234,767],'':235},
474
474
  {
475
475
  '{':236,
476
476
  elements:['ck',236],
@@ -479,10 +479,10 @@ enum:[0,179],
479
479
  '':0
480
480
  },
481
481
  [0,331],
482
- {'@':[237,769],'':238},
482
+ {'@':[237,767],'':238},
483
483
  {'{':[239,331],'':0},
484
484
  {actions:[0,125],'':0},
485
- {'@':[240,769],'':241},
485
+ {'@':[240,767],'':241},
486
486
  {
487
487
  Id:[242,39],
488
488
  '{':246,
@@ -500,29 +500,29 @@ definitions:['ck',249,1],
500
500
  {actions:[0,125],'':0},
501
501
  [247,331],
502
502
  {actions:[0,125],'':0},
503
- [0,555],
503
+ [0,554],
504
504
  [0,5],
505
505
  'extendService',
506
506
  ['mk',252,'service'],
507
507
  [253,35],
508
508
  {with:['ck',254],'':254},
509
509
  ['g',255],
510
- {'@':[255,769],'':256},
510
+ {'@':[255,767],'':256},
511
511
  {'{':[0,5],'':0},
512
512
  'extendContext',
513
513
  ['mk',259,'context'],
514
514
  [260,35],
515
515
  {with:['ck',261],'':261},
516
516
  ['g',262],
517
- {'@':[262,769],'':263},
517
+ {'@':[262,767],'':263},
518
518
  {'{':[0,5],'':0},
519
519
  'extendType',
520
520
  ['mk',266,'type'],
521
521
  [267,35],
522
522
  {with:['ck',270],'':268},
523
- {'@':[268,769],'':269},
523
+ {'@':[268,767],'':269},
524
524
  {'{':[0,331],'':0},
525
- {'@':[270,769],'':271},
525
+ {'@':[270,767],'':271},
526
526
  {
527
527
  Id:[272,39],
528
528
  '{':275,
@@ -539,8 +539,8 @@ enum:[0,179,1],
539
539
  {aspect:['ck',278],entity:'aspect'},
540
540
  [279,35],
541
541
  {with:['ck',281],'':280},
542
- {'@':[280,769],'':285},
543
- {'@':[281,769],'':282},
542
+ {'@':[280,767],'':285},
543
+ {'@':[281,767],'':282},
544
544
  {
545
545
  Id:[283,39],
546
546
  actions:['g',285,1],
@@ -555,8 +555,8 @@ actions:['g',285,1],
555
555
  [290,35],
556
556
  {with:['ck',291],'':291},
557
557
  ['g',292],
558
- {'@':[292,769],'':293},
559
- {'{':[294,555],'':294},
558
+ {'@':[292,767],'':293},
559
+ {'{':[294,554],'':294},
560
560
  {actions:[0,125],'':0},
561
561
  'annotateActionsBlock',
562
562
  ['mk',297,'actions'],
@@ -569,11 +569,11 @@ Id:['g',298,,'afterBrace'],'@':'Id',
569
569
  },
570
570
  ['m',0,'}',,,'afterBrace'],
571
571
  'annotateBoundAction',
572
- {'@':[302,769],'':303},
572
+ {'@':[302,767],'':303},
573
573
  ['mi',304],
574
- {'@':[304,769],'':305},
574
+ {'@':[304,767],'':305},
575
575
  {'(':[306,308],'':306},
576
- {returns:[0,317,1],'':0},
576
+ {returns:[0,317],'':0},
577
577
  'annotateParamsBlock',
578
578
  ['m',309,'('],
579
579
  {Id:[310,313],'@':'Id','':311},
@@ -583,12 +583,12 @@ Id:['g',298,,'afterBrace'],'@':'Id',
583
583
  },
584
584
  ['m',0,')'],
585
585
  'annotateParam',
586
- {'@':[313,769],'':314},
586
+ {'@':[313,767],'':314},
587
587
  ['mi',315],
588
- {'@':[315,769],'':0},
588
+ {'@':[315,767],'':0},
589
589
  'annotateReturns',
590
590
  ['mk',318,'returns'],
591
- {'@':[318,769],'':319},
591
+ {'@':[318,767],'':319},
592
592
  {'{':[0,321],'':0},
593
593
  'annotateElementsBlock',
594
594
  ['m',322,'{'],
@@ -600,9 +600,9 @@ Id:['g',322,,'afterBrace'],'@':'Id',
600
600
  },
601
601
  ['m',0,'}',,,'afterBrace'],
602
602
  'annotateElement',
603
- {'@':[326,769],'':327},
603
+ {'@':[326,767],'':327},
604
604
  ['mi',328],
605
- {'@':[328,769],'':329},
605
+ {'@':[328,767],'':329},
606
606
  {'{':[0,321],'':0},
607
607
  'extendElementsBlock',
608
608
  ['m',332,'{'],
@@ -614,7 +614,7 @@ Id:['g',332,,'afterBrace'],'@':'Id',key:'Id',
614
614
  },
615
615
  ['m',0,'}',,,'afterBrace'],
616
616
  'elementDefOrExtend',
617
- {'@':[336,769],'':337},
617
+ {'@':[336,767],'':337},
618
618
  {
619
619
  Id:[0,163],'@':'Id',key:'Id',
620
620
  extend:['ck',338,1],
@@ -622,9 +622,9 @@ extend:['ck',338,1],
622
622
  {element:['ck',339,1],'':339},
623
623
  ['mi',340],
624
624
  {with:['ck',343],'':341},
625
- {'@':[341,769],'':342},
625
+ {'@':[341,767],'':342},
626
626
  {'{':[0,331],'':0},
627
- {'@':[343,769],'':344},
627
+ {'@':[343,767],'':344},
628
628
  {
629
629
  '{':345,
630
630
  elements:['ck',345],
@@ -670,9 +670,9 @@ many:['ck',378,1,,'calc','elementRestriction'],
670
670
  '{':[383,158,,,'calc','elementRestriction'],
671
671
  },
672
672
  ['g',359],
673
- {'@':[359,769],'':360},
673
+ {'@':[359,767],'':360},
674
674
  {not:[361,438,,'elementRestriction','notNull'],null:'not','':362},
675
- {'@':[361,769],'':362},
675
+ {'@':[361,767],'':362},
676
676
  {
677
677
  enum:[363,179,,,'anno','elementRestriction'],
678
678
  '@':[0,392],not:'@',null:'@',default:'@',
@@ -680,7 +680,7 @@ enum:[363,179,,,'anno','elementRestriction'],
680
680
  },
681
681
  {not:[364,438,,'elementRestriction','notNull'],null:'not','':364},
682
682
  {default:['ck',365,,'elementRestriction','default'],'':366},
683
- [366,639],
683
+ [366,638],
684
684
  {not:[0,438,,'elementRestriction','notNull'],null:'not','':0},
685
685
  [368,403],
686
686
  {'@':[0,392],not:'@',null:'@',default:'@','':0},
@@ -703,29 +703,29 @@ type:[379,395,1],
703
703
  },
704
704
  {not:[380,438,,'elementRestriction','notNull'],null:'not','':380},
705
705
  {enum:[382,179],'':381},
706
- {'@':[381,769],'':0},
706
+ {'@':[381,767],'':0},
707
707
  {not:[0,438,,'elementRestriction','notNull'],null:'not','':0},
708
708
  {not:[0,438],null:'not','':0},
709
709
  'typeAssocProperties',
710
710
  [386,39],
711
- {'@':[386,769],'':387},
711
+ {'@':[386,767],'':387},
712
712
  {
713
713
  on:['ck',388],
714
714
  '{':[390,194],
715
715
  '@':[0,392],not:'@',null:'@',default:'@',
716
716
  '':0
717
717
  },
718
- [389,637],
719
- {'@':[389,769],'':0},
718
+ [389,636],
719
+ {'@':[389,767],'':0},
720
720
  {'@':[0,392],not:'@',null:'@',default:'@','':0},
721
721
  'typeProperties',
722
722
  {
723
- '@':[392,769],
723
+ '@':[392,767],
724
724
  not:[392,438,,'elementRestriction','notNull'],null:'not',
725
725
  default:['ck',393,,'elementRestriction','default'],
726
726
  '':0
727
727
  },
728
- [392,639],
728
+ [392,638],
729
729
  'typeTypeOf',
730
730
  ['mk',396,'type'],
731
731
  ['mk',397,'of'],
@@ -816,9 +816,9 @@ not:['ck',439],
816
816
  'projectionSpec',
817
817
  ['mk',446,'projection'],
818
818
  ['mk',447,'on'],
819
- [448,511],
820
- {'{':[449,555],'':449},
821
- {excluding:[0,548],'':0},
819
+ [448,510],
820
+ {'{':[449,554],'':449},
821
+ {excluding:[0,547],'':0},
822
822
  'queryExpression',
823
823
  {
824
824
  '(':['c',452],
@@ -835,7 +835,7 @@ union:['ck',456,,'precLeft_',2],
835
835
  {distinct:['ck',457],'':457},
836
836
  {all:['ck',457],distinct:'all','':457},
837
837
  [454,451,,,,'orderByLimitRestriction'],
838
- {limit:[0,617,,'orderByLimitRestriction'],order:'limit','':0},
838
+ {limit:[0,616,,'orderByLimitRestriction'],order:'limit','':0},
839
839
  'selectQuery',
840
840
  ['mk',461,'select'],
841
841
  {
@@ -854,21 +854,21 @@ all:['ck',472],distinct:'all',
854
854
  ['m',468,'}'],
855
855
  ['mk',469,'into'],
856
856
  {all:['ck',470],distinct:'all','':470},
857
- {'{':[471,555],'':471},
858
- {excluding:[478,548],'':478},
857
+ {'{':[471,554],'':471},
858
+ {excluding:[478,547],'':478},
859
859
  ['g',473,,,'sqlStyle','inSelectItem'],
860
860
  {
861
861
  '*':['c',474],
862
- Id:[474,565],'#':'Id','(':'Id','+':'Id','-':'Id',':':'Id','?':'Id','@':'Id','{':'Id',Number:'Id',String:'Id',QuotedLiteral:'Id',
862
+ Id:[474,564],'#':'Id','(':'Id','+':'Id','-':'Id',':':'Id','?':'Id','@':'Id','{':'Id',Number:'Id',String:'Id',QuotedLiteral:'Id',
863
863
  },
864
864
  {',':['c',475],'':476},
865
865
  {
866
866
  '*':['c',474],
867
- Id:[474,565],'#':'Id','(':'Id','+':'Id','-':'Id',':':'Id','?':'Id','@':'Id','{':'Id',Number:'Id',String:'Id',QuotedLiteral:'Id',
867
+ Id:[474,564],'#':'Id','(':'Id','+':'Id','-':'Id',':':'Id','?':'Id','@':'Id','{':'Id',Number:'Id',String:'Id',QuotedLiteral:'Id',
868
868
  },
869
869
  ['mk',477,'from'],
870
870
  [478,480],
871
- {group:[0,605],where:'group',having:'group','':0},
871
+ {group:[0,604],where:'group',having:'group','':0},
872
872
  'querySource',
873
873
  [481,485],
874
874
  {',':482,'':0},
@@ -876,469 +876,471 @@ Id:[474,565],'#':'Id','(':'Id','+':'Id','-':'Id',':':'Id','?':'Id','@':'Id','{':
876
876
  [482,485],
877
877
  'tableExpression',
878
878
  {
879
- '(':[486,498],
880
- Id:[487,511],
879
+ '(':[486,497],
880
+ Id:[486,510],
881
881
  },
882
- ['g',487],
883
882
  {
884
- cross:['ck',488],
885
- inner:['ck',491],
886
- full:['ck',490],left:'full',right:'full',
887
- join:['ck',493],
883
+ cross:['ck',487],
884
+ inner:['ck',490],
885
+ full:['ck',489],left:'full',right:'full',
886
+ join:['ck',492],
888
887
  '':0
889
888
  },
890
- ['mk',489,'join'],
889
+ ['mk',488,'join'],
891
890
  {
892
- '(':[487,498],
893
- Id:[487,511],
891
+ '(':[486,497],
892
+ Id:[486,510],
894
893
  },
895
- {outer:['ck',491],'':491},
896
- {one:[492,505],many:'one',exact:'one','':492},
897
- ['mk',493,'join'],
898
- ['g',494],
899
- [495,485],
900
- ['mk',496,'on'],
901
- [487,637],
894
+ {outer:['ck',490],'':490},
895
+ {one:[491,504],many:'one',exact:'one','':491},
896
+ ['mk',492,'join'],
897
+ ['g',493],
898
+ [494,485],
899
+ ['mk',495,'on'],
900
+ [486,636],
902
901
  'tableOrQueryParens',
903
- ['m',499,'(',,,'queryOnLeft'],
902
+ ['m',498,'(',,,'queryOnLeft'],
904
903
  {
905
- '(':[500,498],
906
- Id:[501,485,,,'table','queryOnLeft'],
907
- select:[501,451],
904
+ '(':[499,497],
905
+ Id:[500,485,,,'table','queryOnLeft'],
906
+ select:[500,451],
908
907
  },
909
908
  {
910
- full:[501,486,,,'table','queryOnLeft'],join:'full',left:'full',cross:'full',inner:'full',right:'full',
911
- limit:[501,454,,'queryOnLeft'],minus:'limit',order:'limit',union:'limit',except:'limit',intersect:'limit',
912
- '':501
909
+ full:[500,486,,,'table','queryOnLeft'],join:'full',left:'full',cross:'full',inner:'full',right:'full',
910
+ limit:[500,454,,'queryOnLeft'],minus:'limit',order:'limit',union:'limit',except:'limit',intersect:'limit',
911
+ '':500
913
912
  },
914
- ['m',502,')'],
913
+ ['m',501,')'],
915
914
  {
916
- as:['ck',503,,'queryOnLeft','table'],
915
+ as:['ck',502,,'queryOnLeft','table'],
917
916
  Id:['ci',0,,'queryOnLeftSloppyAlias'],
918
917
  '':0
919
918
  },
920
919
  ['mi',0],
921
920
  'joinCardinality',
922
921
  {
923
- one:506,
924
- exact:['ck',506],
925
- many:['ck',507],
922
+ one:505,
923
+ exact:['ck',505],
924
+ many:['ck',506],
926
925
  },
927
- ['mk',507,'one'],
928
- ['mk',508,'to'],
926
+ ['mk',506,'one'],
927
+ ['mk',507,'to'],
929
928
  {
930
- one:509,
931
- exact:['ck',509],
929
+ one:508,
930
+ exact:['ck',508],
932
931
  many:['ck',0],
933
932
  },
934
933
  ['mk',0,'one'],
935
934
  'fromRefWithOptAlias',
936
- [512,518],
937
- {':':['c',513],'':514},
938
- [514,518],
935
+ [511,517],
936
+ {':':['c',512],'':513},
937
+ [513,517],
939
938
  {
940
- as:['ck',515],
939
+ as:['ck',514],
941
940
  Id:['ci',0,,'isNoKeywordInRuleFollow'],
942
- '':516
941
+ '':515
943
942
  },
944
943
  ['mi',0],
945
944
  ['g',0],
946
945
  'fromPath',
947
- ['mi',519],
948
- {'(':[520,524],'[':'(','':520},
949
- {'.':['c',521,,'notAfterEntityArgOrFilter'],'':0},
950
- ['miA',522],
951
- {'(':[520,524],'[':'(','':520},
946
+ ['mi',518],
947
+ {'(':[519,523],'[':'(','':519},
948
+ {'.':['c',520,,'notAfterEntityArgOrFilter'],'':0},
949
+ ['miA',521],
950
+ {'(':[519,523],'[':'(','':519},
952
951
  'fromArgumentsAndFilter',
953
- {'(':['c',525],'':529},
954
- {Id:526},
955
- {Id:[527,531],'':528},
952
+ {'(':['c',524],'':528},
953
+ {Id:525},
954
+ {Id:[526,530],'':527},
956
955
  {
957
- ',':['c',526],
958
- ')':528,
956
+ ',':['c',525],
957
+ ')':527,
959
958
  },
960
- ['m',529,')'],
961
- {'[':[0,535],'':0},
959
+ ['m',528,')'],
960
+ {'[':[0,534],'':0},
962
961
  'fromNamedArgument',
963
- ['mi',532],
964
- ['m',533,':'],
965
- [0,639],
962
+ ['mi',531],
963
+ ['m',532,':'],
964
+ [0,638],
966
965
  'cardinalityAndFilter',
967
- ['m',536,'['],
968
- {Number:['c',537,,'beforeColon'],'':538},
969
- ['m',538,':'],
966
+ ['m',535,'['],
967
+ {Number:['c',536,,'beforeColon'],'':537},
968
+ ['m',537,':'],
970
969
  {
971
- group:['g',540,1],limit:'group',order:'group',having:'group',
972
- where:['ck',539],
970
+ group:['g',539,1],limit:'group',order:'group',having:'group',
971
+ where:['ck',538],
973
972
  ']':['c',0],
974
- '':539
973
+ '':538
975
974
  },
976
- [540,637],
977
- {group:['g',541,,'hide_'],'':542},
978
- [542,611],
979
- {having:['ck',543,,'hide_'],'':544},
980
- [544,637],
981
- {Id:['g',545,,'hide_'],'':546},
982
- [546,617],
975
+ [539,636],
976
+ {group:['g',540,,'hide_'],'':541},
977
+ [541,610],
978
+ {having:['ck',542,,'hide_'],'':543},
979
+ [543,636],
980
+ {Id:['g',544,,'hide_'],'':545},
981
+ [545,616],
983
982
  ['m',0,']'],
984
983
  'excludingClause',
985
- ['mk',549,'excluding'],
986
- ['m',550,'{'],
987
- {Id:551},
988
- {Id:['ciA',552],'':553},
984
+ ['mk',548,'excluding'],
985
+ ['m',549,'{'],
986
+ {Id:550},
987
+ {Id:['ciA',551],'':552},
989
988
  {
990
- ',':['c',551],
991
- '}':553,
989
+ ',':['c',550],
990
+ '}':552,
992
991
  },
993
992
  ['m',0,'}',,,'afterBrace'],
994
993
  'selectItemsList',
995
- ['m',556,'{',,'top','inSelectItem'],
994
+ ['m',555,'{',,'top','inSelectItem'],
996
995
  {
997
- '*':['c',557],
998
- Id:[557,565],'#':'Id','(':'Id','+':'Id','-':'Id',':':'Id','?':'Id','@':'Id','{':'Id',Number:'Id',String:'Id',QuotedLiteral:'Id',
999
- '':558
996
+ '*':['c',556],
997
+ Id:[556,564],'#':'Id','(':'Id','+':'Id','-':'Id',':':'Id','?':'Id','@':'Id','{':'Id',Number:'Id',String:'Id',QuotedLiteral:'Id',
998
+ '':557
1000
999
  },
1001
1000
  {
1002
- ',':['c',556],
1003
- '}':558,
1001
+ ',':['c',555],
1002
+ '}':557,
1004
1003
  },
1005
1004
  ['m',0,'}',,,'afterBrace'],
1006
1005
  'nestedSelectItemsList',
1007
- ['m',561,'{',,,'inSelectItem'],
1006
+ ['m',560,'{',,,'inSelectItem'],
1008
1007
  {
1009
- '*':['c',562],
1010
- Id:[562,565],'#':'Id','(':'Id','+':'Id','-':'Id',':':'Id','?':'Id','@':'Id','{':'Id',Number:'Id',String:'Id',QuotedLiteral:'Id',
1011
- '':563
1008
+ '*':['c',561],
1009
+ Id:[561,564],'#':'Id','(':'Id','+':'Id','-':'Id',':':'Id','?':'Id','@':'Id','{':'Id',Number:'Id',String:'Id',QuotedLiteral:'Id',
1010
+ '':562
1012
1011
  },
1013
1012
  {
1014
- ',':['c',561],
1015
- '}':563,
1013
+ ',':['c',560],
1014
+ '}':562,
1016
1015
  },
1017
1016
  ['m',0,'}',,,'afterBrace'],
1018
1017
  'selectItemDef',
1019
- {'@':[565,772],'':566},
1020
- {virtual:['ck',567,1,'modifierRestriction'],'':567},
1021
- ['g',568,,,'key','columnExpr'],
1022
- {key:['ck',569,,'modifierRestriction'],'':569},
1018
+ {'@':[564,770],'':565},
1019
+ {virtual:['ck',566,1,'modifierRestriction'],'':566},
1020
+ ['g',567,,,'key','columnExpr'],
1021
+ {key:['ck',568,,'modifierRestriction'],'':568},
1023
1022
  {
1024
- '#':[570,639,1],'(':'#','+':'#','-':'#',':':'#','?':'#',new:'#',not:'#',case:'#',cast:'#',null:'#',true:'#',false:'#',Number:'#',String:'#',exists:'#',QuotedLiteral:'#',
1025
- Id:[572,668],
1026
- '{':[583,560],
1023
+ '#':[569,638,1],'(':'#','+':'#','-':'#',':':'#','?':'#',new:'#',not:'#',case:'#',cast:'#',null:'#',true:'#',false:'#',Number:'#',String:'#',exists:'#',QuotedLiteral:'#',
1024
+ Id:[571,666],
1025
+ '{':[582,559],
1027
1026
  },
1028
1027
  {
1029
- as:['ck',571],
1030
- Id:['ci',580,,'hide_'],
1031
- '':580
1028
+ as:['ck',570],
1029
+ Id:['ci',579,,'hide_'],
1030
+ '':579
1032
1031
  },
1033
- ['mi',580],
1032
+ ['mi',579],
1034
1033
  {
1035
- over:['ck',573],
1036
- '*':[575,640],'+':'*','-':'*','/':'*','<':'*','=':'*','>':'*','?':'*','!=':'*','<=':'*','<>':'*','==':'*','>=':'*',in:'*',is:'*',or:'*','||':'*',and:'*',not:'*',like:'*',between:'*',
1037
- as:['ck',577],
1038
- Id:['ci',580,,'hide_',,'nestedExpand'],
1039
- '.':['c',578],
1040
- '':580
1034
+ over:['ck',572],
1035
+ '*':[574,649],'+':'*','-':'*','/':'*','<':'*','=':'*','>':'*','?':'*','!=':'*','<=':'*','<>':'*','==':'*','>=':'*',in:'*',is:'*',or:'*','||':'*',and:'*',not:'*',like:'*',between:'*',
1036
+ as:['ck',576],
1037
+ Id:['ci',579,,'hide_',,'nestedExpand'],
1038
+ '.':['c',577],
1039
+ '':579
1041
1040
  },
1042
- [574,730],
1043
- {'*':[575,640],'+':'*','-':'*','/':'*','<':'*','=':'*','>':'*','?':'*','!=':'*','<=':'*','<>':'*','==':'*','>=':'*',in:'*',is:'*',or:'*','||':'*',and:'*',not:'*',like:'*',between:'*','':575},
1041
+ [573,728],
1042
+ {'*':[574,649],'+':'*','-':'*','/':'*','<':'*','=':'*','>':'*','?':'*','!=':'*','<=':'*','<>':'*','==':'*','>=':'*',in:'*',is:'*',or:'*','||':'*',and:'*',not:'*',like:'*',between:'*','':574},
1044
1043
  {
1045
- as:['ck',576],
1046
- Id:['ci',580,,'hide_'],
1047
- '':580
1044
+ as:['ck',575],
1045
+ Id:['ci',579,,'hide_'],
1046
+ '':579
1048
1047
  },
1049
- ['mi',580],
1050
- ['mi',580,,,,'nestedExpand'],
1048
+ ['mi',579],
1049
+ ['mi',579,,,,'nestedExpand'],
1051
1050
  {
1052
- '{':[579,560],
1051
+ '{':[578,559],
1053
1052
  '*':['c',0],
1054
1053
  },
1055
- {excluding:[0,548],'':0},
1056
- {'{':['g',581,,'nestedExpand'],'':586},
1057
- [582,560],
1058
- {excluding:[586,548],'':586},
1059
- {excluding:[584,548],'':584},
1060
- ['mk',585,'as'],
1061
- ['mi',586],
1062
- ['g',587,,,,'columnExpr'],
1063
- {'@':[587,775],'':588},
1064
- {':':['c',589],'':0},
1054
+ {excluding:[0,547],'':0},
1055
+ {'{':['g',580,,'nestedExpand'],'':585},
1056
+ [581,559],
1057
+ {excluding:[585,547],'':585},
1058
+ {excluding:[583,547],'':583},
1059
+ ['mk',584,'as'],
1060
+ ['mi',585],
1061
+ ['g',586,,,,'columnExpr'],
1062
+ {'@':[586,773],'':587},
1063
+ {':':['c',588],'':0},
1065
1064
  {
1066
- Id:[602,357],'{':'Id',
1067
- redirected:['ck',590,1],
1068
- association:['ck',594,1,'columnExpr'],
1069
- composition:['ck',596,1,'columnExpr'],
1065
+ Id:[601,357],'{':'Id',
1066
+ redirected:['ck',589,1],
1067
+ association:['ck',593,1,'columnExpr'],
1068
+ composition:['ck',595,1,'columnExpr'],
1070
1069
  },
1071
- ['mk',591,'to'],
1072
- [592,39],
1070
+ ['mk',590,'to'],
1071
+ [591,39],
1073
1072
  {
1074
- on:['ck',593],
1075
- '{':[602,194],
1076
- '':602
1073
+ on:['ck',592],
1074
+ '{':[601,194],
1075
+ '':601
1077
1076
  },
1078
- [602,637],
1079
- {'[':[595,426],'':595},
1080
- ['mk',598,'to'],
1081
- {'[':[597,426],'':597},
1082
- ['mk',598,'of'],
1083
- {one:['ck',599,1,'noRepeatedCardinality'],many:'one','':599},
1084
- [600,39],
1085
- ['mk',601,'on'],
1086
- [602,637],
1087
- ['g',603],
1088
- {'@':[603,769],'':0},
1077
+ [601,636],
1078
+ {'[':[594,426],'':594},
1079
+ ['mk',597,'to'],
1080
+ {'[':[596,426],'':596},
1081
+ ['mk',597,'of'],
1082
+ {one:['ck',598,1,'noRepeatedCardinality'],many:'one','':598},
1083
+ [599,39],
1084
+ ['mk',600,'on'],
1085
+ [601,636],
1086
+ ['g',602],
1087
+ {'@':[602,767],'':0},
1089
1088
  'whereGroupByHaving',
1090
- {where:['ck',606],'':607},
1091
- [607,637],
1092
- {group:[608,611],'':608},
1093
- {having:['ck',609],'':0},
1094
- [0,637],
1089
+ {where:['ck',605],'':606},
1090
+ [606,636],
1091
+ {group:[607,610],'':607},
1092
+ {having:['ck',608],'':0},
1093
+ [0,636],
1095
1094
  'groupByClause',
1096
- ['mk',612,'group'],
1097
- ['mk',613,'by'],
1098
- [614,639],
1099
- {',':['c',615],'':0},
1100
- [614,639],
1095
+ ['mk',611,'group'],
1096
+ ['mk',612,'by'],
1097
+ [613,638],
1098
+ {',':['c',614],'':0},
1099
+ [613,638],
1101
1100
  'orderByLimitOffset',
1102
- {order:[618,623],'':618},
1103
- {limit:['ck',619],'':0},
1104
- [620,639],
1105
- {offset:['ck',621],'':0},
1106
- [0,639],
1101
+ {order:[617,622],'':617},
1102
+ {limit:['ck',618],'':0},
1103
+ [619,638],
1104
+ {offset:['ck',620],'':0},
1105
+ [0,638],
1107
1106
  'orderByClause',
1108
- ['mk',624,'order'],
1109
- ['mk',625,'by'],
1110
- [626,629],
1111
- {',':['c',627],'':0},
1112
- [626,629],
1107
+ ['mk',623,'order'],
1108
+ ['mk',624,'by'],
1109
+ [625,628],
1110
+ {',':['c',626],'':0},
1111
+ [625,628],
1113
1112
  'orderByExpression',
1114
- [630,639],
1115
- {asc:['ck',631],desc:'asc','':631},
1116
- {nulls:['ck',632],'':0},
1113
+ [629,638],
1114
+ {asc:['ck',630],desc:'asc','':630},
1115
+ {nulls:['ck',631],'':0},
1117
1116
  {last:['ck',0],first:'last'},
1118
1117
  'conditionEOF',
1119
- [635,639],
1118
+ [634,638],
1120
1119
  ['m',0,'EOF'],
1121
1120
  'condition',
1122
- [0,639],
1121
+ [0,638],
1123
1122
  'expression',
1124
1123
  {
1125
- '(':[640,674],
1126
- '#':[651,766],null:'#',true:'#',false:'#',Number:'#',String:'#',QuotedLiteral:'#',
1127
- ':':['c',641],
1128
- '?':['c',651,,'hide_'],
1129
- Id:[643,668],
1130
- new:['ck',646,1],
1131
- exists:['ck',647],
1132
- case:[651,686],
1133
- cast:[651,697],
1134
- '+':['c',650,,'precRight_',30],'-':'+',
1135
- not:['ck',650,,'precRight_',8],
1124
+ '(':[649,672],
1125
+ '#':[649,764],null:'#',true:'#',false:'#',Number:'#',String:'#',QuotedLiteral:'#',
1126
+ ':':['c',639],
1127
+ '?':['c',649,,'hide_'],
1128
+ Id:[641,666],
1129
+ new:['ck',644,1],
1130
+ exists:['ck',645],
1131
+ case:[649,684],
1132
+ cast:[649,695],
1133
+ '+':['c',648,,'precRight_',30],'-':'+',
1134
+ not:['ck',648,,'precRight_',8],
1136
1135
  },
1137
- ['g',651],
1138
1136
  {
1139
- Id:['ciA',642],
1140
- Number:['c',651,,'hide_'],
1137
+ Id:['ciA',640],
1138
+ Number:['c',649,,'hide_'],
1141
1139
  },
1142
- {'.':[651,670],'':651},
1143
- {over:['ck',644],'':645},
1144
- [645,730],
1145
- ['g',651],
1146
- [651,668],
1140
+ {'.':[649,668],'':649},
1141
+ {over:['ck',642],'':643},
1142
+ [643,728],
1143
+ ['g',649],
1144
+ [649,666],
1147
1145
  {
1148
- '(':['c',648],
1149
- Id:[651,668],
1150
- '?':['c',651,,'hide_'],
1146
+ '(':['c',646],
1147
+ Id:[649,666],
1148
+ '?':['c',649,,'hide_'],
1151
1149
  },
1152
- [649,451],
1153
- ['m',651,')'],
1154
- [651,639],
1150
+ [647,451],
1151
+ ['m',649,')'],
1152
+ [649,638],
1155
1153
  {
1156
- '*':['c',655,,'precLeft_',24],'/':'*',
1157
- '+':['c',655,,'precLeft_',22],'-':'+',
1158
- '||':['c',655,,'precLeft_',20],
1159
- and:['ck',655,,'precLeft_',4],
1160
- or:['ck',655,,'precLeft_',2],
1161
- '?':['c',652,,'precRight_',0],
1162
- '<':['c',654,,'precNone_',10],'=':'<','>':'<','!=':'<','<=':'<','<>':'<','>=':'<',
1163
- '==':['c',655,,'precNone_',10],
1164
- is:['ck',656,,'precNone_',10],
1165
- not:['ck',658,,'isNegatedRelation',10],
1166
- in:['g',658,,'precNone_',10],like:'in',between:'in',
1154
+ '*':['c',653,,'precLeft_',24],'/':'*',
1155
+ '+':['c',653,,'precLeft_',22],'-':'+',
1156
+ '||':['c',653,,'precLeft_',20],
1157
+ and:['ck',653,,'precLeft_',4],
1158
+ or:['ck',653,,'precLeft_',2],
1159
+ '?':['c',650,,'precRight_',0],
1160
+ '<':['c',652,,'precNone_',10],'=':'<','>':'<','!=':'<','<=':'<','<>':'<','>=':'<',
1161
+ '==':['c',653,,'precNone_',10],
1162
+ is:['ck',654,,'precNone_',10],
1163
+ not:['ck',656,,'isNegatedRelation',10],
1164
+ in:['g',656,,'precNone_',10],like:'in',between:'in',
1167
1165
  '':0
1168
1166
  },
1169
- [653,639],
1170
- ['m',655,':'],
1171
- {all:['ck',655],any:'all',some:'all','':655},
1172
- [666,639],
1173
- {not:['ck',657],'':657},
1174
- ['mk',666,'null'],
1167
+ [651,638],
1168
+ ['m',653,':'],
1169
+ {all:['ck',653],any:'all',some:'all','':653},
1170
+ [664,638],
1171
+ {not:['ck',655],'':655},
1172
+ ['mk',664,'null'],
1175
1173
  {
1176
- between:['ck',659],
1177
- in:['ck',662],
1178
- like:['ck',663],
1174
+ between:['ck',657],
1175
+ in:['ck',660],
1176
+ like:['ck',661],
1179
1177
  },
1180
- [660,639],
1181
- ['mk',661,'and'],
1182
- [666,639],
1183
- [666,639],
1184
- [664,639],
1185
- {escape:['ck',665],'':666},
1186
- [666,639],
1187
- ['g',651],
1178
+ [658,638],
1179
+ ['mk',659,'and'],
1180
+ [664,638],
1181
+ [664,638],
1182
+ [662,638],
1183
+ {escape:['ck',663],'':664},
1184
+ [664,638],
1185
+ ['g',649],
1188
1186
  'valuePath',
1189
- ['mi',669],
1190
- {'(':[670,704],'[':'(','':670},
1191
- {'.':['c',671,,'isDotForPath'],'':0},
1192
- ['miA',672],
1193
- {'(':[670,704],'[':'(','':670},
1187
+ ['mi',667],
1188
+ {'(':[668,702],'[':'(','':668},
1189
+ {'.':['c',669,,'isDotForPath'],'':0},
1190
+ ['miA',670],
1191
+ {'(':[668,702],'[':'(','':668},
1194
1192
  'expressionOrQueryParens',
1195
- ['m',675,'(',,,'queryOnLeft'],
1193
+ ['m',673,'(',,,'queryOnLeft'],
1196
1194
  {
1197
- '(':[676,674],
1198
- Id:[678,639,,,'expr','queryOnLeft'],'#':'Id','+':'Id','-':'Id',':':'Id','?':'Id',not:'Id',case:'Id',cast:'Id',null:'Id',true:'Id',false:'Id',Number:'Id',String:'Id',exists:'Id',QuotedLiteral:'Id',
1199
- select:[679,451],
1195
+ '(':[674,672],
1196
+ Id:[676,638,,,'expr','queryOnLeft'],'#':'Id','+':'Id','-':'Id',':':'Id','?':'Id',not:'Id',case:'Id',cast:'Id',null:'Id',true:'Id',false:'Id',Number:'Id',String:'Id',exists:'Id',QuotedLiteral:'Id',
1197
+ select:[677,451],
1200
1198
  },
1201
1199
  {
1202
- '*':[677,640,,,'expr','queryOnLeft'],'+':'*','-':'*','/':'*','<':'*','=':'*','>':'*','?':'*','!=':'*','<=':'*','<>':'*','==':'*','>=':'*',in:'*',is:'*',or:'*','||':'*',and:'*',not:'*',like:'*',between:'*',
1203
- ',':[679,681,,,'expr','queryOnLeft'],
1204
- limit:[679,454,,'queryOnLeft'],minus:'limit',order:'limit',union:'limit',except:'limit',intersect:'limit',
1205
- '':679
1200
+ '*':[675,649,,,'expr','queryOnLeft'],'+':'*','-':'*','/':'*','<':'*','=':'*','>':'*','?':'*','!=':'*','<=':'*','<>':'*','==':'*','>=':'*',in:'*',is:'*',or:'*','||':'*',and:'*',not:'*',like:'*',between:'*',
1201
+ ',':[677,679,,,'expr','queryOnLeft'],
1202
+ limit:[677,454,,'queryOnLeft'],minus:'limit',order:'limit',union:'limit',except:'limit',intersect:'limit',
1203
+ '':677
1206
1204
  },
1207
- {',':[679,681],'':679},
1208
- {',':[679,681],'':679},
1205
+ {',':[677,679],'':677},
1206
+ {',':[677,679],'':677},
1209
1207
  ['m',0,')'],
1210
1208
  'continueExpressionslist',
1211
- ['m',682,','],
1212
- {Id:683,'#':683,'(':683,'+':683,'-':683,':':683,'?':683,not:683,case:683,cast:683,null:683,true:683,false:683,Number:683,String:683,exists:683,QuotedLiteral:683},
1213
- {Id:[684,639],'#':'Id','(':'Id','+':'Id','-':'Id',':':'Id','?':'Id',Number:'Id',String:'Id',QuotedLiteral:'Id','':0},
1214
- {',':['c',683],'':0},
1209
+ ['m',680,','],
1210
+ {Id:681,'#':681,'(':681,'+':681,'-':681,':':681,'?':681,not:681,case:681,cast:681,null:681,true:681,false:681,Number:681,String:681,exists:681,QuotedLiteral:681},
1211
+ {Id:[682,638],'#':'Id','(':'Id','+':'Id','-':'Id',':':'Id','?':'Id',Number:'Id',String:'Id',QuotedLiteral:'Id','':0},
1212
+ {',':['c',681],'':0},
1215
1213
  'caseExpression',
1216
- ['mk',687,'case'],
1217
- {Id:[688,639],'#':'Id','(':'Id','+':'Id','-':'Id',':':'Id','?':'Id',not:'Id',case:'Id',cast:'Id',null:'Id',true:'Id',false:'Id',Number:'Id',String:'Id',exists:'Id',QuotedLiteral:'Id','':688},
1218
- {when:689},
1219
- {when:['ck',690],'':693},
1220
- [691,639],
1221
- ['mk',692,'then'],
1222
- [689,639],
1223
- {else:['ck',694],'':695},
1224
- [695,639],
1214
+ ['mk',685,'case'],
1215
+ {
1216
+ Id:[686,638],'#':'Id','(':'Id','+':'Id','-':'Id',':':'Id','?':'Id',not:'Id',case:'Id',cast:'Id',null:'Id',true:'Id',false:'Id',Number:'Id',String:'Id',exists:'Id',QuotedLiteral:'Id',
1217
+ when:['g',686,1],
1218
+ '':686
1219
+ },
1220
+ {when:687},
1221
+ {when:['ck',688],'':691},
1222
+ [689,638],
1223
+ ['mk',690,'then'],
1224
+ [687,638],
1225
+ {else:['ck',692],'':693},
1226
+ [693,638],
1225
1227
  ['mk',0,'end'],
1226
1228
  'castFunction',
1227
- ['mk',698,'cast'],
1228
- ['m',699,'('],
1229
- [700,639],
1230
- ['mk',701,'as'],
1231
- [702,403],
1229
+ ['mk',696,'cast'],
1230
+ ['m',697,'('],
1231
+ [698,638],
1232
+ ['mk',699,'as'],
1233
+ [700,403],
1232
1234
  ['m',0,')'],
1233
1235
  'argumentsAndFilter',
1234
- {'(':['c',705,,,,'prepareSpecialFunction'],'':723},
1236
+ {'(':['c',703,,,,'prepareSpecialFunction'],'':721},
1235
1237
  {
1236
- ')':722,
1237
- Id:['ciA',706,,'isNamedArg'],
1238
- '':715
1238
+ ')':720,
1239
+ Id:['ciA',704,,'isNamedArg'],
1240
+ '':713
1239
1241
  },
1240
1242
  {
1241
- ':':['c',707],
1242
- '=>':['c',711],
1243
+ ':':['c',705],
1244
+ '=>':['c',709],
1243
1245
  },
1244
- [708,639],
1246
+ [706,638],
1245
1247
  {
1246
- ',':['c',709],
1247
- ')':722,
1248
+ ',':['c',707],
1249
+ ')':720,
1248
1250
  },
1249
1251
  {
1250
- Id:['ciA',710],
1251
- ')':722,
1252
+ Id:['ciA',708],
1253
+ ')':720,
1252
1254
  },
1253
- ['m',707,':'],
1254
- [712,639],
1255
+ ['m',705,':'],
1256
+ [710,638],
1255
1257
  {
1256
- ',':['c',713],
1257
- ')':722,
1258
+ ',':['c',711],
1259
+ ')':720,
1258
1260
  },
1259
1261
  {
1260
- Id:['ciA',714],
1261
- ')':722,
1262
+ Id:['ciA',712],
1263
+ ')':720,
1262
1264
  },
1263
- ['m',711,'=>'],
1264
- [716,725],
1265
- {',':['c',717,,,,'nextFunctionArgument'],'':719},
1266
- {')':['c',718],'':715},
1267
- {'[':[0,535],'':0},
1268
- {order:['ck',720],'':722},
1269
- ['mk',721,'by'],
1270
- [722,745],
1271
- ['m',723,')'],
1272
- {'[':[0,535],'':0},
1265
+ ['m',709,'=>'],
1266
+ [714,723],
1267
+ {',':['c',715,,,,'nextFunctionArgument'],'':717},
1268
+ {')':['c',716],'':713},
1269
+ {'[':[0,534],'':0},
1270
+ {order:['ck',718],'':720},
1271
+ ['mk',719,'by'],
1272
+ [720,743],
1273
+ ['m',721,')'],
1274
+ {'[':[0,534],'':0},
1273
1275
  'funcExpression',
1274
1276
  {
1275
1277
  ' lookahead':'lGenericIntroOrExpr',
1276
- Id:[727,639],'#':'Id','(':'Id','+':'Id','-':'Id',':':'Id','?':'Id',Number:'Id',String:'Id',QuotedLiteral:'Id',
1277
- GenericExpr:['ckA',727],
1278
- GenericIntro:['ckA',726],
1278
+ Id:[725,638],'#':'Id','(':'Id','+':'Id','-':'Id',':':'Id','?':'Id',Number:'Id',String:'Id',QuotedLiteral:'Id',
1279
+ GenericExpr:['ckA',725],
1280
+ GenericIntro:['ckA',724],
1279
1281
  },
1280
- [727,639],
1282
+ [725,638],
1281
1283
  {
1282
1284
  ' lookahead':'lGenericSeparator',
1283
- GenericSeparator:['ckA',728],
1285
+ GenericSeparator:['ckA',726],
1284
1286
  '':0
1285
1287
  },
1286
1288
  {
1287
1289
  ' lookahead':'lGenericExpr',
1288
- Id:[727,639],'#':'Id','(':'Id','+':'Id','-':'Id',':':'Id','?':'Id',Number:'Id',String:'Id',QuotedLiteral:'Id',
1289
- GenericExpr:['ckA',727],
1290
+ Id:[725,638],'#':'Id','(':'Id','+':'Id','-':'Id',':':'Id','?':'Id',Number:'Id',String:'Id',QuotedLiteral:'Id',
1291
+ GenericExpr:['ckA',725],
1290
1292
  },
1291
1293
  'overClause',
1292
- ['m',731,'('],
1293
- {partition:['ck',732],'':734},
1294
- ['mk',733,'by'],
1295
- [734,741],
1296
- {order:['ck',735],'':737},
1297
- ['mk',736,'by'],
1298
- [737,745],
1299
- {rows:['ck',738],'':739},
1300
- [739,754],
1294
+ ['m',729,'('],
1295
+ {partition:['ck',730],'':732},
1296
+ ['mk',731,'by'],
1297
+ [732,739],
1298
+ {order:['ck',733],'':735},
1299
+ ['mk',734,'by'],
1300
+ [735,743],
1301
+ {rows:['ck',736],'':737},
1302
+ [737,752],
1301
1303
  ['m',0,')'],
1302
1304
  'expressionsAsXpr',
1303
- [742,639],
1304
- {',':['c',743],'':0},
1305
- [742,639],
1305
+ [740,638],
1306
+ {',':['c',741],'':0},
1307
+ [740,638],
1306
1308
  'orderByClauseAsXpr',
1307
- [746,749],
1308
- {',':['c',747],'':0},
1309
- [746,749],
1309
+ [744,747],
1310
+ {',':['c',745],'':0},
1311
+ [744,747],
1310
1312
  'orderBySpecAsXpr',
1311
- [750,639],
1312
- {asc:['ck',751],desc:'asc','':751},
1313
- {nulls:['ck',752],'':0},
1313
+ [748,638],
1314
+ {asc:['ck',749],desc:'asc','':749},
1315
+ {nulls:['ck',750],'':0},
1314
1316
  {last:['ck',0],first:'last'},
1315
1317
  'windowFrameClause',
1316
1318
  {
1317
- unbounded:['ck',755],
1318
- Number:['c',755],
1319
- current:['ck',756],
1320
- between:['ck',757],
1319
+ unbounded:['ck',753],
1320
+ Number:['c',753],
1321
+ current:['ck',754],
1322
+ between:['ck',755],
1321
1323
  },
1322
1324
  ['mk',0,'preceding'],
1323
1325
  ['mk',0,'row'],
1324
- [758,761],
1325
- ['mk',759,'and'],
1326
- [0,761],
1326
+ [756,759],
1327
+ ['mk',757,'and'],
1328
+ [0,759],
1327
1329
  'windowFrameBoundSpec',
1328
1330
  {
1329
- unbounded:['ck',762],
1330
- Number:['c',762],
1331
- current:['ck',764],
1331
+ unbounded:['ck',760],
1332
+ Number:['c',760],
1333
+ current:['ck',762],
1332
1334
  },
1333
1335
  {
1334
- following:['ck',763],
1335
- preceding:['ck',763],
1336
+ following:['ck',761],
1337
+ preceding:['ck',761],
1336
1338
  },
1337
1339
  ['g',0],
1338
1340
  ['mk',0,'row'],
1339
1341
  'literalValue',
1340
1342
  {
1341
- '#':['c',767],
1343
+ '#':['c',765],
1342
1344
  null:['ck',0],
1343
1345
  true:['ck',0],false:'true',
1344
1346
  Number:['c',0],
@@ -1347,101 +1349,101 @@ QuotedLiteral:['c',0],
1347
1349
  },
1348
1350
  ['miA',0],
1349
1351
  'annoAssignStd',
1350
- ['m',770,'@',,,'annoInSameLine'],
1352
+ ['m',768,'@',,,'annoInSameLine'],
1351
1353
  {
1352
- '(':[0,778],
1353
- Id:[0,783],
1354
+ '(':[0,776],
1355
+ Id:[0,781],
1354
1356
  },
1355
1357
  'annoAssignCol',
1356
- ['m',773,'@'],
1358
+ ['m',771,'@'],
1357
1359
  {
1358
- '(':[0,778],
1359
- Id:[0,783],
1360
+ '(':[0,776],
1361
+ Id:[0,781],
1360
1362
  },
1361
1363
  'annoAssignMid',
1362
- ['m',776,'@',,,'annoInSameLine'],
1364
+ ['m',774,'@',,,'annoInSameLine'],
1363
1365
  {
1364
- '(':[0,778],
1365
- Id:[0,787],
1366
+ '(':[0,776],
1367
+ Id:[0,785],
1366
1368
  },
1367
1369
  'annoAssignParen',
1368
- ['m',779,'(',,,'annoInSameLine'],
1369
- {Id:[780,783],'':781},
1370
+ ['m',777,'(',,,'annoInSameLine'],
1371
+ {Id:[778,781],'':779},
1370
1372
  {
1371
- ',':['c',779],
1372
- ')':781,
1373
+ ',':['c',777],
1374
+ ')':779,
1373
1375
  },
1374
1376
  ['m',0,')'],
1375
1377
  'annoAssignBase',
1376
- [784,787],
1377
- {':':['c',785,,'annoInSameLine'],'':0},
1378
- [0,809],
1378
+ [782,785],
1379
+ {':':['c',783,,'annoInSameLine'],'':0},
1380
+ [0,807],
1379
1381
  'annoNamePath',
1380
- ['miA',788],
1381
- {'.':['c',789],'':791},
1382
+ ['miA',786],
1383
+ {'.':['c',787],'':789},
1382
1384
  {
1383
- Id:['ciA',788],
1384
- '@':['c',790],
1385
+ Id:['ciA',786],
1386
+ '@':['c',788],
1385
1387
  },
1386
- ['miA',788],
1387
- {'#':[0,800,,'annoInSameLine'],'':0},
1388
+ ['miA',786],
1389
+ {'#':[0,798,,'annoInSameLine'],'':0},
1388
1390
  'annoPath',
1389
1391
  {
1390
- Id:['ciA',795],
1391
- '@':['c',794],
1392
+ Id:['ciA',793],
1393
+ '@':['c',792],
1392
1394
  },
1393
- ['miA',795],
1394
- {'.':['c',796],'':798},
1395
+ ['miA',793],
1396
+ {'.':['c',794],'':796},
1395
1397
  {
1396
- Id:['ciA',795],
1397
- '@':['c',797],
1398
+ Id:['ciA',793],
1399
+ '@':['c',795],
1398
1400
  },
1399
- ['miA',795],
1400
- {'#':[0,800],'':0},
1401
+ ['miA',793],
1402
+ {'#':[0,798],'':0},
1401
1403
  'annoPathVariant',
1402
- ['m',801,'#'],
1403
- ['miA',802],
1404
- {'.':['c',803],'':0},
1405
- ['miA',802],
1404
+ ['m',799,'#'],
1405
+ ['miA',800],
1406
+ {'.':['c',801],'':0},
1407
+ ['miA',800],
1406
1408
  'annoStructValue',
1407
- [806,793],
1408
- {':':['c',807],'':0},
1409
- [0,809],
1409
+ [804,791],
1410
+ {':':['c',805],'':0},
1411
+ [0,807],
1410
1412
  'annoValue',
1411
1413
  {
1412
- '#':[0,766],null:'#',true:'#',false:'#',Number:'#',String:'#',QuotedLiteral:'#',
1413
- '+':['c',810],'-':'+',
1414
- Id:[0,793],'@':'Id',
1415
- '{':['c',811],
1416
- '[':['c',814,,,,'arrayAnno'],
1417
- '(':['c',820],
1414
+ '#':[0,764],null:'#',true:'#',false:'#',Number:'#',String:'#',QuotedLiteral:'#',
1415
+ '+':['c',808],'-':'+',
1416
+ Id:[0,791],'@':'Id',
1417
+ '{':['c',809],
1418
+ '[':['c',812,,,,'arrayAnno'],
1419
+ '(':['c',818],
1418
1420
  },
1419
1421
  ['m',0,'Number'],
1420
- {Id:[812,805],'@':'Id','':813},
1422
+ {Id:[810,803],'@':'Id','':811},
1421
1423
  {
1422
- ',':['c',811],
1423
- '}':813,
1424
- Id:['g',811,,'fail'],'@':'Id',
1424
+ ',':['c',809],
1425
+ '}':811,
1426
+ Id:['g',809,,'fail'],'@':'Id',
1425
1427
  },
1426
1428
  ['m',0,'}','arrayAnno','orNotEmpty'],
1427
1429
  {
1428
- Id:[818,809],'#':'Id','(':'Id','+':'Id','-':'Id','@':'Id','[':'Id','{':'Id',Number:'Id',String:'Id',QuotedLiteral:'Id',
1429
- '...':['c',815,,'arrayAnno','ellipsis'],
1430
- '':819
1430
+ Id:[816,807],'#':'Id','(':'Id','+':'Id','-':'Id','@':'Id','[':'Id','{':'Id',Number:'Id',String:'Id',QuotedLiteral:'Id',
1431
+ '...':['c',813,,'arrayAnno','ellipsis'],
1432
+ '':817
1431
1433
  },
1432
1434
  {
1433
- up:['ck',816],
1434
- ',':818,']':818,
1435
+ up:['ck',814],
1436
+ ',':816,']':816,
1435
1437
  },
1436
- ['mk',817,'to'],
1437
- [818,809],
1438
+ ['mk',815,'to'],
1439
+ [816,807],
1438
1440
  {
1439
- ',':['c',814],
1440
- ']':819,
1441
+ ',':['c',812],
1442
+ ']':817,
1441
1443
  },
1442
1444
  ['m',0,']','arrayAnno','bracket'],
1443
- {')':['c',0,,'fail'],'':821},
1444
- [822,637],
1445
+ {')':['c',0,,'fail'],'':819},
1446
+ [820,636],
1445
1447
  ['m',0,')'],
1446
1448
  ]
1447
1449
  class CdlParser extends AstBuildingParser{
@@ -2581,7 +2583,7 @@ case'(':this.annotateParamsBlock({art},306);continue
2581
2583
  default:this.s=306;continue
2582
2584
  }
2583
2585
  case 306:switch(this.lk()){
2584
- case'returns':this.lP()&&this.annotateReturns({outer:art},0);continue
2586
+ case'returns':this.annotateReturns({outer:art},0);continue
2585
2587
  default:this.gr([';']);continue
2586
2588
  }
2587
2589
  default:
@@ -3280,88 +3282,87 @@ let join;let tab;let card;let cond;let _
3280
3282
  this.rule_($startState??485,$next)
3281
3283
  for(;;)switch(this.s){
3282
3284
  case 485:switch(this.l()){
3283
- case'(':this.tableOrQueryParens($,486);continue
3284
- case'Id':this.fromRefWithOptAlias($,487);continue
3285
+ case'(':if(this.tableOrQueryParens($,486)){ $.expr = this.taggedIfQuery( $.expr ); }continue
3286
+ case'Id':this.fromRefWithOptAlias($,486);continue
3285
3287
  default:this.e();continue
3286
3288
  }
3287
- case 486:this.s=487;{ $.expr = this.taggedIfQuery( $.expr ); }continue
3288
- case 487:switch(this.lk()){
3289
- case'cross':if(this.ck(488))join=this.lb();continue
3290
- case'inner':if(this.ck(491))join=this.lb();continue
3291
- case'full':case'left':case'right':if(this.ck(490))join=this.lb();continue
3292
- case'join':if(this.ck(493)){ join = undefined; }continue
3289
+ case 486:switch(this.lk()){
3290
+ case'cross':if(this.ck(487))join=this.lb();continue
3291
+ case'inner':if(this.ck(490))join=this.lb();continue
3292
+ case'full':case'left':case'right':if(this.ck(489))join=this.lb();continue
3293
+ case'join':if(this.ck(492)){ join = undefined; }continue
3293
3294
  default:this.gr();continue
3294
3295
  }
3295
- case 488:if(this.mk(489,'join')){ if ($.expr?.join?.val !== 'cross' || $.expr.$parens) $.expr = { op: this.valueWithLocation(), join: this.valueWithLocation( undefined, join ), args: [ $.expr ] }; }continue
3296
- case 489:switch(this.l()){
3297
- case'(':if(this.tableOrQueryParens(_={},487)){tab=_.expr; const r = this.taggedIfQuery( tab ); if (r) $.expr.args.push( r );
3296
+ case 487:if(this.mk(488,'join')){ if ($.expr?.join?.val !== 'cross' || $.expr.$parens) $.expr = { op: this.valueWithLocation(), join: this.valueWithLocation( undefined, join ), args: [ $.expr ] }; }continue
3297
+ case 488:switch(this.l()){
3298
+ case'(':if(this.tableOrQueryParens(_={},486)){tab=_.expr; const r = this.taggedIfQuery( tab ); if (r) $.expr.args.push( r );
3298
3299
  this.attachLocation( $.expr ); }continue
3299
- case'Id':if(this.fromRefWithOptAlias(_={},487)){tab=_.expr; if (tab) $.expr.args.push( tab );
3300
+ case'Id':if(this.fromRefWithOptAlias(_={},486)){tab=_.expr; if (tab) $.expr.args.push( tab );
3300
3301
  this.attachLocation( $.expr ); }continue
3301
3302
  default:this.e();continue
3302
3303
  }
3304
+ case 489:switch(this.lk()){
3305
+ case'outer':this.ck(490);continue
3306
+ default:this.s=490;continue
3307
+ }
3303
3308
  case 490:switch(this.lk()){
3304
- case'outer':this.ck(491);continue
3309
+ case'one':case'many':case'exact':this.joinCardinality(card={},491);continue
3305
3310
  default:this.s=491;continue
3306
3311
  }
3307
- case 491:switch(this.lk()){
3308
- case'one':case'many':case'exact':this.joinCardinality(card={},492);continue
3309
- default:this.s=492;continue
3310
- }
3311
- case 492:this.mk(493,'join');continue
3312
- case 493:this.s=494;{ $.expr = { op: this.valueWithLocation(), join: this.valueWithLocation( join?.keyword || 'inner', join ), args: [ $.expr ] }; if (card) $.expr.cardinality = card; card = undefined; }continue
3313
- case 494:if(this.tableExpression(_={},495)){tab=_.expr; $.expr.args.push( tab ); this.attachLocation( $.expr ); }continue
3314
- case 495:this.mk(496,'on');continue
3315
- case 496:if(this.condition(_={},487)){cond=_.expr; $.expr.on = cond;
3312
+ case 491:this.mk(492,'join');continue
3313
+ case 492:this.s=493;{ $.expr = { op: this.valueWithLocation(), join: this.valueWithLocation( join?.keyword || 'inner', join ), args: [ $.expr ] }; if (card) $.expr.cardinality = card; card = undefined; }continue
3314
+ case 493:if(this.tableExpression(_={},494)){tab=_.expr; $.expr.args.push( tab ); this.attachLocation( $.expr ); }continue
3315
+ case 494:this.mk(495,'on');continue
3316
+ case 495:if(this.condition(_={},486)){cond=_.expr; $.expr.on = cond;
3316
3317
  this.attachLocation( $.expr ); }continue
3317
3318
  default:return this.exit_()
3318
3319
  }
3319
3320
  }
3320
3321
  tableOrQueryParens($,$next){
3321
3322
  $.expr??=undefined
3322
- this.rule_(498,$next)
3323
+ this.rule_(497,$next)
3323
3324
  for(;;)switch(this.s){
3324
- case 498:if(this.m(499,'(')){this.queryOnLeft()}continue;
3325
- case 499:switch(this.lk()){
3326
- case'(':this.tableOrQueryParens($,500);continue
3327
- case'Id':if(this.tableExpression($,501)){this.queryOnLeft('table')}continue;
3328
- case'select':this.queryExpression($,501);continue
3325
+ case 497:if(this.m(498,'(')){this.queryOnLeft()}continue;
3326
+ case 498:switch(this.lk()){
3327
+ case'(':this.tableOrQueryParens($,499);continue
3328
+ case'Id':if(this.tableExpression($,500)){this.queryOnLeft('table')}continue;
3329
+ case'select':this.queryExpression($,500);continue
3329
3330
  default:this.ei();continue
3330
3331
  }
3331
- case 500:switch(this.lk()){
3332
- case'full':case'join':case'left':case'cross':case'inner':case'right':if(this.tableExpression($,501,486)){this.queryOnLeft('table')}continue;
3333
- case'limit':case'minus':case'order':case'union':case'except':case'intersect':this.gc(501,'queryOnLeft')&&this.queryExpression($,501,454);continue
3334
- default:this.s=501;continue
3332
+ case 499:switch(this.lk()){
3333
+ case'full':case'join':case'left':case'cross':case'inner':case'right':if(this.tableExpression(( $.expr = this.taggedIfQuery( $.expr ), $ ),500,486)){this.queryOnLeft('table')}continue;
3334
+ case'limit':case'minus':case'order':case'union':case'except':case'intersect':this.gc(500,'queryOnLeft')&&this.queryExpression($,500,454);continue
3335
+ default:this.s=500;continue
3335
3336
  }
3336
- case 501:if(this.m(502,')')){ this.surroundByParens( $.expr ); }continue
3337
- case 502:switch(this.lk()){
3338
- case'as':this.gc(0,'queryOnLeft','table')&&this.ck(503);continue
3337
+ case 500:if(this.m(501,')')){ this.surroundByParens( $.expr ); }continue
3338
+ case 501:switch(this.lk()){
3339
+ case'as':this.gc(0,'queryOnLeft','table')&&this.ck(502);continue
3339
3340
  case'Id':if(this.gc(0,'queryOnLeftSloppyAlias')&&this.ci(0,'FromAlias')){ $.expr = this.taggedIfQuery( $.expr ); $.expr.name = this.fragileAlias(); }continue
3340
3341
  default:this.gi(0,['full','join','left','cross','inner','right']);continue
3341
3342
  }
3342
- case 503:if(this.mi(0,'FromAlias')){ $.expr = this.taggedIfQuery( $.expr ); $.expr.name = this.identAst(); }continue
3343
+ case 502:if(this.mi(0,'FromAlias')){ $.expr = this.taggedIfQuery( $.expr ); $.expr.name = this.identAst(); }continue
3343
3344
  default:return this.exit_()
3344
3345
  }
3345
3346
  }
3346
3347
  joinCardinality($,$next){
3347
3348
  $.sourceMax??=undefined;$.targetMax??=undefined
3348
- this.rule_(505,$next)
3349
+ this.rule_(504,$next)
3349
3350
  for(;;)switch(this.s){
3350
- case 505:switch(this.lk()){
3351
- case'one':this.s=506;continue
3352
- case'exact':if(this.ck(506)){ $.sourceMin = this.valueWithLocation( 1 ); }continue
3353
- case'many':if(this.ck(507)){ $.sourceMax = this.valueWithLocation( '*' ); }continue
3351
+ case 504:switch(this.lk()){
3352
+ case'one':this.s=505;continue
3353
+ case'exact':if(this.ck(505)){ $.sourceMin = this.valueWithLocation( 1 ); }continue
3354
+ case'many':if(this.ck(506)){ $.sourceMax = this.valueWithLocation( '*' ); }continue
3354
3355
  default:this.e();continue
3355
3356
  }
3356
- case 506:if(this.mk(507,'one')){ $.sourceMax = this.valueWithLocation( 1 ); }continue
3357
- case 507:this.mk(508,'to');continue
3358
- case 508:switch(this.lk()){
3359
- case'one':this.s=509;continue
3360
- case'exact':if(this.ck(509)){ $.targetMin = this.valueWithLocation( 1 ); }continue
3357
+ case 505:if(this.mk(506,'one')){ $.sourceMax = this.valueWithLocation( 1 ); }continue
3358
+ case 506:this.mk(507,'to');continue
3359
+ case 507:switch(this.lk()){
3360
+ case'one':this.s=508;continue
3361
+ case'exact':if(this.ck(508)){ $.targetMin = this.valueWithLocation( 1 ); }continue
3361
3362
  case'many':if(this.ck(0)){ $.targetMax = this.valueWithLocation( '*' ); }continue
3362
3363
  default:this.e();continue
3363
3364
  }
3364
- case 509:if(this.mk(0,'one')){ $.targetMax = this.valueWithLocation( 1 ); }continue
3365
+ case 508:if(this.mk(0,'one')){ $.targetMax = this.valueWithLocation( 1 ); }continue
3365
3366
  default:
3366
3367
  this.attachLocation( $ )
3367
3368
  return this.exit_()
@@ -3369,25 +3370,25 @@ return this.exit_()
3369
3370
  }
3370
3371
  fromRefWithOptAlias($,$next){
3371
3372
  $.expr??={}
3372
- this.rule_(511,$next)
3373
+ this.rule_(510,$next)
3373
3374
  { $.expr.path = []; }
3374
3375
  for(;;)switch(this.s){
3375
- case 511:this.fromPath({table:$.expr,category:'artref'},512);continue
3376
- case 512:switch(this.l()){
3377
- case':':if(this.c(513)){ if (!$.expr.scope) $.expr.scope = $.expr.path.length; else {
3376
+ case 510:this.fromPath({table:$.expr,category:'artref'},511);continue
3377
+ case 511:switch(this.l()){
3378
+ case':':if(this.c(512)){ if (!$.expr.scope) $.expr.scope = $.expr.path.length; else {
3378
3379
  this.warning( 'syntax-invalid-path-separator', this.lb(),
3379
3380
  { '#': 'colon', code: ':', newcode: '.' } );
3380
3381
  } }continue
3381
- default:this.s=514;continue
3382
+ default:this.s=513;continue
3382
3383
  }
3383
- case 513:this.fromPath({table:$.expr,category:'ref'},514);continue
3384
- case 514:switch(this.lk()){
3385
- case'as':this.ck(515);continue
3386
- case'Id':if(this.gc(516,'isNoKeywordInRuleFollow')&&this.ci(0,'FromAlias')){ $.expr.name = this.fragileAlias(); }continue
3387
- default:this.gi(516);continue
3384
+ case 512:this.fromPath({table:$.expr,category:'ref'},513);continue
3385
+ case 513:switch(this.lk()){
3386
+ case'as':this.ck(514);continue
3387
+ case'Id':if(this.gc(515,'isNoKeywordInRuleFollow')&&this.ci(0,'FromAlias')){ $.expr.name = this.fragileAlias(); }continue
3388
+ default:this.gi(515);continue
3388
3389
  }
3389
- case 515:if(this.mi(0,'FromAlias')){ $.expr.name = this.identAst(); }continue
3390
- case 516:if(this.gr()){ this.classifyImplicitName( $.expr.scope ? 'FromElemImplicit' : 'FromImplicit', $.expr ); }continue
3390
+ case 514:if(this.mi(0,'FromAlias')){ $.expr.name = this.identAst(); }continue
3391
+ case 515:if(this.gr()){ this.classifyImplicitName( $.expr.scope ? 'FromElemImplicit' : 'FromImplicit', $.expr ); }continue
3391
3392
  default:
3392
3393
  this.attachLocation( $.expr )
3393
3394
  return this.exit_()
@@ -3395,25 +3396,25 @@ return this.exit_()
3395
3396
  }
3396
3397
  fromPath($,$next){
3397
3398
  let pathItem
3398
- this.rule_(518,$next)
3399
+ this.rule_(517,$next)
3399
3400
  for(;;)switch(this.s){
3400
- case 518:if(this.mi(519,$.category)){ $.table.path.push( pathItem = this.identAst() ); }continue
3401
- case 519:switch(this.l()){
3402
- case'(':case'[':if(this.fromArgumentsAndFilter({pathStep:pathItem},520)){ pathItem = null; }continue
3403
- default:this.s=520;continue
3401
+ case 517:if(this.mi(518,$.category)){ $.table.path.push( pathItem = this.identAst() ); }continue
3402
+ case 518:switch(this.l()){
3403
+ case'(':case'[':if(this.fromArgumentsAndFilter({pathStep:pathItem},519)){ pathItem = null; }continue
3404
+ default:this.s=519;continue
3404
3405
  }
3405
- case 520:switch(this.l()){
3406
- case'.':if(this.gc(0,'notAfterEntityArgOrFilter')&&this.c(521)){ if (!pathItem && !$.table.scope) {
3406
+ case 519:switch(this.l()){
3407
+ case'.':if(this.gc(0,'notAfterEntityArgOrFilter')&&this.c(520)){ if (!pathItem && !$.table.scope) {
3407
3408
  $.table.scope = $.table.path.length; $.category = 'ref';
3408
3409
  this.warning( 'syntax-invalid-path-separator', this.lb(),
3409
3410
  { '#': 'dot', code: '.', newcode: ':' } );
3410
3411
  } }continue
3411
3412
  default:this.gr(['Id','as']);continue
3412
3413
  }
3413
- case 521:if(this.miA(522,$.category)){ $.table.path.push( pathItem = this.identAst() ); }continue
3414
- case 522:switch(this.l()){
3415
- case'(':case'[':if(this.fromArgumentsAndFilter({pathStep:pathItem},520)){ pathItem = null; }continue
3416
- default:this.s=520;continue
3414
+ case 520:if(this.miA(521,$.category)){ $.table.path.push( pathItem = this.identAst() ); }continue
3415
+ case 521:switch(this.l()){
3416
+ case'(':case'[':if(this.fromArgumentsAndFilter({pathStep:pathItem},519)){ pathItem = null; }continue
3417
+ default:this.s=519;continue
3417
3418
  }
3418
3419
  default:
3419
3420
  this.attachLocation( $.table.path )
@@ -3421,27 +3422,27 @@ return this.exit_()
3421
3422
  }
3422
3423
  }
3423
3424
  fromArgumentsAndFilter($,$next){
3424
- this.rule_(524,$next)
3425
+ this.rule_(523,$next)
3425
3426
  for(;;)switch(this.s){
3426
- case 524:switch(this.l()){
3427
- case'(':if(this.c(525)){ $.pathStep.args = this.createDict(); $.pathStep.$syntax = ':'; }continue
3428
- default:this.s=529;continue
3427
+ case 523:switch(this.l()){
3428
+ case'(':if(this.c(524)){ $.pathStep.args = this.createDict(); $.pathStep.$syntax = ':'; }continue
3429
+ default:this.s=528;continue
3429
3430
  }
3430
- case 525:switch(this.lk()){
3431
- case'Id':this.s=526;continue
3431
+ case 524:switch(this.lk()){
3432
+ case'Id':this.s=525;continue
3432
3433
  default:this.ei();continue
3433
3434
  }
3434
- case 526:switch(this.l()){
3435
- case'Id':this.fromNamedArgument($,527);continue
3436
- default:this.s=528;continue
3435
+ case 525:switch(this.l()){
3436
+ case'Id':this.fromNamedArgument($,526);continue
3437
+ default:this.s=527;continue
3437
3438
  }
3438
- case 527:switch(this.l()){
3439
- case',':this.c(526);continue
3440
- case')':this.s=528;continue
3439
+ case 526:switch(this.l()){
3440
+ case',':this.c(525);continue
3441
+ case')':this.s=527;continue
3441
3442
  default:this.e();continue
3442
3443
  }
3443
- case 528:this.m(529,')');continue
3444
- case 529:switch(this.l()){
3444
+ case 527:this.m(528,')');continue
3445
+ case 528:switch(this.l()){
3445
3446
  case'[':this.cardinalityAndFilter($,0);continue
3446
3447
  default:this.gr(['Id','.','as']);continue
3447
3448
  }
@@ -3450,229 +3451,229 @@ default:return this.exit_()
3450
3451
  }
3451
3452
  fromNamedArgument($,$next){
3452
3453
  let name;let expr;let _
3453
- this.rule_(531,$next)
3454
+ this.rule_(530,$next)
3454
3455
  for(;;)switch(this.s){
3455
- case 531:if(this.mi(532,'paramname'))name=this.lb();continue
3456
- case 532:this.m(533,':');continue
3457
- case 533:if(this.expression(_={},0)){expr=_.expr; this.addDef( expr, $.pathStep, 'args', 0, this.identAst( name ) ); }continue
3456
+ case 530:if(this.mi(531,'paramname'))name=this.lb();continue
3457
+ case 531:this.m(532,':');continue
3458
+ case 532:if(this.expression(_={},0)){expr=_.expr; this.addDef( expr, $.pathStep, 'args', 0, this.identAst( name ) ); }continue
3458
3459
  default:return this.exit_()
3459
3460
  }
3460
3461
  }
3461
3462
  cardinalityAndFilter($,$next){
3462
3463
  let cond;let _
3463
- this.rule_(535,$next)
3464
+ this.rule_(534,$next)
3464
3465
  for(;;)switch(this.s){
3465
- case 535:this.m(536,'[');continue
3466
- case 536:switch(this.l()){
3467
- case'Number':if(this.gc(538,'beforeColon')&&this.c(537)){ $.pathStep.cardinality = { targetMax: this.unsignedIntegerLiteral(), location: this.lb().location }; }continue
3468
- default:this.s=538;continue
3469
- }
3470
- case 537:this.m(538,':');continue
3471
- case 538:switch(this.lk()){
3472
- case'group':case'limit':case'order':case'having':this.gP(540);continue
3473
- case'where':this.ck(539);continue
3466
+ case 534:this.m(535,'[');continue
3467
+ case 535:switch(this.l()){
3468
+ case'Number':if(this.gc(537,'beforeColon')&&this.c(536)){ $.pathStep.cardinality = { targetMax: this.unsignedIntegerLiteral(), location: this.lb().location }; }continue
3469
+ default:this.s=537;continue
3470
+ }
3471
+ case 536:this.m(537,':');continue
3472
+ case 537:switch(this.lk()){
3473
+ case'group':case'limit':case'order':case'having':this.gP(539);continue
3474
+ case'where':this.ck(538);continue
3474
3475
  case']':if(this.c(0)){ $.pathStep.where ??= { args: [] }; }continue
3475
- default:this.s=539;continue
3476
+ default:this.s=538;continue
3476
3477
  }
3477
- case 539:if(this.condition(_={},540)){cond=_.expr; $.pathStep.where = cond; }continue
3478
- case 540:switch(this.lk()){
3479
- case'group':this.s=541;{ this.csnParseOnly('syntax-unexpected-sql-clause', 1, { keyword: 'group by' }); }continue
3480
- default:this.s=542;continue
3478
+ case 538:if(this.condition(_={},539)){cond=_.expr; $.pathStep.where = cond; }continue
3479
+ case 539:switch(this.lk()){
3480
+ case'group':this.s=540;{ this.csnParseOnly('syntax-unexpected-sql-clause', 1, { keyword: 'group by' }); }continue
3481
+ default:this.s=541;continue
3481
3482
  }
3482
- case 541:this.groupByClause({query:$.pathStep},542);continue
3483
- case 542:switch(this.lk()){
3484
- case'having':if(this.ck(543)){ this.csnParseOnly('syntax-unexpected-sql-clause', -1, { keyword: 'having' }); }continue
3485
- default:this.s=544;continue
3483
+ case 540:this.groupByClause({query:$.pathStep},541);continue
3484
+ case 541:switch(this.lk()){
3485
+ case'having':if(this.ck(542)){ this.csnParseOnly('syntax-unexpected-sql-clause', -1, { keyword: 'having' }); }continue
3486
+ default:this.s=543;continue
3486
3487
  }
3487
- case 543:if(this.condition(_={},544)){cond=_.expr; $.pathStep.having = cond; }continue
3488
- case 544:switch(this.l()){
3489
- case'Id':this.s=545;{ if (this.lk() === 'limit') this.csnParseOnly('syntax-unexpected-sql-clause', 0, { keyword: 'limit' } ); else this.csnParseOnly('syntax-unexpected-sql-clause', 1, { keyword: 'order by' } ); }continue
3490
- default:this.s=546;continue
3488
+ case 542:if(this.condition(_={},543)){cond=_.expr; $.pathStep.having = cond; }continue
3489
+ case 543:switch(this.l()){
3490
+ case'Id':this.s=544;{ if (this.lk() === 'limit') this.csnParseOnly('syntax-unexpected-sql-clause', 0, { keyword: 'limit' } ); else this.csnParseOnly('syntax-unexpected-sql-clause', 1, { keyword: 'order by' } ); }continue
3491
+ default:this.s=545;continue
3491
3492
  }
3492
- case 545:this.orderByLimitOffset({query:$.pathStep},546);continue
3493
- case 546:this.m(0,']');continue
3493
+ case 544:this.orderByLimitOffset({query:$.pathStep},545);continue
3494
+ case 545:this.m(0,']');continue
3494
3495
  default:return this.exit_()
3495
3496
  }
3496
3497
  }
3497
3498
  excludingClause($,$next){
3498
- this.rule_(548,$next)
3499
+ this.rule_(547,$next)
3499
3500
  for(;;)switch(this.s){
3500
- case 548:if(this.mk(549,'excluding')){ $.query.excludingDict = this.createDict(); }continue
3501
- case 549:this.m(550,'{');continue
3502
- case 550:switch(this.l()){
3503
- case'Id':this.s=551;continue
3501
+ case 547:if(this.mk(548,'excluding')){ $.query.excludingDict = this.createDict(); }continue
3502
+ case 548:this.m(549,'{');continue
3503
+ case 549:switch(this.l()){
3504
+ case'Id':this.s=550;continue
3504
3505
  default:this.e();continue
3505
3506
  }
3506
- case 551:switch(this.l()){
3507
- case'Id':if(this.ciA(552,'ref')){ this.addDef( { location: this.lb().location }, $.query, 'excludingDict', '', this.identAst() ); }continue
3508
- default:this.s=553;continue
3507
+ case 550:switch(this.l()){
3508
+ case'Id':if(this.ciA(551,'ref')){ this.addDef( { location: this.lb().location }, $.query, 'excludingDict', '', this.identAst() ); }continue
3509
+ default:this.s=552;continue
3509
3510
  }
3510
- case 552:switch(this.l()){
3511
- case',':this.c(551);continue
3512
- case'}':this.s=553;continue
3511
+ case 551:switch(this.l()){
3512
+ case',':this.c(550);continue
3513
+ case'}':this.s=552;continue
3513
3514
  default:this.e();continue
3514
3515
  }
3515
- case 553:if(this.m(0,'}')){this.afterBrace(); this.finalizeDictOrArray( $.query.excludingDict ); }continue
3516
+ case 552:if(this.m(0,'}')){this.afterBrace(); this.finalizeDictOrArray( $.query.excludingDict ); }continue
3516
3517
  default:return this.exit_()
3517
3518
  }
3518
3519
  }
3519
3520
  selectItemsList($,$next){
3520
- this.rule_(555,$next)
3521
+ this.rule_(554,$next)
3521
3522
  for(;;)switch(this.s){
3522
- case 555:if(this.m(556,'{')){this.inSelectItem('top'); $.query.columns = this.createArray( $.start ); }continue
3523
- case 556:switch(this.l()){
3524
- case'*':if(this.c(557)){ $.query.columns.push( this.valueWithLocation() ); }continue
3525
- case'Id':case'#':case'(':case'+':case'-':case':':case'?':case'@':case'{':case'Number':case'String':case'QuotedLiteral':this.selectItemDef({columns:$.query.columns},557);continue
3526
- default:this.s=558;continue
3523
+ case 554:if(this.m(555,'{')){this.inSelectItem('top'); $.query.columns = this.createArray( $.start ); }continue
3524
+ case 555:switch(this.l()){
3525
+ case'*':if(this.c(556)){ $.query.columns.push( this.valueWithLocation() ); }continue
3526
+ case'Id':case'#':case'(':case'+':case'-':case':':case'?':case'@':case'{':case'Number':case'String':case'QuotedLiteral':this.selectItemDef({columns:$.query.columns},556);continue
3527
+ default:this.s=557;continue
3527
3528
  }
3528
- case 557:switch(this.l()){
3529
- case',':this.c(556);continue
3530
- case'}':this.s=558;continue
3529
+ case 556:switch(this.l()){
3530
+ case',':this.c(555);continue
3531
+ case'}':this.s=557;continue
3531
3532
  default:this.e();continue
3532
3533
  }
3533
- case 558:if(this.m(0,'}')){this.afterBrace(); this.finalizeDictOrArray( $.query.columns ); }continue
3534
+ case 557:if(this.m(0,'}')){this.afterBrace(); this.finalizeDictOrArray( $.query.columns ); }continue
3534
3535
  default:return this.exit_()
3535
3536
  }
3536
3537
  }
3537
3538
  nestedSelectItemsList($,$next){
3538
- this.rule_(560,$next)
3539
+ this.rule_(559,$next)
3539
3540
  for(;;)switch(this.s){
3540
- case 560:if(this.m(561,'{')){this.inSelectItem(); $.query[$.clause] = this.createArray(); }continue
3541
- case 561:switch(this.l()){
3542
- case'*':if(this.c(562)){ $.query[$.clause].push( this.valueWithLocation() ); }continue
3543
- case'Id':case'#':case'(':case'+':case'-':case':':case'?':case'@':case'{':case'Number':case'String':case'QuotedLiteral':this.selectItemDef({columns:$.query[$.clause]},562);continue
3544
- default:this.s=563;continue
3541
+ case 559:if(this.m(560,'{')){this.inSelectItem(); $.query[$.clause] = this.createArray(); }continue
3542
+ case 560:switch(this.l()){
3543
+ case'*':if(this.c(561)){ $.query[$.clause].push( this.valueWithLocation() ); }continue
3544
+ case'Id':case'#':case'(':case'+':case'-':case':':case'?':case'@':case'{':case'Number':case'String':case'QuotedLiteral':this.selectItemDef({columns:$.query[$.clause]},561);continue
3545
+ default:this.s=562;continue
3545
3546
  }
3546
- case 562:switch(this.l()){
3547
- case',':this.c(561);continue
3548
- case'}':this.s=563;continue
3547
+ case 561:switch(this.l()){
3548
+ case',':this.c(560);continue
3549
+ case'}':this.s=562;continue
3549
3550
  default:this.e();continue
3550
3551
  }
3551
- case 563:if(this.m(0,'}')){this.afterBrace(); this.finalizeDictOrArray( $.query[$.clause] ); }continue
3552
+ case 562:if(this.m(0,'}')){this.afterBrace(); this.finalizeDictOrArray( $.query[$.clause] ); }continue
3552
3553
  default:return this.exit_()
3553
3554
  }
3554
3555
  }
3555
3556
  selectItemDef($,$next){
3556
3557
  let art=new XsnArtifact()
3557
3558
  let expr;let e;let target;let cond;let assoc;let card;let _
3558
- this.rule_(565,$next)
3559
+ this.rule_(564,$next)
3559
3560
  { $.columns.push( art );
3560
3561
  this.docComment( art ); }
3561
3562
  for(;;)switch(this.s){
3562
- case 565:switch(this.l()){
3563
- case'@':this.annoAssignCol({art},565);continue
3563
+ case 564:switch(this.l()){
3564
+ case'@':this.annoAssignCol({art},564);continue
3565
+ default:this.s=565;continue
3566
+ }
3567
+ case 565:switch(this.lk()){
3568
+ case'virtual':if(this.lP(['Id','#','(','+','-',':','?','{','key','not','case','cast','null','true','false','Number','String','exists','QuotedLiteral'])&&this.gc(566,'modifierRestriction')&&this.ck(566)){ art.virtual = this.valueWithLocation( true ); }continue
3564
3569
  default:this.s=566;continue
3565
3570
  }
3566
- case 566:switch(this.lk()){
3567
- case'virtual':if(this.lP(['Id','#','(','+','-',':','?','{','key','not','case','cast','null','true','false','Number','String','exists','QuotedLiteral'])&&this.gc(567,'modifierRestriction')&&this.ck(567)){ art.virtual = this.valueWithLocation( true ); }continue
3568
- default:this.s=567;continue
3571
+ case 566:this.s=567;{this.columnExpr('key')}continue;
3572
+ case 567:switch(this.lk()){
3573
+ case'key':if(this.gc(568,'modifierRestriction')&&this.ck(568)){ art.key = this.valueWithLocation( true ); }continue
3574
+ default:this.s=568;continue
3569
3575
  }
3570
- case 567:this.s=568;{this.columnExpr('key')}continue;
3571
3576
  case 568:switch(this.lk()){
3572
- case'key':if(this.gc(569,'modifierRestriction')&&this.ck(569)){ art.key = this.valueWithLocation( true ); }continue
3573
- default:this.s=569;continue
3574
- }
3575
- case 569:switch(this.lk()){
3576
- case'#':case'(':case'+':case'-':case':':case'?':case'new':case'not':case'case':case'cast':case'null':case'true':case'false':case'Number':case'String':case'exists':case'QuotedLiteral':if(this.lP()&&this.expression(_={},570)){expr=_.expr; art.value = expr; }continue
3577
- case'Id':if(this.valuePath(_={},572)){expr=_.expr; expr = this.valuePathAst( expr ); art.value = expr; }continue
3578
- case'{':this.nestedSelectItemsList({query:art,clause:'expand'},583);continue
3577
+ case'#':case'(':case'+':case'-':case':':case'?':case'new':case'not':case'case':case'cast':case'null':case'true':case'false':case'Number':case'String':case'exists':case'QuotedLiteral':if(this.lP()&&this.expression(_={},569)){expr=_.expr; art.value = expr; }continue
3578
+ case'Id':if(this.valuePath(_={},571)){expr=_.expr; expr = this.valuePathAst( expr ); art.value = expr; }continue
3579
+ case'{':this.nestedSelectItemsList({query:art,clause:'expand'},582);continue
3579
3580
  default:this.ei();continue
3580
3581
  }
3581
- case 570:switch(this.lk()){
3582
- case'as':this.ck(571);continue
3583
- case'Id':if(this.ci(580,'ItemAlias')){ art.name = this.fragileAlias( true ); }continue
3584
- default:this.gi(580);continue
3585
- }
3586
- case 571:if(this.mi(580,'ItemAlias')){ art.name = this.identAst(); }continue
3587
- case 572:switch(this.lk()){
3588
- case'over':if(this.ck(573)){ this.pushXprToken( expr.suffix = [] ); }continue
3589
- case'*':case'+':case'-':case'/':case'<':case'=':case'>':case'?':case'!=':case'<=':case'<>':case'==':case'>=':case'in':case'is':case'or':case'||':case'and':case'not':case'like':case'between':if(this.expression(_={ expr: expr },575,640)){e=_.expr; Object.assign( e.location || {}, expr.location ); art.value = this.attachLocation( e ) }continue
3590
- case'as':this.ck(577);continue
3591
- case'Id':if(this.ci(580,'ItemAlias')){this.nestedExpand(); art.name = this.fragileAlias( true ); }continue
3592
- case'.':if(this.c(578)){ this.reportUnexpectedSpace( this.lb(), this.la().location, true );
3582
+ case 569:switch(this.lk()){
3583
+ case'as':this.ck(570);continue
3584
+ case'Id':if(this.ci(579,'ItemAlias')){ art.name = this.fragileAlias( true ); }continue
3585
+ default:this.gi(579);continue
3586
+ }
3587
+ case 570:if(this.mi(579,'ItemAlias')){ art.name = this.identAst(); }continue
3588
+ case 571:switch(this.lk()){
3589
+ case'over':if(this.ck(572)){ this.pushXprToken( expr.suffix = [] ); }continue
3590
+ case'*':case'+':case'-':case'/':case'<':case'=':case'>':case'?':case'!=':case'<=':case'<>':case'==':case'>=':case'in':case'is':case'or':case'||':case'and':case'not':case'like':case'between':if(this.expression(_={ expr: expr },574,649)){e=_.expr; Object.assign( e.location || {}, expr.location ); art.value = this.attachLocation( e ) }continue
3591
+ case'as':this.ck(576);continue
3592
+ case'Id':if(this.ci(579,'ItemAlias')){this.nestedExpand(); art.name = this.fragileAlias( true ); }continue
3593
+ case'.':if(this.c(577)){ this.reportUnexpectedSpace( this.lb(), this.la().location, true );
3593
3594
  this.reportExpandInline( art, true ); }continue
3594
- default:if(this.gi(580)){this.nestedExpand(); this.virtualOrImplicit( art ); }continue
3595
+ default:if(this.gi(579)){this.nestedExpand(); this.virtualOrImplicit( art ); }continue
3595
3596
  }
3596
- case 573:this.overClause({outer:expr.suffix},574);continue
3597
- case 574:switch(this.lk()){
3598
- case'*':case'+':case'-':case'/':case'<':case'=':case'>':case'?':case'!=':case'<=':case'<>':case'==':case'>=':case'in':case'is':case'or':case'||':case'and':case'not':case'like':case'between':if(this.expression(_={ expr: expr },575,640)){e=_.expr; Object.assign( e.location || {}, expr.location ); art.value = this.attachLocation( e ) }continue
3599
- default:this.s=575;continue
3600
- }
3601
- case 575:switch(this.lk()){
3602
- case'as':this.ck(576);continue
3603
- case'Id':if(this.ci(580,'ItemAlias')){ art.name = this.fragileAlias( true ); }continue
3604
- default:this.gi(580);continue
3597
+ case 572:this.overClause({outer:expr.suffix},573);continue
3598
+ case 573:switch(this.lk()){
3599
+ case'*':case'+':case'-':case'/':case'<':case'=':case'>':case'?':case'!=':case'<=':case'<>':case'==':case'>=':case'in':case'is':case'or':case'||':case'and':case'not':case'like':case'between':if(this.expression(_={ expr: expr },574,649)){e=_.expr; Object.assign( e.location || {}, expr.location ); art.value = this.attachLocation( e ) }continue
3600
+ default:this.s=574;continue
3605
3601
  }
3606
- case 576:if(this.mi(580,'ItemAlias')){ art.name = this.identAst(); }continue
3607
- case 577:if(this.mi(580,'ItemAlias')){this.nestedExpand(); art.name = this.identAst(); }continue
3608
- case 578:switch(this.l()){
3609
- case'{':this.nestedSelectItemsList({query:art,clause:'inline'},579);continue
3602
+ case 574:switch(this.lk()){
3603
+ case'as':this.ck(575);continue
3604
+ case'Id':if(this.ci(579,'ItemAlias')){ art.name = this.fragileAlias( true ); }continue
3605
+ default:this.gi(579);continue
3606
+ }
3607
+ case 575:if(this.mi(579,'ItemAlias')){ art.name = this.identAst(); }continue
3608
+ case 576:if(this.mi(579,'ItemAlias')){this.nestedExpand(); art.name = this.identAst(); }continue
3609
+ case 577:switch(this.l()){
3610
+ case'{':this.nestedSelectItemsList({query:art,clause:'inline'},578);continue
3610
3611
  case'*':if(this.c(0)){ art.inline = [ this.valueWithLocation() ]; }continue
3611
3612
  default:this.e();continue
3612
3613
  }
3613
- case 579:switch(this.lk()){
3614
+ case 578:switch(this.lk()){
3614
3615
  case'excluding':this.excludingClause({query:art},0);continue
3615
3616
  default:this.gr([',']);continue
3616
3617
  }
3617
- case 580:switch(this.l()){
3618
- case'{':if(this.gc(586,'nestedExpand')&&this.g(581)){ if (!this.nestedExpand(0,true)) this.reportExpandInline( art, false ); }continue
3619
- default:this.s=586;continue
3618
+ case 579:switch(this.l()){
3619
+ case'{':if(this.gc(585,'nestedExpand')&&this.g(580)){ if (!this.nestedExpand(0,true)) this.reportExpandInline( art, false ); }continue
3620
+ default:this.s=585;continue
3621
+ }
3622
+ case 580:this.nestedSelectItemsList({query:art,clause:'expand'},581);continue
3623
+ case 581:switch(this.lk()){
3624
+ case'excluding':this.excludingClause({query:art},585);continue
3625
+ default:this.s=585;continue
3620
3626
  }
3621
- case 581:this.nestedSelectItemsList({query:art,clause:'expand'},582);continue
3622
3627
  case 582:switch(this.lk()){
3623
- case'excluding':this.excludingClause({query:art},586);continue
3624
- default:this.s=586;continue
3628
+ case'excluding':this.excludingClause({query:art},583);continue
3629
+ default:this.s=583;continue
3625
3630
  }
3626
- case 583:switch(this.lk()){
3627
- case'excluding':this.excludingClause({query:art},584);continue
3628
- default:this.s=584;continue
3631
+ case 583:this.mk(584,'as');continue
3632
+ case 584:if(this.mi(585,'ItemAlias')){ art.name = this.identAst(); }continue
3633
+ case 585:this.s=586;{this.columnExpr(); this.docComment( art ); }continue
3634
+ case 586:switch(this.l()){
3635
+ case'@':this.annoAssignMid({art},586);continue
3636
+ default:this.s=587;continue
3629
3637
  }
3630
- case 584:this.mk(585,'as');continue
3631
- case 585:if(this.mi(586,'ItemAlias')){ art.name = this.identAst(); }continue
3632
- case 586:this.s=587;{this.columnExpr(); this.docComment( art ); }continue
3633
3638
  case 587:switch(this.l()){
3634
- case'@':this.annoAssignMid({art},587);continue
3635
- default:this.s=588;continue
3636
- }
3637
- case 588:switch(this.l()){
3638
- case':':this.c(589);continue
3639
+ case':':this.c(588);continue
3639
3640
  default:this.gr([',']);continue
3640
3641
  }
3641
- case 589:switch(this.lk()){
3642
- case'Id':case'{':this.typeExpression({art},602);continue
3643
- case'redirected':this.ckP(590,['to']);continue
3644
- case'association':if(this.lP(['[','to'])&&this.ec('columnExpr')&&this.ck(594)){assoc=this.lb(); this.associationInSelectItem( art ); }continue
3645
- case'composition':if(this.lP(['[','of'])&&this.ec('columnExpr')&&this.ck(596)){assoc=this.lb(); this.associationInSelectItem( art ); }continue
3642
+ case 588:switch(this.lk()){
3643
+ case'Id':case'{':this.typeExpression({art},601);continue
3644
+ case'redirected':this.ckP(589,['to']);continue
3645
+ case'association':if(this.lP(['[','to'])&&this.ec('columnExpr')&&this.ck(593)){assoc=this.lb(); this.associationInSelectItem( art ); }continue
3646
+ case'composition':if(this.lP(['[','of'])&&this.ec('columnExpr')&&this.ck(595)){assoc=this.lb(); this.associationInSelectItem( art ); }continue
3646
3647
  default:this.ei();continue
3647
3648
  }
3648
- case 590:this.mk(591,'to');continue
3649
- case 591:if(this.simplePath(_={category:'artref'},592)){target=_.ref; art.target = target; }continue
3650
- case 592:switch(this.lk()){
3651
- case'on':this.ck(593);continue
3652
- case'{':this.foreignKeysBlock({art},602);continue
3653
- default:this.s=602;continue
3654
- }
3655
- case 593:if(this.condition(_={},602)){cond=_.expr; art.on = cond; }continue
3656
- case 594:switch(this.l()){
3657
- case'[':this.cardinality({art},595);continue
3658
- default:this.s=595;continue
3659
- }
3660
- case 595:this.mk(598,'to');continue
3661
- case 596:switch(this.l()){
3662
- case'[':this.cardinality({art},597);continue
3663
- default:this.s=597;continue
3664
- }
3665
- case 597:this.mk(598,'of');continue
3666
- case 598:switch(this.lk()){
3667
- case'one':case'many':if(this.lP(['Id'])&&this.gc(599,'noRepeatedCardinality')&&this.ck(599))card=this.lb();continue
3668
- default:this.s=599;continue
3669
- }
3670
- case 599:if(this.simplePath(_={category:'artref'},600)){target=_.ref; this.setAssocAndComposition( art, assoc, card, target ); }continue
3671
- case 600:this.mk(601,'on');continue
3672
- case 601:if(this.condition(_={},602)){expr=_.expr; art.on = expr; }continue
3673
- case 602:this.s=603;{ this.docComment( art ); }continue
3674
- case 603:switch(this.l()){
3675
- case'@':this.annoAssignStd({art},603);continue
3649
+ case 589:this.mk(590,'to');continue
3650
+ case 590:if(this.simplePath(_={category:'artref'},591)){target=_.ref; art.target = target; }continue
3651
+ case 591:switch(this.lk()){
3652
+ case'on':this.ck(592);continue
3653
+ case'{':this.foreignKeysBlock({art},601);continue
3654
+ default:this.s=601;continue
3655
+ }
3656
+ case 592:if(this.condition(_={},601)){cond=_.expr; art.on = cond; }continue
3657
+ case 593:switch(this.l()){
3658
+ case'[':this.cardinality({art},594);continue
3659
+ default:this.s=594;continue
3660
+ }
3661
+ case 594:this.mk(597,'to');continue
3662
+ case 595:switch(this.l()){
3663
+ case'[':this.cardinality({art},596);continue
3664
+ default:this.s=596;continue
3665
+ }
3666
+ case 596:this.mk(597,'of');continue
3667
+ case 597:switch(this.lk()){
3668
+ case'one':case'many':if(this.lP(['Id'])&&this.gc(598,'noRepeatedCardinality')&&this.ck(598))card=this.lb();continue
3669
+ default:this.s=598;continue
3670
+ }
3671
+ case 598:if(this.simplePath(_={category:'artref'},599)){target=_.ref; this.setAssocAndComposition( art, assoc, card, target ); }continue
3672
+ case 599:this.mk(600,'on');continue
3673
+ case 600:if(this.condition(_={},601)){expr=_.expr; art.on = expr; }continue
3674
+ case 601:this.s=602;{ this.docComment( art ); }continue
3675
+ case 602:switch(this.l()){
3676
+ case'@':this.annoAssignStd({art},602);continue
3676
3677
  default:this.gr([',']);continue
3677
3678
  }
3678
3679
  default:
@@ -3682,90 +3683,90 @@ return this.exit_()
3682
3683
  }
3683
3684
  whereGroupByHaving($,$next){
3684
3685
  let cond;let _
3685
- this.rule_(605,$next)
3686
+ this.rule_(604,$next)
3686
3687
  for(;;)switch(this.s){
3687
- case 605:switch(this.lk()){
3688
- case'where':this.ck(606);continue
3688
+ case 604:switch(this.lk()){
3689
+ case'where':this.ck(605);continue
3690
+ default:this.s=606;continue
3691
+ }
3692
+ case 605:if(this.condition(_={},606)){cond=_.expr; $.query.where = cond; }continue
3693
+ case 606:switch(this.lk()){
3694
+ case'group':this.groupByClause($,607);continue
3689
3695
  default:this.s=607;continue
3690
3696
  }
3691
- case 606:if(this.condition(_={},607)){cond=_.expr; $.query.where = cond; }continue
3692
3697
  case 607:switch(this.lk()){
3693
- case'group':this.groupByClause($,608);continue
3694
- default:this.s=608;continue
3695
- }
3696
- case 608:switch(this.lk()){
3697
- case'having':this.ck(609);continue
3698
+ case'having':this.ck(608);continue
3698
3699
  default:this.gr(['limit','order']);continue
3699
3700
  }
3700
- case 609:if(this.condition(_={},0)){cond=_.expr; $.query.having = cond; }continue
3701
+ case 608:if(this.condition(_={},0)){cond=_.expr; $.query.having = cond; }continue
3701
3702
  default:return this.exit_()
3702
3703
  }
3703
3704
  }
3704
3705
  groupByClause($,$next){
3705
3706
  let expr;let _
3706
- this.rule_(611,$next)
3707
+ this.rule_(610,$next)
3707
3708
  for(;;)switch(this.s){
3708
- case 611:this.mk(612,'group');continue
3709
- case 612:this.mk(613,'by');continue
3710
- case 613:if(this.expression(_={},614)){expr=_.expr; $.query.groupBy = [ expr ]; }continue
3711
- case 614:switch(this.l()){
3712
- case',':this.c(615);continue
3709
+ case 610:this.mk(611,'group');continue
3710
+ case 611:this.mk(612,'by');continue
3711
+ case 612:if(this.expression(_={},613)){expr=_.expr; $.query.groupBy = [ expr ]; }continue
3712
+ case 613:switch(this.l()){
3713
+ case',':this.c(614);continue
3713
3714
  default:this.gr(['limit','order','having']);continue
3714
3715
  }
3715
- case 615:if(this.expression(_={},614)){expr=_.expr; $.query.groupBy.push( expr ); }continue
3716
+ case 614:if(this.expression(_={},613)){expr=_.expr; $.query.groupBy.push( expr ); }continue
3716
3717
  default:return this.exit_()
3717
3718
  }
3718
3719
  }
3719
3720
  orderByLimitOffset($,$next){
3720
3721
  let expr;let _
3721
- this.rule_(617,$next)
3722
+ this.rule_(616,$next)
3722
3723
  for(;;)switch(this.s){
3723
- case 617:switch(this.lk()){
3724
- case'order':this.orderByClause($,618);continue
3725
- default:this.s=618;continue
3724
+ case 616:switch(this.lk()){
3725
+ case'order':this.orderByClause($,617);continue
3726
+ default:this.s=617;continue
3726
3727
  }
3727
- case 618:switch(this.lk()){
3728
- case'limit':this.ck(619);continue
3728
+ case 617:switch(this.lk()){
3729
+ case'limit':this.ck(618);continue
3729
3730
  default:this.gr();continue
3730
3731
  }
3731
- case 619:if(this.expression(_={},620)){expr=_.expr; $.query.limit = { rows: expr }; }continue
3732
- case 620:switch(this.lk()){
3733
- case'offset':this.ck(621);continue
3732
+ case 618:if(this.expression(_={},619)){expr=_.expr; $.query.limit = { rows: expr }; }continue
3733
+ case 619:switch(this.lk()){
3734
+ case'offset':this.ck(620);continue
3734
3735
  default:this.gr();continue
3735
3736
  }
3736
- case 621:if(this.expression(_={},0)){expr=_.expr; $.query.limit.offset = expr; }continue
3737
+ case 620:if(this.expression(_={},0)){expr=_.expr; $.query.limit.offset = expr; }continue
3737
3738
  default:return this.exit_()
3738
3739
  }
3739
3740
  }
3740
3741
  orderByClause($,$next){
3741
3742
  let expr;let _
3742
- this.rule_(623,$next)
3743
+ this.rule_(622,$next)
3743
3744
  for(;;)switch(this.s){
3744
- case 623:this.mk(624,'order');continue
3745
- case 624:this.mk(625,'by');continue
3746
- case 625:if(this.orderByExpression(_={},626)){expr=_.expr; $.query.orderBy = [ expr ]; }continue
3747
- case 626:switch(this.l()){
3748
- case',':this.c(627);continue
3745
+ case 622:this.mk(623,'order');continue
3746
+ case 623:this.mk(624,'by');continue
3747
+ case 624:if(this.orderByExpression(_={},625)){expr=_.expr; $.query.orderBy = [ expr ]; }continue
3748
+ case 625:switch(this.l()){
3749
+ case',':this.c(626);continue
3749
3750
  default:this.gr(['limit']);continue
3750
3751
  }
3751
- case 627:if(this.orderByExpression(_={},626)){expr=_.expr; $.query.orderBy.push( expr ); }continue
3752
+ case 626:if(this.orderByExpression(_={},625)){expr=_.expr; $.query.orderBy.push( expr ); }continue
3752
3753
  default:return this.exit_()
3753
3754
  }
3754
3755
  }
3755
3756
  orderByExpression($,$next){
3756
3757
  $.expr??=undefined
3757
- this.rule_(629,$next)
3758
+ this.rule_(628,$next)
3758
3759
  for(;;)switch(this.s){
3759
- case 629:this.expression($,630);continue
3760
- case 630:switch(this.lk()){
3761
- case'asc':case'desc':if(this.ck(631)){ $.expr.sort = this.valueWithLocation(); }continue
3762
- default:this.s=631;continue
3760
+ case 628:this.expression($,629);continue
3761
+ case 629:switch(this.lk()){
3762
+ case'asc':case'desc':if(this.ck(630)){ $.expr.sort = this.valueWithLocation(); }continue
3763
+ default:this.s=630;continue
3763
3764
  }
3764
- case 631:switch(this.lk()){
3765
- case'nulls':this.ck(632);continue
3765
+ case 630:switch(this.lk()){
3766
+ case'nulls':this.ck(631);continue
3766
3767
  default:this.gr([',','limit']);continue
3767
3768
  }
3768
- case 632:switch(this.lk()){
3769
+ case 631:switch(this.lk()){
3769
3770
  case'last':case'first':if(this.ck(0)){ $.expr.nulls = this.valueWithLocation(); }continue
3770
3771
  default:this.e();continue
3771
3772
  }
@@ -3775,114 +3776,113 @@ default:return this.exit_()
3775
3776
  conditionEOF($,$next){
3776
3777
  $.cond??=undefined
3777
3778
  let _
3778
- this.rule_(634,$next)
3779
+ this.rule_(633,$next)
3779
3780
  for(;;)switch(this.s){
3780
- case 634:if(this.expression(_={},635))$.cond=_.expr;continue
3781
- case 635:this.m(0,'EOF');continue
3781
+ case 633:if(this.expression(_={},634))$.cond=_.expr;continue
3782
+ case 634:this.m(0,'EOF');continue
3782
3783
  default:return this.exit_()
3783
3784
  }
3784
3785
  }
3785
3786
  condition($,$next){
3786
3787
  $.expr??=undefined
3787
- this.rule_(637,$next)
3788
+ this.rule_(636,$next)
3788
3789
  for(;;)switch(this.s){
3789
- case 637:this.expression($,0);continue
3790
+ case 636:this.expression($,0);continue
3790
3791
  default:return this.exit_()
3791
3792
  }
3792
3793
  }
3793
3794
  expression($,$next,$startState){
3794
3795
  $.expr??={}
3795
3796
  let e;let open;let _
3796
- this.rule_($startState??639,$next)
3797
+ this.rule_($startState??638,$next)
3797
3798
  for(;;)switch(this.s){
3798
- case 639:switch(this.lk()){
3799
- case'(':this.expressionOrQueryParens($,640);continue
3800
- case'#':case'null':case'true':case'false':case'Number':case'String':case'QuotedLiteral':this.literalValue($,651);continue
3801
- case':':if(this.c(641)){ this.reportUnexpectedSpace(); }continue
3802
- case'?':if(this.c(651)){ this.csnParseOnly( 'syntax-unsupported-param', -1, { '#': 'dynamic', code: '?' } );
3799
+ case 638:switch(this.lk()){
3800
+ case'(':if(this.expressionOrQueryParens($,649)){ $.expr = this.taggedIfQuery( $.expr ); }continue
3801
+ case'#':case'null':case'true':case'false':case'Number':case'String':case'QuotedLiteral':this.literalValue($,649);continue
3802
+ case':':if(this.c(639)){ this.reportUnexpectedSpace(); }continue
3803
+ case'?':if(this.c(649)){ this.csnParseOnly( 'syntax-unsupported-param', -1, { '#': 'dynamic', code: '?' } );
3803
3804
  $.expr = this.attachLocation({ param: this.valueWithLocation(), scope: 'param' }); }continue
3804
- case'Id':if(this.valuePath(_={},643)){e=_.expr; $.expr = this.valuePathAst( e ); }continue
3805
- case'new':if(this.ckP(646,['Id'])){ $.expr = this.applyOpToken(); }continue
3806
- case'exists':if(this.ck(647)){ $.expr = this.applyOpToken(); }continue
3807
- case'case':this.caseExpression($,651);continue
3808
- case'cast':this.castFunction($,651);continue
3809
- case'+':case'-':if(this.ec('precRight_',30)&&this.c(650)){ $.expr = this.applyOpToken(); }continue
3810
- case'not':if(this.ec('precRight_',8)&&this.ck(650)){ $.expr = this.applyOpToken(); }continue
3805
+ case'Id':if(this.valuePath(_={},641)){e=_.expr; $.expr = this.valuePathAst( e ); }continue
3806
+ case'new':if(this.ckP(644,['Id'])){ $.expr = this.applyOpToken(); }continue
3807
+ case'exists':if(this.ck(645)){ $.expr = this.applyOpToken(); }continue
3808
+ case'case':this.caseExpression($,649);continue
3809
+ case'cast':this.castFunction($,649);continue
3810
+ case'+':case'-':if(this.ec('precRight_',30)&&this.c(648)){ $.expr = this.applyOpToken(); }continue
3811
+ case'not':if(this.ec('precRight_',8)&&this.ck(648)){ $.expr = this.applyOpToken(); }continue
3811
3812
  default:this.ei();continue
3812
3813
  }
3813
- case 640:this.s=651;{ $.expr = this.taggedIfQuery( $.expr ); }continue
3814
- case 641:switch(this.l()){
3815
- case'Id':if(this.ciA(642,'paramref')){ $.expr = { path: [ this.identAst() ], location: this.startLocation(), scope: 'param' }; }continue
3816
- case'Number':if(this.c(651)){ this.csnParseOnly( 'syntax-unsupported-param', -1, { '#': 'positional', code: ':' + this.lb().text } );
3814
+ case 639:switch(this.l()){
3815
+ case'Id':if(this.ciA(640,'paramref')){ $.expr = { path: [ this.identAst() ], location: this.startLocation(), scope: 'param' }; }continue
3816
+ case'Number':if(this.c(649)){ this.csnParseOnly( 'syntax-unsupported-param', -1, { '#': 'positional', code: ':' + this.lb().text } );
3817
3817
  $.expr = this.attachLocation({ param: this.unsignedIntegerLiteral(), scope: 'param' }); }continue
3818
3818
  default:this.e();continue
3819
3819
  }
3820
- case 642:switch(this.l()){
3821
- case'.':if(this.valuePath($,651,670)){ $.expr = this.valuePathAst( $.expr ); }continue
3822
- default:this.s=651;{ this.attachLocation( $.expr ); }continue
3820
+ case 640:switch(this.l()){
3821
+ case'.':if(this.valuePath($,649,668)){ $.expr = this.valuePathAst( $.expr ); }continue
3822
+ default:this.s=649;{ this.attachLocation( $.expr ); }continue
3823
3823
  }
3824
- case 643:switch(this.lk()){
3825
- case'over':if(this.ck(644)){ this.pushXprToken( $.expr.suffix = [] ); }continue
3826
- default:this.s=645;continue
3824
+ case 641:switch(this.lk()){
3825
+ case'over':if(this.ck(642)){ this.pushXprToken( $.expr.suffix = [] ); }continue
3826
+ default:this.s=643;continue
3827
3827
  }
3828
- case 644:this.overClause(e={outer:$.expr.suffix},645);continue
3829
- case 645:this.s=651;{ this.attachLocation( $.expr ); }continue
3830
- case 646:if(this.valuePath(_={},651)){e=_.expr; this.valuePathAstWithNew( $.expr, e ); }continue
3831
- case 647:switch(this.l()){
3832
- case'(':if(this.c(648))open=this.lb();continue
3833
- case'Id':if(this.valuePath(_={},651)){e=_.expr; e = this.valuePathAst( e ); e.$syntax = 'after-exists';
3828
+ case 642:this.overClause(e={outer:$.expr.suffix},643);continue
3829
+ case 643:this.s=649;{ this.attachLocation( $.expr ); }continue
3830
+ case 644:if(this.valuePath(_={},649)){e=_.expr; this.valuePathAstWithNew( $.expr, e ); }continue
3831
+ case 645:switch(this.l()){
3832
+ case'(':if(this.c(646))open=this.lb();continue
3833
+ case'Id':if(this.valuePath(_={},649)){e=_.expr; e = this.valuePathAst( e ); e.$syntax = 'after-exists';
3834
3834
  $.expr.args.push( e ); this.attachLocation( $.expr ); }continue
3835
- case'?':if(this.c(651)){ this.csnParseOnly( 'syntax-unsupported-param', -1, { '#': 'dynamic', code: '?' } );
3835
+ case'?':if(this.c(649)){ this.csnParseOnly( 'syntax-unsupported-param', -1, { '#': 'dynamic', code: '?' } );
3836
3836
  $.expr.args.push( { param: this.valueWithLocation(), scope: 'param' } ); this.attachLocation( $.expr ); }continue
3837
3837
  default:this.e();continue
3838
3838
  }
3839
- case 648:if(this.queryExpression(_={},649))e=_.expr;continue
3840
- case 649:if(this.m(651,')')){ $.expr.args.push( this.taggedIfQuery( this.surroundByParens( e, open ) ) );
3839
+ case 646:if(this.queryExpression(_={},647))e=_.expr;continue
3840
+ case 647:if(this.m(649,')')){ $.expr.args.push( this.taggedIfQuery( this.surroundByParens( e, open ) ) );
3841
3841
  this.attachLocation( $.expr ); }continue
3842
- case 650:if(this.expression(_={},651)){e=_.expr; $.expr = this.signedExpression( $.expr, e ); }continue
3843
- case 651:switch(this.lk()){
3844
- case'*':case'/':if(this.gc(0,'precLeft_',24)&&this.c(655)){ $.expr = this.applyOpToken( $.expr, 'nary' ); }continue
3845
- case'+':case'-':if(this.gc(0,'precLeft_',22)&&this.c(655)){ $.expr = this.applyOpToken( $.expr, 'nary' ); }continue
3846
- case'||':if(this.gc(0,'precLeft_',20)&&this.c(655)){ $.expr = this.applyOpToken( $.expr, 'nary' ); }continue
3847
- case'and':if(this.gc(0,'precLeft_',4)&&this.ck(655)){ $.expr = this.applyOpToken( $.expr, 'nary' ); }continue
3848
- case'or':if(this.gc(0,'precLeft_',2)&&this.ck(655)){ $.expr = this.applyOpToken( $.expr, 'nary' ); }continue
3849
- case'?':if(this.gc(0,'precRight_',0)&&this.c(652)){ $.expr = this.applyOpToken( $.expr, '?:' ); }continue
3850
- case'<':case'=':case'>':case'!=':case'<=':case'<>':case'>=':if(this.gc(0,'precNone_',10)&&this.c(654)){ $.expr = this.applyOpToken( $.expr ); }continue
3851
- case'==':if(this.gc(0,'precNone_',10)&&this.c(655)){ $.expr = this.applyOpToken( $.expr ); }continue
3852
- case'is':if(this.gc(0,'precNone_',10)&&this.ck(656)){ $.expr = this.applyOpToken( $.expr ); }continue
3853
- case'not':if(this.gc(0,'isNegatedRelation',10)&&this.ck(658)){ $.expr = this.applyOpToken( $.expr ); }continue
3854
- case'in':case'like':case'between':if(this.gc(0,'precNone_',10)&&this.g(658)){ $.expr = { op: { val: 'ixpr', location: this.la().location }, args: [ $.expr ] }; }continue
3842
+ case 648:if(this.expression(_={},649)){e=_.expr; $.expr = this.signedExpression( $.expr, e ); }continue
3843
+ case 649:switch(this.lk()){
3844
+ case'*':case'/':if(this.gc(0,'precLeft_',24)&&this.c(653)){ $.expr = this.applyOpToken( $.expr, 'nary' ); }continue
3845
+ case'+':case'-':if(this.gc(0,'precLeft_',22)&&this.c(653)){ $.expr = this.applyOpToken( $.expr, 'nary' ); }continue
3846
+ case'||':if(this.gc(0,'precLeft_',20)&&this.c(653)){ $.expr = this.applyOpToken( $.expr, 'nary' ); }continue
3847
+ case'and':if(this.gc(0,'precLeft_',4)&&this.ck(653)){ $.expr = this.applyOpToken( $.expr, 'nary' ); }continue
3848
+ case'or':if(this.gc(0,'precLeft_',2)&&this.ck(653)){ $.expr = this.applyOpToken( $.expr, 'nary' ); }continue
3849
+ case'?':if(this.gc(0,'precRight_',0)&&this.c(650)){ $.expr = this.applyOpToken( $.expr, '?:' ); }continue
3850
+ case'<':case'=':case'>':case'!=':case'<=':case'<>':case'>=':if(this.gc(0,'precNone_',10)&&this.c(652)){ $.expr = this.applyOpToken( $.expr ); }continue
3851
+ case'==':if(this.gc(0,'precNone_',10)&&this.c(653)){ $.expr = this.applyOpToken( $.expr ); }continue
3852
+ case'is':if(this.gc(0,'precNone_',10)&&this.ck(654)){ $.expr = this.applyOpToken( $.expr ); }continue
3853
+ case'not':if(this.gc(0,'isNegatedRelation',10)&&this.ck(656)){ $.expr = this.applyOpToken( $.expr ); }continue
3854
+ case'in':case'like':case'between':if(this.gc(0,'precNone_',10)&&this.g(656)){ $.expr = { op: { val: 'ixpr', location: this.la().location }, args: [ $.expr ] }; }continue
3855
3855
  default:this.gr();continue
3856
3856
  }
3857
- case 652:if(this.expression(_={},653)){e=_.expr; $.expr.args.push( e ); }continue
3858
- case 653:if(this.m(655,':')){ this.pushXprToken( $.expr ); }continue
3857
+ case 650:if(this.expression(_={},651)){e=_.expr; $.expr.args.push( e ); }continue
3858
+ case 651:if(this.m(653,':')){ this.pushXprToken( $.expr ); }continue
3859
+ case 652:switch(this.lk()){
3860
+ case'all':case'any':case'some':if(this.ck(653)){ this.pushXprToken( $.expr ); }continue
3861
+ default:this.s=653;continue
3862
+ }
3863
+ case 653:if(this.expression(_={},664)){e=_.expr; $.expr.args.push( e ); }continue
3859
3864
  case 654:switch(this.lk()){
3860
- case'all':case'any':case'some':if(this.ck(655)){ this.pushXprToken( $.expr ); }continue
3865
+ case'not':if(this.ck(655)){ this.pushXprToken( $.expr ); }continue
3861
3866
  default:this.s=655;continue
3862
3867
  }
3863
- case 655:if(this.expression(_={},666)){e=_.expr; $.expr.args.push( e ); }continue
3868
+ case 655:if(this.mk(664,'null')){ this.pushXprToken( $.expr ); }continue
3864
3869
  case 656:switch(this.lk()){
3865
- case'not':if(this.ck(657)){ this.pushXprToken( $.expr ); }continue
3866
- default:this.s=657;continue
3867
- }
3868
- case 657:if(this.mk(666,'null')){ this.pushXprToken( $.expr ); }continue
3869
- case 658:switch(this.lk()){
3870
- case'between':if(this.ck(659)){ this.pushXprToken( $.expr ); }continue
3871
- case'in':if(this.ck(662)){ this.pushXprToken( $.expr ); }continue
3872
- case'like':if(this.ck(663)){ this.pushXprToken( $.expr ); }continue
3870
+ case'between':if(this.ck(657)){ this.pushXprToken( $.expr ); }continue
3871
+ case'in':if(this.ck(660)){ this.pushXprToken( $.expr ); }continue
3872
+ case'like':if(this.ck(661)){ this.pushXprToken( $.expr ); }continue
3873
3873
  default:this.e();continue
3874
3874
  }
3875
- case 659:if(this.expression(_={},660)){e=_.expr; $.expr.args?.push( e ); }continue
3876
- case 660:if(this.mk(661,'and')){ this.pushXprToken( $.expr ); }continue
3877
- case 661:if(this.expression(_={},666)){e=_.expr; $.expr.args?.push( e ); }continue
3878
- case 662:if(this.expression(_={},666)){e=_.expr; $.expr.args?.push( this.secureParens( e ) ); }continue
3879
- case 663:if(this.expression(_={},664)){e=_.expr; $.expr.args?.push( e ); }continue
3880
- case 664:switch(this.lk()){
3881
- case'escape':if(this.ck(665)){ this.pushXprToken( $.expr ); }continue
3882
- default:this.s=666;continue
3875
+ case 657:if(this.expression(_={},658)){e=_.expr; $.expr.args?.push( e ); }continue
3876
+ case 658:if(this.mk(659,'and')){ this.pushXprToken( $.expr ); }continue
3877
+ case 659:if(this.expression(_={},664)){e=_.expr; $.expr.args?.push( e ); }continue
3878
+ case 660:if(this.expression(_={},664)){e=_.expr; $.expr.args?.push( this.secureParens( e ) ); }continue
3879
+ case 661:if(this.expression(_={},662)){e=_.expr; $.expr.args?.push( e ); }continue
3880
+ case 662:switch(this.lk()){
3881
+ case'escape':if(this.ck(663)){ this.pushXprToken( $.expr ); }continue
3882
+ default:this.s=664;continue
3883
3883
  }
3884
- case 665:if(this.expression(_={},666)){e=_.expr; $.expr.args?.push( e ); }continue
3885
- case 666:this.s=651;{ this.attachLocation( $.expr ); }continue
3884
+ case 663:if(this.expression(_={},664)){e=_.expr; $.expr.args?.push( e ); }continue
3885
+ case 664:this.s=649;{ this.attachLocation( $.expr ); }continue
3886
3886
  default:
3887
3887
  if (this.s == null) this.attachLocation( $.expr )
3888
3888
  return this.exit_()
@@ -3891,21 +3891,21 @@ return this.exit_()
3891
3891
  valuePath($,$next,$startState){
3892
3892
  $.expr??={ path: [] }
3893
3893
  let pathItem
3894
- this.rule_($startState??668,$next)
3894
+ this.rule_($startState??666,$next)
3895
3895
  for(;;)switch(this.s){
3896
- case 668:if(this.mi(669,'ref')){ $.expr.path.push( pathItem = this.identAst() ); }continue
3897
- case 669:switch(this.l()){
3898
- case'(':case'[':this.argumentsAndFilter({pathStep:pathItem},670);continue
3899
- default:this.s=670;continue
3896
+ case 666:if(this.mi(667,'ref')){ $.expr.path.push( pathItem = this.identAst() ); }continue
3897
+ case 667:switch(this.l()){
3898
+ case'(':case'[':this.argumentsAndFilter({pathStep:pathItem},668);continue
3899
+ default:this.s=668;continue
3900
3900
  }
3901
- case 670:switch(this.l()){
3902
- case'.':this.gc(0,'isDotForPath')&&this.c(671);continue
3901
+ case 668:switch(this.l()){
3902
+ case'.':this.gc(0,'isDotForPath')&&this.c(669);continue
3903
3903
  default:this.gr(['*','+','-','/','<','=','>','?','!=','<=','<>','==','>=','in','is','or','||','and','not','like','between']);continue
3904
3904
  }
3905
- case 671:if(this.miA(672,'ref')){ $.expr.path.push( pathItem = this.identAst() ); }continue
3906
- case 672:switch(this.l()){
3907
- case'(':case'[':if(this.argumentsAndFilter({pathStep:pathItem},670)){ pathItem = null; }continue
3908
- default:this.s=670;continue
3905
+ case 669:if(this.miA(670,'ref')){ $.expr.path.push( pathItem = this.identAst() ); }continue
3906
+ case 670:switch(this.l()){
3907
+ case'(':case'[':if(this.argumentsAndFilter({pathStep:pathItem},668)){ pathItem = null; }continue
3908
+ default:this.s=668;continue
3909
3909
  }
3910
3910
  default:
3911
3911
  this.attachLocation( $.expr )
@@ -3914,48 +3914,48 @@ return this.exit_()
3914
3914
  }
3915
3915
  expressionOrQueryParens($,$next){
3916
3916
  $.expr??=undefined
3917
- this.rule_(674,$next)
3917
+ this.rule_(672,$next)
3918
3918
  for(;;)switch(this.s){
3919
- case 674:if(this.m(675,'(')){this.queryOnLeft()}continue;
3920
- case 675:switch(this.lk()){
3921
- case'(':this.expressionOrQueryParens($,676);continue
3922
- case'Id':case'#':case'+':case'-':case':':case'?':case'not':case'case':case'cast':case'null':case'true':case'false':case'Number':case'String':case'exists':case'QuotedLiteral':if(this.expression($,678)){this.queryOnLeft('expr')}continue;
3923
- case'select':this.queryExpression($,679);continue
3919
+ case 672:if(this.m(673,'(')){this.queryOnLeft()}continue;
3920
+ case 673:switch(this.lk()){
3921
+ case'(':this.expressionOrQueryParens($,674);continue
3922
+ case'Id':case'#':case'+':case'-':case':':case'?':case'not':case'case':case'cast':case'null':case'true':case'false':case'Number':case'String':case'exists':case'QuotedLiteral':if(this.expression($,676)){this.queryOnLeft('expr')}continue;
3923
+ case'select':this.queryExpression($,677);continue
3924
3924
  default:this.ei();continue
3925
3925
  }
3926
- case 676:switch(this.lk()){
3927
- case'*':case'+':case'-':case'/':case'<':case'=':case'>':case'?':case'!=':case'<=':case'<>':case'==':case'>=':case'in':case'is':case'or':case'||':case'and':case'not':case'like':case'between':if(this.expression($,677,640)){this.queryOnLeft('expr')}continue;
3928
- case',':if(this.continueExpressionslist($,679)){this.queryOnLeft('expr')}continue;
3929
- case'limit':case'minus':case'order':case'union':case'except':case'intersect':this.gc(679,'queryOnLeft')&&this.queryExpression($,679,454);continue
3930
- default:this.s=679;continue
3926
+ case 674:switch(this.lk()){
3927
+ case'*':case'+':case'-':case'/':case'<':case'=':case'>':case'?':case'!=':case'<=':case'<>':case'==':case'>=':case'in':case'is':case'or':case'||':case'and':case'not':case'like':case'between':if(this.expression(( $.expr = this.taggedIfQuery( $.expr ), $ ),675,649)){this.queryOnLeft('expr')}continue;
3928
+ case',':if(this.continueExpressionslist($,677)){this.queryOnLeft('expr')}continue;
3929
+ case'limit':case'minus':case'order':case'union':case'except':case'intersect':this.gc(677,'queryOnLeft')&&this.queryExpression($,677,454);continue
3930
+ default:this.s=677;continue
3931
3931
  }
3932
- case 677:switch(this.l()){
3933
- case',':this.continueExpressionslist($,679);continue
3934
- default:this.s=679;continue
3932
+ case 675:switch(this.l()){
3933
+ case',':this.continueExpressionslist($,677);continue
3934
+ default:this.s=677;continue
3935
3935
  }
3936
- case 678:switch(this.l()){
3937
- case',':this.continueExpressionslist($,679);continue
3938
- default:this.s=679;continue
3936
+ case 676:switch(this.l()){
3937
+ case',':this.continueExpressionslist($,677);continue
3938
+ default:this.s=677;continue
3939
3939
  }
3940
- case 679:if(this.m(0,')')){ if ($.expr.op?.val !== 'list' || $.expr.location) this.surroundByParens( $.expr ); else this.attachLocation( $.expr ); }continue
3940
+ case 677:if(this.m(0,')')){ if ($.expr.op?.val !== 'list' || $.expr.location) this.surroundByParens( $.expr ); else this.attachLocation( $.expr ); }continue
3941
3941
  default:return this.exit_()
3942
3942
  }
3943
3943
  }
3944
3944
  continueExpressionslist($,$next){
3945
3945
  let e;let _
3946
- this.rule_(681,$next)
3946
+ this.rule_(679,$next)
3947
3947
  for(;;)switch(this.s){
3948
- case 681:if(this.m(682,',')){ $.expr = { op: this.valueWithLocation( 'list' ), args: [ $.expr ], location: null }; }continue
3949
- case 682:switch(this.lk()){
3950
- case'Id':case'#':case'(':case'+':case'-':case':':case'?':case'not':case'case':case'cast':case'null':case'true':case'false':case'Number':case'String':case'exists':case'QuotedLiteral':this.s=683;continue
3948
+ case 679:if(this.m(680,',')){ $.expr = { op: this.valueWithLocation( 'list' ), args: [ $.expr ], location: null }; }continue
3949
+ case 680:switch(this.lk()){
3950
+ case'Id':case'#':case'(':case'+':case'-':case':':case'?':case'not':case'case':case'cast':case'null':case'true':case'false':case'Number':case'String':case'exists':case'QuotedLiteral':this.s=681;continue
3951
3951
  default:this.ei();continue
3952
3952
  }
3953
- case 683:switch(this.l()){
3954
- case'Id':case'#':case'(':case'+':case'-':case':':case'?':case'Number':case'String':case'QuotedLiteral':if(this.expression(_={},684)){e=_.expr; $.expr.args.push( e ); }continue
3953
+ case 681:switch(this.l()){
3954
+ case'Id':case'#':case'(':case'+':case'-':case':':case'?':case'Number':case'String':case'QuotedLiteral':if(this.expression(_={},682)){e=_.expr; $.expr.args.push( e ); }continue
3955
3955
  default:this.gr([')']);continue
3956
3956
  }
3957
- case 684:switch(this.l()){
3958
- case',':this.c(683);continue
3957
+ case 682:switch(this.l()){
3958
+ case',':this.c(681);continue
3959
3959
  default:this.gr([')']);continue
3960
3960
  }
3961
3961
  default:return this.exit_()
@@ -3964,30 +3964,31 @@ default:return this.exit_()
3964
3964
  caseExpression($,$next){
3965
3965
  $.expr??=undefined
3966
3966
  let e;let _
3967
- this.rule_(686,$next)
3967
+ this.rule_(684,$next)
3968
3968
  for(;;)switch(this.s){
3969
- case 686:if(this.mk(687,'case')){ $.expr.op = { val: 'ixpr', location: this.lb().location }; $.expr.args = []; this.pushXprToken( $.expr ); }continue
3970
- case 687:switch(this.lk()){
3971
- case'Id':case'#':case'(':case'+':case'-':case':':case'?':case'not':case'case':case'cast':case'null':case'true':case'false':case'Number':case'String':case'exists':case'QuotedLiteral':if(this.expression(_={},688)){e=_.expr; $.expr.args.push( e ); }continue
3972
- default:this.gi(688);continue
3973
- }
3974
- case 688:switch(this.lk()){
3975
- case'when':this.s=689;continue
3969
+ case 684:if(this.mk(685,'case')){ $.expr.op = { val: 'ixpr', location: this.lb().location }; $.expr.args = []; this.pushXprToken( $.expr ); }continue
3970
+ case 685:switch(this.lk()){
3971
+ case'Id':case'#':case'(':case'+':case'-':case':':case'?':case'not':case'case':case'cast':case'null':case'true':case'false':case'Number':case'String':case'exists':case'QuotedLiteral':if(this.expression(_={},686)){e=_.expr; $.expr.args.push( e ); }continue
3972
+ case'when':this.gP(686);continue
3973
+ default:this.gi(686);continue
3974
+ }
3975
+ case 686:switch(this.lk()){
3976
+ case'when':this.s=687;continue
3976
3977
  default:this.e();continue
3977
3978
  }
3978
- case 689:switch(this.lk()){
3979
- case'when':if(this.ck(690)){ this.pushXprToken( $.expr ); }continue
3979
+ case 687:switch(this.lk()){
3980
+ case'when':if(this.ck(688)){ this.pushXprToken( $.expr ); }continue
3981
+ default:this.s=691;continue
3982
+ }
3983
+ case 688:if(this.expression(_={},689)){e=_.expr; $.expr.args.push( e ); }continue
3984
+ case 689:if(this.mk(690,'then')){ this.pushXprToken( $.expr ); }continue
3985
+ case 690:if(this.expression(_={},687)){e=_.expr; $.expr.args.push( e ); }continue
3986
+ case 691:switch(this.lk()){
3987
+ case'else':if(this.ck(692)){ this.pushXprToken( $.expr ); }continue
3980
3988
  default:this.s=693;continue
3981
3989
  }
3982
- case 690:if(this.expression(_={},691)){e=_.expr; $.expr.args.push( e ); }continue
3983
- case 691:if(this.mk(692,'then')){ this.pushXprToken( $.expr ); }continue
3984
- case 692:if(this.expression(_={},689)){e=_.expr; $.expr.args.push( e ); }continue
3985
- case 693:switch(this.lk()){
3986
- case'else':if(this.ck(694)){ this.pushXprToken( $.expr ); }continue
3987
- default:this.s=695;continue
3988
- }
3989
- case 694:if(this.expression(_={},695)){e=_.expr; $.expr.args.push( e ); }continue
3990
- case 695:if(this.mk(0,'end')){ this.pushXprToken( $.expr ); }continue
3990
+ case 692:if(this.expression(_={},693)){e=_.expr; $.expr.args.push( e ); }continue
3991
+ case 693:if(this.mk(0,'end')){ this.pushXprToken( $.expr ); }continue
3991
3992
  default:
3992
3993
  this.attachLocation( $.expr )
3993
3994
  return this.exit_()
@@ -3996,14 +3997,14 @@ return this.exit_()
3996
3997
  castFunction($,$next){
3997
3998
  $.expr??=undefined
3998
3999
  let arg;let _
3999
- this.rule_(697,$next)
4000
+ this.rule_(695,$next)
4000
4001
  for(;;)switch(this.s){
4001
- case 697:if(this.mk(698,'cast')){ $.expr.op = this.valueWithLocation(); }continue
4002
- case 698:if(this.m(699,'(')){ $.expr.args = this.createArray(); }continue
4003
- case 699:if(this.expression(_={},700)){arg=_.expr; $.expr.args?.push( arg ); }continue
4004
- case 700:this.mk(701,'as');continue
4005
- case 701:this.typeRefOptArgs({art:$.expr},702);continue
4006
- case 702:if(this.m(0,')')){ this.finalizeDictOrArray( $.expr.args ); }continue
4002
+ case 695:if(this.mk(696,'cast')){ $.expr.op = this.valueWithLocation(); }continue
4003
+ case 696:if(this.m(697,'(')){ $.expr.args = this.createArray(); }continue
4004
+ case 697:if(this.expression(_={},698)){arg=_.expr; $.expr.args?.push( arg ); }continue
4005
+ case 698:this.mk(699,'as');continue
4006
+ case 699:this.typeRefOptArgs({art:$.expr},700);continue
4007
+ case 700:if(this.m(0,')')){ this.finalizeDictOrArray( $.expr.args ); }continue
4007
4008
  default:
4008
4009
  this.attachLocation( $.expr )
4009
4010
  return this.exit_()
@@ -4011,67 +4012,67 @@ return this.exit_()
4011
4012
  }
4012
4013
  argumentsAndFilter($,$next){
4013
4014
  let open;let id;let expr;let _
4014
- this.rule_(704,$next)
4015
+ this.rule_(702,$next)
4015
4016
  for(;;)switch(this.s){
4016
- case 704:switch(this.l()){
4017
- case'(':if(this.c(705)){open=this.lb();this.prepareSpecialFunction(); $.pathStep.args = this.createArray(); }continue
4018
- default:this.s=723;continue
4017
+ case 702:switch(this.l()){
4018
+ case'(':if(this.c(703)){open=this.lb();this.prepareSpecialFunction(); $.pathStep.args = this.createArray(); }continue
4019
+ default:this.s=721;continue
4019
4020
  }
4020
- case 705:switch(this.l()){
4021
- case')':this.s=722;continue
4022
- case'Id':if(this.gc(715,'isNamedArg')&&this.ciA(706,'paramname'))id=this.lb();continue
4023
- default:this.s=715;continue
4021
+ case 703:switch(this.l()){
4022
+ case')':this.s=720;continue
4023
+ case'Id':if(this.gc(713,'isNamedArg')&&this.ciA(704,'paramname'))id=this.lb();continue
4024
+ default:this.s=713;continue
4024
4025
  }
4025
- case 706:switch(this.l()){
4026
- case':':if(this.c(707)){ $.pathStep.args = this.createDict( open ); $.pathStep.$syntax = ':'; }continue
4027
- case'=>':if(this.c(711)){ $.pathStep.args = this.createDict(); }continue
4026
+ case 704:switch(this.l()){
4027
+ case':':if(this.c(705)){ $.pathStep.args = this.createDict( open ); $.pathStep.$syntax = ':'; }continue
4028
+ case'=>':if(this.c(709)){ $.pathStep.args = this.createDict(); }continue
4028
4029
  default:this.e();continue
4029
4030
  }
4030
- case 707:if(this.expression(_={},708)){expr=_.expr; this.addNamedArg( $.pathStep, id, expr ); }continue
4031
- case 708:switch(this.l()){
4032
- case',':this.c(709);continue
4033
- case')':this.s=722;continue
4031
+ case 705:if(this.expression(_={},706)){expr=_.expr; this.addNamedArg( $.pathStep, id, expr ); }continue
4032
+ case 706:switch(this.l()){
4033
+ case',':this.c(707);continue
4034
+ case')':this.s=720;continue
4034
4035
  default:this.e();continue
4035
4036
  }
4036
- case 709:switch(this.l()){
4037
- case'Id':if(this.ciA(710,'paramname'))id=this.lb();continue
4038
- case')':this.s=722;continue
4037
+ case 707:switch(this.l()){
4038
+ case'Id':if(this.ciA(708,'paramname'))id=this.lb();continue
4039
+ case')':this.s=720;continue
4039
4040
  default:this.e();continue
4040
4041
  }
4041
- case 710:this.m(707,':');continue
4042
- case 711:if(this.expression(_={},712)){expr=_.expr; this.addNamedArg( $.pathStep, id, expr ); }continue
4043
- case 712:switch(this.l()){
4044
- case',':this.c(713);continue
4045
- case')':this.s=722;continue
4042
+ case 708:this.m(705,':');continue
4043
+ case 709:if(this.expression(_={},710)){expr=_.expr; this.addNamedArg( $.pathStep, id, expr ); }continue
4044
+ case 710:switch(this.l()){
4045
+ case',':this.c(711);continue
4046
+ case')':this.s=720;continue
4046
4047
  default:this.e();continue
4047
4048
  }
4048
- case 713:switch(this.l()){
4049
- case'Id':if(this.ciA(714,'paramname'))id=this.lb();continue
4050
- case')':this.s=722;continue
4049
+ case 711:switch(this.l()){
4050
+ case'Id':if(this.ciA(712,'paramname'))id=this.lb();continue
4051
+ case')':this.s=720;continue
4051
4052
  default:this.e();continue
4052
4053
  }
4053
- case 714:this.m(711,'=>');continue
4054
- case 715:if(this.funcExpression(_={},716)){expr=_.expr; $.pathStep.args.push( expr ); }continue
4055
- case 716:switch(this.l()){
4056
- case',':if(this.c(717)){this.nextFunctionArgument()}continue;
4057
- default:this.s=719;continue
4054
+ case 712:this.m(709,'=>');continue
4055
+ case 713:if(this.funcExpression(_={},714)){expr=_.expr; $.pathStep.args.push( expr ); }continue
4056
+ case 714:switch(this.l()){
4057
+ case',':if(this.c(715)){this.nextFunctionArgument()}continue;
4058
+ default:this.s=717;continue
4058
4059
  }
4059
- case 717:switch(this.l()){
4060
- case')':this.c(718);continue
4061
- default:this.s=715;continue
4060
+ case 715:switch(this.l()){
4061
+ case')':this.c(716);continue
4062
+ default:this.s=713;continue
4062
4063
  }
4063
- case 718:switch(this.l()){
4064
+ case 716:switch(this.l()){
4064
4065
  case'[':this.cardinalityAndFilter($,0);continue
4065
4066
  default:this.gr(['*','+','-','.','/','<','=','>','?','!=','<=','<>','==','>=','in','is','or','||','and','not','like','between']);continue
4066
4067
  }
4067
- case 719:switch(this.lk()){
4068
- case'order':if(this.ck(720)){ expr = $.pathStep.args[$.pathStep.args.length - 1] = this.applyOpToken( expr ); }continue
4069
- default:this.s=722;continue
4068
+ case 717:switch(this.lk()){
4069
+ case'order':if(this.ck(718)){ expr = $.pathStep.args[$.pathStep.args.length - 1] = this.applyOpToken( expr ); }continue
4070
+ default:this.s=720;continue
4070
4071
  }
4071
- case 720:if(this.mk(721,'by')){ this.pushXprToken( expr ); }continue
4072
- case 721:if(this.orderByClauseAsXpr({outer:expr.args},722)){ this.attachLocation( expr ); }continue
4073
- case 722:if(this.m(723,')')){ this.finalizeDictOrArray( $.pathStep.args ); }continue
4074
- case 723:switch(this.l()){
4072
+ case 718:if(this.mk(719,'by')){ this.pushXprToken( expr ); }continue
4073
+ case 719:if(this.orderByClauseAsXpr({outer:expr.args},720)){ this.attachLocation( expr ); }continue
4074
+ case 720:if(this.m(721,')')){ this.finalizeDictOrArray( $.pathStep.args ); }continue
4075
+ case 721:switch(this.l()){
4075
4076
  case'[':this.cardinalityAndFilter($,0);continue
4076
4077
  default:this.gr(['*','+','-','.','/','<','=','>','?','!=','<=','<>','==','>=','in','is','or','||','and','not','like','between']);continue
4077
4078
  }
@@ -4082,22 +4083,22 @@ funcExpression($,$next){
4082
4083
  $.expr??=undefined
4083
4084
  let args
4084
4085
  let tok;let e;let _
4085
- this.rule_(725,$next)
4086
+ this.rule_(723,$next)
4086
4087
  for(;;)switch(this.s){
4087
- case 725:switch(this.lGenericIntroOrExpr()){
4088
- case'Id':case'#':case'(':case'+':case'-':case':':case'?':case'Number':case'String':case'QuotedLiteral':if(this.expression(_={},727))$.expr=_.expr;continue
4089
- case'GenericExpr':if(this.ckA(727)){tok=this.lb(); $.expr = { val: tok.keyword ?? tok.type, location: tok.location, literal: 'token' }; }continue
4090
- case'GenericIntro':if(this.ckA(726)){ $.expr = this.applyOpToken(); args = $.expr.args; }continue
4088
+ case 723:switch(this.lGenericIntroOrExpr()){
4089
+ case'Id':case'#':case'(':case'+':case'-':case':':case'?':case'Number':case'String':case'QuotedLiteral':if(this.expression(_={},725))$.expr=_.expr;continue
4090
+ case'GenericExpr':if(this.ckA(725)){tok=this.lb(); $.expr = { val: tok.keyword ?? tok.type, location: tok.location, literal: 'token' }; }continue
4091
+ case'GenericIntro':if(this.ckA(724)){ $.expr = this.applyOpToken(); args = $.expr.args; }continue
4091
4092
  default:this.e();continue
4092
4093
  }
4093
- case 726:if(this.expression(_={},727)){e=_.expr; $.expr.args.push( e ); }continue
4094
- case 727:switch(this.lGenericSeparator()){
4095
- case'GenericSeparator':if(this.ckA(728)){ if (args) this.pushXprToken( args ); else { $.expr= this.applyOpToken( $.expr ); args = $.expr.args; } }continue
4094
+ case 724:if(this.expression(_={},725)){e=_.expr; $.expr.args.push( e ); }continue
4095
+ case 725:switch(this.lGenericSeparator()){
4096
+ case'GenericSeparator':if(this.ckA(726)){ if (args) this.pushXprToken( args ); else { $.expr= this.applyOpToken( $.expr ); args = $.expr.args; } }continue
4096
4097
  default:this.gr([')',',','order']);continue
4097
4098
  }
4098
- case 728:switch(this.lGenericExpr()){
4099
- case'Id':case'#':case'(':case'+':case'-':case':':case'?':case'Number':case'String':case'QuotedLiteral':if(this.expression(_={},727)){e=_.expr; args.push( e ); }continue
4100
- case'GenericExpr':if(this.ckA(727)){ this.pushXprToken( args ); }continue
4099
+ case 726:switch(this.lGenericExpr()){
4100
+ case'Id':case'#':case'(':case'+':case'-':case':':case'?':case'Number':case'String':case'QuotedLiteral':if(this.expression(_={},725)){e=_.expr; args.push( e ); }continue
4101
+ case'GenericExpr':if(this.ckA(725)){ this.pushXprToken( args ); }continue
4101
4102
  default:this.e();continue
4102
4103
  }
4103
4104
  default:
@@ -4107,27 +4108,27 @@ return this.exit_()
4107
4108
  }
4108
4109
  overClause($,$next){
4109
4110
  let over=[]
4110
- this.rule_(730,$next)
4111
+ this.rule_(728,$next)
4111
4112
  for(;;)switch(this.s){
4112
- case 730:this.m(731,'(');continue
4113
- case 731:switch(this.lk()){
4114
- case'partition':if(this.ck(732)){ this.pushXprToken( over ); }continue
4115
- default:this.s=734;continue
4116
- }
4117
- case 732:if(this.mk(733,'by')){ this.pushXprToken( over ); }continue
4118
- case 733:this.expressionsAsXpr({outer:over},734);continue
4119
- case 734:switch(this.lk()){
4120
- case'order':if(this.ck(735)){ this.pushXprToken( over ); }continue
4113
+ case 728:this.m(729,'(');continue
4114
+ case 729:switch(this.lk()){
4115
+ case'partition':if(this.ck(730)){ this.pushXprToken( over ); }continue
4116
+ default:this.s=732;continue
4117
+ }
4118
+ case 730:if(this.mk(731,'by')){ this.pushXprToken( over ); }continue
4119
+ case 731:this.expressionsAsXpr({outer:over},732);continue
4120
+ case 732:switch(this.lk()){
4121
+ case'order':if(this.ck(733)){ this.pushXprToken( over ); }continue
4122
+ default:this.s=735;continue
4123
+ }
4124
+ case 733:if(this.mk(734,'by')){ this.pushXprToken( over ); }continue
4125
+ case 734:this.orderByClauseAsXpr({outer:over},735);continue
4126
+ case 735:switch(this.lk()){
4127
+ case'rows':if(this.ck(736)){ this.pushXprToken( over ); }continue
4121
4128
  default:this.s=737;continue
4122
4129
  }
4123
- case 735:if(this.mk(736,'by')){ this.pushXprToken( over ); }continue
4124
- case 736:this.orderByClauseAsXpr({outer:over},737);continue
4125
- case 737:switch(this.lk()){
4126
- case'rows':if(this.ck(738)){ this.pushXprToken( over ); }continue
4127
- default:this.s=739;continue
4128
- }
4129
- case 738:this.windowFrameClause({outer:over},739);continue
4130
- case 739:this.m(0,')');continue
4130
+ case 736:this.windowFrameClause({outer:over},737);continue
4131
+ case 737:this.m(0,')');continue
4131
4132
  default:
4132
4133
  $.outer.push( this.surroundByParens( this.ixprAst( over ) ) )
4133
4134
  return this.exit_()
@@ -4136,14 +4137,14 @@ return this.exit_()
4136
4137
  expressionsAsXpr($,$next){
4137
4138
  let args=[]
4138
4139
  let expr;let _
4139
- this.rule_(741,$next)
4140
+ this.rule_(739,$next)
4140
4141
  for(;;)switch(this.s){
4141
- case 741:if(this.expression(_={},742)){expr=_.expr; args.push( expr ); }continue
4142
- case 742:switch(this.l()){
4143
- case',':if(this.c(743)){ this.pushXprToken( args ); }continue
4142
+ case 739:if(this.expression(_={},740)){expr=_.expr; args.push( expr ); }continue
4143
+ case 740:switch(this.l()){
4144
+ case',':if(this.c(741)){ this.pushXprToken( args ); }continue
4144
4145
  default:this.gr([')','rows','order']);continue
4145
4146
  }
4146
- case 743:if(this.expression(_={},742)){expr=_.expr; args.push( expr ); }continue
4147
+ case 741:if(this.expression(_={},740)){expr=_.expr; args.push( expr ); }continue
4147
4148
  default:
4148
4149
  $.outer.push( this.ixprAst( args ) )
4149
4150
  return this.exit_()
@@ -4151,14 +4152,14 @@ return this.exit_()
4151
4152
  }
4152
4153
  orderByClauseAsXpr($,$next){
4153
4154
  let args=[]
4154
- this.rule_(745,$next)
4155
+ this.rule_(743,$next)
4155
4156
  for(;;)switch(this.s){
4156
- case 745:this.orderBySpecAsXpr({args},746);continue
4157
- case 746:switch(this.l()){
4158
- case',':if(this.c(747)){ this.pushXprToken( args ); }continue
4157
+ case 743:this.orderBySpecAsXpr({args},744);continue
4158
+ case 744:switch(this.l()){
4159
+ case',':if(this.c(745)){ this.pushXprToken( args ); }continue
4159
4160
  default:this.gr([')']);continue
4160
4161
  }
4161
- case 747:this.orderBySpecAsXpr({args},746);continue
4162
+ case 745:this.orderBySpecAsXpr({args},744);continue
4162
4163
  default:
4163
4164
  $.outer.push( this.ixprAst( args ) )
4164
4165
  return this.exit_()
@@ -4166,18 +4167,18 @@ return this.exit_()
4166
4167
  }
4167
4168
  orderBySpecAsXpr($,$next){
4168
4169
  let expr;let _
4169
- this.rule_(749,$next)
4170
+ this.rule_(747,$next)
4170
4171
  for(;;)switch(this.s){
4171
- case 749:if(this.expression(_={},750)){expr=_.expr; $.args.push( expr ); }continue
4172
- case 750:switch(this.lk()){
4173
- case'asc':case'desc':if(this.ck(751)){ this.pushXprToken( $.args ); }continue
4174
- default:this.s=751;continue
4172
+ case 747:if(this.expression(_={},748)){expr=_.expr; $.args.push( expr ); }continue
4173
+ case 748:switch(this.lk()){
4174
+ case'asc':case'desc':if(this.ck(749)){ this.pushXprToken( $.args ); }continue
4175
+ default:this.s=749;continue
4175
4176
  }
4176
- case 751:switch(this.lk()){
4177
- case'nulls':if(this.ck(752)){ this.pushXprToken( $.args ); }continue
4177
+ case 749:switch(this.lk()){
4178
+ case'nulls':if(this.ck(750)){ this.pushXprToken( $.args ); }continue
4178
4179
  default:this.gr([')',',']);continue
4179
4180
  }
4180
- case 752:switch(this.lk()){
4181
+ case 750:switch(this.lk()){
4181
4182
  case'last':case'first':if(this.ck(0)){ this.pushXprToken( $.args ); }continue
4182
4183
  default:this.e();continue
4183
4184
  }
@@ -4186,50 +4187,50 @@ default:return this.exit_()
4186
4187
  }
4187
4188
  windowFrameClause($,$next){
4188
4189
  let args=[]
4189
- this.rule_(754,$next)
4190
+ this.rule_(752,$next)
4190
4191
  for(;;)switch(this.s){
4191
- case 754:switch(this.lk()){
4192
- case'unbounded':if(this.ck(755)){ this.pushXprToken( args ); }continue
4193
- case'Number':if(this.c(755)){ args.push( this.unsignedIntegerLiteral() ); }continue
4194
- case'current':if(this.ck(756)){ this.pushXprToken( args ); }continue
4195
- case'between':if(this.ck(757)){ this.pushXprToken( args ); }continue
4192
+ case 752:switch(this.lk()){
4193
+ case'unbounded':if(this.ck(753)){ this.pushXprToken( args ); }continue
4194
+ case'Number':if(this.c(753)){ args.push( this.unsignedIntegerLiteral() ); }continue
4195
+ case'current':if(this.ck(754)){ this.pushXprToken( args ); }continue
4196
+ case'between':if(this.ck(755)){ this.pushXprToken( args ); }continue
4196
4197
  default:this.e();continue
4197
4198
  }
4198
- case 755:if(this.mk(0,'preceding')){ this.pushXprToken( args ); }continue
4199
- case 756:if(this.mk(0,'row')){ this.pushXprToken( args ); }continue
4200
- case 757:this.windowFrameBoundSpec({args},758);continue
4201
- case 758:if(this.mk(759,'and')){ this.pushXprToken( args ); }continue
4202
- case 759:this.windowFrameBoundSpec({args},0);continue
4199
+ case 753:if(this.mk(0,'preceding')){ this.pushXprToken( args ); }continue
4200
+ case 754:if(this.mk(0,'row')){ this.pushXprToken( args ); }continue
4201
+ case 755:this.windowFrameBoundSpec({args},756);continue
4202
+ case 756:if(this.mk(757,'and')){ this.pushXprToken( args ); }continue
4203
+ case 757:this.windowFrameBoundSpec({args},0);continue
4203
4204
  default:
4204
4205
  $.outer.push( this.ixprAst( args ) )
4205
4206
  return this.exit_()
4206
4207
  }
4207
4208
  }
4208
4209
  windowFrameBoundSpec($,$next){
4209
- this.rule_(761,$next)
4210
+ this.rule_(759,$next)
4210
4211
  for(;;)switch(this.s){
4211
- case 761:switch(this.lk()){
4212
- case'unbounded':if(this.ck(762)){ this.pushXprToken( $.args ); }continue
4213
- case'Number':if(this.c(762)){ $.args.push( this.unsignedIntegerLiteral() ); }continue
4214
- case'current':if(this.ck(764)){ this.pushXprToken( $.args ); }continue
4212
+ case 759:switch(this.lk()){
4213
+ case'unbounded':if(this.ck(760)){ this.pushXprToken( $.args ); }continue
4214
+ case'Number':if(this.c(760)){ $.args.push( this.unsignedIntegerLiteral() ); }continue
4215
+ case'current':if(this.ck(762)){ this.pushXprToken( $.args ); }continue
4215
4216
  default:this.e();continue
4216
4217
  }
4217
- case 762:switch(this.lk()){
4218
- case'following':this.ck(763);continue
4219
- case'preceding':this.ck(763);continue
4218
+ case 760:switch(this.lk()){
4219
+ case'following':this.ck(761);continue
4220
+ case'preceding':this.ck(761);continue
4220
4221
  default:this.e();continue
4221
4222
  }
4222
- case 763:if(this.gr()){ this.pushXprToken( $.args ); }continue
4223
- case 764:if(this.mk(0,'row')){ this.pushXprToken( $.args ); }continue
4223
+ case 761:if(this.gr()){ this.pushXprToken( $.args ); }continue
4224
+ case 762:if(this.mk(0,'row')){ this.pushXprToken( $.args ); }continue
4224
4225
  default:return this.exit_()
4225
4226
  }
4226
4227
  }
4227
4228
  literalValue($,$next){
4228
4229
  $.expr??={}
4229
- this.rule_(766,$next)
4230
+ this.rule_(764,$next)
4230
4231
  for(;;)switch(this.s){
4231
- case 766:switch(this.lk()){
4232
- case'#':if(this.c(767)){ this.reportUnexpectedSpace(); }continue
4232
+ case 764:switch(this.lk()){
4233
+ case'#':if(this.c(765)){ this.reportUnexpectedSpace(); }continue
4233
4234
  case'null':if(this.ck(0)){ $.expr = { literal: 'null', val: null }; }continue
4234
4235
  case'true':case'false':if(this.ck(0)){ $.expr = { literal: 'boolean', val: this.lb().keyword === 'true' }; }continue
4235
4236
  case'Number':if(this.c(0)){ $.expr = this.numberLiteral(); }continue
@@ -4237,17 +4238,17 @@ case'String':if(this.c(0)){ $.expr = this.quotedLiteral(); }continue
4237
4238
  case'QuotedLiteral':if(this.c(0)){ $.expr = this.quotedLiteral(); }continue
4238
4239
  default:this.e();continue
4239
4240
  }
4240
- case 767:if(this.miA(0,'enumref')){ $.expr = { literal: 'enum', sym: this.identAst() } }continue
4241
+ case 765:if(this.miA(0,'enumref')){ $.expr = { literal: 'enum', sym: this.identAst() } }continue
4241
4242
  default:
4242
4243
  this.attachLocation( $.expr )
4243
4244
  return this.exit_()
4244
4245
  }
4245
4246
  }
4246
4247
  annoAssignStd($,$next){
4247
- this.rule_(769,$next)
4248
+ this.rule_(767,$next)
4248
4249
  for(;;)switch(this.s){
4249
- case 769:if(this.m(770,'@')){this.annoInSameLine(); this.reportDubiousAnnoSpacing(); }continue
4250
- case 770:switch(this.l()){
4250
+ case 767:if(this.m(768,'@')){this.annoInSameLine(); this.reportDubiousAnnoSpacing(); }continue
4251
+ case 768:switch(this.l()){
4251
4252
  case'(':this.annoAssignParen($,0);continue
4252
4253
  case'Id':this.annoAssignBase($,0);continue
4253
4254
  default:this.e();continue
@@ -4258,10 +4259,10 @@ return this.exit_()
4258
4259
  }
4259
4260
  }
4260
4261
  annoAssignCol($,$next){
4261
- this.rule_(772,$next)
4262
+ this.rule_(770,$next)
4262
4263
  for(;;)switch(this.s){
4263
- case 772:if(this.m(773,'@')){ this.reportDubiousAnnoSpacing(); }continue
4264
- case 773:switch(this.l()){
4264
+ case 770:if(this.m(771,'@')){ this.reportDubiousAnnoSpacing(); }continue
4265
+ case 771:switch(this.l()){
4265
4266
  case'(':this.annoAssignParen($,0);continue
4266
4267
  case'Id':this.annoAssignBase($,0);continue
4267
4268
  default:this.e();continue
@@ -4273,10 +4274,10 @@ return this.exit_()
4273
4274
  }
4274
4275
  annoAssignMid($,$next){
4275
4276
  let name;let _
4276
- this.rule_(775,$next)
4277
+ this.rule_(773,$next)
4277
4278
  for(;;)switch(this.s){
4278
- case 775:if(this.m(776,'@')){this.annoInSameLine(); this.reportDubiousAnnoSpacing(); }continue
4279
- case 776:switch(this.l()){
4279
+ case 773:if(this.m(774,'@')){this.annoInSameLine(); this.reportDubiousAnnoSpacing(); }continue
4280
+ case 774:switch(this.l()){
4280
4281
  case'(':this.annoAssignParen($,0);continue
4281
4282
  case'Id':if(this.annoNamePath(_={category:'anno'},0)){name=_.name; this.assignAnnotation( $.art, {}, name ); this.warnIfColonFollows( name ); }continue
4282
4283
  default:this.e();continue
@@ -4287,33 +4288,33 @@ return this.exit_()
4287
4288
  }
4288
4289
  }
4289
4290
  annoAssignParen($,$next){
4290
- this.rule_(778,$next)
4291
+ this.rule_(776,$next)
4291
4292
  for(;;)switch(this.s){
4292
- case 778:if(this.m(779,'(')){this.annoInSameLine()}continue;
4293
- case 779:switch(this.l()){
4294
- case'Id':this.annoAssignBase({art:$.art},780);continue
4295
- default:this.s=781;continue
4296
- }
4297
- case 780:switch(this.l()){
4298
- case',':this.c(779);continue
4299
- case')':this.s=781;continue
4293
+ case 776:if(this.m(777,'(')){this.annoInSameLine()}continue;
4294
+ case 777:switch(this.l()){
4295
+ case'Id':this.annoAssignBase({art:$.art},778);continue
4296
+ default:this.s=779;continue
4297
+ }
4298
+ case 778:switch(this.l()){
4299
+ case',':this.c(777);continue
4300
+ case')':this.s=779;continue
4300
4301
  default:this.e();continue
4301
4302
  }
4302
- case 781:this.m(0,')');continue
4303
+ case 779:this.m(0,')');continue
4303
4304
  default:return this.exit_()
4304
4305
  }
4305
4306
  }
4306
4307
  annoAssignBase($,$next){
4307
4308
  let value={}
4308
4309
  let name;let _
4309
- this.rule_(783,$next)
4310
+ this.rule_(781,$next)
4310
4311
  for(;;)switch(this.s){
4311
- case 783:if(this.annoNamePath(_={category:'anno'},784))name=_.name;continue
4312
- case 784:switch(this.l()){
4313
- case':':this.gc(0,'annoInSameLine')&&this.c(785);continue
4312
+ case 781:if(this.annoNamePath(_={category:'anno'},782))name=_.name;continue
4313
+ case 782:switch(this.l()){
4314
+ case':':this.gc(0,'annoInSameLine')&&this.c(783);continue
4314
4315
  default:this.gr();continue
4315
4316
  }
4316
- case 785:if(this.annoValue(_={},0))value=_.value;continue
4317
+ case 783:if(this.annoValue(_={},0))value=_.value;continue
4317
4318
  default:
4318
4319
  this.assignAnnotation( $.art, value, name || {} )
4319
4320
  return this.exit_()
@@ -4322,20 +4323,20 @@ return this.exit_()
4322
4323
  annoNamePath($,$next){
4323
4324
  $.name??=new XsnName()
4324
4325
  let at
4325
- this.rule_(787,$next)
4326
+ this.rule_(785,$next)
4326
4327
  for(;;)switch(this.s){
4327
- case 787:if(this.miA(788,$.category)){ $.name.path = [ this.identAst() ]; }continue
4328
- case 788:switch(this.l()){
4329
- case'.':this.c(789);continue
4330
- default:this.s=791;continue
4331
- }
4332
- case 789:switch(this.l()){
4333
- case'Id':if(this.ciA(788,$.category)){ $.name.path.push( this.identAst() ); }continue
4334
- case'@':if(this.c(790))at=this.lb();continue
4328
+ case 785:if(this.miA(786,$.category)){ $.name.path = [ this.identAst() ]; }continue
4329
+ case 786:switch(this.l()){
4330
+ case'.':this.c(787);continue
4331
+ default:this.s=789;continue
4332
+ }
4333
+ case 787:switch(this.l()){
4334
+ case'Id':if(this.ciA(786,$.category)){ $.name.path.push( this.identAst() ); }continue
4335
+ case'@':if(this.c(788))at=this.lb();continue
4335
4336
  default:this.e();continue
4336
4337
  }
4337
- case 790:if(this.miA(788,$.category)){ $.name.path.push( this.identAstWithPrefix( at ) ); }continue
4338
- case 791:switch(this.l()){
4338
+ case 788:if(this.miA(786,$.category)){ $.name.path.push( this.identAstWithPrefix( at ) ); }continue
4339
+ case 789:switch(this.l()){
4339
4340
  case'#':this.gc(0,'annoInSameLine')&&this.annoPathVariant({nameOrRef:$.name},0);continue
4340
4341
  default:this.gr();continue
4341
4342
  }
@@ -4346,25 +4347,25 @@ return this.exit_()
4346
4347
  }
4347
4348
  annoPath($,$next){
4348
4349
  let at
4349
- this.rule_(793,$next)
4350
+ this.rule_(791,$next)
4350
4351
  for(;;)switch(this.s){
4351
- case 793:switch(this.l()){
4352
- case'Id':if(this.ciA(795,$.category)){ $.nameOrRef.path = [ this.identAst() ]; }continue
4353
- case'@':if(this.c(794))at=this.lb();continue
4352
+ case 791:switch(this.l()){
4353
+ case'Id':if(this.ciA(793,$.category)){ $.nameOrRef.path = [ this.identAst() ]; }continue
4354
+ case'@':if(this.c(792))at=this.lb();continue
4354
4355
  default:this.e();continue
4355
4356
  }
4356
- case 794:if(this.miA(795,$.category)){ $.nameOrRef.path = [ this.identAstWithPrefix( at ) ]; }continue
4357
- case 795:switch(this.l()){
4358
- case'.':this.c(796);continue
4359
- default:this.s=798;continue
4357
+ case 792:if(this.miA(793,$.category)){ $.nameOrRef.path = [ this.identAstWithPrefix( at ) ]; }continue
4358
+ case 793:switch(this.l()){
4359
+ case'.':this.c(794);continue
4360
+ default:this.s=796;continue
4360
4361
  }
4361
- case 796:switch(this.l()){
4362
- case'Id':if(this.ciA(795,$.category)){ $.nameOrRef.path.push( this.identAst() ); }continue
4363
- case'@':if(this.c(797))at=this.lb();continue
4362
+ case 794:switch(this.l()){
4363
+ case'Id':if(this.ciA(793,$.category)){ $.nameOrRef.path.push( this.identAst() ); }continue
4364
+ case'@':if(this.c(795))at=this.lb();continue
4364
4365
  default:this.e();continue
4365
4366
  }
4366
- case 797:if(this.miA(795,$.category)){ $.nameOrRef.path.push( this.identAstWithPrefix( at ) ); }continue
4367
- case 798:switch(this.l()){
4367
+ case 795:if(this.miA(793,$.category)){ $.nameOrRef.path.push( this.identAstWithPrefix( at ) ); }continue
4368
+ case 796:switch(this.l()){
4368
4369
  case'#':this.annoPathVariant({nameOrRef:$.nameOrRef},0);continue
4369
4370
  default:this.gr();continue
4370
4371
  }
@@ -4374,15 +4375,15 @@ return this.exit_()
4374
4375
  }
4375
4376
  }
4376
4377
  annoPathVariant($,$next){
4377
- this.rule_(800,$next)
4378
+ this.rule_(798,$next)
4378
4379
  for(;;)switch(this.s){
4379
- case 800:if(this.m(801,'#')){ this.reportUnexpectedSpace(); }continue
4380
- case 801:if(this.miA(802,'variant')){ $.nameOrRef.variant = { path: [ this.identAst() ] }; }continue
4381
- case 802:switch(this.l()){
4382
- case'.':this.c(803);continue
4380
+ case 798:if(this.m(799,'#')){ this.reportUnexpectedSpace(); }continue
4381
+ case 799:if(this.miA(800,'variant')){ $.nameOrRef.variant = { path: [ this.identAst() ] }; }continue
4382
+ case 800:switch(this.l()){
4383
+ case'.':this.c(801);continue
4383
4384
  default:this.gr();continue
4384
4385
  }
4385
- case 803:if(this.miA(802,'variant')){ $.nameOrRef.variant.path.push( this.identAst() ); }continue
4386
+ case 801:if(this.miA(800,'variant')){ $.nameOrRef.variant.path.push( this.identAst() ); }continue
4386
4387
  default:
4387
4388
  this.attachLocation( $.nameOrRef.variant )
4388
4389
  return this.exit_()
@@ -4392,14 +4393,14 @@ annoStructValue($,$next){
4392
4393
  $.value??={}
4393
4394
  let name=new XsnName()
4394
4395
  let _
4395
- this.rule_(805,$next)
4396
+ this.rule_(803,$next)
4396
4397
  for(;;)switch(this.s){
4397
- case 805:if(this.annoPath({nameOrRef:name,category:'name'},806)){ this.attachLocation( name ); }continue
4398
- case 806:switch(this.l()){
4399
- case':':this.c(807);continue
4398
+ case 803:if(this.annoPath({nameOrRef:name,category:'name'},804)){ this.attachLocation( name ); }continue
4399
+ case 804:switch(this.l()){
4400
+ case':':this.c(805);continue
4400
4401
  default:if(this.gr(['Id',',','@','}'])){ this.attachLocation( $.value ); }continue
4401
4402
  }
4402
- case 807:if(this.annoValue(_={},0))$.value=_.value;continue
4403
+ case 805:if(this.annoValue(_={},0))$.value=_.value;continue
4403
4404
  default:
4404
4405
  $.value.name = name
4405
4406
  return this.exit_()
@@ -4408,55 +4409,55 @@ return this.exit_()
4408
4409
  annoValue($,$next){
4409
4410
  $.value??={}
4410
4411
  let sign;let sub;let ellipsis;let upTo;let _
4411
- this.rule_(809,$next)
4412
+ this.rule_(807,$next)
4412
4413
  for(;;)switch(this.s){
4413
- case 809:switch(this.lk()){
4414
+ case 807:switch(this.lk()){
4414
4415
  case'#':case'null':case'true':case'false':case'Number':case'String':case'QuotedLiteral':if(this.literalValue(_={},0)){$.value=_.expr; this.adjustAnnoNumber( $.value ); }continue
4415
- case'+':case'-':if(this.c(810))sign=this.lb();continue
4416
+ case'+':case'-':if(this.c(808))sign=this.lb();continue
4416
4417
  case'Id':case'@':this.annoPath({nameOrRef:$.value,category:'annoref'},0);continue
4417
- case'{':if(this.c(811)){ if (!this.dynamic_.arrayAnno) $.value.$flatten = [];
4418
+ case'{':if(this.c(809)){ if (!this.dynamic_.arrayAnno) $.value.$flatten = [];
4418
4419
  else { $.value.struct = Object.create(null); $.value.literal = 'struct'; } }continue
4419
- case'[':if(this.c(814)){this.arrayAnno(); $.value.val = []; $.value.literal = 'array' }continue
4420
- case'(':this.c(820);continue
4420
+ case'[':if(this.c(812)){this.arrayAnno(); $.value.val = []; $.value.literal = 'array' }continue
4421
+ case'(':this.c(818);continue
4421
4422
  default:this.ei();continue
4422
4423
  }
4423
- case 810:if(this.m(0,'Number')){ this.adjustAnnoNumber( $.value = this.numberLiteral( sign ) ); }continue
4424
- case 811:switch(this.l()){
4425
- case'Id':case'@':if(this.annoStructValue(_={},812)){sub=_.value; if ($.value.$flatten) $.value.$flatten.push( sub );
4424
+ case 808:if(this.m(0,'Number')){ this.adjustAnnoNumber( $.value = this.numberLiteral( sign ) ); }continue
4425
+ case 809:switch(this.l()){
4426
+ case'Id':case'@':if(this.annoStructValue(_={},810)){sub=_.value; if ($.value.$flatten) $.value.$flatten.push( sub );
4426
4427
  else this.addDef( sub, $.value, 'struct', null, sub.name ); }continue
4427
- default:this.s=813;continue
4428
+ default:this.s=811;continue
4428
4429
  }
4429
- case 812:switch(this.lk()){
4430
- case',':this.c(811);continue
4431
- case'}':this.s=813;continue
4432
- case'Id':case'@':this.ec('fail')&&this.g(811);continue
4430
+ case 810:switch(this.lk()){
4431
+ case',':this.c(809);continue
4432
+ case'}':this.s=811;continue
4433
+ case'Id':case'@':this.ec('fail')&&this.g(809);continue
4433
4434
  default:this.ei();continue
4434
4435
  }
4435
- case 813:this.ec('arrayAnno','orNotEmpty')&&this.m(0,'}');continue
4436
- case 814:switch(this.l()){
4437
- case'Id':case'#':case'(':case'+':case'-':case'@':case'[':case'{':case'Number':case'String':case'QuotedLiteral':if(this.annoValue(_={},818)){sub=_.value; $.value.val.push( sub ) }continue
4438
- case'...':if(this.gc(819,'arrayAnno','ellipsis')&&this.c(815))ellipsis=this.lb();continue
4439
- default:this.s=819;continue
4436
+ case 811:this.ec('arrayAnno','orNotEmpty')&&this.m(0,'}');continue
4437
+ case 812:switch(this.l()){
4438
+ case'Id':case'#':case'(':case'+':case'-':case'@':case'[':case'{':case'Number':case'String':case'QuotedLiteral':if(this.annoValue(_={},816)){sub=_.value; $.value.val.push( sub ) }continue
4439
+ case'...':if(this.gc(817,'arrayAnno','ellipsis')&&this.c(813))ellipsis=this.lb();continue
4440
+ default:this.s=817;continue
4440
4441
  }
4441
- case 815:switch(this.lk()){
4442
- case'up':this.ck(816);continue
4443
- case',':case']':this.s=818;{ $.value.val.push( { literal: 'token', val: '...', location: ellipsis.location } ); }continue
4442
+ case 813:switch(this.lk()){
4443
+ case'up':this.ck(814);continue
4444
+ case',':case']':this.s=816;{ $.value.val.push( { literal: 'token', val: '...', location: ellipsis.location } ); }continue
4444
4445
  default:this.e();continue
4445
4446
  }
4446
- case 816:this.mk(817,'to');continue
4447
- case 817:if(this.annoValue(_={},818)){upTo=_.value; $.value.val.push( { literal: 'token', val: '...', location: ellipsis.location, upTo: upTo } ); }continue
4448
- case 818:switch(this.l()){
4449
- case',':this.c(814);continue
4450
- case']':this.s=819;continue
4447
+ case 814:this.mk(815,'to');continue
4448
+ case 815:if(this.annoValue(_={},816)){upTo=_.value; $.value.val.push( { literal: 'token', val: '...', location: ellipsis.location, upTo: upTo } ); }continue
4449
+ case 816:switch(this.l()){
4450
+ case',':this.c(812);continue
4451
+ case']':this.s=817;continue
4451
4452
  default:this.e();continue
4452
4453
  }
4453
- case 819:this.ec('arrayAnno','bracket')&&this.m(0,']');continue
4454
- case 820:switch(this.l()){
4455
- case')':this.gc(821,'fail')&&this.c(0);continue
4456
- default:this.s=821;continue
4454
+ case 817:this.ec('arrayAnno','bracket')&&this.m(0,']');continue
4455
+ case 818:switch(this.l()){
4456
+ case')':this.gc(819,'fail')&&this.c(0);continue
4457
+ default:this.s=819;continue
4457
4458
  }
4458
- case 821:if(this.condition(_={},822)){$.value=_.expr; $.value.$tokenTexts = this.ruleTokensText(); }continue
4459
- case 822:this.m(0,')');continue
4459
+ case 819:if(this.condition(_={},820)){$.value=_.expr; $.value.$tokenTexts = this.ruleTokensText(); }continue
4460
+ case 820:this.m(0,')');continue
4460
4461
  default:
4461
4462
  this.attachLocation( $.value )
4462
4463
  return this.exit_()