-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathParser.cs
707 lines (693 loc) · 57.4 KB
/
Parser.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
// This code was generated by the Gardens Point Parser Generator
// Copyright (c) Wayne Kelly, QUT 2005-2010
// (see accompanying GPPGcopyright.rtf)
// GPPG version 1.4.0
// Machine: VOSTRO
// DateTime: 4/7/2012 2:05:22 PM
// UserName: Tim
// Input file <..\GeneratorInputFiles\tranche.y>
// options: no-lines gplex
using System;
using System.Collections.Generic;
using System.Globalization;
using System.Text;
using QUT.Gppg;
using LexicalAnalysis;
using AbstractSyntaxTree;
using AbstractSyntaxTree.InternalTypes;
using tc;
namespace SyntaxAnalysis
{
internal enum Tokens {
error=1,EOF=2,SETTINGS=3,DEAL=4,COLLATERAL=5,COLLATERALITEM=6,
SECURITIES=7,BOND=8,CREDITPAYMENTRULES=9,INTEREST=10,PRINCIPAL=11,SIMULATION=12,
RULES=13,UPTO=14,DOWNTO=15,TRUE=16,FALSE=17,AND=18,
OR=19,WHERE=20,AGGREGATE=21,FILTER=22,FIRST=23,LAST=24,
WITH=25,RULE=26,PLUS=27,MINUS=28,TIMES=29,DIVIDE=30,
SMALLER=31,GREATER=32,SMEQ=33,GTEQ=34,EQ=35,NEQ=36,
ASSIGN=37,NOT=38,MOD=39,LPAREN=40,RPAREN=41,LBRACE=42,
RBRACE=43,LBRACKET=44,RBRACKET=45,PBRACKET=46,INCREMENT=47,DECREMENT=48,
EXP=49,DOT=50,COMMA=51,CONS=52,ATPLUS=53,ATMINUS=54,
ATTIMES=55,ATDIV=56,ATMOD=57,ATEXP=58,PIPE=59,LITERAL_INT=60,
LITERAL_REAL=61,LITERAL_STRING=62,IDENTIFIER=63,PLUSDAY=64,MINUSDAY=65,PLUSMONTH=66,
MINUSMONTH=67,PLUSYEAR=68,MINUSYEAR=69,CONCAT=70};
// Abstract base class for GPLEX scanners
internal abstract class ScanBase : AbstractScanner<SemanticValue,LexLocation> {
private LexLocation __yylloc = new LexLocation();
public override LexLocation yylloc { get { return __yylloc; } set { __yylloc = value; } }
protected virtual bool yywrap() { return true; }
}
internal class Parser: ShiftReduceParser<SemanticValue, LexLocation>
{
#pragma warning disable 649
private static Dictionary<int, string> aliasses;
#pragma warning restore 649
private static Rule[] rules = new Rule[96];
private static State[] states = new State[228];
private static string[] nonTerms = new string[] {
"program", "statementList", "statement", "loop", "instantiation", "expression",
"literal", "compExpression", "lvalue", "arithmetic", "concat", "onePlusActuals",
"actuals", "boolListOpt", "specialFunction", "settingsOpt", "dealOpt",
"collatSection", "securitySection", "simSection", "secListOpt", "creditRulesOpt",
"rulesListOpt", "collListOpt", "interestRules", "principalRules", "$accept",
};
static Parser() {
states[0] = new State(new int[]{3,224,4,-3,5,-3},new int[]{-1,1,-16,3});
states[1] = new State(new int[]{2,2});
states[2] = new State(-1);
states[3] = new State(new int[]{4,220,5,-5},new int[]{-17,4});
states[4] = new State(new int[]{5,211},new int[]{-18,5});
states[5] = new State(new int[]{7,202},new int[]{-19,6});
states[6] = new State(new int[]{9,178,12,-9},new int[]{-22,7});
states[7] = new State(new int[]{12,9},new int[]{-20,8});
states[8] = new State(-2);
states[9] = new State(new int[]{42,10});
states[10] = new State(new int[]{63,15,42,132,44,136,60,74,61,75,62,76,16,77,17,78,43,-21},new int[]{-2,11,-3,13,-4,135,-6,146,-9,64,-7,70,-8,79,-10,80,-11,81});
states[11] = new State(new int[]{43,12});
states[12] = new State(-11);
states[13] = new State(new int[]{63,15,42,132,44,136,60,74,61,75,62,76,16,77,17,78,43,-21,45,-21,41,-21},new int[]{-2,14,-3,13,-4,135,-6,146,-9,64,-7,70,-8,79,-10,80,-11,81});
states[14] = new State(-22);
states[15] = new State(new int[]{37,16,40,57,70,107,52,172,50,-59,64,-59,65,-59,66,-59,67,-59,68,-59,69,-59,35,-59,27,-59,28,-59,29,-59,30,-59,39,-59,49,-59,53,-59,54,-59,55,-59,56,-59,57,-59,58,-59,47,-59,48,-59,36,-59,33,-59,34,-59,32,-59,31,-59,63,-59,42,-59,44,-59,60,-59,61,-59,62,-59,16,-59,17,-59,43,-59,45,-59,41,-59});
states[16] = new State(new int[]{40,111,63,56,60,74,61,75,62,76,16,77,17,78,31,115,44,120,22,159,21,165,59,168},new int[]{-6,17,-5,110,-9,64,-7,70,-8,79,-10,80,-11,81,-4,171});
states[17] = new State(new int[]{35,18,27,20,28,22,29,24,30,26,39,28,49,30,53,32,54,34,55,36,56,38,57,40,58,42,47,44,48,45,36,46,33,48,34,50,32,52,31,54,63,-23,42,-23,44,-23,60,-23,61,-23,62,-23,16,-23,17,-23,43,-23,45,-23,41,-23});
states[18] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,19,-9,64,-7,70,-8,79,-10,80,-11,81});
states[19] = new State(new int[]{35,-61,27,20,28,22,29,24,30,26,39,28,49,-61,53,32,54,34,55,36,56,38,57,40,58,42,47,-61,48,-61,36,-61,33,-61,34,-61,32,-61,31,-61,63,-61,42,-61,44,-61,60,-61,61,-61,62,-61,16,-61,17,-61,43,-61,45,-61,41,-61,51,-61,14,-61,15,-61,25,-61,59,-61,26,-61,19,-61,18,-61});
states[20] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,21,-9,64,-7,70,-8,79,-10,80,-11,81});
states[21] = new State(new int[]{35,-67,27,-67,28,-67,29,-67,30,-67,39,-67,49,-67,53,32,54,34,55,36,56,38,57,40,58,42,47,-67,48,-67,36,-67,33,-67,34,-67,32,-67,31,-67,63,-67,42,-67,44,-67,60,-67,61,-67,62,-67,16,-67,17,-67,43,-67,45,-67,41,-67,51,-67,14,-67,15,-67,25,-67,59,-67,26,-67,19,-67,18,-67});
states[22] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,23,-9,64,-7,70,-8,79,-10,80,-11,81});
states[23] = new State(new int[]{35,-68,27,-68,28,-68,29,-68,30,-68,39,-68,49,-68,53,32,54,34,55,36,56,38,57,40,58,42,47,-68,48,-68,36,-68,33,-68,34,-68,32,-68,31,-68,63,-68,42,-68,44,-68,60,-68,61,-68,62,-68,16,-68,17,-68,43,-68,45,-68,41,-68,51,-68,14,-68,15,-68,25,-68,59,-68,26,-68,19,-68,18,-68});
states[24] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,25,-9,64,-7,70,-8,79,-10,80,-11,81});
states[25] = new State(new int[]{35,-69,27,-69,28,-69,29,-69,30,-69,39,-69,49,-69,53,32,54,34,55,36,56,38,57,40,58,42,47,-69,48,-69,36,-69,33,-69,34,-69,32,-69,31,-69,63,-69,42,-69,44,-69,60,-69,61,-69,62,-69,16,-69,17,-69,43,-69,45,-69,41,-69,51,-69,14,-69,15,-69,25,-69,59,-69,26,-69,19,-69,18,-69});
states[26] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,27,-9,64,-7,70,-8,79,-10,80,-11,81});
states[27] = new State(new int[]{35,-70,27,-70,28,-70,29,-70,30,-70,39,-70,49,-70,53,32,54,34,55,36,56,38,57,40,58,42,47,-70,48,-70,36,-70,33,-70,34,-70,32,-70,31,-70,63,-70,42,-70,44,-70,60,-70,61,-70,62,-70,16,-70,17,-70,43,-70,45,-70,41,-70,51,-70,14,-70,15,-70,25,-70,59,-70,26,-70,19,-70,18,-70});
states[28] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,29,-9,64,-7,70,-8,79,-10,80,-11,81});
states[29] = new State(new int[]{35,-71,27,-71,28,-71,29,-71,30,-71,39,-71,49,-71,53,32,54,34,55,36,56,38,57,40,58,42,47,-71,48,-71,36,-71,33,-71,34,-71,32,-71,31,-71,63,-71,42,-71,44,-71,60,-71,61,-71,62,-71,16,-71,17,-71,43,-71,45,-71,41,-71,51,-71,14,-71,15,-71,25,-71,59,-71,26,-71,19,-71,18,-71});
states[30] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,31,-9,64,-7,70,-8,79,-10,80,-11,81});
states[31] = new State(new int[]{35,18,27,20,28,22,29,24,30,26,39,28,49,-72,53,32,54,34,55,36,56,38,57,40,58,42,47,-72,48,-72,36,46,33,48,34,50,32,52,31,54,63,-72,42,-72,44,-72,60,-72,61,-72,62,-72,16,-72,17,-72,43,-72,45,-72,41,-72,51,-72,14,-72,15,-72,25,-72,59,-72,26,-72,19,-72,18,-72});
states[32] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,33,-9,64,-7,70,-8,79,-10,80,-11,81});
states[33] = new State(-73);
states[34] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,35,-9,64,-7,70,-8,79,-10,80,-11,81});
states[35] = new State(-74);
states[36] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,37,-9,64,-7,70,-8,79,-10,80,-11,81});
states[37] = new State(-75);
states[38] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,39,-9,64,-7,70,-8,79,-10,80,-11,81});
states[39] = new State(-76);
states[40] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,41,-9,64,-7,70,-8,79,-10,80,-11,81});
states[41] = new State(-77);
states[42] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,43,-9,64,-7,70,-8,79,-10,80,-11,81});
states[43] = new State(-78);
states[44] = new State(-79);
states[45] = new State(-80);
states[46] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,47,-9,64,-7,70,-8,79,-10,80,-11,81});
states[47] = new State(new int[]{35,-62,27,20,28,22,29,24,30,26,39,28,49,-62,53,32,54,34,55,36,56,38,57,40,58,42,47,-62,48,-62,36,-62,33,-62,34,-62,32,-62,31,-62,63,-62,42,-62,44,-62,60,-62,61,-62,62,-62,16,-62,17,-62,43,-62,45,-62,41,-62,51,-62,14,-62,15,-62,25,-62,59,-62,26,-62,19,-62,18,-62});
states[48] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,49,-9,64,-7,70,-8,79,-10,80,-11,81});
states[49] = new State(new int[]{35,-63,27,20,28,22,29,24,30,26,39,28,49,-63,53,32,54,34,55,36,56,38,57,40,58,42,47,-63,48,-63,36,-63,33,-63,34,-63,32,-63,31,-63,63,-63,42,-63,44,-63,60,-63,61,-63,62,-63,16,-63,17,-63,43,-63,45,-63,41,-63,51,-63,14,-63,15,-63,25,-63,59,-63,26,-63,19,-63,18,-63});
states[50] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,51,-9,64,-7,70,-8,79,-10,80,-11,81});
states[51] = new State(new int[]{35,-64,27,20,28,22,29,24,30,26,39,28,49,-64,53,32,54,34,55,36,56,38,57,40,58,42,47,-64,48,-64,36,-64,33,-64,34,-64,32,-64,31,-64,63,-64,42,-64,44,-64,60,-64,61,-64,62,-64,16,-64,17,-64,43,-64,45,-64,41,-64,51,-64,14,-64,15,-64,25,-64,59,-64,26,-64,19,-64,18,-64});
states[52] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,53,-9,64,-7,70,-8,79,-10,80,-11,81});
states[53] = new State(new int[]{35,-65,27,20,28,22,29,24,30,26,39,28,49,-65,53,32,54,34,55,36,56,38,57,40,58,42,47,-65,48,-65,36,-65,33,-65,34,-65,32,-65,31,-65,63,-65,42,-65,44,-65,60,-65,61,-65,62,-65,16,-65,17,-65,43,-65,45,-65,41,-65,51,-65,14,-65,15,-65,25,-65,59,-65,26,-65,19,-65,18,-65});
states[54] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,55,-9,64,-7,70,-8,79,-10,80,-11,81});
states[55] = new State(new int[]{35,-66,27,20,28,22,29,24,30,26,39,28,49,-66,53,32,54,34,55,36,56,38,57,40,58,42,47,-66,48,-66,36,-66,33,-66,34,-66,32,-66,31,-66,63,-66,42,-66,44,-66,60,-66,61,-66,62,-66,16,-66,17,-66,43,-66,45,-66,41,-66,51,-66,14,-66,15,-66,25,-66,59,-66,26,-66,19,-66,18,-66});
states[56] = new State(new int[]{40,57,70,107,50,-59,64,-59,65,-59,66,-59,67,-59,68,-59,69,-59,35,-59,27,-59,28,-59,29,-59,30,-59,39,-59,49,-59,53,-59,54,-59,55,-59,56,-59,57,-59,58,-59,47,-59,48,-59,36,-59,33,-59,34,-59,32,-59,31,-59,63,-59,42,-59,44,-59,60,-59,61,-59,62,-59,16,-59,17,-59,43,-59,45,-59,41,-59,51,-59,14,-59,15,-59,25,-59,59,-59,26,-59,19,-59,18,-59});
states[57] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78,41,-87},new int[]{-13,58,-12,60,-6,61,-9,64,-7,70,-8,79,-10,80,-11,81});
states[58] = new State(new int[]{41,59});
states[59] = new State(-35);
states[60] = new State(-88);
states[61] = new State(new int[]{35,18,27,20,28,22,29,24,30,26,39,28,49,30,53,32,54,34,55,36,56,38,57,40,58,42,47,44,48,45,36,46,33,48,34,50,32,52,31,54,51,62,41,-89});
states[62] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78,41,-87},new int[]{-13,63,-12,60,-6,61,-9,64,-7,70,-8,79,-10,80,-11,81});
states[63] = new State(-90);
states[64] = new State(new int[]{50,65,64,83,65,87,66,91,67,95,68,99,69,103,35,-39,27,-39,28,-39,29,-39,30,-39,39,-39,49,-39,53,-39,54,-39,55,-39,56,-39,57,-39,58,-39,47,-39,48,-39,36,-39,33,-39,34,-39,32,-39,31,-39,63,-39,42,-39,44,-39,60,-39,61,-39,62,-39,16,-39,17,-39,43,-39,45,-39,41,-39,51,-39,14,-39,15,-39,25,-39,59,-39,26,-39,19,-39,18,-39},new int[]{-15,82});
states[65] = new State(new int[]{63,66});
states[66] = new State(new int[]{40,67,50,-60,64,-60,65,-60,66,-60,67,-60,68,-60,69,-60,35,-60,27,-60,28,-60,29,-60,30,-60,39,-60,49,-60,53,-60,54,-60,55,-60,56,-60,57,-60,58,-60,47,-60,48,-60,36,-60,33,-60,34,-60,32,-60,31,-60,63,-60,42,-60,44,-60,60,-60,61,-60,62,-60,16,-60,17,-60,43,-60,45,-60,41,-60,51,-60,14,-60,15,-60,25,-60,59,-60,26,-60,19,-60,18,-60});
states[67] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78,41,-87},new int[]{-13,68,-12,60,-6,61,-9,64,-7,70,-8,79,-10,80,-11,81});
states[68] = new State(new int[]{41,69});
states[69] = new State(-36);
states[70] = new State(new int[]{70,71,35,-37,27,-37,28,-37,29,-37,30,-37,39,-37,49,-37,53,-37,54,-37,55,-37,56,-37,57,-37,58,-37,47,-37,48,-37,36,-37,33,-37,34,-37,32,-37,31,-37,63,-37,42,-37,44,-37,60,-37,61,-37,62,-37,16,-37,17,-37,43,-37,45,-37,41,-37,51,-37,14,-37,15,-37,25,-37,59,-37,26,-37,19,-37,18,-37});
states[71] = new State(new int[]{63,72,60,74,61,75,62,76,16,77,17,78},new int[]{-7,73});
states[72] = new State(-53);
states[73] = new State(-54);
states[74] = new State(-91);
states[75] = new State(-92);
states[76] = new State(-93);
states[77] = new State(-94);
states[78] = new State(-95);
states[79] = new State(-38);
states[80] = new State(-40);
states[81] = new State(-42);
states[82] = new State(-41);
states[83] = new State(new int[]{40,84});
states[84] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,85,-9,64,-7,70,-8,79,-10,80,-11,81});
states[85] = new State(new int[]{41,86,35,18,27,20,28,22,29,24,30,26,39,28,49,30,53,32,54,34,55,36,56,38,57,40,58,42,47,44,48,45,36,46,33,48,34,50,32,52,31,54});
states[86] = new State(-81);
states[87] = new State(new int[]{40,88});
states[88] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,89,-9,64,-7,70,-8,79,-10,80,-11,81});
states[89] = new State(new int[]{41,90,35,18,27,20,28,22,29,24,30,26,39,28,49,30,53,32,54,34,55,36,56,38,57,40,58,42,47,44,48,45,36,46,33,48,34,50,32,52,31,54});
states[90] = new State(-82);
states[91] = new State(new int[]{40,92});
states[92] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,93,-9,64,-7,70,-8,79,-10,80,-11,81});
states[93] = new State(new int[]{41,94,35,18,27,20,28,22,29,24,30,26,39,28,49,30,53,32,54,34,55,36,56,38,57,40,58,42,47,44,48,45,36,46,33,48,34,50,32,52,31,54});
states[94] = new State(-83);
states[95] = new State(new int[]{40,96});
states[96] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,97,-9,64,-7,70,-8,79,-10,80,-11,81});
states[97] = new State(new int[]{41,98,35,18,27,20,28,22,29,24,30,26,39,28,49,30,53,32,54,34,55,36,56,38,57,40,58,42,47,44,48,45,36,46,33,48,34,50,32,52,31,54});
states[98] = new State(-84);
states[99] = new State(new int[]{40,100});
states[100] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,101,-9,64,-7,70,-8,79,-10,80,-11,81});
states[101] = new State(new int[]{41,102,35,18,27,20,28,22,29,24,30,26,39,28,49,30,53,32,54,34,55,36,56,38,57,40,58,42,47,44,48,45,36,46,33,48,34,50,32,52,31,54});
states[102] = new State(-85);
states[103] = new State(new int[]{40,104});
states[104] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,105,-9,64,-7,70,-8,79,-10,80,-11,81});
states[105] = new State(new int[]{41,106,35,18,27,20,28,22,29,24,30,26,39,28,49,30,53,32,54,34,55,36,56,38,57,40,58,42,47,44,48,45,36,46,33,48,34,50,32,52,31,54});
states[106] = new State(-86);
states[107] = new State(new int[]{63,108,60,74,61,75,62,76,16,77,17,78},new int[]{-7,109});
states[108] = new State(-51);
states[109] = new State(-52);
states[110] = new State(-24);
states[111] = new State(new int[]{63,112});
states[112] = new State(new int[]{41,113});
states[113] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,114,-9,64,-7,70,-8,79,-10,80,-11,81});
states[114] = new State(new int[]{35,18,27,20,28,22,29,24,30,26,39,28,49,30,53,32,54,34,55,36,56,38,57,40,58,42,47,44,48,45,36,46,33,48,34,50,32,52,31,54,63,-25,42,-25,44,-25,60,-25,61,-25,62,-25,16,-25,17,-25,43,-25,45,-25,41,-25});
states[115] = new State(new int[]{63,116});
states[116] = new State(new int[]{51,117});
states[117] = new State(new int[]{63,118});
states[118] = new State(new int[]{32,119});
states[119] = new State(-43);
states[120] = new State(new int[]{63,123,42,132,44,136,60,74,61,75,62,76,16,77,17,78,45,-21},new int[]{-2,121,-3,13,-4,135,-6,146,-9,64,-7,70,-8,79,-10,80,-11,81});
states[121] = new State(new int[]{45,122});
states[122] = new State(-44);
states[123] = new State(new int[]{37,124,40,57,70,107,52,172,50,-59,64,-59,65,-59,66,-59,67,-59,68,-59,69,-59,35,-59,27,-59,28,-59,29,-59,30,-59,39,-59,49,-59,53,-59,54,-59,55,-59,56,-59,57,-59,58,-59,47,-59,48,-59,36,-59,33,-59,34,-59,32,-59,31,-59,63,-59,42,-59,44,-59,60,-59,61,-59,62,-59,16,-59,17,-59,45,-59});
states[124] = new State(new int[]{40,111,63,56,60,74,61,75,62,76,16,77,17,78,31,115,44,120,22,159,21,165,59,168},new int[]{-6,125,-5,110,-9,64,-7,70,-8,79,-10,80,-11,81,-4,171});
states[125] = new State(new int[]{14,126,15,140,35,18,27,20,28,22,29,24,30,26,39,28,49,30,53,32,54,34,55,36,56,38,57,40,58,42,47,44,48,45,36,46,33,48,34,50,32,52,31,54,63,-23,42,-23,44,-23,60,-23,61,-23,62,-23,16,-23,17,-23,45,-23});
states[126] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,127,-9,64,-7,70,-8,79,-10,80,-11,81});
states[127] = new State(new int[]{45,128,25,153,35,18,27,20,28,22,29,24,30,26,39,28,49,30,53,32,54,34,55,36,56,38,57,40,58,42,47,44,48,45,36,46,33,48,34,50,32,52,31,54});
states[128] = new State(new int[]{40,129});
states[129] = new State(new int[]{63,15,42,132,44,136,60,74,61,75,62,76,16,77,17,78,41,-21},new int[]{-2,130,-3,13,-4,135,-6,146,-9,64,-7,70,-8,79,-10,80,-11,81});
states[130] = new State(new int[]{41,131});
states[131] = new State(-55);
states[132] = new State(new int[]{63,15,42,132,44,136,60,74,61,75,62,76,16,77,17,78,43,-21},new int[]{-2,133,-3,13,-4,135,-6,146,-9,64,-7,70,-8,79,-10,80,-11,81});
states[133] = new State(new int[]{43,134});
states[134] = new State(-26);
states[135] = new State(-27);
states[136] = new State(new int[]{63,137});
states[137] = new State(new int[]{37,138});
states[138] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,139,-9,64,-7,70,-8,79,-10,80,-11,81});
states[139] = new State(new int[]{14,126,15,140,35,18,27,20,28,22,29,24,30,26,39,28,49,30,53,32,54,34,55,36,56,38,57,40,58,42,47,44,48,45,36,46,33,48,34,50,32,52,31,54});
states[140] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,141,-9,64,-7,70,-8,79,-10,80,-11,81});
states[141] = new State(new int[]{45,142,25,147,35,18,27,20,28,22,29,24,30,26,39,28,49,30,53,32,54,34,55,36,56,38,57,40,58,42,47,44,48,45,36,46,33,48,34,50,32,52,31,54});
states[142] = new State(new int[]{40,143});
states[143] = new State(new int[]{63,15,42,132,44,136,60,74,61,75,62,76,16,77,17,78,41,-21},new int[]{-2,144,-3,13,-4,135,-6,146,-9,64,-7,70,-8,79,-10,80,-11,81});
states[144] = new State(new int[]{41,145});
states[145] = new State(-56);
states[146] = new State(new int[]{35,18,27,20,28,22,29,24,30,26,39,28,49,30,53,32,54,34,55,36,56,38,57,40,58,42,47,44,48,45,36,46,33,48,34,50,32,52,31,54,63,-28,42,-28,44,-28,60,-28,61,-28,62,-28,16,-28,17,-28,43,-28,45,-28,41,-28});
states[147] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,148,-9,64,-7,70,-8,79,-10,80,-11,81});
states[148] = new State(new int[]{45,149,35,18,27,20,28,22,29,24,30,26,39,28,49,30,53,32,54,34,55,36,56,38,57,40,58,42,47,44,48,45,36,46,33,48,34,50,32,52,31,54});
states[149] = new State(new int[]{40,150});
states[150] = new State(new int[]{63,15,42,132,44,136,60,74,61,75,62,76,16,77,17,78,41,-21},new int[]{-2,151,-3,13,-4,135,-6,146,-9,64,-7,70,-8,79,-10,80,-11,81});
states[151] = new State(new int[]{41,152});
states[152] = new State(-58);
states[153] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,154,-9,64,-7,70,-8,79,-10,80,-11,81});
states[154] = new State(new int[]{45,155,35,18,27,20,28,22,29,24,30,26,39,28,49,30,53,32,54,34,55,36,56,38,57,40,58,42,47,44,48,45,36,46,33,48,34,50,32,52,31,54});
states[155] = new State(new int[]{40,156});
states[156] = new State(new int[]{63,15,42,132,44,136,60,74,61,75,62,76,16,77,17,78,41,-21},new int[]{-2,157,-3,13,-4,135,-6,146,-9,64,-7,70,-8,79,-10,80,-11,81});
states[157] = new State(new int[]{41,158});
states[158] = new State(-57);
states[159] = new State(new int[]{63,160});
states[160] = new State(new int[]{63,161});
states[161] = new State(new int[]{23,162,24,163,63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,164,-9,64,-7,70,-8,79,-10,80,-11,81});
states[162] = new State(-45);
states[163] = new State(-46);
states[164] = new State(new int[]{35,18,27,20,28,22,29,24,30,26,39,28,49,30,53,32,54,34,55,36,56,38,57,40,58,42,47,44,48,45,36,46,33,48,34,50,32,52,31,54,63,-47,42,-47,44,-47,60,-47,61,-47,62,-47,16,-47,17,-47,43,-47,45,-47,41,-47});
states[165] = new State(new int[]{63,166});
states[166] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,167,-9,64,-7,70,-8,79,-10,80,-11,81});
states[167] = new State(new int[]{35,18,27,20,28,22,29,24,30,26,39,28,49,30,53,32,54,34,55,36,56,38,57,40,58,42,47,44,48,45,36,46,33,48,34,50,32,52,31,54,63,-48,42,-48,44,-48,60,-48,61,-48,62,-48,16,-48,17,-48,43,-48,45,-48,41,-48});
states[168] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-6,169,-9,64,-7,70,-8,79,-10,80,-11,81});
states[169] = new State(new int[]{59,170,35,18,27,20,28,22,29,24,30,26,39,28,49,30,53,32,54,34,55,36,56,38,57,40,58,42,47,44,48,45,36,46,33,48,34,50,32,52,31,54});
states[170] = new State(-49);
states[171] = new State(-50);
states[172] = new State(new int[]{60,74,61,75,62,76,16,77,17,78,63,177},new int[]{-7,173,-9,174});
states[173] = new State(-29);
states[174] = new State(new int[]{50,175,63,-30,42,-30,44,-30,60,-30,61,-30,62,-30,16,-30,17,-30,43,-30,45,-30,41,-30});
states[175] = new State(new int[]{63,176});
states[176] = new State(-60);
states[177] = new State(-59);
states[178] = new State(new int[]{42,179});
states[179] = new State(new int[]{10,198,11,-12,43,-12},new int[]{-25,180});
states[180] = new State(new int[]{11,183,43,-14},new int[]{-26,181});
states[181] = new State(new int[]{43,182});
states[182] = new State(-10);
states[183] = new State(new int[]{42,184});
states[184] = new State(new int[]{26,187,43,-16},new int[]{-23,185});
states[185] = new State(new int[]{43,186});
states[186] = new State(-15);
states[187] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-8,188,-6,197,-9,64,-7,70,-10,80,-11,81});
states[188] = new State(new int[]{26,187,19,191,18,194,35,-38,36,-38,27,-38,28,-38,29,-38,30,-38,39,-38,49,-38,53,-38,54,-38,55,-38,56,-38,57,-38,58,-38,47,-38,48,-38,33,-38,34,-38,32,-38,31,-38,43,-16},new int[]{-14,189,-23,190});
states[189] = new State(-17);
states[190] = new State(-18);
states[191] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-8,192,-6,197,-9,64,-7,70,-10,80,-11,81});
states[192] = new State(new int[]{26,187,19,191,18,194,35,-38,36,-38,27,-38,28,-38,29,-38,30,-38,39,-38,49,-38,53,-38,54,-38,55,-38,56,-38,57,-38,58,-38,47,-38,48,-38,33,-38,34,-38,32,-38,31,-38,43,-16},new int[]{-14,193,-23,190});
states[193] = new State(-19);
states[194] = new State(new int[]{63,56,60,74,61,75,62,76,16,77,17,78},new int[]{-8,195,-6,197,-9,64,-7,70,-10,80,-11,81});
states[195] = new State(new int[]{26,187,19,191,18,194,35,-38,36,-38,27,-38,28,-38,29,-38,30,-38,39,-38,49,-38,53,-38,54,-38,55,-38,56,-38,57,-38,58,-38,47,-38,48,-38,33,-38,34,-38,32,-38,31,-38,43,-16},new int[]{-14,196,-23,190});
states[196] = new State(-20);
states[197] = new State(new int[]{35,18,36,46,27,20,28,22,29,24,30,26,39,28,49,30,53,32,54,34,55,36,56,38,57,40,58,42,47,44,48,45,33,48,34,50,32,52,31,54});
states[198] = new State(new int[]{42,199});
states[199] = new State(new int[]{26,187,43,-16},new int[]{-23,200});
states[200] = new State(new int[]{43,201});
states[201] = new State(-13);
states[202] = new State(new int[]{42,203});
states[203] = new State(new int[]{8,206,43,-33},new int[]{-21,204});
states[204] = new State(new int[]{43,205});
states[205] = new State(-8);
states[206] = new State(new int[]{42,207});
states[207] = new State(new int[]{63,15,42,132,44,136,60,74,61,75,62,76,16,77,17,78,43,-21},new int[]{-2,208,-3,13,-4,135,-6,146,-9,64,-7,70,-8,79,-10,80,-11,81});
states[208] = new State(new int[]{43,209});
states[209] = new State(new int[]{8,206,43,-33},new int[]{-21,210});
states[210] = new State(-34);
states[211] = new State(new int[]{42,212});
states[212] = new State(new int[]{6,215,43,-31},new int[]{-24,213});
states[213] = new State(new int[]{43,214});
states[214] = new State(-7);
states[215] = new State(new int[]{42,216});
states[216] = new State(new int[]{63,15,42,132,44,136,60,74,61,75,62,76,16,77,17,78,43,-21},new int[]{-2,217,-3,13,-4,135,-6,146,-9,64,-7,70,-8,79,-10,80,-11,81});
states[217] = new State(new int[]{43,218});
states[218] = new State(new int[]{6,215,43,-31},new int[]{-24,219});
states[219] = new State(-32);
states[220] = new State(new int[]{42,221});
states[221] = new State(new int[]{63,15,42,132,44,136,60,74,61,75,62,76,16,77,17,78,43,-21},new int[]{-2,222,-3,13,-4,135,-6,146,-9,64,-7,70,-8,79,-10,80,-11,81});
states[222] = new State(new int[]{43,223});
states[223] = new State(-6);
states[224] = new State(new int[]{42,225});
states[225] = new State(new int[]{63,15,42,132,44,136,60,74,61,75,62,76,16,77,17,78,43,-21},new int[]{-2,226,-3,13,-4,135,-6,146,-9,64,-7,70,-8,79,-10,80,-11,81});
states[226] = new State(new int[]{43,227});
states[227] = new State(-4);
rules[1] = new Rule(-27, new int[]{-1,2});
rules[2] = new Rule(-1, new int[]{-16,-17,-18,-19,-22,-20});
rules[3] = new Rule(-16, new int[]{});
rules[4] = new Rule(-16, new int[]{3,42,-2,43});
rules[5] = new Rule(-17, new int[]{});
rules[6] = new Rule(-17, new int[]{4,42,-2,43});
rules[7] = new Rule(-18, new int[]{5,42,-24,43});
rules[8] = new Rule(-19, new int[]{7,42,-21,43});
rules[9] = new Rule(-22, new int[]{});
rules[10] = new Rule(-22, new int[]{9,42,-25,-26,43});
rules[11] = new Rule(-20, new int[]{12,42,-2,43});
rules[12] = new Rule(-25, new int[]{});
rules[13] = new Rule(-25, new int[]{10,42,-23,43});
rules[14] = new Rule(-26, new int[]{});
rules[15] = new Rule(-26, new int[]{11,42,-23,43});
rules[16] = new Rule(-23, new int[]{});
rules[17] = new Rule(-23, new int[]{26,-8,-14});
rules[18] = new Rule(-14, new int[]{-23});
rules[19] = new Rule(-14, new int[]{19,-8,-14});
rules[20] = new Rule(-14, new int[]{18,-8,-14});
rules[21] = new Rule(-2, new int[]{});
rules[22] = new Rule(-2, new int[]{-3,-2});
rules[23] = new Rule(-3, new int[]{63,37,-6});
rules[24] = new Rule(-3, new int[]{63,37,-5});
rules[25] = new Rule(-3, new int[]{63,37,40,63,41,-6});
rules[26] = new Rule(-3, new int[]{42,-2,43});
rules[27] = new Rule(-3, new int[]{-4});
rules[28] = new Rule(-3, new int[]{-6});
rules[29] = new Rule(-3, new int[]{63,52,-7});
rules[30] = new Rule(-3, new int[]{63,52,-9});
rules[31] = new Rule(-24, new int[]{});
rules[32] = new Rule(-24, new int[]{6,42,-2,43,-24});
rules[33] = new Rule(-21, new int[]{});
rules[34] = new Rule(-21, new int[]{8,42,-2,43,-21});
rules[35] = new Rule(-6, new int[]{63,40,-13,41});
rules[36] = new Rule(-6, new int[]{-9,50,63,40,-13,41});
rules[37] = new Rule(-6, new int[]{-7});
rules[38] = new Rule(-6, new int[]{-8});
rules[39] = new Rule(-6, new int[]{-9});
rules[40] = new Rule(-6, new int[]{-10});
rules[41] = new Rule(-6, new int[]{-9,-15});
rules[42] = new Rule(-6, new int[]{-11});
rules[43] = new Rule(-5, new int[]{31,63,51,63,32});
rules[44] = new Rule(-5, new int[]{44,-2,45});
rules[45] = new Rule(-5, new int[]{22,63,63,23});
rules[46] = new Rule(-5, new int[]{22,63,63,24});
rules[47] = new Rule(-5, new int[]{22,63,63,-6});
rules[48] = new Rule(-5, new int[]{21,63,-6});
rules[49] = new Rule(-5, new int[]{59,-6,59});
rules[50] = new Rule(-5, new int[]{-4});
rules[51] = new Rule(-11, new int[]{63,70,63});
rules[52] = new Rule(-11, new int[]{63,70,-7});
rules[53] = new Rule(-11, new int[]{-7,70,63});
rules[54] = new Rule(-11, new int[]{-7,70,-7});
rules[55] = new Rule(-4, new int[]{44,63,37,-6,14,-6,45,40,-2,41});
rules[56] = new Rule(-4, new int[]{44,63,37,-6,15,-6,45,40,-2,41});
rules[57] = new Rule(-4, new int[]{44,63,37,-6,14,-6,25,-6,45,40,-2,41});
rules[58] = new Rule(-4, new int[]{44,63,37,-6,15,-6,25,-6,45,40,-2,41});
rules[59] = new Rule(-9, new int[]{63});
rules[60] = new Rule(-9, new int[]{-9,50,63});
rules[61] = new Rule(-8, new int[]{-6,35,-6});
rules[62] = new Rule(-8, new int[]{-6,36,-6});
rules[63] = new Rule(-8, new int[]{-6,33,-6});
rules[64] = new Rule(-8, new int[]{-6,34,-6});
rules[65] = new Rule(-8, new int[]{-6,32,-6});
rules[66] = new Rule(-8, new int[]{-6,31,-6});
rules[67] = new Rule(-10, new int[]{-6,27,-6});
rules[68] = new Rule(-10, new int[]{-6,28,-6});
rules[69] = new Rule(-10, new int[]{-6,29,-6});
rules[70] = new Rule(-10, new int[]{-6,30,-6});
rules[71] = new Rule(-10, new int[]{-6,39,-6});
rules[72] = new Rule(-10, new int[]{-6,49,-6});
rules[73] = new Rule(-10, new int[]{-6,53,-6});
rules[74] = new Rule(-10, new int[]{-6,54,-6});
rules[75] = new Rule(-10, new int[]{-6,55,-6});
rules[76] = new Rule(-10, new int[]{-6,56,-6});
rules[77] = new Rule(-10, new int[]{-6,57,-6});
rules[78] = new Rule(-10, new int[]{-6,58,-6});
rules[79] = new Rule(-10, new int[]{-6,47});
rules[80] = new Rule(-10, new int[]{-6,48});
rules[81] = new Rule(-15, new int[]{64,40,-6,41});
rules[82] = new Rule(-15, new int[]{65,40,-6,41});
rules[83] = new Rule(-15, new int[]{66,40,-6,41});
rules[84] = new Rule(-15, new int[]{67,40,-6,41});
rules[85] = new Rule(-15, new int[]{68,40,-6,41});
rules[86] = new Rule(-15, new int[]{69,40,-6,41});
rules[87] = new Rule(-13, new int[]{});
rules[88] = new Rule(-13, new int[]{-12});
rules[89] = new Rule(-12, new int[]{-6});
rules[90] = new Rule(-12, new int[]{-6,51,-13});
rules[91] = new Rule(-7, new int[]{60});
rules[92] = new Rule(-7, new int[]{61});
rules[93] = new Rule(-7, new int[]{62});
rules[94] = new Rule(-7, new int[]{16});
rules[95] = new Rule(-7, new int[]{17});
}
protected override void Initialize() {
this.InitSpecialTokens((int)Tokens.error, (int)Tokens.EOF);
this.InitStates(states);
this.InitRules(rules);
this.InitNonTerminals(nonTerms);
}
protected override void DoAction(int action)
{
switch (action)
{
case 2: // program -> settingsOpt, dealOpt, collatSection, securitySection, creditRulesOpt,
// simSection
{ CurrentSemanticValue.Prog = new Prog(ValueStack[ValueStack.Depth-6].DeclarationClass, ValueStack[ValueStack.Depth-5].DeclarationClass, ValueStack[ValueStack.Depth-4].DeclarationClass, ValueStack[ValueStack.Depth-3].DeclarationClass, ValueStack[ValueStack.Depth-2].DeclarationClass, ValueStack[ValueStack.Depth-1].DeclarationClass); SyntaxTreeRoot = CurrentSemanticValue.Prog; CurrentSemanticValue.Prog.Location = CurrentLocationSpan; }
break;
case 3: // settingsOpt -> /* empty */
{ CurrentSemanticValue.DeclarationClass = new Settings(); CurrentSemanticValue.DeclarationClass.Location = CurrentLocationSpan; }
break;
case 4: // settingsOpt -> SETTINGS, LBRACE, statementList, RBRACE
{ CurrentSemanticValue.DeclarationClass = new Settings(ValueStack[ValueStack.Depth-2].StatementList); }
break;
case 5: // dealOpt -> /* empty */
{ CurrentSemanticValue.DeclarationClass = new Deal(); CurrentSemanticValue.DeclarationClass.Location = CurrentLocationSpan; }
break;
case 6: // dealOpt -> DEAL, LBRACE, statementList, RBRACE
{ CurrentSemanticValue.DeclarationClass = new Deal(ValueStack[ValueStack.Depth-2].StatementList); CurrentSemanticValue.DeclarationClass.Location = CurrentLocationSpan; }
break;
case 7: // collatSection -> COLLATERAL, LBRACE, collListOpt, RBRACE
{ CurrentSemanticValue.DeclarationClass = new Collateral(ValueStack[ValueStack.Depth-2].CollateralItem); CurrentSemanticValue.DeclarationClass.Location = CurrentLocationSpan; }
break;
case 8: // securitySection -> SECURITIES, LBRACE, secListOpt, RBRACE
{ CurrentSemanticValue.DeclarationClass = new Securities(ValueStack[ValueStack.Depth-2].Bond); CurrentSemanticValue.DeclarationClass.Location = CurrentLocationSpan; }
break;
case 9: // creditRulesOpt -> /* empty */
{ CurrentSemanticValue.DeclarationClass = new CreditPaymentRules(); CurrentSemanticValue.DeclarationClass.Location = CurrentLocationSpan; }
break;
case 10: // creditRulesOpt -> CREDITPAYMENTRULES, LBRACE, interestRules, principalRules,
// RBRACE
{ CurrentSemanticValue.DeclarationClass = new CreditPaymentRules(new StatementList(ValueStack[ValueStack.Depth-3].InterestRules,ValueStack[ValueStack.Depth-2].PrincipalRules)); CurrentSemanticValue.DeclarationClass.Location = CurrentLocationSpan; }
break;
case 11: // simSection -> SIMULATION, LBRACE, statementList, RBRACE
{ CurrentSemanticValue.DeclarationClass = new Simulation(ValueStack[ValueStack.Depth-2].StatementList); CurrentSemanticValue.DeclarationClass.Location = CurrentLocationSpan; }
break;
case 12: // interestRules -> /* empty */
{ CurrentSemanticValue.InterestRules = new InterestRules(); CurrentSemanticValue.InterestRules.Location = CurrentLocationSpan; }
break;
case 13: // interestRules -> INTEREST, LBRACE, rulesListOpt, RBRACE
{ CurrentSemanticValue.InterestRules = new InterestRules(ValueStack[ValueStack.Depth-2].InternalRuleList); CurrentSemanticValue.InterestRules.Location = CurrentLocationSpan; }
break;
case 14: // principalRules -> /* empty */
{ CurrentSemanticValue.PrincipalRules = new PrincipalRules(); CurrentSemanticValue.PrincipalRules.Location = CurrentLocationSpan; }
break;
case 15: // principalRules -> PRINCIPAL, LBRACE, rulesListOpt, RBRACE
{ CurrentSemanticValue.PrincipalRules = new PrincipalRules(ValueStack[ValueStack.Depth-2].InternalRuleList); CurrentSemanticValue.PrincipalRules.Location = CurrentLocationSpan; }
break;
case 16: // rulesListOpt -> /* empty */
{ CurrentSemanticValue.InternalRuleList = new InternalRuleList(); CurrentSemanticValue.InternalRuleList.Location = CurrentLocationSpan; }
break;
case 17: // rulesListOpt -> RULE, compExpression, boolListOpt
{ CurrentSemanticValue.InternalRuleList = new InternalRuleList(ValueStack[ValueStack.Depth-2].Expression, ValueStack[ValueStack.Depth-1].ExpressionList); CurrentSemanticValue.InternalRuleList.Location = CurrentLocationSpan; }
break;
case 18: // boolListOpt -> rulesListOpt
{ CurrentSemanticValue.ExpressionList = ValueStack[ValueStack.Depth-1].InternalRuleList; CurrentSemanticValue.ExpressionList.Location = CurrentLocationSpan; }
break;
case 19: // boolListOpt -> OR, compExpression, boolListOpt
{ CurrentSemanticValue.ExpressionList = new InternalRuleListOr(ValueStack[ValueStack.Depth-2].Expression, ValueStack[ValueStack.Depth-1].ExpressionList); CurrentSemanticValue.ExpressionList.Location = CurrentLocationSpan; }
break;
case 20: // boolListOpt -> AND, compExpression, boolListOpt
{ CurrentSemanticValue.ExpressionList = new InternalRuleListAnd(ValueStack[ValueStack.Depth-2].Expression, ValueStack[ValueStack.Depth-1].ExpressionList); CurrentSemanticValue.ExpressionList.Location = CurrentLocationSpan; }
break;
case 21: // statementList -> /* empty */
{ CurrentSemanticValue.StatementList = new StatementList(); CurrentSemanticValue.StatementList.Location = CurrentLocationSpan; }
break;
case 22: // statementList -> statement, statementList
{ CurrentSemanticValue.StatementList = new StatementList(ValueStack[ValueStack.Depth-2].Statement, ValueStack[ValueStack.Depth-1].StatementList); CurrentSemanticValue.StatementList.Location = CurrentLocationSpan; }
break;
case 23: // statement -> IDENTIFIER, ASSIGN, expression
{ CurrentSemanticValue.Statement = new Assign(new Identifier(CurrentLocationSpan, ValueStack[ValueStack.Depth-3].Token.Value), ValueStack[ValueStack.Depth-1].Expression); CurrentSemanticValue.Statement.Location = CurrentLocationSpan; }
break;
case 24: // statement -> IDENTIFIER, ASSIGN, instantiation
{ CurrentSemanticValue.Statement = new Assign(new Identifier(CurrentLocationSpan, ValueStack[ValueStack.Depth-3].Token.Value), ValueStack[ValueStack.Depth-1].Statement); CurrentSemanticValue.Statement.Location = CurrentLocationSpan; }
break;
case 25: // statement -> IDENTIFIER, ASSIGN, LPAREN, IDENTIFIER, RPAREN, expression
{ CurrentSemanticValue.Statement = new Assign(new Identifier(CurrentLocationSpan, ValueStack[ValueStack.Depth-6].Token.Value), new Qualifier(ValueStack[ValueStack.Depth-3].Token.Value, ValueStack[ValueStack.Depth-1].Expression)); CurrentSemanticValue.Statement.Location = CurrentLocationSpan; }
break;
case 26: // statement -> LBRACE, statementList, RBRACE
{ CurrentSemanticValue.Statement = new Block(ValueStack[ValueStack.Depth-2].StatementList); CurrentSemanticValue.Statement.Location = CurrentLocationSpan; }
break;
case 27: // statement -> loop
{ CurrentSemanticValue.Statement = ValueStack[ValueStack.Depth-1].Statement; CurrentSemanticValue.Statement.Location = CurrentLocationSpan; }
break;
case 28: // statement -> expression
{ CurrentSemanticValue.Statement = new StatementExpression(ValueStack[ValueStack.Depth-1].Expression); CurrentSemanticValue.Statement.Location = CurrentLocationSpan; }
break;
case 29: // statement -> IDENTIFIER, CONS, literal
{ CurrentSemanticValue.Statement = new Cons(new Identifier(CurrentLocationSpan, ValueStack[ValueStack.Depth-3].Token.Value), ValueStack[ValueStack.Depth-1].Expression); CurrentSemanticValue.Statement.Location = CurrentLocationSpan; }
break;
case 30: // statement -> IDENTIFIER, CONS, lvalue
{ CurrentSemanticValue.Statement = new Cons(new Identifier(CurrentLocationSpan, ValueStack[ValueStack.Depth-3].Token.Value), ValueStack[ValueStack.Depth-1].Expression); CurrentSemanticValue.Statement.Location = CurrentLocationSpan; }
break;
case 31: // collListOpt -> /* empty */
{ CurrentSemanticValue.CollateralItem = new CollateralItem(); CurrentSemanticValue.CollateralItem.Location = CurrentLocationSpan; }
break;
case 32: // collListOpt -> COLLATERALITEM, LBRACE, statementList, RBRACE, collListOpt
{ CurrentSemanticValue.CollateralItem = new CollateralItem(ValueStack[ValueStack.Depth-3].StatementList, ValueStack[ValueStack.Depth-1].CollateralItem); CurrentSemanticValue.CollateralItem.Location = CurrentLocationSpan; }
break;
case 33: // secListOpt -> /* empty */
{ CurrentSemanticValue.Bond = new Bond(); CurrentSemanticValue.Bond.Location = CurrentLocationSpan; }
break;
case 34: // secListOpt -> BOND, LBRACE, statementList, RBRACE, secListOpt
{ CurrentSemanticValue.Bond = new Bond(ValueStack[ValueStack.Depth-3].StatementList, ValueStack[ValueStack.Depth-1].Bond); CurrentSemanticValue.Bond.Location = CurrentLocationSpan; }
break;
case 35: // expression -> IDENTIFIER, LPAREN, actuals, RPAREN
{ CurrentSemanticValue.Expression = new Invoke(ValueStack[ValueStack.Depth-4].Token.Value, ValueStack[ValueStack.Depth-2].ExpressionList); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 36: // expression -> lvalue, DOT, IDENTIFIER, LPAREN, actuals, RPAREN
{ CurrentSemanticValue.Expression = new Invoke(ValueStack[ValueStack.Depth-6].Expression, ValueStack[ValueStack.Depth-4].Token.Value, ValueStack[ValueStack.Depth-2].ExpressionList); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 37: // expression -> literal
{ CurrentSemanticValue.Expression = ValueStack[ValueStack.Depth-1].Expression; CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 38: // expression -> compExpression
{ CurrentSemanticValue.Expression = ValueStack[ValueStack.Depth-1].Expression; CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 39: // expression -> lvalue
{ CurrentSemanticValue.Expression = ValueStack[ValueStack.Depth-1].Expression; CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 40: // expression -> arithmetic
{ CurrentSemanticValue.Expression = ValueStack[ValueStack.Depth-1].Expression; CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 41: // expression -> lvalue, specialFunction
{ CurrentSemanticValue.Expression = new Invoke(ValueStack[ValueStack.Depth-2].Expression, ValueStack[ValueStack.Depth-1].SpecialFunction); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 42: // expression -> concat
{ CurrentSemanticValue.Expression = ValueStack[ValueStack.Depth-1].Expression; CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 43: // instantiation -> SMALLER, IDENTIFIER, COMMA, IDENTIFIER, GREATER
{ CurrentSemanticValue.Statement = new TimeSeries(new Identifier(CurrentLocationSpan, ValueStack[ValueStack.Depth-4].Token.Value), new Identifier(CurrentLocationSpan, ValueStack[ValueStack.Depth-2].Token.Value)); CurrentSemanticValue.Statement.Location = CurrentLocationSpan; }
break;
case 44: // instantiation -> LBRACKET, statementList, RBRACKET
{ CurrentSemanticValue.Statement = new Set(ValueStack[ValueStack.Depth-2].StatementList); CurrentSemanticValue.Statement.Location = CurrentLocationSpan; }
break;
case 45: // instantiation -> FILTER, IDENTIFIER, IDENTIFIER, FIRST
{ CurrentSemanticValue.Statement = new Filter(new Identifier(CurrentLocationSpan, ValueStack[ValueStack.Depth-3].Token.Value), new Identifier(CurrentLocationSpan, ValueStack[ValueStack.Depth-2].Token.Value), "first"); CurrentSemanticValue.Statement.Location = CurrentLocationSpan; }
break;
case 46: // instantiation -> FILTER, IDENTIFIER, IDENTIFIER, LAST
{ CurrentSemanticValue.Statement = new Filter(new Identifier(CurrentLocationSpan, ValueStack[ValueStack.Depth-3].Token.Value), new Identifier(CurrentLocationSpan, ValueStack[ValueStack.Depth-2].Token.Value), "last"); CurrentSemanticValue.Statement.Location = CurrentLocationSpan; }
break;
case 47: // instantiation -> FILTER, IDENTIFIER, IDENTIFIER, expression
{ CurrentSemanticValue.Statement = new Filter(new Identifier(CurrentLocationSpan, ValueStack[ValueStack.Depth-3].Token.Value), new Identifier(CurrentLocationSpan, ValueStack[ValueStack.Depth-2].Token.Value), ValueStack[ValueStack.Depth-1].Expression); CurrentSemanticValue.Statement.Location = CurrentLocationSpan; }
break;
case 48: // instantiation -> AGGREGATE, IDENTIFIER, expression
{ CurrentSemanticValue.Statement = new Aggregate(new Identifier(CurrentLocationSpan, ValueStack[ValueStack.Depth-2].Token.Value), ValueStack[ValueStack.Depth-1].Expression); CurrentSemanticValue.Statement.Location = CurrentLocationSpan; }
break;
case 49: // instantiation -> PIPE, expression, PIPE
{ CurrentSemanticValue.Statement = new RuleType(ValueStack[ValueStack.Depth-2].Expression); CurrentSemanticValue.Statement.Location = CurrentLocationSpan; }
break;
case 50: // instantiation -> loop
{ CurrentSemanticValue.Statement = ValueStack[ValueStack.Depth-1].Statement; CurrentSemanticValue.Statement.Location = CurrentLocationSpan; }
break;
case 51: // concat -> IDENTIFIER, CONCAT, IDENTIFIER
{ CurrentSemanticValue.Expression = new Concat(new Identifier(CurrentLocationSpan, ValueStack[ValueStack.Depth-3].Token.Value), new Identifier(CurrentLocationSpan, ValueStack[ValueStack.Depth-1].Token.Value)); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 52: // concat -> IDENTIFIER, CONCAT, literal
{ CurrentSemanticValue.Expression = new Concat(new Identifier(CurrentLocationSpan, ValueStack[ValueStack.Depth-3].Token.Value), ValueStack[ValueStack.Depth-1].Expression); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 53: // concat -> literal, CONCAT, IDENTIFIER
{ CurrentSemanticValue.Expression = new Concat(ValueStack[ValueStack.Depth-3].Expression, new Identifier(CurrentLocationSpan, ValueStack[ValueStack.Depth-1].Token.Value)); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 54: // concat -> literal, CONCAT, literal
{ CurrentSemanticValue.Expression = new Concat(ValueStack[ValueStack.Depth-3].Expression, ValueStack[ValueStack.Depth-1].Expression); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 55: // loop -> LBRACKET, IDENTIFIER, ASSIGN, expression, UPTO, expression, RBRACKET,
// LPAREN, statementList, RPAREN
{ CurrentSemanticValue.Statement = new Loop(ValueStack[ValueStack.Depth-9].Token.Value, ValueStack[ValueStack.Depth-7].Expression, "upto", ValueStack[ValueStack.Depth-5].Expression, ValueStack[ValueStack.Depth-2].StatementList); CurrentSemanticValue.Statement.Location = CurrentLocationSpan; }
break;
case 56: // loop -> LBRACKET, IDENTIFIER, ASSIGN, expression, DOWNTO, expression, RBRACKET,
// LPAREN, statementList, RPAREN
{ CurrentSemanticValue.Statement = new Loop(ValueStack[ValueStack.Depth-9].Token.Value, ValueStack[ValueStack.Depth-7].Expression, "downto", ValueStack[ValueStack.Depth-5].Expression, ValueStack[ValueStack.Depth-2].StatementList); CurrentSemanticValue.Statement.Location = CurrentLocationSpan; }
break;
case 57: // loop -> LBRACKET, IDENTIFIER, ASSIGN, expression, UPTO, expression, WITH,
// expression, RBRACKET, LPAREN, statementList, RPAREN
{ CurrentSemanticValue.Statement = new Loop(ValueStack[ValueStack.Depth-11].Token.Value, ValueStack[ValueStack.Depth-9].Expression, "upto", ValueStack[ValueStack.Depth-7].Expression, ValueStack[ValueStack.Depth-5].Expression, ValueStack[ValueStack.Depth-2].StatementList); CurrentSemanticValue.Statement.Location = CurrentLocationSpan; }
break;
case 58: // loop -> LBRACKET, IDENTIFIER, ASSIGN, expression, DOWNTO, expression, WITH,
// expression, RBRACKET, LPAREN, statementList, RPAREN
{ CurrentSemanticValue.Statement = new Loop(ValueStack[ValueStack.Depth-11].Token.Value, ValueStack[ValueStack.Depth-9].Expression, "downto", ValueStack[ValueStack.Depth-7].Expression, ValueStack[ValueStack.Depth-5].Expression, ValueStack[ValueStack.Depth-2].StatementList); CurrentSemanticValue.Statement.Location = CurrentLocationSpan; }
break;
case 59: // lvalue -> IDENTIFIER
{ CurrentSemanticValue.Expression = new Identifier(CurrentLocationSpan, ValueStack[ValueStack.Depth-1].Token.Value); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 60: // lvalue -> lvalue, DOT, IDENTIFIER
{ CurrentSemanticValue.Expression = new DereferenceField(ValueStack[ValueStack.Depth-3].Expression, ValueStack[ValueStack.Depth-1].Token.Value); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 61: // compExpression -> expression, EQ, expression
{ CurrentSemanticValue.Expression = new Equal(ValueStack[ValueStack.Depth-3].Expression, ValueStack[ValueStack.Depth-1].Expression); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 62: // compExpression -> expression, NEQ, expression
{ CurrentSemanticValue.Expression = new NotEqual(ValueStack[ValueStack.Depth-3].Expression, ValueStack[ValueStack.Depth-1].Expression); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 63: // compExpression -> expression, SMEQ, expression
{ CurrentSemanticValue.Expression = new SmallerEqual(ValueStack[ValueStack.Depth-3].Expression, ValueStack[ValueStack.Depth-1].Expression); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 64: // compExpression -> expression, GTEQ, expression
{ CurrentSemanticValue.Expression = new GreaterEqual(ValueStack[ValueStack.Depth-3].Expression, ValueStack[ValueStack.Depth-1].Expression); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 65: // compExpression -> expression, GREATER, expression
{ CurrentSemanticValue.Expression = new Greater(ValueStack[ValueStack.Depth-3].Expression, ValueStack[ValueStack.Depth-1].Expression); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 66: // compExpression -> expression, SMALLER, expression
{ CurrentSemanticValue.Expression = new Smaller(ValueStack[ValueStack.Depth-3].Expression, ValueStack[ValueStack.Depth-1].Expression); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 67: // arithmetic -> expression, PLUS, expression
{ CurrentSemanticValue.Expression = new Plus(ValueStack[ValueStack.Depth-3].Expression, ValueStack[ValueStack.Depth-1].Expression); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 68: // arithmetic -> expression, MINUS, expression
{ CurrentSemanticValue.Expression = new Minus(ValueStack[ValueStack.Depth-3].Expression, ValueStack[ValueStack.Depth-1].Expression); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 69: // arithmetic -> expression, TIMES, expression
{ CurrentSemanticValue.Expression = new Times(ValueStack[ValueStack.Depth-3].Expression, ValueStack[ValueStack.Depth-1].Expression); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 70: // arithmetic -> expression, DIVIDE, expression
{ CurrentSemanticValue.Expression = new Divide(ValueStack[ValueStack.Depth-3].Expression, ValueStack[ValueStack.Depth-1].Expression); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 71: // arithmetic -> expression, MOD, expression
{ CurrentSemanticValue.Expression = new Mod(ValueStack[ValueStack.Depth-3].Expression, ValueStack[ValueStack.Depth-1].Expression); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 72: // arithmetic -> expression, EXP, expression
{ CurrentSemanticValue.Expression = new Exp(ValueStack[ValueStack.Depth-3].Expression, ValueStack[ValueStack.Depth-1].Expression); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 73: // arithmetic -> expression, ATPLUS, expression
{ CurrentSemanticValue.Expression = new Plus(ValueStack[ValueStack.Depth-3].Expression, true, ValueStack[ValueStack.Depth-1].Expression); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 74: // arithmetic -> expression, ATMINUS, expression
{ CurrentSemanticValue.Expression = new Minus(ValueStack[ValueStack.Depth-3].Expression, true, ValueStack[ValueStack.Depth-1].Expression); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 75: // arithmetic -> expression, ATTIMES, expression
{ CurrentSemanticValue.Expression = new Times(ValueStack[ValueStack.Depth-3].Expression, true, ValueStack[ValueStack.Depth-1].Expression); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 76: // arithmetic -> expression, ATDIV, expression
{ CurrentSemanticValue.Expression = new Divide(ValueStack[ValueStack.Depth-3].Expression, true, ValueStack[ValueStack.Depth-1].Expression); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 77: // arithmetic -> expression, ATMOD, expression
{ CurrentSemanticValue.Expression = new Mod(ValueStack[ValueStack.Depth-3].Expression, true, ValueStack[ValueStack.Depth-1].Expression); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 78: // arithmetic -> expression, ATEXP, expression
{ CurrentSemanticValue.Expression = new Exp(ValueStack[ValueStack.Depth-3].Expression, true, ValueStack[ValueStack.Depth-1].Expression); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 79: // arithmetic -> expression, INCREMENT
{ CurrentSemanticValue.Expression = new Increment(ValueStack[ValueStack.Depth-2].Expression); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 80: // arithmetic -> expression, DECREMENT
{ CurrentSemanticValue.Expression = new Decrement(ValueStack[ValueStack.Depth-2].Expression); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 81: // specialFunction -> PLUSDAY, LPAREN, expression, RPAREN
{ CurrentSemanticValue.SpecialFunction = new SpecialFunction(ValueStack[ValueStack.Depth-4].Token.Value, ValueStack[ValueStack.Depth-2].Expression); CurrentSemanticValue.SpecialFunction.Location = CurrentLocationSpan; }
break;
case 82: // specialFunction -> MINUSDAY, LPAREN, expression, RPAREN
{ CurrentSemanticValue.SpecialFunction = new SpecialFunction(ValueStack[ValueStack.Depth-4].Token.Value, ValueStack[ValueStack.Depth-2].Expression); CurrentSemanticValue.SpecialFunction.Location = CurrentLocationSpan; }
break;
case 83: // specialFunction -> PLUSMONTH, LPAREN, expression, RPAREN
{ CurrentSemanticValue.SpecialFunction = new SpecialFunction(ValueStack[ValueStack.Depth-4].Token.Value, ValueStack[ValueStack.Depth-2].Expression); CurrentSemanticValue.SpecialFunction.Location = CurrentLocationSpan; }
break;
case 84: // specialFunction -> MINUSMONTH, LPAREN, expression, RPAREN
{ CurrentSemanticValue.SpecialFunction = new SpecialFunction(ValueStack[ValueStack.Depth-4].Token.Value, ValueStack[ValueStack.Depth-2].Expression); CurrentSemanticValue.SpecialFunction.Location = CurrentLocationSpan; }
break;
case 85: // specialFunction -> PLUSYEAR, LPAREN, expression, RPAREN
{ CurrentSemanticValue.SpecialFunction = new SpecialFunction(ValueStack[ValueStack.Depth-4].Token.Value, ValueStack[ValueStack.Depth-2].Expression); CurrentSemanticValue.SpecialFunction.Location = CurrentLocationSpan; }
break;
case 86: // specialFunction -> MINUSYEAR, LPAREN, expression, RPAREN
{ CurrentSemanticValue.SpecialFunction = new SpecialFunction(ValueStack[ValueStack.Depth-4].Token.Value, ValueStack[ValueStack.Depth-2].Expression); CurrentSemanticValue.SpecialFunction.Location = CurrentLocationSpan; }
break;
case 87: // actuals -> /* empty */
{ CurrentSemanticValue.ExpressionList = new ExpressionList(); CurrentSemanticValue.ExpressionList.Location = CurrentLocationSpan; }
break;
case 88: // actuals -> onePlusActuals
{ CurrentSemanticValue.ExpressionList = ValueStack[ValueStack.Depth-1].ExpressionList; CurrentSemanticValue.ExpressionList.Location = CurrentLocationSpan; }
break;
case 89: // onePlusActuals -> expression
{ CurrentSemanticValue.ExpressionList = new ExpressionList(ValueStack[ValueStack.Depth-1].Expression, new ExpressionList()); CurrentSemanticValue.ExpressionList.Location = CurrentLocationSpan; }
break;
case 90: // onePlusActuals -> expression, COMMA, actuals
{ CurrentSemanticValue.ExpressionList = new ExpressionList(ValueStack[ValueStack.Depth-3].Expression, ValueStack[ValueStack.Depth-1].ExpressionList); CurrentSemanticValue.ExpressionList.Location = CurrentLocationSpan; }
break;
case 91: // literal -> LITERAL_INT
{ CurrentSemanticValue.Expression = new IntegerLiteral(Int32.Parse(ValueStack[ValueStack.Depth-1].Token.Value.ToString().Replace(",",""))); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 92: // literal -> LITERAL_REAL
{ CurrentSemanticValue.Expression = new RealLiteral(Double.Parse(ValueStack[ValueStack.Depth-1].Token.Value.ToString().Replace(",",""))); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 93: // literal -> LITERAL_STRING
{ CurrentSemanticValue.Expression = new StringLiteral(ValueStack[ValueStack.Depth-1].Token.Value); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 94: // literal -> TRUE
{ CurrentSemanticValue.Expression = new BooleanLiteral(true); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
case 95: // literal -> FALSE
{ CurrentSemanticValue.Expression = new BooleanLiteral(false); CurrentSemanticValue.Expression.Location = CurrentLocationSpan; }
break;
}
}
protected override string TerminalToString(int terminal)
{
if (aliasses != null && aliasses.ContainsKey(terminal))
return aliasses[terminal];
else if (((Tokens)terminal).ToString() != terminal.ToString(CultureInfo.InvariantCulture))
return ((Tokens)terminal).ToString();
else
return CharToString((char)terminal);
}
public Prog SyntaxTreeRoot { get; set; }
public Parser(Scanner scan) : base(scan)
{
}
}
}