sdl92Parser.py 2.18 MB
Newer Older
1
# $ANTLR 3.5.2 sdl92.g 2021-03-28 16:21:30
Maxime Perrotin's avatar
Maxime Perrotin committed
2
3
4
5
6
7
8
9

import sys
from antlr3 import *

from antlr3.tree import *



Maxime Perrotin's avatar
Maxime Perrotin committed
10

Maxime Perrotin's avatar
Maxime Perrotin committed
11
12
13
14
# for convenience in actions
HIDDEN = BaseRecognizer.HIDDEN

# token types
15
EOF=-1
Maxime Perrotin's avatar
Maxime Perrotin committed
16
T__225=225
17
T__226=226
Maxime Perrotin's avatar
Maxime Perrotin committed
18
19
20
T__227=227
T__228=228
T__229=229
Maxime Perrotin's avatar
Maxime Perrotin committed
21
T__230=230
22
T__231=231
Maxime Perrotin's avatar
Maxime Perrotin committed
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
A=4
ACTION=5
ACTIVE=6
AGGREGATION=7
ALL=8
ALPHA=9
ALTERNATIVE=10
AND=11
ANSWER=12
ANY=13
APPEND=14
ARRAY=15
ASN1=16
ASNFILENAME=17
ASSIGN=18
ASSIG_OP=19
ASTERISK=20
B=21
BASE=22
BITSTR=23
BLOCK=24
C=25
CALL=26
CHANNEL=27
CHOICE=28
CIF=29
CLOSED_RANGE=30
COMMA=31
COMMENT=32
COMMENT2=33
COMPOSITE_STATE=34
CONDITIONAL=35
CONNECT=36
CONNECTION=37
CONSTANT=38
CONSTANTS=39
CREATE=40
D=41
DASH=42
DCL=43
DECISION=44
DEFAULT=45
DIGITS=46
DIV=47
DOT=48
E=49
ELSE=50
EMPTYSTR=51
END=52
ENDALTERNATIVE=53
ENDBLOCK=54
ENDCHANNEL=55
ENDCONNECTION=56
ENDDECISION=57
ENDFOR=58
ENDNEWTYPE=59
ENDPROCEDURE=60
ENDPROCESS=61
ENDSTATE=62
ENDSUBSTRUCTURE=63
ENDSYNTYPE=64
ENDSYSTEM=65
ENDTEXT=66
ENTRY_POINT=67
EQ=68
EXPONENT=69
EXPORT=70
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
EXPORTED=71
EXPRESSION=72
EXTERNAL=73
Exponent=74
F=75
FALSE=76
FI=77
FIELD=78
FIELDS=79
FIELD_NAME=80
FLOAT=81
FLOAT2=82
FLOATING_LABEL=83
FOR=84
FPAR=85
FROM=86
G=87
GE=88
GEODE=89
GROUND=90
GT=91
H=92
HYPERLINK=93
I=94
ID=95
IF=96
IFTHENELSE=97
IMPLIES=98
IMPORT=99
IN=100
INFORMAL_TEXT=101
INOUT=102
INPUT=103
INPUTLIST=104
INPUT_NONE=105
INT=106
J=107
JOIN=108
K=109
KEEP=110
L=111
LABEL=112
LE=113
LITERAL=114
LT=115
L_BRACKET=116
L_PAREN=117
M=118
MANTISSA=119
MINUS_INFINITY=120
MKSTRING=121
MOD=122
N=123
NEG=124
NEQ=125
NEWTYPE=126
NEXTSTATE=127
NONE=128
NOT=129
NUMBER_OF_INSTANCES=130
O=131
OCTSTR=132
OPEN_RANGE=133
OR=134
OUT=135
OUTPUT=136
OUTPUT_BODY=137
P=138
PARAM=139
PARAMNAMES=140
PARAMS=141
PAREN=142
PFPAR=143
PLUS=144
PLUS_INFINITY=145
POINT=146
PRIMARY=147
PRIORITY=148
PROCEDURE=149
PROCEDURE_CALL=150
PROCEDURE_NAME=151
PROCESS=152
PROVIDED=153
Q=154
QUESTION=155
R=156
RANGE=157
REFERENCED=158
REM=159
RESET=160
RETURN=161
RETURNS=162
ROUTE=163
R_BRACKET=164
R_PAREN=165
S=166
SAVE=167
SELECTOR=168
SEMI=169
SEQOF=170
SEQUENCE=171
SET=172
SIGNAL=173
SIGNALROUTE=174
SIGNAL_LIST=175
SORT=176
SPECIFIC=177
START=178
STATE=179
STATELIST=180
STATE_AGGREGATION=181
STATE_PARTITION_CONNECTION=182
STIMULUS=183
STOP=184
STOPIF=185
STR=186
STRING=187
STRUCT=188
SUBSTRUCTURE=189
SYNONYM=190
SYNONYM_LIST=191
SYNTYPE=192
SYSTEM=193
T=194
TASK=195
TASK_BODY=196
TERMINATOR=197
TEXT=198
TEXTAREA=199
TEXTAREA_CONTENT=200
THEN=201
THIS=202
TIMER=203
TO=204
TRANSITION=205
TRUE=206
TYPE=207
TYPE_INSTANCE=208
U=209
USE=210
V=211
VALUE=212
VARIABLE=213
VARIABLES=214
VIA=215
VIAPATH=216
VIEW=217
W=218
WITH=219
WS=220
X=221
XOR=222
Y=223
Z=224
Maxime Perrotin's avatar
Maxime Perrotin committed
244
245
246
247

# token names
tokenNamesMap = {
    0: "<invalid>", 1: "<EOR>", 2: "<DOWN>", 3: "<UP>",
248
249
    -1: "EOF", 225: "T__225", 226: "T__226", 227: "T__227", 228: "T__228", 
    229: "T__229", 230: "T__230", 231: "T__231", 4: "A", 5: "ACTION", 6: "ACTIVE", 
Maxime Perrotin's avatar
Maxime Perrotin committed
250
251
252
253
254
255
256
257
258
259
260
261
    7: "AGGREGATION", 8: "ALL", 9: "ALPHA", 10: "ALTERNATIVE", 11: "AND", 
    12: "ANSWER", 13: "ANY", 14: "APPEND", 15: "ARRAY", 16: "ASN1", 17: "ASNFILENAME", 
    18: "ASSIGN", 19: "ASSIG_OP", 20: "ASTERISK", 21: "B", 22: "BASE", 23: "BITSTR", 
    24: "BLOCK", 25: "C", 26: "CALL", 27: "CHANNEL", 28: "CHOICE", 29: "CIF", 
    30: "CLOSED_RANGE", 31: "COMMA", 32: "COMMENT", 33: "COMMENT2", 34: "COMPOSITE_STATE", 
    35: "CONDITIONAL", 36: "CONNECT", 37: "CONNECTION", 38: "CONSTANT", 
    39: "CONSTANTS", 40: "CREATE", 41: "D", 42: "DASH", 43: "DCL", 44: "DECISION", 
    45: "DEFAULT", 46: "DIGITS", 47: "DIV", 48: "DOT", 49: "E", 50: "ELSE", 
    51: "EMPTYSTR", 52: "END", 53: "ENDALTERNATIVE", 54: "ENDBLOCK", 55: "ENDCHANNEL", 
    56: "ENDCONNECTION", 57: "ENDDECISION", 58: "ENDFOR", 59: "ENDNEWTYPE", 
    60: "ENDPROCEDURE", 61: "ENDPROCESS", 62: "ENDSTATE", 63: "ENDSUBSTRUCTURE", 
    64: "ENDSYNTYPE", 65: "ENDSYSTEM", 66: "ENDTEXT", 67: "ENTRY_POINT", 
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
    68: "EQ", 69: "EXPONENT", 70: "EXPORT", 71: "EXPORTED", 72: "EXPRESSION", 
    73: "EXTERNAL", 74: "Exponent", 75: "F", 76: "FALSE", 77: "FI", 78: "FIELD", 
    79: "FIELDS", 80: "FIELD_NAME", 81: "FLOAT", 82: "FLOAT2", 83: "FLOATING_LABEL", 
    84: "FOR", 85: "FPAR", 86: "FROM", 87: "G", 88: "GE", 89: "GEODE", 90: "GROUND", 
    91: "GT", 92: "H", 93: "HYPERLINK", 94: "I", 95: "ID", 96: "IF", 97: "IFTHENELSE", 
    98: "IMPLIES", 99: "IMPORT", 100: "IN", 101: "INFORMAL_TEXT", 102: "INOUT", 
    103: "INPUT", 104: "INPUTLIST", 105: "INPUT_NONE", 106: "INT", 107: "J", 
    108: "JOIN", 109: "K", 110: "KEEP", 111: "L", 112: "LABEL", 113: "LE", 
    114: "LITERAL", 115: "LT", 116: "L_BRACKET", 117: "L_PAREN", 118: "M", 
    119: "MANTISSA", 120: "MINUS_INFINITY", 121: "MKSTRING", 122: "MOD", 
    123: "N", 124: "NEG", 125: "NEQ", 126: "NEWTYPE", 127: "NEXTSTATE", 
    128: "NONE", 129: "NOT", 130: "NUMBER_OF_INSTANCES", 131: "O", 132: "OCTSTR", 
    133: "OPEN_RANGE", 134: "OR", 135: "OUT", 136: "OUTPUT", 137: "OUTPUT_BODY", 
    138: "P", 139: "PARAM", 140: "PARAMNAMES", 141: "PARAMS", 142: "PAREN", 
    143: "PFPAR", 144: "PLUS", 145: "PLUS_INFINITY", 146: "POINT", 147: "PRIMARY", 
    148: "PRIORITY", 149: "PROCEDURE", 150: "PROCEDURE_CALL", 151: "PROCEDURE_NAME", 
    152: "PROCESS", 153: "PROVIDED", 154: "Q", 155: "QUESTION", 156: "R", 
    157: "RANGE", 158: "REFERENCED", 159: "REM", 160: "RESET", 161: "RETURN", 
    162: "RETURNS", 163: "ROUTE", 164: "R_BRACKET", 165: "R_PAREN", 166: "S", 
    167: "SAVE", 168: "SELECTOR", 169: "SEMI", 170: "SEQOF", 171: "SEQUENCE", 
    172: "SET", 173: "SIGNAL", 174: "SIGNALROUTE", 175: "SIGNAL_LIST", 176: "SORT", 
    177: "SPECIFIC", 178: "START", 179: "STATE", 180: "STATELIST", 181: "STATE_AGGREGATION", 
    182: "STATE_PARTITION_CONNECTION", 183: "STIMULUS", 184: "STOP", 185: "STOPIF", 
    186: "STR", 187: "STRING", 188: "STRUCT", 189: "SUBSTRUCTURE", 190: "SYNONYM", 
    191: "SYNONYM_LIST", 192: "SYNTYPE", 193: "SYSTEM", 194: "T", 195: "TASK", 
    196: "TASK_BODY", 197: "TERMINATOR", 198: "TEXT", 199: "TEXTAREA", 200: "TEXTAREA_CONTENT", 
    201: "THEN", 202: "THIS", 203: "TIMER", 204: "TO", 205: "TRANSITION", 
    206: "TRUE", 207: "TYPE", 208: "TYPE_INSTANCE", 209: "U", 210: "USE", 
    211: "V", 212: "VALUE", 213: "VARIABLE", 214: "VARIABLES", 215: "VIA", 
    216: "VIAPATH", 217: "VIEW", 218: "W", 219: "WITH", 220: "WS", 221: "X", 
    222: "XOR", 223: "Y", 224: "Z"
Maxime Perrotin's avatar
Maxime Perrotin committed
293
294
}
Token.registerTokenNamesMap(tokenNamesMap)
Maxime Perrotin's avatar
Maxime Perrotin committed
295
296
297

# token names
tokenNames = [
Maxime Perrotin's avatar
Maxime Perrotin committed
298
299
300
301
302
    "<invalid>", "<EOR>", "<DOWN>", "<UP>",
    "A", "ACTION", "ACTIVE", "AGGREGATION", "ALL", "ALPHA", "ALTERNATIVE", 
    "AND", "ANSWER", "ANY", "APPEND", "ARRAY", "ASN1", "ASNFILENAME", "ASSIGN", 
    "ASSIG_OP", "ASTERISK", "B", "BASE", "BITSTR", "BLOCK", "C", "CALL", 
    "CHANNEL", "CHOICE", "CIF", "CLOSED_RANGE", "COMMA", "COMMENT", "COMMENT2", 
303
    "COMPOSITE_STATE", "CONDITIONAL", "CONNECT", "CONNECTION", "CONSTANT", 
Maxime Perrotin's avatar
Maxime Perrotin committed
304
305
306
307
    "CONSTANTS", "CREATE", "D", "DASH", "DCL", "DECISION", "DEFAULT", "DIGITS", 
    "DIV", "DOT", "E", "ELSE", "EMPTYSTR", "END", "ENDALTERNATIVE", "ENDBLOCK", 
    "ENDCHANNEL", "ENDCONNECTION", "ENDDECISION", "ENDFOR", "ENDNEWTYPE", 
    "ENDPROCEDURE", "ENDPROCESS", "ENDSTATE", "ENDSUBSTRUCTURE", "ENDSYNTYPE", 
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
    "ENDSYSTEM", "ENDTEXT", "ENTRY_POINT", "EQ", "EXPONENT", "EXPORT", "EXPORTED", 
    "EXPRESSION", "EXTERNAL", "Exponent", "F", "FALSE", "FI", "FIELD", "FIELDS", 
    "FIELD_NAME", "FLOAT", "FLOAT2", "FLOATING_LABEL", "FOR", "FPAR", "FROM", 
    "G", "GE", "GEODE", "GROUND", "GT", "H", "HYPERLINK", "I", "ID", "IF", 
    "IFTHENELSE", "IMPLIES", "IMPORT", "IN", "INFORMAL_TEXT", "INOUT", "INPUT", 
    "INPUTLIST", "INPUT_NONE", "INT", "J", "JOIN", "K", "KEEP", "L", "LABEL", 
    "LE", "LITERAL", "LT", "L_BRACKET", "L_PAREN", "M", "MANTISSA", "MINUS_INFINITY", 
    "MKSTRING", "MOD", "N", "NEG", "NEQ", "NEWTYPE", "NEXTSTATE", "NONE", 
    "NOT", "NUMBER_OF_INSTANCES", "O", "OCTSTR", "OPEN_RANGE", "OR", "OUT", 
    "OUTPUT", "OUTPUT_BODY", "P", "PARAM", "PARAMNAMES", "PARAMS", "PAREN", 
    "PFPAR", "PLUS", "PLUS_INFINITY", "POINT", "PRIMARY", "PRIORITY", "PROCEDURE", 
    "PROCEDURE_CALL", "PROCEDURE_NAME", "PROCESS", "PROVIDED", "Q", "QUESTION", 
    "R", "RANGE", "REFERENCED", "REM", "RESET", "RETURN", "RETURNS", "ROUTE", 
    "R_BRACKET", "R_PAREN", "S", "SAVE", "SELECTOR", "SEMI", "SEQOF", "SEQUENCE", 
    "SET", "SIGNAL", "SIGNALROUTE", "SIGNAL_LIST", "SORT", "SPECIFIC", "START", 
    "STATE", "STATELIST", "STATE_AGGREGATION", "STATE_PARTITION_CONNECTION", 
    "STIMULUS", "STOP", "STOPIF", "STR", "STRING", "STRUCT", "SUBSTRUCTURE", 
    "SYNONYM", "SYNONYM_LIST", "SYNTYPE", "SYSTEM", "T", "TASK", "TASK_BODY", 
    "TERMINATOR", "TEXT", "TEXTAREA", "TEXTAREA_CONTENT", "THEN", "THIS", 
    "TIMER", "TO", "TRANSITION", "TRUE", "TYPE", "TYPE_INSTANCE", "U", "USE", 
    "V", "VALUE", "VARIABLE", "VARIABLES", "VIA", "VIAPATH", "VIEW", "W", 
    "WITH", "WS", "X", "XOR", "Y", "Z", "'!'", "'(.'", "'*/'", "'->'", "'.)'", 
    "'/* CIF'", "':'"
Maxime Perrotin's avatar
Maxime Perrotin committed
331
332
333
334
335
336
]



class sdl92Parser(Parser):
    grammarFileName = "sdl92.g"
Maxime Perrotin's avatar
Maxime Perrotin committed
337
    api_version = 1
Maxime Perrotin's avatar
Maxime Perrotin committed
338
339
340
341
342
343
    tokenNames = tokenNames

    def __init__(self, input, state=None, *args, **kwargs):
        if state is None:
            state = RecognizerSharedState()

Maxime Perrotin's avatar
Maxime Perrotin committed
344
        super().__init__(input, state, *args, **kwargs)
Maxime Perrotin's avatar
Maxime Perrotin committed
345

346
347
348
349
350
351
352
353
354
        self.dfa54 = self.DFA54(
            self, 54,
            eot = self.DFA54_eot,
            eof = self.DFA54_eof,
            min = self.DFA54_min,
            max = self.DFA54_max,
            accept = self.DFA54_accept,
            special = self.DFA54_special,
            transition = self.DFA54_transition
Maxime Perrotin's avatar
Maxime Perrotin committed
355
356
            )

357
358
359
360
361
362
363
364
365
        self.dfa95 = self.DFA95(
            self, 95,
            eot = self.DFA95_eot,
            eof = self.DFA95_eof,
            min = self.DFA95_min,
            max = self.DFA95_max,
            accept = self.DFA95_accept,
            special = self.DFA95_special,
            transition = self.DFA95_transition
366
367
            )

368
369
370
371
372
373
374
375
376
        self.dfa137 = self.DFA137(
            self, 137,
            eot = self.DFA137_eot,
            eof = self.DFA137_eof,
            min = self.DFA137_min,
            max = self.DFA137_max,
            accept = self.DFA137_accept,
            special = self.DFA137_special,
            transition = self.DFA137_transition
377
378
            )

379
380
381
382
383
384
385
386
387
        self.dfa198 = self.DFA198(
            self, 198,
            eot = self.DFA198_eot,
            eof = self.DFA198_eof,
            min = self.DFA198_min,
            max = self.DFA198_max,
            accept = self.DFA198_accept,
            special = self.DFA198_special,
            transition = self.DFA198_transition
388
389
            )

Maxime Perrotin's avatar
Maxime Perrotin committed
390
391
392



Maxime Perrotin's avatar
Maxime Perrotin committed
393
        self.delegates = []
Maxime Perrotin's avatar
Maxime Perrotin committed
394
395
396
397
398

        self._adaptor = None
        self.adaptor = CommonTreeAdaptor()


Maxime Perrotin's avatar
Maxime Perrotin committed
399

Maxime Perrotin's avatar
Maxime Perrotin committed
400
401
402
403
404
405
406
407
408
409
410
    def getTreeAdaptor(self):
        return self._adaptor

    def setTreeAdaptor(self, adaptor):
        self._adaptor = adaptor

    adaptor = property(getTreeAdaptor, setTreeAdaptor)


    class pr_file_return(ParserRuleReturnScope):
        def __init__(self):
Maxime Perrotin's avatar
Maxime Perrotin committed
411
            super().__init__()
Maxime Perrotin's avatar
Maxime Perrotin committed
412
413
414
415
416
417

            self.tree = None




Maxime Perrotin's avatar
Maxime Perrotin committed
418

Maxime Perrotin's avatar
Maxime Perrotin committed
419
    # $ANTLR start "pr_file"
420
    # sdl92.g:146:1: pr_file : ( use_clause | system_definition | process_definition )+ ;
Maxime Perrotin's avatar
Maxime Perrotin committed
421
422
423
424
    def pr_file(self, ):
        retval = self.pr_file_return()
        retval.start = self.input.LT(1)

Maxime Perrotin's avatar
Maxime Perrotin committed
425

Maxime Perrotin's avatar
Maxime Perrotin committed
426
427
428
429
430
431
432
433
434
        root_0 = None

        use_clause1 = None
        system_definition2 = None
        process_definition3 = None


        try:
            try:
435
436
                # sdl92.g:147:9: ( ( use_clause | system_definition | process_definition )+ )
                # sdl92.g:147:17: ( use_clause | system_definition | process_definition )+
Maxime Perrotin's avatar
Maxime Perrotin committed
437
438
439
                pass 
                root_0 = self._adaptor.nil()

Maxime Perrotin's avatar
Maxime Perrotin committed
440

441
                # sdl92.g:147:17: ( use_clause | system_definition | process_definition )+
Maxime Perrotin's avatar
Maxime Perrotin committed
442
443
444
445
                cnt1 = 0
                while True: #loop1
                    alt1 = 4
                    LA1 = self.input.LA(1)
446
                    if LA1 in {230}:
447
448
                        LA1_2 = self.input.LA(2)

Maxime Perrotin's avatar
Maxime Perrotin committed
449
                        if (LA1_2 == KEEP) :
450
                            alt1 = 1
Maxime Perrotin's avatar
Maxime Perrotin committed
451
452
                        elif (LA1_2 in {ANSWER, COMMENT, CONNECT, DECISION, INPUT, JOIN, LABEL, NEXTSTATE, OUTPUT, PROCEDURE, PROCEDURE_CALL, PROCESS, PROVIDED, RETURN, START, STATE, STOP, TASK, TEXT}) :
                            alt1 = 3
453
454


Maxime Perrotin's avatar
Maxime Perrotin committed
455
                    elif LA1 in {USE}:
Maxime Perrotin's avatar
Maxime Perrotin committed
456
                        alt1 = 1
Maxime Perrotin's avatar
Maxime Perrotin committed
457
                    elif LA1 in {SYSTEM}:
Maxime Perrotin's avatar
Maxime Perrotin committed
458
                        alt1 = 2
Maxime Perrotin's avatar
Maxime Perrotin committed
459
                    elif LA1 in {PROCESS}:
Maxime Perrotin's avatar
Maxime Perrotin committed
460
461
462
                        alt1 = 3

                    if alt1 == 1:
463
                        # sdl92.g:147:18: use_clause
Maxime Perrotin's avatar
Maxime Perrotin committed
464
                        pass 
465
                        self._state.following.append(self.FOLLOW_use_clause_in_pr_file1375)
Maxime Perrotin's avatar
Maxime Perrotin committed
466
467
468
469
470
471
472
                        use_clause1 = self.use_clause()

                        self._state.following.pop()
                        if self._state.backtracking == 0:
                            self._adaptor.addChild(root_0, use_clause1.tree)


Maxime Perrotin's avatar
Maxime Perrotin committed
473

Maxime Perrotin's avatar
Maxime Perrotin committed
474
                    elif alt1 == 2:
475
                        # sdl92.g:148:19: system_definition
Maxime Perrotin's avatar
Maxime Perrotin committed
476
                        pass 
477
                        self._state.following.append(self.FOLLOW_system_definition_in_pr_file1395)
Maxime Perrotin's avatar
Maxime Perrotin committed
478
479
480
481
482
483
484
                        system_definition2 = self.system_definition()

                        self._state.following.pop()
                        if self._state.backtracking == 0:
                            self._adaptor.addChild(root_0, system_definition2.tree)


Maxime Perrotin's avatar
Maxime Perrotin committed
485

Maxime Perrotin's avatar
Maxime Perrotin committed
486
                    elif alt1 == 3:
487
                        # sdl92.g:149:19: process_definition
Maxime Perrotin's avatar
Maxime Perrotin committed
488
                        pass 
489
                        self._state.following.append(self.FOLLOW_process_definition_in_pr_file1415)
Maxime Perrotin's avatar
Maxime Perrotin committed
490
491
492
493
494
495
496
                        process_definition3 = self.process_definition()

                        self._state.following.pop()
                        if self._state.backtracking == 0:
                            self._adaptor.addChild(root_0, process_definition3.tree)


Maxime Perrotin's avatar
Maxime Perrotin committed
497

Maxime Perrotin's avatar
Maxime Perrotin committed
498
499
500
501
502
503
504
                    else:
                        if cnt1 >= 1:
                            break #loop1

                        if self._state.backtracking > 0:
                            raise BacktrackingFailed

Maxime Perrotin's avatar
Maxime Perrotin committed
505

Maxime Perrotin's avatar
Maxime Perrotin committed
506
507
508
509
510
511
512
                        eee = EarlyExitException(1, self.input)
                        raise eee

                    cnt1 += 1



Maxime Perrotin's avatar
Maxime Perrotin committed
513

Maxime Perrotin's avatar
Maxime Perrotin committed
514
515
516
                retval.stop = self.input.LT(-1)


Maxime Perrotin's avatar
Maxime Perrotin committed
517
                if self._state.backtracking == 0:
Maxime Perrotin's avatar
Maxime Perrotin committed
518
519
520
521
                    retval.tree = self._adaptor.rulePostProcessing(root_0)
                    self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop)


Maxime Perrotin's avatar
Maxime Perrotin committed
522
523

            except RecognitionException as re:
Maxime Perrotin's avatar
Maxime Perrotin committed
524
525
526
527
                self.reportError(re)
                self.recover(self.input, re)
                retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re)

Maxime Perrotin's avatar
Maxime Perrotin committed
528
        finally:
Maxime Perrotin's avatar
Maxime Perrotin committed
529
530
531
532
533
            pass
        return retval

    # $ANTLR end "pr_file"

Maxime Perrotin's avatar
Maxime Perrotin committed
534

Maxime Perrotin's avatar
Maxime Perrotin committed
535
536
    class system_definition_return(ParserRuleReturnScope):
        def __init__(self):
Maxime Perrotin's avatar
Maxime Perrotin committed
537
            super().__init__()
Maxime Perrotin's avatar
Maxime Perrotin committed
538
539
540
541
542
543

            self.tree = None




Maxime Perrotin's avatar
Maxime Perrotin committed
544

Maxime Perrotin's avatar
Maxime Perrotin committed
545
    # $ANTLR start "system_definition"
546
    # sdl92.g:153:1: system_definition : SYSTEM system_name end ( entity_in_system )* ENDSYSTEM ( system_name )? end -> ^( SYSTEM system_name ( entity_in_system )* ) ;
Maxime Perrotin's avatar
Maxime Perrotin committed
547
548
549
550
    def system_definition(self, ):
        retval = self.system_definition_return()
        retval.start = self.input.LT(1)

Maxime Perrotin's avatar
Maxime Perrotin committed
551

Maxime Perrotin's avatar
Maxime Perrotin committed
552
553
554
555
556
557
558
559
560
561
562
563
        root_0 = None

        SYSTEM4 = None
        ENDSYSTEM8 = None
        system_name5 = None
        end6 = None
        entity_in_system7 = None
        system_name9 = None
        end10 = None

        SYSTEM4_tree = None
        ENDSYSTEM8_tree = None
Maxime Perrotin's avatar
Maxime Perrotin committed
564
        stream_SYSTEM = RewriteRuleTokenStream(self._adaptor, "token SYSTEM")
565
        stream_ENDSYSTEM = RewriteRuleTokenStream(self._adaptor, "token ENDSYSTEM")
Maxime Perrotin's avatar
Maxime Perrotin committed
566
567
568
569
570
        stream_entity_in_system = RewriteRuleSubtreeStream(self._adaptor, "rule entity_in_system")
        stream_system_name = RewriteRuleSubtreeStream(self._adaptor, "rule system_name")
        stream_end = RewriteRuleSubtreeStream(self._adaptor, "rule end")
        try:
            try:
571
572
                # sdl92.g:154:9: ( SYSTEM system_name end ( entity_in_system )* ENDSYSTEM ( system_name )? end -> ^( SYSTEM system_name ( entity_in_system )* ) )
                # sdl92.g:154:17: SYSTEM system_name end ( entity_in_system )* ENDSYSTEM ( system_name )? end
Maxime Perrotin's avatar
Maxime Perrotin committed
573
                pass 
Maxime Perrotin's avatar
Maxime Perrotin committed
574
                SYSTEM4 = self.match(self.input, SYSTEM, self.FOLLOW_SYSTEM_in_system_definition1449) 
Maxime Perrotin's avatar
Maxime Perrotin committed
575
576
                if self._state.backtracking == 0:
                    stream_SYSTEM.add(SYSTEM4)
Maxime Perrotin's avatar
Maxime Perrotin committed
577
578


579
                self._state.following.append(self.FOLLOW_system_name_in_system_definition1451)
Maxime Perrotin's avatar
Maxime Perrotin committed
580
581
582
583
584
                system_name5 = self.system_name()

                self._state.following.pop()
                if self._state.backtracking == 0:
                    stream_system_name.add(system_name5.tree)
Maxime Perrotin's avatar
Maxime Perrotin committed
585
586


587
                self._state.following.append(self.FOLLOW_end_in_system_definition1453)
Maxime Perrotin's avatar
Maxime Perrotin committed
588
589
590
591
592
                end6 = self.end()

                self._state.following.pop()
                if self._state.backtracking == 0:
                    stream_end.add(end6.tree)
Maxime Perrotin's avatar
Maxime Perrotin committed
593
594


595
                # sdl92.g:155:17: ( entity_in_system )*
Maxime Perrotin's avatar
Maxime Perrotin committed
596
597
598
599
                while True: #loop2
                    alt2 = 2
                    LA2_0 = self.input.LA(1)

600
                    if (LA2_0 in {BLOCK, CHANNEL, EXPORTED, PROCEDURE, SIGNAL, 230}) :
Maxime Perrotin's avatar
Maxime Perrotin committed
601
602
603
604
                        alt2 = 1


                    if alt2 == 1:
Maxime Perrotin's avatar
Maxime Perrotin committed
605
                        # sdl92.g:155:17: entity_in_system
Maxime Perrotin's avatar
Maxime Perrotin committed
606
                        pass 
607
                        self._state.following.append(self.FOLLOW_entity_in_system_in_system_definition1471)
Maxime Perrotin's avatar
Maxime Perrotin committed
608
609
610
611
612
613
614
                        entity_in_system7 = self.entity_in_system()

                        self._state.following.pop()
                        if self._state.backtracking == 0:
                            stream_entity_in_system.add(entity_in_system7.tree)


Maxime Perrotin's avatar
Maxime Perrotin committed
615

Maxime Perrotin's avatar
Maxime Perrotin committed
616
617
                    else:
                        break #loop2
Maxime Perrotin's avatar
Maxime Perrotin committed
618
619
620


                ENDSYSTEM8 = self.match(self.input, ENDSYSTEM, self.FOLLOW_ENDSYSTEM_in_system_definition1490) 
Maxime Perrotin's avatar
Maxime Perrotin committed
621
622
                if self._state.backtracking == 0:
                    stream_ENDSYSTEM.add(ENDSYSTEM8)
Maxime Perrotin's avatar
Maxime Perrotin committed
623
624


625
                # sdl92.g:156:27: ( system_name )?
Maxime Perrotin's avatar
Maxime Perrotin committed
626
627
628
629
630
631
                alt3 = 2
                LA3_0 = self.input.LA(1)

                if (LA3_0 == ID) :
                    alt3 = 1
                if alt3 == 1:
Maxime Perrotin's avatar
Maxime Perrotin committed
632
                    # sdl92.g:156:27: system_name
Maxime Perrotin's avatar
Maxime Perrotin committed
633
                    pass 
634
                    self._state.following.append(self.FOLLOW_system_name_in_system_definition1492)
Maxime Perrotin's avatar
Maxime Perrotin committed
635
636
637
638
639
640
641
642
                    system_name9 = self.system_name()

                    self._state.following.pop()
                    if self._state.backtracking == 0:
                        stream_system_name.add(system_name9.tree)



Maxime Perrotin's avatar
Maxime Perrotin committed
643
644


645
                self._state.following.append(self.FOLLOW_end_in_system_definition1495)
Maxime Perrotin's avatar
Maxime Perrotin committed
646
647
648
649
650
651
                end10 = self.end()

                self._state.following.pop()
                if self._state.backtracking == 0:
                    stream_end.add(end10.tree)

Maxime Perrotin's avatar
Maxime Perrotin committed
652

Maxime Perrotin's avatar
Maxime Perrotin committed
653
                # AST Rewrite
Maxime Perrotin's avatar
Maxime Perrotin committed
654
                # elements: SYSTEM, system_name, entity_in_system
Maxime Perrotin's avatar
Maxime Perrotin committed
655
656
657
658
659
660
661
662
663
664
665
666
667
668
                # token labels: 
                # rule labels: retval
                # token list labels: 
                # rule list labels: 
                # wildcard labels: 
                if self._state.backtracking == 0:
                    retval.tree = root_0
                    if retval is not None:
                        stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree)
                    else:
                        stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None)


                    root_0 = self._adaptor.nil()
669
670
                    # 157:9: -> ^( SYSTEM system_name ( entity_in_system )* )
                    # sdl92.g:157:17: ^( SYSTEM system_name ( entity_in_system )* )
Maxime Perrotin's avatar
Maxime Perrotin committed
671
                    root_1 = self._adaptor.nil()
Maxime Perrotin's avatar
Maxime Perrotin committed
672
673
674
                    root_1 = self._adaptor.becomeRoot(
                    stream_SYSTEM.nextNode()
                    , root_1)
Maxime Perrotin's avatar
Maxime Perrotin committed
675
676

                    self._adaptor.addChild(root_1, stream_system_name.nextTree())
Maxime Perrotin's avatar
Maxime Perrotin committed
677

678
                    # sdl92.g:157:38: ( entity_in_system )*
Maxime Perrotin's avatar
Maxime Perrotin committed
679
680
681
682
683
684
685
686
687
688
                    while stream_entity_in_system.hasNext():
                        self._adaptor.addChild(root_1, stream_entity_in_system.nextTree())


                    stream_entity_in_system.reset();

                    self._adaptor.addChild(root_0, root_1)



Maxime Perrotin's avatar
Maxime Perrotin committed
689

Maxime Perrotin's avatar
Maxime Perrotin committed
690
691
692
693
                    retval.tree = root_0



Maxime Perrotin's avatar
Maxime Perrotin committed
694
695


Maxime Perrotin's avatar
Maxime Perrotin committed
696
697
698
                retval.stop = self.input.LT(-1)


Maxime Perrotin's avatar
Maxime Perrotin committed
699
                if self._state.backtracking == 0:
Maxime Perrotin's avatar
Maxime Perrotin committed
700
701
702
703
                    retval.tree = self._adaptor.rulePostProcessing(root_0)
                    self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop)


Maxime Perrotin's avatar
Maxime Perrotin committed
704
705

            except RecognitionException as re:
Maxime Perrotin's avatar
Maxime Perrotin committed
706
707
708
709
                self.reportError(re)
                self.recover(self.input, re)
                retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re)

Maxime Perrotin's avatar
Maxime Perrotin committed
710
        finally:
Maxime Perrotin's avatar
Maxime Perrotin committed
711
712
713
714
715
            pass
        return retval

    # $ANTLR end "system_definition"

Maxime Perrotin's avatar
Maxime Perrotin committed
716

Maxime Perrotin's avatar
Maxime Perrotin committed
717
718
    class use_clause_return(ParserRuleReturnScope):
        def __init__(self):
Maxime Perrotin's avatar
Maxime Perrotin committed
719
            super().__init__()
Maxime Perrotin's avatar
Maxime Perrotin committed
720
721
722
723
724
725

            self.tree = None




Maxime Perrotin's avatar
Maxime Perrotin committed
726

Maxime Perrotin's avatar
Maxime Perrotin committed
727
    # $ANTLR start "use_clause"
728
    # sdl92.g:161:1: use_clause : ( use_asn1 )? USE package_name ( '/' def_selection_list )? end -> ^( USE ( use_asn1 )? ( end )? package_name ( def_selection_list )? ) ;
Maxime Perrotin's avatar
Maxime Perrotin committed
729
730
731
732
    def use_clause(self, ):
        retval = self.use_clause_return()
        retval.start = self.input.LT(1)

Maxime Perrotin's avatar
Maxime Perrotin committed
733

Maxime Perrotin's avatar
Maxime Perrotin committed
734
735
736
        root_0 = None

        USE12 = None
737
        char_literal14 = None
Maxime Perrotin's avatar
Maxime Perrotin committed
738
739
        use_asn111 = None
        package_name13 = None
740
741
        def_selection_list15 = None
        end16 = None
Maxime Perrotin's avatar
Maxime Perrotin committed
742
743

        USE12_tree = None
744
        char_literal14_tree = None
Maxime Perrotin's avatar
Maxime Perrotin committed
745
        stream_DIV = RewriteRuleTokenStream(self._adaptor, "token DIV")
746
        stream_USE = RewriteRuleTokenStream(self._adaptor, "token USE")
Maxime Perrotin's avatar
Maxime Perrotin committed
747
748
        stream_use_asn1 = RewriteRuleSubtreeStream(self._adaptor, "rule use_asn1")
        stream_package_name = RewriteRuleSubtreeStream(self._adaptor, "rule package_name")
Maxime Perrotin's avatar
Maxime Perrotin committed
749
        stream_end = RewriteRuleSubtreeStream(self._adaptor, "rule end")
750
        stream_def_selection_list = RewriteRuleSubtreeStream(self._adaptor, "rule def_selection_list")
Maxime Perrotin's avatar
Maxime Perrotin committed
751
752
        try:
            try:
753
754
                # sdl92.g:162:9: ( ( use_asn1 )? USE package_name ( '/' def_selection_list )? end -> ^( USE ( use_asn1 )? ( end )? package_name ( def_selection_list )? ) )
                # sdl92.g:162:17: ( use_asn1 )? USE package_name ( '/' def_selection_list )? end
Maxime Perrotin's avatar
Maxime Perrotin committed
755
                pass 
756
                # sdl92.g:162:17: ( use_asn1 )?
Maxime Perrotin's avatar
Maxime Perrotin committed
757
758
759
                alt4 = 2
                LA4_0 = self.input.LA(1)

760
                if (LA4_0 == 230) :
Maxime Perrotin's avatar
Maxime Perrotin committed
761
762
                    alt4 = 1
                if alt4 == 1:
Maxime Perrotin's avatar
Maxime Perrotin committed
763
                    # sdl92.g:162:17: use_asn1
Maxime Perrotin's avatar
Maxime Perrotin committed
764
                    pass 
765
                    self._state.following.append(self.FOLLOW_use_asn1_in_use_clause1551)
Maxime Perrotin's avatar
Maxime Perrotin committed
766
767
768
769
770
771
772
773
                    use_asn111 = self.use_asn1()

                    self._state.following.pop()
                    if self._state.backtracking == 0:
                        stream_use_asn1.add(use_asn111.tree)



Maxime Perrotin's avatar
Maxime Perrotin committed
774
775
776


                USE12 = self.match(self.input, USE, self.FOLLOW_USE_in_use_clause1570) 
Maxime Perrotin's avatar
Maxime Perrotin committed
777
778
                if self._state.backtracking == 0:
                    stream_USE.add(USE12)
Maxime Perrotin's avatar
Maxime Perrotin committed
779
780


781
                self._state.following.append(self.FOLLOW_package_name_in_use_clause1572)
Maxime Perrotin's avatar
Maxime Perrotin committed
782
783
784
785
786
                package_name13 = self.package_name()

                self._state.following.pop()
                if self._state.backtracking == 0:
                    stream_package_name.add(package_name13.tree)
Maxime Perrotin's avatar
Maxime Perrotin committed
787
788


789
                # sdl92.g:164:17: ( '/' def_selection_list )?
790
791
792
793
794
795
                alt5 = 2
                LA5_0 = self.input.LA(1)

                if (LA5_0 == DIV) :
                    alt5 = 1
                if alt5 == 1:
796
                    # sdl92.g:164:18: '/' def_selection_list
797
                    pass 
Maxime Perrotin's avatar
Maxime Perrotin committed
798
                    char_literal14 = self.match(self.input, DIV, self.FOLLOW_DIV_in_use_clause1591) 
799
800
                    if self._state.backtracking == 0:
                        stream_DIV.add(char_literal14)
Maxime Perrotin's avatar
Maxime Perrotin committed
801
802


803
                    self._state.following.append(self.FOLLOW_def_selection_list_in_use_clause1593)
804
805
806
807
808
809
810
811
                    def_selection_list15 = self.def_selection_list()

                    self._state.following.pop()
                    if self._state.backtracking == 0:
                        stream_def_selection_list.add(def_selection_list15.tree)



Maxime Perrotin's avatar
Maxime Perrotin committed
812
813


814
                self._state.following.append(self.FOLLOW_end_in_use_clause1614)
815
                end16 = self.end()
Maxime Perrotin's avatar
Maxime Perrotin committed
816
817
818

                self._state.following.pop()
                if self._state.backtracking == 0:
819
                    stream_end.add(end16.tree)
Maxime Perrotin's avatar
Maxime Perrotin committed
820

Maxime Perrotin's avatar
Maxime Perrotin committed
821

Maxime Perrotin's avatar
Maxime Perrotin committed
822
                # AST Rewrite
Maxime Perrotin's avatar
Maxime Perrotin committed
823
                # elements: USE, use_asn1, end, package_name, def_selection_list
Maxime Perrotin's avatar
Maxime Perrotin committed
824
825
826
827
828
829
830
831
832
833
834
835
836
837
                # token labels: 
                # rule labels: retval
                # token list labels: 
                # rule list labels: 
                # wildcard labels: 
                if self._state.backtracking == 0:
                    retval.tree = root_0
                    if retval is not None:
                        stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree)
                    else:
                        stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None)


                    root_0 = self._adaptor.nil()
838
839
                    # 166:9: -> ^( USE ( use_asn1 )? ( end )? package_name ( def_selection_list )? )
                    # sdl92.g:166:17: ^( USE ( use_asn1 )? ( end )? package_name ( def_selection_list )? )
Maxime Perrotin's avatar
Maxime Perrotin committed
840
                    root_1 = self._adaptor.nil()
Maxime Perrotin's avatar
Maxime Perrotin committed
841
842
843
                    root_1 = self._adaptor.becomeRoot(
                    stream_USE.nextNode()
                    , root_1)
Maxime Perrotin's avatar
Maxime Perrotin committed
844

845
                    # sdl92.g:166:23: ( use_asn1 )?
Maxime Perrotin's avatar
Maxime Perrotin committed
846
847
848
849
850
                    if stream_use_asn1.hasNext():
                        self._adaptor.addChild(root_1, stream_use_asn1.nextTree())


                    stream_use_asn1.reset();
Maxime Perrotin's avatar
Maxime Perrotin committed
851

852
                    # sdl92.g:166:33: ( end )?
853
854
855
856
857
                    if stream_end.hasNext():
                        self._adaptor.addChild(root_1, stream_end.nextTree())


                    stream_end.reset();
Maxime Perrotin's avatar
Maxime Perrotin committed
858

Maxime Perrotin's avatar
Maxime Perrotin committed
859
                    self._adaptor.addChild(root_1, stream_package_name.nextTree())
Maxime Perrotin's avatar
Maxime Perrotin committed
860

861
                    # sdl92.g:166:51: ( def_selection_list )?
862
863
864
865
866
                    if stream_def_selection_list.hasNext():
                        self._adaptor.addChild(root_1, stream_def_selection_list.nextTree())


                    stream_def_selection_list.reset();
Maxime Perrotin's avatar
Maxime Perrotin committed
867
868
869
870
871

                    self._adaptor.addChild(root_0, root_1)



Maxime Perrotin's avatar
Maxime Perrotin committed
872

Maxime Perrotin's avatar
Maxime Perrotin committed
873
874
875
876
                    retval.tree = root_0



Maxime Perrotin's avatar
Maxime Perrotin committed
877
878


Maxime Perrotin's avatar
Maxime Perrotin committed
879
880
881
                retval.stop = self.input.LT(-1)


Maxime Perrotin's avatar
Maxime Perrotin committed
882
                if self._state.backtracking == 0:
Maxime Perrotin's avatar
Maxime Perrotin committed
883
884
885
886
                    retval.tree = self._adaptor.rulePostProcessing(root_0)
                    self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop)


Maxime Perrotin's avatar
Maxime Perrotin committed
887
888

            except RecognitionException as re:
Maxime Perrotin's avatar
Maxime Perrotin committed
889
890
891
892
                self.reportError(re)
                self.recover(self.input, re)
                retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re)

Maxime Perrotin's avatar
Maxime Perrotin committed
893
        finally:
Maxime Perrotin's avatar
Maxime Perrotin committed
894
895
896
897
898
            pass
        return retval

    # $ANTLR end "use_clause"

Maxime Perrotin's avatar
Maxime Perrotin committed
899

900
901
    class def_selection_list_return(ParserRuleReturnScope):
        def __init__(self):
Maxime Perrotin's avatar
Maxime Perrotin committed
902
            super().__init__()
903
904
905
906
907
908

            self.tree = None




Maxime Perrotin's avatar
Maxime Perrotin committed
909

910
    # $ANTLR start "def_selection_list"
Maxime Perrotin's avatar
Maxime Perrotin committed
911
    # sdl92.g:173:1: def_selection_list : ID ( ',' ! ID )* ;
912
913
914
915
    def def_selection_list(self, ):
        retval = self.def_selection_list_return()
        retval.start = self.input.LT(1)

Maxime Perrotin's avatar
Maxime Perrotin committed
916

917
918
919
920
921
922
923
924
925
926
927
928
        root_0 = None

        ID17 = None
        char_literal18 = None
        ID19 = None

        ID17_tree = None
        char_literal18_tree = None
        ID19_tree = None

        try:
            try:
Maxime Perrotin's avatar
Maxime Perrotin committed
929
930
                # sdl92.g:174:9: ( ID ( ',' ! ID )* )
                # sdl92.g:174:17: ID ( ',' ! ID )*
931
932
933
934
                pass 
                root_0 = self._adaptor.nil()


Maxime Perrotin's avatar
Maxime Perrotin committed
935
936
                ID17 = self.match(self.input, ID, self.FOLLOW_ID_in_def_selection_list1678)
                if self._state.backtracking == 0:
937
938
939
                    ID17_tree = self._adaptor.createWithPayload(ID17)
                    self._adaptor.addChild(root_0, ID17_tree)

Maxime Perrotin's avatar
Maxime Perrotin committed
940
941
942


                # sdl92.g:174:20: ( ',' ! ID )*
943
944
945
946
947
948
949
950
951
                while True: #loop6
                    alt6 = 2
                    LA6_0 = self.input.LA(1)

                    if (LA6_0 == COMMA) :
                        alt6 = 1


                    if alt6 == 1:
Maxime Perrotin's avatar
Maxime Perrotin committed
952
                        # sdl92.g:174:21: ',' ! ID
953
                        pass 
Maxime Perrotin's avatar
Maxime Perrotin committed
954
                        char_literal18 = self.match(self.input, COMMA, self.FOLLOW_COMMA_in_def_selection_list1681)
955

Maxime Perrotin's avatar
Maxime Perrotin committed
956
957
                        ID19 = self.match(self.input, ID, self.FOLLOW_ID_in_def_selection_list1684)
                        if self._state.backtracking == 0:
958
959
960
961
962
                            ID19_tree = self._adaptor.createWithPayload(ID19)
                            self._adaptor.addChild(root_0, ID19_tree)



Maxime Perrotin's avatar
Maxime Perrotin committed
963

964
965
966
967
968
                    else:
                        break #loop6



Maxime Perrotin's avatar
Maxime Perrotin committed
969

970
971
972
                retval.stop = self.input.LT(-1)


Maxime Perrotin's avatar
Maxime Perrotin committed
973
                if self._state.backtracking == 0:
974
975
976
977
                    retval.tree = self._adaptor.rulePostProcessing(root_0)
                    self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop)


Maxime Perrotin's avatar
Maxime Perrotin committed
978
979

            except RecognitionException as re:
980
981
982
983
                self.reportError(re)
                self.recover(self.input, re)
                retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re)

Maxime Perrotin's avatar
Maxime Perrotin committed
984
        finally:
985
986
987
988
989
            pass
        return retval

    # $ANTLR end "def_selection_list"

Maxime Perrotin's avatar
Maxime Perrotin committed
990

Maxime Perrotin's avatar
Maxime Perrotin committed
991
992
    class entity_in_system_return(ParserRuleReturnScope):
        def __init__(self):
Maxime Perrotin's avatar
Maxime Perrotin committed
993
            super().__init__()
Maxime Perrotin's avatar
Maxime Perrotin committed
994
995
996
997
998
999

            self.tree = None




Maxime Perrotin's avatar
Maxime Perrotin committed
1000