GlueGen: build/gensrc/java/com/jogamp/gluegen/cgram/StdCParser.java Source File

GlueGen v2.6.0-rc-20250712 GlueGen, Native Binding Generator for Java™ (public API).

StdCParser.java
Go to the documentation of this file.
1// $ANTLR 2.7.7 (2006-11-01): "StdCParser.g" -> "StdCParser.java"$
2
3 package com.jogamp.gluegen.cgram;
4
5 import java.io.*;
6
7 import antlr.CommonAST;
8 import antlr.DumpASTVisitor;
9
10import antlr.TokenBuffer;
11import antlr.TokenStreamException;
12import antlr.TokenStreamIOException;
13import antlr.ANTLRException;
14import antlr.LLkParser;
15import antlr.Token;
16import antlr.TokenStream;
17import antlr.RecognitionException;
18import antlr.NoViableAltException;
19import antlr.MismatchedTokenException;
20import antlr.SemanticException;
21import antlr.ParserSharedInputState;
22import antlr.collections.impl.BitSet;
23import antlr.collections.AST;
24import java.util.Hashtable;
25import antlr.ASTFactory;
26import antlr.ASTPair;
27import antlr.collections.impl.ASTArray;
28
29 public class StdCParser extends antlr.LLkParser implements STDCTokenTypes
30 {
31
32 // Suppport C++-style single-line comments?
33 public static boolean CPPComments = true;
34
35 // access to symbol table
36 public CSymbolTable symbolTable = new CSymbolTable();
37
38 // source for names to unnamed scopes
39 protected int unnamedScopeCounter = 0;
40
41 public boolean isTypedefName(String name) {
42 boolean returnValue = false;
43 TNode node = symbolTable.lookupNameInCurrentScope(name);
44 for (; node != null; node = (TNode) node.getNextSibling() ) {
45 if(node.getType() == LITERAL_typedef) {
46 returnValue = true;
47 break;
48 }
49 }
50 return returnValue;
51 }
52
53
54 public String getAScopeName() {
55 return "" + (unnamedScopeCounter++);
56 }
57
58 public void pushScope(String scopeName) {
59 symbolTable.pushScope(scopeName);
60 }
61
62 public void popScope() {
63 symbolTable.popScope();
64 }
65
66 protected boolean debugging = false;
67
68 public boolean getDebug() {
69 return debugging;
70 }
71
72 public void setDebug(boolean debug) {
73 this.debugging = debug;
74 }
75
76 int traceDepth = 0;
77 public void reportError(RecognitionException ex) {
78 try {
79 System.err.println("ANTLR Parsing Error: "+ex + " token name:" + tokenNames[LA(1)]);
80 ex.printStackTrace(System.err);
81 }
82 catch (TokenStreamException e) {
83 System.err.println("ANTLR Parsing Error: "+ex);
84 ex.printStackTrace(System.err);
85 }
86 }
87 public void reportError(String s) {
88 System.err.println("ANTLR Parsing Error from String: " + s);
89 }
90 public void reportWarning(String s) {
91 System.err.println("ANTLR Parsing Warning from String: " + s);
92 }
93 public void match(int t) throws MismatchedTokenException {
94 if ( debugging ) {
95 for (int x=0; x<traceDepth; x++) System.out.print(" ");
96 try {
97 System.out.println("Match("+tokenNames[t]+") with LA(1)="+
98 tokenNames[LA(1)] + ((inputState.guessing>0)?" [inputState.guessing "+ inputState.guessing + "]":""));
99 }
100 catch (TokenStreamException e) {
101 System.out.println("Match("+tokenNames[t]+") " + ((inputState.guessing>0)?" [inputState.guessing "+ inputState.guessing + "]":""));
102
103 }
104
105 }
106 try {
107 if ( LA(1)!=t ) {
108 if ( debugging ){
109 for (int x=0; x<traceDepth; x++) System.out.print(" ");
110 System.out.println("token mismatch: "+tokenNames[LA(1)]
111 + "!="+tokenNames[t]);
112 }
113 throw new MismatchedTokenException(tokenNames, LT(1), t, false, getFilename());
114
115 } else {
116 // mark token as consumed -- fetch next token deferred until LA/LT
117 consume();
118 }
119 }
120 catch (TokenStreamException e) {
121 }
122
123 }
124 public void traceIn(String rname) {
125 traceDepth += 1;
126 for (int x=0; x<traceDepth; x++) System.out.print(" ");
127 try {
128 System.out.println("> "+rname+"; LA(1)==("+ tokenNames[LT(1).getType()]
129 + ") " + LT(1).getText() + " [inputState.guessing "+ inputState.guessing + "]");
130 }
131 catch (TokenStreamException e) {
132 }
133 }
134 public void traceOut(String rname) {
135 for (int x=0; x<traceDepth; x++) System.out.print(" ");
136 try {
137 System.out.println("< "+rname+"; LA(1)==("+ tokenNames[LT(1).getType()]
138 + ") "+LT(1).getText() + " [inputState.guessing "+ inputState.guessing + "]");
139 }
140 catch (TokenStreamException e) {
141 }
142 traceDepth -= 1;
143 }
144
145
146 protected StdCParser(TokenBuffer tokenBuf, int k) {
147 super(tokenBuf,k);
148 tokenNames = _tokenNames;
149 buildTokenTypeASTClassMap();
150 astFactory = new ASTFactory(getTokenTypeToASTClassMap());
151}
152
153 public StdCParser(TokenBuffer tokenBuf) {
154 this(tokenBuf,2);
155}
156
157 protected StdCParser(TokenStream lexer, int k) {
158 super(lexer,k);
159 tokenNames = _tokenNames;
160 buildTokenTypeASTClassMap();
161 astFactory = new ASTFactory(getTokenTypeToASTClassMap());
162}
163
164 public StdCParser(TokenStream lexer) {
165 this(lexer,2);
166}
167
168 public StdCParser(ParserSharedInputState state) {
169 super(state,2);
170 tokenNames = _tokenNames;
171 buildTokenTypeASTClassMap();
172 astFactory = new ASTFactory(getTokenTypeToASTClassMap());
173}
174
175 public final void translationUnit() throws RecognitionException, TokenStreamException {
176
177 returnAST = null;
178 ASTPair currentAST = new ASTPair();
179 TNode translationUnit_AST = null;
180
181 try { // for error handling
182 switch ( LA(1)) {
183 case LITERAL_typedef:
184 case LITERAL_asm:
185 case LITERAL_volatile:
186 case LITERAL_struct:
187 case LITERAL_union:
188 case LITERAL_enum:
189 case LITERAL_auto:
190 case LITERAL_register:
191 case LITERAL_extern:
192 case LITERAL_static:
193 case LITERAL_const:
194 case LITERAL_void:
195 case LITERAL_char:
196 case LITERAL_short:
197 case LITERAL_int:
198 case LITERAL_long:
199 case LITERAL_float:
200 case LITERAL_double:
201 case LITERAL_signed:
202 case LITERAL_unsigned:
203 case 27:
204 case 28:
205 case 29:
206 case 30:
207 case 31:
208 case 32:
209 case LITERAL_wchar_t:
210 case 34:
211 case 35:
212 case 36:
213 case 37:
214 case LITERAL_ptrdiff_t:
215 case LITERAL_intptr_t:
216 case LITERAL_size_t:
217 case LITERAL_uintptr_t:
218 case ID:
219 case STAR:
220 case LPAREN:
221 {
222 externalList();
223 astFactory.addASTChild(currentAST, returnAST);
224 translationUnit_AST = (TNode)currentAST.root;
225 break;
226 }
227 case EOF:
228 {
229 if ( inputState.guessing==0 ) {
230
231 System.err.println ( "Empty source file!" );
232
233 }
234 translationUnit_AST = (TNode)currentAST.root;
235 break;
236 }
237 default:
238 {
239 throw new NoViableAltException(LT(1), getFilename());
240 }
241 }
242 }
243 catch (RecognitionException ex) {
244 if (inputState.guessing==0) {
245 reportError(ex);
246 recover(ex,_tokenSet_0);
247 } else {
248 throw ex;
249 }
250 }
251 returnAST = translationUnit_AST;
252 }
253
254 public final void externalList() throws RecognitionException, TokenStreamException {
255
256 returnAST = null;
257 ASTPair currentAST = new ASTPair();
258 TNode externalList_AST = null;
259
260 try { // for error handling
261 {
262 int _cnt4=0;
263 _loop4:
264 do {
265 if ((_tokenSet_1.member(LA(1)))) {
266 externalDef();
267 astFactory.addASTChild(currentAST, returnAST);
268 }
269 else {
270 if ( _cnt4>=1 ) { break _loop4; } else {throw new NoViableAltException(LT(1), getFilename());}
271 }
272
273 _cnt4++;
274 } while (true);
275 }
276 externalList_AST = (TNode)currentAST.root;
277 }
278 catch (RecognitionException ex) {
279 if (inputState.guessing==0) {
280 reportError(ex);
281 recover(ex,_tokenSet_0);
282 } else {
283 throw ex;
284 }
285 }
286 returnAST = externalList_AST;
287 }
288
289 public final void externalDef() throws RecognitionException, TokenStreamException {
290
291 returnAST = null;
292 ASTPair currentAST = new ASTPair();
293 TNode externalDef_AST = null;
294
295 try { // for error handling
296 boolean synPredMatched7 = false;
297 if (((_tokenSet_2.member(LA(1))) && (_tokenSet_3.member(LA(2))))) {
298 int _m7 = mark();
299 synPredMatched7 = true;
300 inputState.guessing++;
301 try {
302 {
303 if ((LA(1)==LITERAL_typedef) && (true)) {
304 match(LITERAL_typedef);
305 }
306 else if ((_tokenSet_2.member(LA(1))) && (_tokenSet_3.member(LA(2)))) {
307 declaration();
308 }
309 else {
310 throw new NoViableAltException(LT(1), getFilename());
311 }
312
313 }
314 }
315 catch (RecognitionException pe) {
316 synPredMatched7 = false;
317 }
318 rewind(_m7);
319inputState.guessing--;
320 }
321 if ( synPredMatched7 ) {
322 declaration();
323 astFactory.addASTChild(currentAST, returnAST);
324 externalDef_AST = (TNode)currentAST.root;
325 }
326 else if ((_tokenSet_4.member(LA(1))) && (_tokenSet_5.member(LA(2)))) {
327 functionDef();
328 astFactory.addASTChild(currentAST, returnAST);
329 externalDef_AST = (TNode)currentAST.root;
330 }
331 else if ((LA(1)==LITERAL_asm)) {
332 asm_expr();
333 astFactory.addASTChild(currentAST, returnAST);
334 externalDef_AST = (TNode)currentAST.root;
335 }
336 else {
337 throw new NoViableAltException(LT(1), getFilename());
338 }
339
340 }
341 catch (RecognitionException ex) {
342 if (inputState.guessing==0) {
343 reportError(ex);
344 recover(ex,_tokenSet_6);
345 } else {
346 throw ex;
347 }
348 }
349 returnAST = externalDef_AST;
350 }
351
352 public final void declaration() throws RecognitionException, TokenStreamException {
353
354 returnAST = null;
355 ASTPair currentAST = new ASTPair();
356 TNode declaration_AST = null;
357 TNode ds_AST = null;
358 AST ds1 = null;
359
360 try { // for error handling
361 declSpecifiers();
362 ds_AST = (TNode)returnAST;
363 astFactory.addASTChild(currentAST, returnAST);
364 if ( inputState.guessing==0 ) {
365 ds1 = astFactory.dupList(ds_AST);
366 }
367 {
368 switch ( LA(1)) {
369 case ID:
370 case STAR:
371 case LPAREN:
372 {
373 initDeclList(ds1);
374 astFactory.addASTChild(currentAST, returnAST);
375 break;
376 }
377 case SEMI:
378 {
379 break;
380 }
381 default:
382 {
383 throw new NoViableAltException(LT(1), getFilename());
384 }
385 }
386 }
387 match(SEMI);
388 if ( inputState.guessing==0 ) {
389 declaration_AST = (TNode)currentAST.root;
390 declaration_AST = (TNode)astFactory.make( (new ASTArray(2)).add((TNode)astFactory.create(NDeclaration)).add(declaration_AST));
391 currentAST.root = declaration_AST;
392 currentAST.child = declaration_AST!=null &&declaration_AST.getFirstChild()!=null ?
393 declaration_AST.getFirstChild() : declaration_AST;
394 currentAST.advanceChildToEnd();
395 }
396 declaration_AST = (TNode)currentAST.root;
397 }
398 catch (RecognitionException ex) {
399 if (inputState.guessing==0) {
400 reportError(ex);
401 recover(ex,_tokenSet_7);
402 } else {
403 throw ex;
404 }
405 }
406 returnAST = declaration_AST;
407 }
408
409 public final void functionDef() throws RecognitionException, TokenStreamException {
410
411 returnAST = null;
412 ASTPair currentAST = new ASTPair();
413 TNode functionDef_AST = null;
414 TNode ds_AST = null;
415 TNode d_AST = null;
416 String declName;
417
418 try { // for error handling
419 {
420 boolean synPredMatched94 = false;
421 if (((_tokenSet_8.member(LA(1))) && (_tokenSet_9.member(LA(2))))) {
422 int _m94 = mark();
423 synPredMatched94 = true;
424 inputState.guessing++;
425 try {
426 {
427 functionDeclSpecifiers();
428 }
429 }
430 catch (RecognitionException pe) {
431 synPredMatched94 = false;
432 }
433 rewind(_m94);
434inputState.guessing--;
435 }
436 if ( synPredMatched94 ) {
437 functionDeclSpecifiers();
438 ds_AST = (TNode)returnAST;
439 astFactory.addASTChild(currentAST, returnAST);
440 }
441 else if ((_tokenSet_10.member(LA(1))) && (_tokenSet_5.member(LA(2)))) {
442 }
443 else {
444 throw new NoViableAltException(LT(1), getFilename());
445 }
446
447 }
448 declName=declarator(true);
449 d_AST = (TNode)returnAST;
450 astFactory.addASTChild(currentAST, returnAST);
451 if ( inputState.guessing==0 ) {
452
453 AST d2, ds2;
454 d2 = astFactory.dupList(d_AST);
455 ds2 = astFactory.dupList(ds_AST);
456 symbolTable.add(declName, (TNode)astFactory.make( (new ASTArray(3)).add(null).add(ds2).add(d2)));
457 pushScope(declName);
458
459 }
460 {
461 _loop96:
462 do {
463 if ((_tokenSet_2.member(LA(1)))) {
464 declaration();
465 astFactory.addASTChild(currentAST, returnAST);
466 }
467 else {
468 break _loop96;
469 }
470
471 } while (true);
472 }
473 {
474 switch ( LA(1)) {
475 case VARARGS:
476 {
477 TNode tmp2_AST = null;
478 tmp2_AST = (TNode)astFactory.create(LT(1));
479 astFactory.addASTChild(currentAST, tmp2_AST);
480 match(VARARGS);
481 break;
482 }
483 case LCURLY:
484 case SEMI:
485 {
486 break;
487 }
488 default:
489 {
490 throw new NoViableAltException(LT(1), getFilename());
491 }
492 }
493 }
494 {
495 _loop99:
496 do {
497 if ((LA(1)==SEMI)) {
498 match(SEMI);
499 }
500 else {
501 break _loop99;
502 }
503
504 } while (true);
505 }
506 if ( inputState.guessing==0 ) {
507 popScope();
508 }
509 compoundStatement(declName);
510 astFactory.addASTChild(currentAST, returnAST);
511 if ( inputState.guessing==0 ) {
512 functionDef_AST = (TNode)currentAST.root;
513 functionDef_AST = (TNode)astFactory.make( (new ASTArray(2)).add((TNode)astFactory.create(NFunctionDef)).add(functionDef_AST));
514 currentAST.root = functionDef_AST;
515 currentAST.child = functionDef_AST!=null &&functionDef_AST.getFirstChild()!=null ?
516 functionDef_AST.getFirstChild() : functionDef_AST;
517 currentAST.advanceChildToEnd();
518 }
519 functionDef_AST = (TNode)currentAST.root;
520 }
521 catch (RecognitionException ex) {
522 if (inputState.guessing==0) {
523 reportError(ex);
524 recover(ex,_tokenSet_6);
525 } else {
526 throw ex;
527 }
528 }
529 returnAST = functionDef_AST;
530 }
531
532 public final void asm_expr() throws RecognitionException, TokenStreamException {
533
534 returnAST = null;
535 ASTPair currentAST = new ASTPair();
536 TNode asm_expr_AST = null;
537
538 try { // for error handling
539 TNode tmp4_AST = null;
540 tmp4_AST = (TNode)astFactory.create(LT(1));
541 astFactory.makeASTRoot(currentAST, tmp4_AST);
542 match(LITERAL_asm);
543 {
544 switch ( LA(1)) {
545 case LITERAL_volatile:
546 {
547 TNode tmp5_AST = null;
548 tmp5_AST = (TNode)astFactory.create(LT(1));
549 astFactory.addASTChild(currentAST, tmp5_AST);
550 match(LITERAL_volatile);
551 break;
552 }
553 case LCURLY:
554 {
555 break;
556 }
557 default:
558 {
559 throw new NoViableAltException(LT(1), getFilename());
560 }
561 }
562 }
563 match(LCURLY);
564 expr();
565 astFactory.addASTChild(currentAST, returnAST);
566 match(RCURLY);
567 match(SEMI);
568 asm_expr_AST = (TNode)currentAST.root;
569 }
570 catch (RecognitionException ex) {
571 if (inputState.guessing==0) {
572 reportError(ex);
573 recover(ex,_tokenSet_6);
574 } else {
575 throw ex;
576 }
577 }
578 returnAST = asm_expr_AST;
579 }
580
581 public final void expr() throws RecognitionException, TokenStreamException {
582
583 returnAST = null;
584 ASTPair currentAST = new ASTPair();
585 TNode expr_AST = null;
586 Token c = null;
587 TNode c_AST = null;
588
589 try { // for error handling
590 assignExpr();
591 astFactory.addASTChild(currentAST, returnAST);
592 {
593 _loop129:
594 do {
595 if ((LA(1)==COMMA) && (_tokenSet_11.member(LA(2)))) {
596 c = LT(1);
597 c_AST = (TNode)astFactory.create(c);
598 astFactory.makeASTRoot(currentAST, c_AST);
599 match(COMMA);
600 if ( inputState.guessing==0 ) {
601 c_AST.setType(NCommaExpr);
602 }
603 assignExpr();
604 astFactory.addASTChild(currentAST, returnAST);
605 }
606 else {
607 break _loop129;
608 }
609
610 } while (true);
611 }
612 expr_AST = (TNode)currentAST.root;
613 }
614 catch (RecognitionException ex) {
615 if (inputState.guessing==0) {
616 reportError(ex);
617 recover(ex,_tokenSet_12);
618 } else {
619 throw ex;
620 }
621 }
622 returnAST = expr_AST;
623 }
624
625 public final void declSpecifiers() throws RecognitionException, TokenStreamException {
626
627 returnAST = null;
628 ASTPair currentAST = new ASTPair();
629 TNode declSpecifiers_AST = null;
630 TNode s_AST = null;
631 int specCount=0;
632
633 try { // for error handling
634 {
635 int _cnt16=0;
636 _loop16:
637 do {
638 switch ( LA(1)) {
639 case LITERAL_typedef:
640 case LITERAL_auto:
641 case LITERAL_register:
642 case LITERAL_extern:
643 case LITERAL_static:
644 {
645 storageClassSpecifier();
646 s_AST = (TNode)returnAST;
647 astFactory.addASTChild(currentAST, returnAST);
648 break;
649 }
650 case LITERAL_volatile:
651 case LITERAL_const:
652 {
653 typeQualifier();
654 astFactory.addASTChild(currentAST, returnAST);
655 break;
656 }
657 default:
658 boolean synPredMatched15 = false;
659 if (((_tokenSet_13.member(LA(1))) && (_tokenSet_14.member(LA(2))))) {
660 int _m15 = mark();
661 synPredMatched15 = true;
662 inputState.guessing++;
663 try {
664 {
665 if ((LA(1)==LITERAL_struct) && (true)) {
666 match(LITERAL_struct);
667 }
668 else if ((LA(1)==LITERAL_union) && (true)) {
669 match(LITERAL_union);
670 }
671 else if ((LA(1)==LITERAL_enum) && (true)) {
672 match(LITERAL_enum);
673 }
674 else if ((_tokenSet_13.member(LA(1))) && (true)) {
675 typeSpecifier(specCount);
676 }
677 else {
678 throw new NoViableAltException(LT(1), getFilename());
679 }
680
681 }
682 }
683 catch (RecognitionException pe) {
684 synPredMatched15 = false;
685 }
686 rewind(_m15);
687inputState.guessing--;
688 }
689 if ( synPredMatched15 ) {
690 specCount=typeSpecifier(specCount);
691 astFactory.addASTChild(currentAST, returnAST);
692 }
693 else {
694 if ( _cnt16>=1 ) { break _loop16; } else {throw new NoViableAltException(LT(1), getFilename());}
695 }
696 }
697 _cnt16++;
698 } while (true);
699 }
700 declSpecifiers_AST = (TNode)currentAST.root;
701 }
702 catch (RecognitionException ex) {
703 if (inputState.guessing==0) {
704 reportError(ex);
705 recover(ex,_tokenSet_15);
706 } else {
707 throw ex;
708 }
709 }
710 returnAST = declSpecifiers_AST;
711 }
712
713 public final void initDeclList(
714 AST declarationSpecifiers
715 ) throws RecognitionException, TokenStreamException {
716
717 returnAST = null;
718 ASTPair currentAST = new ASTPair();
719 TNode initDeclList_AST = null;
720
721 try { // for error handling
722 initDecl(declarationSpecifiers);
723 astFactory.addASTChild(currentAST, returnAST);
724 {
725 _loop56:
726 do {
727 if ((LA(1)==COMMA)) {
728 match(COMMA);
729 initDecl(declarationSpecifiers);
730 astFactory.addASTChild(currentAST, returnAST);
731 }
732 else {
733 break _loop56;
734 }
735
736 } while (true);
737 }
738 initDeclList_AST = (TNode)currentAST.root;
739 }
740 catch (RecognitionException ex) {
741 if (inputState.guessing==0) {
742 reportError(ex);
743 recover(ex,_tokenSet_16);
744 } else {
745 throw ex;
746 }
747 }
748 returnAST = initDeclList_AST;
749 }
750
751 public final void storageClassSpecifier() throws RecognitionException, TokenStreamException {
752
753 returnAST = null;
754 ASTPair currentAST = new ASTPair();
755 TNode storageClassSpecifier_AST = null;
756
757 try { // for error handling
758 switch ( LA(1)) {
759 case LITERAL_auto:
760 {
761 TNode tmp10_AST = null;
762 tmp10_AST = (TNode)astFactory.create(LT(1));
763 astFactory.addASTChild(currentAST, tmp10_AST);
764 match(LITERAL_auto);
765 storageClassSpecifier_AST = (TNode)currentAST.root;
766 break;
767 }
768 case LITERAL_register:
769 {
770 TNode tmp11_AST = null;
771 tmp11_AST = (TNode)astFactory.create(LT(1));
772 astFactory.addASTChild(currentAST, tmp11_AST);
773 match(LITERAL_register);
774 storageClassSpecifier_AST = (TNode)currentAST.root;
775 break;
776 }
777 case LITERAL_typedef:
778 {
779 TNode tmp12_AST = null;
780 tmp12_AST = (TNode)astFactory.create(LT(1));
781 astFactory.addASTChild(currentAST, tmp12_AST);
782 match(LITERAL_typedef);
783 storageClassSpecifier_AST = (TNode)currentAST.root;
784 break;
785 }
786 case LITERAL_extern:
787 case LITERAL_static:
788 {
789 functionStorageClassSpecifier();
790 astFactory.addASTChild(currentAST, returnAST);
791 storageClassSpecifier_AST = (TNode)currentAST.root;
792 break;
793 }
794 default:
795 {
796 throw new NoViableAltException(LT(1), getFilename());
797 }
798 }
799 }
800 catch (RecognitionException ex) {
801 if (inputState.guessing==0) {
802 reportError(ex);
803 recover(ex,_tokenSet_17);
804 } else {
805 throw ex;
806 }
807 }
808 returnAST = storageClassSpecifier_AST;
809 }
810
811 public final void typeQualifier() throws RecognitionException, TokenStreamException {
812
813 returnAST = null;
814 ASTPair currentAST = new ASTPair();
815 TNode typeQualifier_AST = null;
816
817 try { // for error handling
818 switch ( LA(1)) {
819 case LITERAL_const:
820 {
821 TNode tmp13_AST = null;
822 tmp13_AST = (TNode)astFactory.create(LT(1));
823 astFactory.addASTChild(currentAST, tmp13_AST);
824 match(LITERAL_const);
825 typeQualifier_AST = (TNode)currentAST.root;
826 break;
827 }
828 case LITERAL_volatile:
829 {
830 TNode tmp14_AST = null;
831 tmp14_AST = (TNode)astFactory.create(LT(1));
832 astFactory.addASTChild(currentAST, tmp14_AST);
833 match(LITERAL_volatile);
834 typeQualifier_AST = (TNode)currentAST.root;
835 break;
836 }
837 default:
838 {
839 throw new NoViableAltException(LT(1), getFilename());
840 }
841 }
842 }
843 catch (RecognitionException ex) {
844 if (inputState.guessing==0) {
845 reportError(ex);
846 recover(ex,_tokenSet_18);
847 } else {
848 throw ex;
849 }
850 }
851 returnAST = typeQualifier_AST;
852 }
853
854 public final int typeSpecifier(
855 int specCount
856 ) throws RecognitionException, TokenStreamException {
857 int retSpecCount;
858
859 returnAST = null;
860 ASTPair currentAST = new ASTPair();
861 TNode typeSpecifier_AST = null;
862 retSpecCount = specCount + 1;
863
864 try { // for error handling
865 {
866 switch ( LA(1)) {
867 case LITERAL_void:
868 {
869 TNode tmp15_AST = null;
870 tmp15_AST = (TNode)astFactory.create(LT(1));
871 astFactory.addASTChild(currentAST, tmp15_AST);
872 match(LITERAL_void);
873 break;
874 }
875 case LITERAL_char:
876 {
877 TNode tmp16_AST = null;
878 tmp16_AST = (TNode)astFactory.create(LT(1));
879 astFactory.addASTChild(currentAST, tmp16_AST);
880 match(LITERAL_char);
881 break;
882 }
883 case LITERAL_short:
884 {
885 TNode tmp17_AST = null;
886 tmp17_AST = (TNode)astFactory.create(LT(1));
887 astFactory.addASTChild(currentAST, tmp17_AST);
888 match(LITERAL_short);
889 break;
890 }
891 case LITERAL_int:
892 {
893 TNode tmp18_AST = null;
894 tmp18_AST = (TNode)astFactory.create(LT(1));
895 astFactory.addASTChild(currentAST, tmp18_AST);
896 match(LITERAL_int);
897 break;
898 }
899 case LITERAL_long:
900 {
901 TNode tmp19_AST = null;
902 tmp19_AST = (TNode)astFactory.create(LT(1));
903 astFactory.addASTChild(currentAST, tmp19_AST);
904 match(LITERAL_long);
905 break;
906 }
907 case LITERAL_float:
908 {
909 TNode tmp20_AST = null;
910 tmp20_AST = (TNode)astFactory.create(LT(1));
911 astFactory.addASTChild(currentAST, tmp20_AST);
912 match(LITERAL_float);
913 break;
914 }
915 case LITERAL_double:
916 {
917 TNode tmp21_AST = null;
918 tmp21_AST = (TNode)astFactory.create(LT(1));
919 astFactory.addASTChild(currentAST, tmp21_AST);
920 match(LITERAL_double);
921 break;
922 }
923 case LITERAL_signed:
924 {
925 TNode tmp22_AST = null;
926 tmp22_AST = (TNode)astFactory.create(LT(1));
927 astFactory.addASTChild(currentAST, tmp22_AST);
928 match(LITERAL_signed);
929 break;
930 }
931 case LITERAL_unsigned:
932 {
933 TNode tmp23_AST = null;
934 tmp23_AST = (TNode)astFactory.create(LT(1));
935 astFactory.addASTChild(currentAST, tmp23_AST);
936 match(LITERAL_unsigned);
937 break;
938 }
939 case 27:
940 {
941 TNode tmp24_AST = null;
942 tmp24_AST = (TNode)astFactory.create(LT(1));
943 astFactory.addASTChild(currentAST, tmp24_AST);
944 match(27);
945 break;
946 }
947 case 28:
948 {
949 TNode tmp25_AST = null;
950 tmp25_AST = (TNode)astFactory.create(LT(1));
951 astFactory.addASTChild(currentAST, tmp25_AST);
952 match(28);
953 break;
954 }
955 case 29:
956 {
957 TNode tmp26_AST = null;
958 tmp26_AST = (TNode)astFactory.create(LT(1));
959 astFactory.addASTChild(currentAST, tmp26_AST);
960 match(29);
961 break;
962 }
963 case 30:
964 {
965 TNode tmp27_AST = null;
966 tmp27_AST = (TNode)astFactory.create(LT(1));
967 astFactory.addASTChild(currentAST, tmp27_AST);
968 match(30);
969 break;
970 }
971 case 31:
972 {
973 TNode tmp28_AST = null;
974 tmp28_AST = (TNode)astFactory.create(LT(1));
975 astFactory.addASTChild(currentAST, tmp28_AST);
976 match(31);
977 break;
978 }
979 case 32:
980 {
981 TNode tmp29_AST = null;
982 tmp29_AST = (TNode)astFactory.create(LT(1));
983 astFactory.addASTChild(currentAST, tmp29_AST);
984 match(32);
985 break;
986 }
987 case LITERAL_wchar_t:
988 {
989 TNode tmp30_AST = null;
990 tmp30_AST = (TNode)astFactory.create(LT(1));
991 astFactory.addASTChild(currentAST, tmp30_AST);
992 match(LITERAL_wchar_t);
993 break;
994 }
995 case 34:
996 {
997 TNode tmp31_AST = null;
998 tmp31_AST = (TNode)astFactory.create(LT(1));
999 astFactory.addASTChild(currentAST, tmp31_AST);
1000 match(34);
1001 break;
1002 }
1003 case 35:
1004 {
1005 TNode tmp32_AST = null;
1006 tmp32_AST = (TNode)astFactory.create(LT(1));
1007 astFactory.addASTChild(currentAST, tmp32_AST);
1008 match(35);
1009 break;
1010 }
1011 case 36:
1012 {
1013 TNode tmp33_AST = null;
1014 tmp33_AST = (TNode)astFactory.create(LT(1));
1015 astFactory.addASTChild(currentAST, tmp33_AST);
1016 match(36);
1017 break;
1018 }
1019 case 37:
1020 {
1021 TNode tmp34_AST = null;
1022 tmp34_AST = (TNode)astFactory.create(LT(1));
1023 astFactory.addASTChild(currentAST, tmp34_AST);
1024 match(37);
1025 break;
1026 }
1027 case LITERAL_ptrdiff_t:
1028 {
1029 TNode tmp35_AST = null;
1030 tmp35_AST = (TNode)astFactory.create(LT(1));
1031 astFactory.addASTChild(currentAST, tmp35_AST);
1032 match(LITERAL_ptrdiff_t);
1033 break;
1034 }
1035 case LITERAL_intptr_t:
1036 {
1037 TNode tmp36_AST = null;
1038 tmp36_AST = (TNode)astFactory.create(LT(1));
1039 astFactory.addASTChild(currentAST, tmp36_AST);
1040 match(LITERAL_intptr_t);
1041 break;
1042 }
1043 case LITERAL_size_t:
1044 {
1045 TNode tmp37_AST = null;
1046 tmp37_AST = (TNode)astFactory.create(LT(1));
1047 astFactory.addASTChild(currentAST, tmp37_AST);
1048 match(LITERAL_size_t);
1049 break;
1050 }
1051 case LITERAL_uintptr_t:
1052 {
1053 TNode tmp38_AST = null;
1054 tmp38_AST = (TNode)astFactory.create(LT(1));
1055 astFactory.addASTChild(currentAST, tmp38_AST);
1056 match(LITERAL_uintptr_t);
1057 break;
1058 }
1059 case LITERAL_struct:
1060 case LITERAL_union:
1061 {
1062 structOrUnionSpecifier();
1063 astFactory.addASTChild(currentAST, returnAST);
1064 break;
1065 }
1066 case LITERAL_enum:
1067 {
1068 enumSpecifier();
1069 astFactory.addASTChild(currentAST, returnAST);
1070 break;
1071 }
1072 default:
1073 if (((LA(1)==ID))&&( specCount == 0 )) {
1074 typedefName();
1075 astFactory.addASTChild(currentAST, returnAST);
1076 }
1077 else {
1078 throw new NoViableAltException(LT(1), getFilename());
1079 }
1080 }
1081 }
1082 typeSpecifier_AST = (TNode)currentAST.root;
1083 }
1084 catch (RecognitionException ex) {
1085 if (inputState.guessing==0) {
1086 reportError(ex);
1087 recover(ex,_tokenSet_18);
1088 } else {
1089 throw ex;
1090 }
1091 }
1092 returnAST = typeSpecifier_AST;
1093 return retSpecCount;
1094 }
1095
1096 public final void functionStorageClassSpecifier() throws RecognitionException, TokenStreamException {
1097
1098 returnAST = null;
1099 ASTPair currentAST = new ASTPair();
1100 TNode functionStorageClassSpecifier_AST = null;
1101
1102 try { // for error handling
1103 switch ( LA(1)) {
1104 case LITERAL_extern:
1105 {
1106 TNode tmp39_AST = null;
1107 tmp39_AST = (TNode)astFactory.create(LT(1));
1108 astFactory.addASTChild(currentAST, tmp39_AST);
1109 match(LITERAL_extern);
1110 functionStorageClassSpecifier_AST = (TNode)currentAST.root;
1111 break;
1112 }
1113 case LITERAL_static:
1114 {
1115 TNode tmp40_AST = null;
1116 tmp40_AST = (TNode)astFactory.create(LT(1));
1117 astFactory.addASTChild(currentAST, tmp40_AST);
1118 match(LITERAL_static);
1119 functionStorageClassSpecifier_AST = (TNode)currentAST.root;
1120 break;
1121 }
1122 default:
1123 {
1124 throw new NoViableAltException(LT(1), getFilename());
1125 }
1126 }
1127 }
1128 catch (RecognitionException ex) {
1129 if (inputState.guessing==0) {
1130 reportError(ex);
1131 recover(ex,_tokenSet_17);
1132 } else {
1133 throw ex;
1134 }
1135 }
1136 returnAST = functionStorageClassSpecifier_AST;
1137 }
1138
1139 public final void structOrUnionSpecifier() throws RecognitionException, TokenStreamException {
1140
1141 returnAST = null;
1142 ASTPair currentAST = new ASTPair();
1143 TNode structOrUnionSpecifier_AST = null;
1144 TNode sou_AST = null;
1145 Token i = null;
1146 TNode i_AST = null;
1147 Token l = null;
1148 TNode l_AST = null;
1149 Token l1 = null;
1150 TNode l1_AST = null;
1151 String scopeName;
1152
1153 try { // for error handling
1154 structOrUnion();
1155 sou_AST = (TNode)returnAST;
1156 {
1157 boolean synPredMatched26 = false;
1158 if (((LA(1)==ID) && (LA(2)==LCURLY))) {
1159 int _m26 = mark();
1160 synPredMatched26 = true;
1161 inputState.guessing++;
1162 try {
1163 {
1164 match(ID);
1165 match(LCURLY);
1166 }
1167 }
1168 catch (RecognitionException pe) {
1169 synPredMatched26 = false;
1170 }
1171 rewind(_m26);
1172inputState.guessing--;
1173 }
1174 if ( synPredMatched26 ) {
1175 i = LT(1);
1176 i_AST = (TNode)astFactory.create(i);
1177 astFactory.addASTChild(currentAST, i_AST);
1178 match(ID);
1179 l = LT(1);
1180 l_AST = (TNode)astFactory.create(l);
1181 astFactory.addASTChild(currentAST, l_AST);
1182 match(LCURLY);
1183 if ( inputState.guessing==0 ) {
1184
1185 scopeName = sou_AST.getText() + " " + i_AST.getText();
1186 l_AST.setText(scopeName);
1187 pushScope(scopeName);
1188
1189 }
1190 structDeclarationList();
1191 astFactory.addASTChild(currentAST, returnAST);
1192 if ( inputState.guessing==0 ) {
1193 popScope();
1194 }
1195 match(RCURLY);
1196 }
1197 else if ((LA(1)==LCURLY)) {
1198 l1 = LT(1);
1199 l1_AST = (TNode)astFactory.create(l1);
1200 astFactory.addASTChild(currentAST, l1_AST);
1201 match(LCURLY);
1202 if ( inputState.guessing==0 ) {
1203
1204 scopeName = getAScopeName();
1205 l1_AST.setText(scopeName);
1206 pushScope(scopeName);
1207
1208 }
1209 structDeclarationList();
1210 astFactory.addASTChild(currentAST, returnAST);
1211 if ( inputState.guessing==0 ) {
1212 popScope();
1213 }
1214 match(RCURLY);
1215 }
1216 else if ((LA(1)==ID) && (_tokenSet_18.member(LA(2)))) {
1217 TNode tmp43_AST = null;
1218 tmp43_AST = (TNode)astFactory.create(LT(1));
1219 astFactory.addASTChild(currentAST, tmp43_AST);
1220 match(ID);
1221 }
1222 else {
1223 throw new NoViableAltException(LT(1), getFilename());
1224 }
1225
1226 }
1227 if ( inputState.guessing==0 ) {
1228 structOrUnionSpecifier_AST = (TNode)currentAST.root;
1229
1230 structOrUnionSpecifier_AST = (TNode)astFactory.make( (new ASTArray(2)).add(sou_AST).add(structOrUnionSpecifier_AST));
1231
1232 currentAST.root = structOrUnionSpecifier_AST;
1233 currentAST.child = structOrUnionSpecifier_AST!=null &&structOrUnionSpecifier_AST.getFirstChild()!=null ?
1234 structOrUnionSpecifier_AST.getFirstChild() : structOrUnionSpecifier_AST;
1235 currentAST.advanceChildToEnd();
1236 }
1237 structOrUnionSpecifier_AST = (TNode)currentAST.root;
1238 }
1239 catch (RecognitionException ex) {
1240 if (inputState.guessing==0) {
1241 reportError(ex);
1242 recover(ex,_tokenSet_18);
1243 } else {
1244 throw ex;
1245 }
1246 }
1247 returnAST = structOrUnionSpecifier_AST;
1248 }
1249
1250 public final void enumSpecifier() throws RecognitionException, TokenStreamException {
1251
1252 returnAST = null;
1253 ASTPair currentAST = new ASTPair();
1254 TNode enumSpecifier_AST = null;
1255 Token i = null;
1256 TNode i_AST = null;
1257
1258 try { // for error handling
1259 TNode tmp44_AST = null;
1260 tmp44_AST = (TNode)astFactory.create(LT(1));
1261 astFactory.makeASTRoot(currentAST, tmp44_AST);
1262 match(LITERAL_enum);
1263 {
1264 boolean synPredMatched48 = false;
1265 if (((LA(1)==ID) && (LA(2)==LCURLY))) {
1266 int _m48 = mark();
1267 synPredMatched48 = true;
1268 inputState.guessing++;
1269 try {
1270 {
1271 match(ID);
1272 match(LCURLY);
1273 }
1274 }
1275 catch (RecognitionException pe) {
1276 synPredMatched48 = false;
1277 }
1278 rewind(_m48);
1279inputState.guessing--;
1280 }
1281 if ( synPredMatched48 ) {
1282 i = LT(1);
1283 i_AST = (TNode)astFactory.create(i);
1284 astFactory.addASTChild(currentAST, i_AST);
1285 match(ID);
1286 TNode tmp45_AST = null;
1287 tmp45_AST = (TNode)astFactory.create(LT(1));
1288 astFactory.addASTChild(currentAST, tmp45_AST);
1289 match(LCURLY);
1290 enumList(i.getText());
1291 astFactory.addASTChild(currentAST, returnAST);
1292 match(RCURLY);
1293 }
1294 else if ((LA(1)==LCURLY)) {
1295 TNode tmp47_AST = null;
1296 tmp47_AST = (TNode)astFactory.create(LT(1));
1297 astFactory.addASTChild(currentAST, tmp47_AST);
1298 match(LCURLY);
1299 enumList("anonymous");
1300 astFactory.addASTChild(currentAST, returnAST);
1301 match(RCURLY);
1302 }
1303 else if ((LA(1)==ID) && (_tokenSet_18.member(LA(2)))) {
1304 TNode tmp49_AST = null;
1305 tmp49_AST = (TNode)astFactory.create(LT(1));
1306 astFactory.addASTChild(currentAST, tmp49_AST);
1307 match(ID);
1308 }
1309 else {
1310 throw new NoViableAltException(LT(1), getFilename());
1311 }
1312
1313 }
1314 enumSpecifier_AST = (TNode)currentAST.root;
1315 }
1316 catch (RecognitionException ex) {
1317 if (inputState.guessing==0) {
1318 reportError(ex);
1319 recover(ex,_tokenSet_18);
1320 } else {
1321 throw ex;
1322 }
1323 }
1324 returnAST = enumSpecifier_AST;
1325 }
1326
1327 public final void typedefName() throws RecognitionException, TokenStreamException {
1328
1329 returnAST = null;
1330 ASTPair currentAST = new ASTPair();
1331 TNode typedefName_AST = null;
1332 Token i = null;
1333 TNode i_AST = null;
1334
1335 try { // for error handling
1336 if (!( isTypedefName ( LT(1).getText() ) ))
1337 throw new SemanticException(" isTypedefName ( LT(1).getText() ) ");
1338 i = LT(1);
1339 i_AST = (TNode)astFactory.create(i);
1340 astFactory.addASTChild(currentAST, i_AST);
1341 match(ID);
1342 if ( inputState.guessing==0 ) {
1343 typedefName_AST = (TNode)currentAST.root;
1344 typedefName_AST = (TNode)astFactory.make( (new ASTArray(2)).add((TNode)astFactory.create(NTypedefName)).add(i_AST));
1345 currentAST.root = typedefName_AST;
1346 currentAST.child = typedefName_AST!=null &&typedefName_AST.getFirstChild()!=null ?
1347 typedefName_AST.getFirstChild() : typedefName_AST;
1348 currentAST.advanceChildToEnd();
1349 }
1350 typedefName_AST = (TNode)currentAST.root;
1351 }
1352 catch (RecognitionException ex) {
1353 if (inputState.guessing==0) {
1354 reportError(ex);
1355 recover(ex,_tokenSet_18);
1356 } else {
1357 throw ex;
1358 }
1359 }
1360 returnAST = typedefName_AST;
1361 }
1362
1363 public final void structOrUnion() throws RecognitionException, TokenStreamException {
1364
1365 returnAST = null;
1366 ASTPair currentAST = new ASTPair();
1367 TNode structOrUnion_AST = null;
1368
1369 try { // for error handling
1370 switch ( LA(1)) {
1371 case LITERAL_struct:
1372 {
1373 TNode tmp50_AST = null;
1374 tmp50_AST = (TNode)astFactory.create(LT(1));
1375 astFactory.addASTChild(currentAST, tmp50_AST);
1376 match(LITERAL_struct);
1377 structOrUnion_AST = (TNode)currentAST.root;
1378 break;
1379 }
1380 case LITERAL_union:
1381 {
1382 TNode tmp51_AST = null;
1383 tmp51_AST = (TNode)astFactory.create(LT(1));
1384 astFactory.addASTChild(currentAST, tmp51_AST);
1385 match(LITERAL_union);
1386 structOrUnion_AST = (TNode)currentAST.root;
1387 break;
1388 }
1389 default:
1390 {
1391 throw new NoViableAltException(LT(1), getFilename());
1392 }
1393 }
1394 }
1395 catch (RecognitionException ex) {
1396 if (inputState.guessing==0) {
1397 reportError(ex);
1398 recover(ex,_tokenSet_19);
1399 } else {
1400 throw ex;
1401 }
1402 }
1403 returnAST = structOrUnion_AST;
1404 }
1405
1406 public final void structDeclarationList() throws RecognitionException, TokenStreamException {
1407
1408 returnAST = null;
1409 ASTPair currentAST = new ASTPair();
1410 TNode structDeclarationList_AST = null;
1411
1412 try { // for error handling
1413 {
1414 int _cnt30=0;
1415 _loop30:
1416 do {
1417 if ((_tokenSet_20.member(LA(1)))) {
1418 structDeclaration();
1419 astFactory.addASTChild(currentAST, returnAST);
1420 }
1421 else {
1422 if ( _cnt30>=1 ) { break _loop30; } else {throw new NoViableAltException(LT(1), getFilename());}
1423 }
1424
1425 _cnt30++;
1426 } while (true);
1427 }
1428 structDeclarationList_AST = (TNode)currentAST.root;
1429 }
1430 catch (RecognitionException ex) {
1431 if (inputState.guessing==0) {
1432 reportError(ex);
1433 recover(ex,_tokenSet_21);
1434 } else {
1435 throw ex;
1436 }
1437 }
1438 returnAST = structDeclarationList_AST;
1439 }
1440
1441 public final void structDeclaration() throws RecognitionException, TokenStreamException {
1442
1443 returnAST = null;
1444 ASTPair currentAST = new ASTPair();
1445 TNode structDeclaration_AST = null;
1446
1447 try { // for error handling
1448 specifierQualifierList();
1449 astFactory.addASTChild(currentAST, returnAST);
1450 structDeclaratorList();
1451 astFactory.addASTChild(currentAST, returnAST);
1452 {
1453 int _cnt33=0;
1454 _loop33:
1455 do {
1456 if ((LA(1)==SEMI)) {
1457 match(SEMI);
1458 }
1459 else {
1460 if ( _cnt33>=1 ) { break _loop33; } else {throw new NoViableAltException(LT(1), getFilename());}
1461 }
1462
1463 _cnt33++;
1464 } while (true);
1465 }
1466 structDeclaration_AST = (TNode)currentAST.root;
1467 }
1468 catch (RecognitionException ex) {
1469 if (inputState.guessing==0) {
1470 reportError(ex);
1471 recover(ex,_tokenSet_22);
1472 } else {
1473 throw ex;
1474 }
1475 }
1476 returnAST = structDeclaration_AST;
1477 }
1478
1479 public final void specifierQualifierList() throws RecognitionException, TokenStreamException {
1480
1481 returnAST = null;
1482 ASTPair currentAST = new ASTPair();
1483 TNode specifierQualifierList_AST = null;
1484 int specCount = 0;
1485
1486 try { // for error handling
1487 {
1488 int _cnt38=0;
1489 _loop38:
1490 do {
1491 boolean synPredMatched37 = false;
1492 if (((_tokenSet_13.member(LA(1))) && (_tokenSet_23.member(LA(2))))) {
1493 int _m37 = mark();
1494 synPredMatched37 = true;
1495 inputState.guessing++;
1496 try {
1497 {
1498 if ((LA(1)==LITERAL_struct) && (true)) {
1499 match(LITERAL_struct);
1500 }
1501 else if ((LA(1)==LITERAL_union) && (true)) {
1502 match(LITERAL_union);
1503 }
1504 else if ((LA(1)==LITERAL_enum) && (true)) {
1505 match(LITERAL_enum);
1506 }
1507 else if ((_tokenSet_13.member(LA(1))) && (true)) {
1508 typeSpecifier(specCount);
1509 }
1510 else {
1511 throw new NoViableAltException(LT(1), getFilename());
1512 }
1513
1514 }
1515 }
1516 catch (RecognitionException pe) {
1517 synPredMatched37 = false;
1518 }
1519 rewind(_m37);
1520inputState.guessing--;
1521 }
1522 if ( synPredMatched37 ) {
1523 specCount=typeSpecifier(specCount);
1524 astFactory.addASTChild(currentAST, returnAST);
1525 }
1526 else if ((LA(1)==LITERAL_volatile||LA(1)==LITERAL_const)) {
1527 typeQualifier();
1528 astFactory.addASTChild(currentAST, returnAST);
1529 }
1530 else {
1531 if ( _cnt38>=1 ) { break _loop38; } else {throw new NoViableAltException(LT(1), getFilename());}
1532 }
1533
1534 _cnt38++;
1535 } while (true);
1536 }
1537 specifierQualifierList_AST = (TNode)currentAST.root;
1538 }
1539 catch (RecognitionException ex) {
1540 if (inputState.guessing==0) {
1541 reportError(ex);
1542 recover(ex,_tokenSet_24);
1543 } else {
1544 throw ex;
1545 }
1546 }
1547 returnAST = specifierQualifierList_AST;
1548 }
1549
1550 public final void structDeclaratorList() throws RecognitionException, TokenStreamException {
1551
1552 returnAST = null;
1553 ASTPair currentAST = new ASTPair();
1554 TNode structDeclaratorList_AST = null;
1555
1556 try { // for error handling
1557 structDeclarator();
1558 astFactory.addASTChild(currentAST, returnAST);
1559 {
1560 _loop41:
1561 do {
1562 if ((LA(1)==COMMA)) {
1563 match(COMMA);
1564 structDeclarator();
1565 astFactory.addASTChild(currentAST, returnAST);
1566 }
1567 else {
1568 break _loop41;
1569 }
1570
1571 } while (true);
1572 }
1573 structDeclaratorList_AST = (TNode)currentAST.root;
1574 }
1575 catch (RecognitionException ex) {
1576 if (inputState.guessing==0) {
1577 reportError(ex);
1578 recover(ex,_tokenSet_16);
1579 } else {
1580 throw ex;
1581 }
1582 }
1583 returnAST = structDeclaratorList_AST;
1584 }
1585
1586 public final void structDeclarator() throws RecognitionException, TokenStreamException {
1587
1588 returnAST = null;
1589 ASTPair currentAST = new ASTPair();
1590 TNode structDeclarator_AST = null;
1591
1592 try { // for error handling
1593 {
1594 switch ( LA(1)) {
1595 case COLON:
1596 {
1597 TNode tmp54_AST = null;
1598 tmp54_AST = (TNode)astFactory.create(LT(1));
1599 astFactory.addASTChild(currentAST, tmp54_AST);
1600 match(COLON);
1601 constExpr();
1602 astFactory.addASTChild(currentAST, returnAST);
1603 break;
1604 }
1605 case ID:
1606 case STAR:
1607 case LPAREN:
1608 {
1609 declarator(false);
1610 astFactory.addASTChild(currentAST, returnAST);
1611 {
1612 switch ( LA(1)) {
1613 case COLON:
1614 {
1615 TNode tmp55_AST = null;
1616 tmp55_AST = (TNode)astFactory.create(LT(1));
1617 astFactory.addASTChild(currentAST, tmp55_AST);
1618 match(COLON);
1619 constExpr();
1620 astFactory.addASTChild(currentAST, returnAST);
1621 break;
1622 }
1623 case SEMI:
1624 case COMMA:
1625 {
1626 break;
1627 }
1628 default:
1629 {
1630 throw new NoViableAltException(LT(1), getFilename());
1631 }
1632 }
1633 }
1634 break;
1635 }
1636 default:
1637 {
1638 throw new NoViableAltException(LT(1), getFilename());
1639 }
1640 }
1641 }
1642 if ( inputState.guessing==0 ) {
1643 structDeclarator_AST = (TNode)currentAST.root;
1644 structDeclarator_AST = (TNode)astFactory.make( (new ASTArray(2)).add((TNode)astFactory.create(NStructDeclarator)).add(structDeclarator_AST));
1645 currentAST.root = structDeclarator_AST;
1646 currentAST.child = structDeclarator_AST!=null &&structDeclarator_AST.getFirstChild()!=null ?
1647 structDeclarator_AST.getFirstChild() : structDeclarator_AST;
1648 currentAST.advanceChildToEnd();
1649 }
1650 structDeclarator_AST = (TNode)currentAST.root;
1651 }
1652 catch (RecognitionException ex) {
1653 if (inputState.guessing==0) {
1654 reportError(ex);
1655 recover(ex,_tokenSet_25);
1656 } else {
1657 throw ex;
1658 }
1659 }
1660 returnAST = structDeclarator_AST;
1661 }
1662
1663 public final void constExpr() throws RecognitionException, TokenStreamException {
1664
1665 returnAST = null;
1666 ASTPair currentAST = new ASTPair();
1667 TNode constExpr_AST = null;
1668
1669 try { // for error handling
1670 conditionalExpr();
1671 astFactory.addASTChild(currentAST, returnAST);
1672 constExpr_AST = (TNode)currentAST.root;
1673 }
1674 catch (RecognitionException ex) {
1675 if (inputState.guessing==0) {
1676 reportError(ex);
1677 recover(ex,_tokenSet_26);
1678 } else {
1679 throw ex;
1680 }
1681 }
1682 returnAST = constExpr_AST;
1683 }
1684
1685 public final String declarator(
1686 boolean isFunctionDefinition
1687 ) throws RecognitionException, TokenStreamException {
1688 String declName;
1689
1690 returnAST = null;
1691 ASTPair currentAST = new ASTPair();
1692 TNode declarator_AST = null;
1693 Token id = null;
1694 TNode id_AST = null;
1695 TNode p_AST = null;
1696 TNode i_AST = null;
1697 declName = "";
1698
1699 try { // for error handling
1700 {
1701 switch ( LA(1)) {
1702 case STAR:
1703 {
1704 pointerGroup();
1705 astFactory.addASTChild(currentAST, returnAST);
1706 break;
1707 }
1708 case ID:
1709 case LPAREN:
1710 {
1711 break;
1712 }
1713 default:
1714 {
1715 throw new NoViableAltException(LT(1), getFilename());
1716 }
1717 }
1718 }
1719 {
1720 switch ( LA(1)) {
1721 case ID:
1722 {
1723 id = LT(1);
1724 id_AST = (TNode)astFactory.create(id);
1725 astFactory.addASTChild(currentAST, id_AST);
1726 match(ID);
1727 if ( inputState.guessing==0 ) {
1728 declName = id.getText();
1729 }
1730 break;
1731 }
1732 case LPAREN:
1733 {
1734 TNode tmp56_AST = null;
1735 tmp56_AST = (TNode)astFactory.create(LT(1));
1736 astFactory.addASTChild(currentAST, tmp56_AST);
1737 match(LPAREN);
1738 declName=declarator(false);
1739 astFactory.addASTChild(currentAST, returnAST);
1740 TNode tmp57_AST = null;
1741 tmp57_AST = (TNode)astFactory.create(LT(1));
1742 astFactory.addASTChild(currentAST, tmp57_AST);
1743 match(RPAREN);
1744 break;
1745 }
1746 default:
1747 {
1748 throw new NoViableAltException(LT(1), getFilename());
1749 }
1750 }
1751 }
1752 {
1753 _loop82:
1754 do {
1755 switch ( LA(1)) {
1756 case LPAREN:
1757 {
1758 TNode tmp58_AST = null;
1759 tmp58_AST = (TNode)astFactory.create(LT(1));
1760 match(LPAREN);
1761 if ( inputState.guessing==0 ) {
1762
1763 if (isFunctionDefinition) {
1764 pushScope(declName);
1765 }
1766 else {
1767 pushScope("!"+declName);
1768 }
1769
1770 }
1771 {
1772 boolean synPredMatched79 = false;
1773 if (((_tokenSet_2.member(LA(1))) && (_tokenSet_27.member(LA(2))))) {
1774 int _m79 = mark();
1775 synPredMatched79 = true;
1776 inputState.guessing++;
1777 try {
1778 {
1779 declSpecifiers();
1780 }
1781 }
1782 catch (RecognitionException pe) {
1783 synPredMatched79 = false;
1784 }
1785 rewind(_m79);
1786inputState.guessing--;
1787 }
1788 if ( synPredMatched79 ) {
1789 parameterTypeList();
1790 p_AST = (TNode)returnAST;
1791 if ( inputState.guessing==0 ) {
1792 declarator_AST = (TNode)currentAST.root;
1793
1794 declarator_AST = (TNode)astFactory.make( (new ASTArray(3)).add(null).add(declarator_AST).add((TNode)astFactory.make( (new ASTArray(2)).add((TNode)astFactory.create(NParameterTypeList)).add(p_AST))));
1795
1796 currentAST.root = declarator_AST;
1797 currentAST.child = declarator_AST!=null &&declarator_AST.getFirstChild()!=null ?
1798 declarator_AST.getFirstChild() : declarator_AST;
1799 currentAST.advanceChildToEnd();
1800 }
1801 }
1802 else if ((LA(1)==ID||LA(1)==RPAREN) && (_tokenSet_28.member(LA(2)))) {
1803 {
1804 switch ( LA(1)) {
1805 case ID:
1806 {
1807 idList();
1808 i_AST = (TNode)returnAST;
1809 break;
1810 }
1811 case RPAREN:
1812 {
1813 break;
1814 }
1815 default:
1816 {
1817 throw new NoViableAltException(LT(1), getFilename());
1818 }
1819 }
1820 }
1821 if ( inputState.guessing==0 ) {
1822 declarator_AST = (TNode)currentAST.root;
1823
1824 declarator_AST = (TNode)astFactory.make( (new ASTArray(3)).add(null).add(declarator_AST).add((TNode)astFactory.make( (new ASTArray(2)).add((TNode)astFactory.create(NParameterTypeList)).add(i_AST))));
1825
1826 currentAST.root = declarator_AST;
1827 currentAST.child = declarator_AST!=null &&declarator_AST.getFirstChild()!=null ?
1828 declarator_AST.getFirstChild() : declarator_AST;
1829 currentAST.advanceChildToEnd();
1830 }
1831 }
1832 else {
1833 throw new NoViableAltException(LT(1), getFilename());
1834 }
1835
1836 }
1837 if ( inputState.guessing==0 ) {
1838
1839 popScope();
1840
1841 }
1842 TNode tmp59_AST = null;
1843 tmp59_AST = (TNode)astFactory.create(LT(1));
1844 match(RPAREN);
1845 break;
1846 }
1847 case LBRACKET:
1848 {
1849 TNode tmp60_AST = null;
1850 tmp60_AST = (TNode)astFactory.create(LT(1));
1851 astFactory.addASTChild(currentAST, tmp60_AST);
1852 match(LBRACKET);
1853 {
1854 switch ( LA(1)) {
1855 case ID:
1856 case STAR:
1857 case LPAREN:
1858 case BAND:
1859 case PLUS:
1860 case MINUS:
1861 case INC:
1862 case DEC:
1863 case LITERAL_sizeof:
1864 case BNOT:
1865 case LNOT:
1866 case CharLiteral:
1867 case StringLiteral:
1868 case IntOctalConst:
1869 case LongOctalConst:
1870 case UnsignedOctalConst:
1871 case IntIntConst:
1872 case LongIntConst:
1873 case UnsignedIntConst:
1874 case IntHexConst:
1875 case LongHexConst:
1876 case UnsignedHexConst:
1877 case FloatDoubleConst:
1878 case DoubleDoubleConst:
1879 case LongDoubleConst:
1880 {
1881 constExpr();
1882 astFactory.addASTChild(currentAST, returnAST);
1883 break;
1884 }
1885 case RBRACKET:
1886 {
1887 break;
1888 }
1889 default:
1890 {
1891 throw new NoViableAltException(LT(1), getFilename());
1892 }
1893 }
1894 }
1895 TNode tmp61_AST = null;
1896 tmp61_AST = (TNode)astFactory.create(LT(1));
1897 astFactory.addASTChild(currentAST, tmp61_AST);
1898 match(RBRACKET);
1899 break;
1900 }
1901 default:
1902 {
1903 break _loop82;
1904 }
1905 }
1906 } while (true);
1907 }
1908 if ( inputState.guessing==0 ) {
1909 declarator_AST = (TNode)currentAST.root;
1910 declarator_AST = (TNode)astFactory.make( (new ASTArray(2)).add((TNode)astFactory.create(NDeclarator)).add(declarator_AST));
1911 currentAST.root = declarator_AST;
1912 currentAST.child = declarator_AST!=null &&declarator_AST.getFirstChild()!=null ?
1913 declarator_AST.getFirstChild() : declarator_AST;
1914 currentAST.advanceChildToEnd();
1915 }
1916 declarator_AST = (TNode)currentAST.root;
1917 }
1918 catch (RecognitionException ex) {
1919 if (inputState.guessing==0) {
1920 reportError(ex);
1921 recover(ex,_tokenSet_29);
1922 } else {
1923 throw ex;
1924 }
1925 }
1926 returnAST = declarator_AST;
1927 return declName;
1928 }
1929
1930 public final void enumList(
1931 String enumName
1932 ) throws RecognitionException, TokenStreamException {
1933
1934 returnAST = null;
1935 ASTPair currentAST = new ASTPair();
1936 TNode enumList_AST = null;
1937
1938 try { // for error handling
1939 enumerator(enumName);
1940 astFactory.addASTChild(currentAST, returnAST);
1941 {
1942 _loop51:
1943 do {
1944 if ((LA(1)==COMMA)) {
1945 match(COMMA);
1946 enumerator(enumName);
1947 astFactory.addASTChild(currentAST, returnAST);
1948 }
1949 else {
1950 break _loop51;
1951 }
1952
1953 } while (true);
1954 }
1955 enumList_AST = (TNode)currentAST.root;
1956 }
1957 catch (RecognitionException ex) {
1958 if (inputState.guessing==0) {
1959 reportError(ex);
1960 recover(ex,_tokenSet_21);
1961 } else {
1962 throw ex;
1963 }
1964 }
1965 returnAST = enumList_AST;
1966 }
1967
1968 public final void enumerator(
1969 String enumName
1970 ) throws RecognitionException, TokenStreamException {
1971
1972 returnAST = null;
1973 ASTPair currentAST = new ASTPair();
1974 TNode enumerator_AST = null;
1975 Token i = null;
1976 TNode i_AST = null;
1977
1978 try { // for error handling
1979 i = LT(1);
1980 i_AST = (TNode)astFactory.create(i);
1981 astFactory.addASTChild(currentAST, i_AST);
1982 match(ID);
1983 if ( inputState.guessing==0 ) {
1984 symbolTable.add( i.getText(),
1985 (TNode)astFactory.make( (new ASTArray(3)).add(null).add((TNode)astFactory.create(LITERAL_enum,"enum")).add((TNode)astFactory.create(ID,enumName)))
1986 );
1987
1988 }
1989 {
1990 switch ( LA(1)) {
1991 case ASSIGN:
1992 {
1993 TNode tmp63_AST = null;
1994 tmp63_AST = (TNode)astFactory.create(LT(1));
1995 astFactory.addASTChild(currentAST, tmp63_AST);
1996 match(ASSIGN);
1997 constExpr();
1998 astFactory.addASTChild(currentAST, returnAST);
1999 break;
2000 }
2001 case RCURLY:
2002 case COMMA:
2003 {
2004 break;
2005 }
2006 default:
2007 {
2008 throw new NoViableAltException(LT(1), getFilename());
2009 }
2010 }
2011 }
2012 enumerator_AST = (TNode)currentAST.root;
2013 }
2014 catch (RecognitionException ex) {
2015 if (inputState.guessing==0) {
2016 reportError(ex);
2017 recover(ex,_tokenSet_30);
2018 } else {
2019 throw ex;
2020 }
2021 }
2022 returnAST = enumerator_AST;
2023 }
2024
2025 public final void initDecl(
2026 AST declarationSpecifiers
2027 ) throws RecognitionException, TokenStreamException {
2028
2029 returnAST = null;
2030 ASTPair currentAST = new ASTPair();
2031 TNode initDecl_AST = null;
2032 TNode d_AST = null;
2033 String declName = "";
2034
2035 try { // for error handling
2036 declName=declarator(false);
2037 d_AST = (TNode)returnAST;
2038 astFactory.addASTChild(currentAST, returnAST);
2039 if ( inputState.guessing==0 ) {
2040 AST ds1, d1;
2041 ds1 = astFactory.dupList(declarationSpecifiers);
2042 d1 = astFactory.dupList(d_AST);
2043 symbolTable.add(declName, (TNode)astFactory.make( (new ASTArray(3)).add(null).add(ds1).add(d1)) );
2044
2045 }
2046 {
2047 switch ( LA(1)) {
2048 case ASSIGN:
2049 {
2050 TNode tmp64_AST = null;
2051 tmp64_AST = (TNode)astFactory.create(LT(1));
2052 astFactory.addASTChild(currentAST, tmp64_AST);
2053 match(ASSIGN);
2054 initializer();
2055 astFactory.addASTChild(currentAST, returnAST);
2056 break;
2057 }
2058 case COLON:
2059 {
2060 TNode tmp65_AST = null;
2061 tmp65_AST = (TNode)astFactory.create(LT(1));
2062 astFactory.addASTChild(currentAST, tmp65_AST);
2063 match(COLON);
2064 expr();
2065 astFactory.addASTChild(currentAST, returnAST);
2066 break;
2067 }
2068 case SEMI:
2069 case COMMA:
2070 {
2071 break;
2072 }
2073 default:
2074 {
2075 throw new NoViableAltException(LT(1), getFilename());
2076 }
2077 }
2078 }
2079 if ( inputState.guessing==0 ) {
2080 initDecl_AST = (TNode)currentAST.root;
2081 initDecl_AST = (TNode)astFactory.make( (new ASTArray(2)).add((TNode)astFactory.create(NInitDecl)).add(initDecl_AST));
2082 currentAST.root = initDecl_AST;
2083 currentAST.child = initDecl_AST!=null &&initDecl_AST.getFirstChild()!=null ?
2084 initDecl_AST.getFirstChild() : initDecl_AST;
2085 currentAST.advanceChildToEnd();
2086 }
2087 initDecl_AST = (TNode)currentAST.root;
2088 }
2089 catch (RecognitionException ex) {
2090 if (inputState.guessing==0) {
2091 reportError(ex);
2092 recover(ex,_tokenSet_25);
2093 } else {
2094 throw ex;
2095 }
2096 }
2097 returnAST = initDecl_AST;
2098 }
2099
2100 public final void initializer() throws RecognitionException, TokenStreamException {
2101
2102 returnAST = null;
2103 ASTPair currentAST = new ASTPair();
2104 TNode initializer_AST = null;
2105
2106 try { // for error handling
2107 {
2108 switch ( LA(1)) {
2109 case ID:
2110 case STAR:
2111 case LPAREN:
2112 case BAND:
2113 case PLUS:
2114 case MINUS:
2115 case INC:
2116 case DEC:
2117 case LITERAL_sizeof:
2118 case BNOT:
2119 case LNOT:
2120 case CharLiteral:
2121 case StringLiteral:
2122 case IntOctalConst:
2123 case LongOctalConst:
2124 case UnsignedOctalConst:
2125 case IntIntConst:
2126 case LongIntConst:
2127 case UnsignedIntConst:
2128 case IntHexConst:
2129 case LongHexConst:
2130 case UnsignedHexConst:
2131 case FloatDoubleConst:
2132 case DoubleDoubleConst:
2133 case LongDoubleConst:
2134 {
2135 assignExpr();
2136 astFactory.addASTChild(currentAST, returnAST);
2137 break;
2138 }
2139 case LCURLY:
2140 {
2141 TNode tmp66_AST = null;
2142 tmp66_AST = (TNode)astFactory.create(LT(1));
2143 astFactory.addASTChild(currentAST, tmp66_AST);
2144 match(LCURLY);
2145 initializerList();
2146 astFactory.addASTChild(currentAST, returnAST);
2147 {
2148 switch ( LA(1)) {
2149 case COMMA:
2150 {
2151 match(COMMA);
2152 break;
2153 }
2154 case RCURLY:
2155 {
2156 break;
2157 }
2158 default:
2159 {
2160 throw new NoViableAltException(LT(1), getFilename());
2161 }
2162 }
2163 }
2164 match(RCURLY);
2165 break;
2166 }
2167 default:
2168 {
2169 throw new NoViableAltException(LT(1), getFilename());
2170 }
2171 }
2172 }
2173 if ( inputState.guessing==0 ) {
2174 initializer_AST = (TNode)currentAST.root;
2175 initializer_AST = (TNode)astFactory.make( (new ASTArray(2)).add((TNode)astFactory.create(NInitializer)).add(initializer_AST));
2176 currentAST.root = initializer_AST;
2177 currentAST.child = initializer_AST!=null &&initializer_AST.getFirstChild()!=null ?
2178 initializer_AST.getFirstChild() : initializer_AST;
2179 currentAST.advanceChildToEnd();
2180 }
2181 initializer_AST = (TNode)currentAST.root;
2182 }
2183 catch (RecognitionException ex) {
2184 if (inputState.guessing==0) {
2185 reportError(ex);
2186 recover(ex,_tokenSet_31);
2187 } else {
2188 throw ex;
2189 }
2190 }
2191 returnAST = initializer_AST;
2192 }
2193
2194 public final void pointerGroup() throws RecognitionException, TokenStreamException {
2195
2196 returnAST = null;
2197 ASTPair currentAST = new ASTPair();
2198 TNode pointerGroup_AST = null;
2199
2200 try { // for error handling
2201 {
2202 int _cnt63=0;
2203 _loop63:
2204 do {
2205 if ((LA(1)==STAR)) {
2206 TNode tmp69_AST = null;
2207 tmp69_AST = (TNode)astFactory.create(LT(1));
2208 astFactory.addASTChild(currentAST, tmp69_AST);
2209 match(STAR);
2210 {
2211 _loop62:
2212 do {
2213 if ((LA(1)==LITERAL_volatile||LA(1)==LITERAL_const)) {
2214 typeQualifier();
2215 astFactory.addASTChild(currentAST, returnAST);
2216 }
2217 else {
2218 break _loop62;
2219 }
2220
2221 } while (true);
2222 }
2223 }
2224 else {
2225 if ( _cnt63>=1 ) { break _loop63; } else {throw new NoViableAltException(LT(1), getFilename());}
2226 }
2227
2228 _cnt63++;
2229 } while (true);
2230 }
2231 if ( inputState.guessing==0 ) {
2232 pointerGroup_AST = (TNode)currentAST.root;
2233 pointerGroup_AST = (TNode)astFactory.make( (new ASTArray(2)).add((TNode)astFactory.create(NPointerGroup)).add(pointerGroup_AST));
2234 currentAST.root = pointerGroup_AST;
2235 currentAST.child = pointerGroup_AST!=null &&pointerGroup_AST.getFirstChild()!=null ?
2236 pointerGroup_AST.getFirstChild() : pointerGroup_AST;
2237 currentAST.advanceChildToEnd();
2238 }
2239 pointerGroup_AST = (TNode)currentAST.root;
2240 }
2241 catch (RecognitionException ex) {
2242 if (inputState.guessing==0) {
2243 reportError(ex);
2244 recover(ex,_tokenSet_32);
2245 } else {
2246 throw ex;
2247 }
2248 }
2249 returnAST = pointerGroup_AST;
2250 }
2251
2252 public final void idList() throws RecognitionException, TokenStreamException {
2253
2254 returnAST = null;
2255 ASTPair currentAST = new ASTPair();
2256 TNode idList_AST = null;
2257
2258 try { // for error handling
2259 TNode tmp70_AST = null;
2260 tmp70_AST = (TNode)astFactory.create(LT(1));
2261 astFactory.addASTChild(currentAST, tmp70_AST);
2262 match(ID);
2263 {
2264 _loop66:
2265 do {
2266 if ((LA(1)==COMMA)) {
2267 match(COMMA);
2268 TNode tmp72_AST = null;
2269 tmp72_AST = (TNode)astFactory.create(LT(1));
2270 astFactory.addASTChild(currentAST, tmp72_AST);
2271 match(ID);
2272 }
2273 else {
2274 break _loop66;
2275 }
2276
2277 } while (true);
2278 }
2279 idList_AST = (TNode)currentAST.root;
2280 }
2281 catch (RecognitionException ex) {
2282 if (inputState.guessing==0) {
2283 reportError(ex);
2284 recover(ex,_tokenSet_33);
2285 } else {
2286 throw ex;
2287 }
2288 }
2289 returnAST = idList_AST;
2290 }
2291
2292 public final void assignExpr() throws RecognitionException, TokenStreamException {
2293
2294 returnAST = null;
2295 ASTPair currentAST = new ASTPair();
2296 TNode assignExpr_AST = null;
2297 TNode a_AST = null;
2298
2299 try { // for error handling
2300 conditionalExpr();
2301 astFactory.addASTChild(currentAST, returnAST);
2302 {
2303 switch ( LA(1)) {
2304 case ASSIGN:
2305 case DIV_ASSIGN:
2306 case PLUS_ASSIGN:
2307 case MINUS_ASSIGN:
2308 case STAR_ASSIGN:
2309 case MOD_ASSIGN:
2310 case RSHIFT_ASSIGN:
2311 case LSHIFT_ASSIGN:
2312 case BAND_ASSIGN:
2313 case BOR_ASSIGN:
2314 case BXOR_ASSIGN:
2315 {
2316 assignOperator();
2317 a_AST = (TNode)returnAST;
2318 assignExpr();
2319 astFactory.addASTChild(currentAST, returnAST);
2320 if ( inputState.guessing==0 ) {
2321 assignExpr_AST = (TNode)currentAST.root;
2322 assignExpr_AST = (TNode)astFactory.make( (new ASTArray(2)).add(a_AST).add(assignExpr_AST));
2323 currentAST.root = assignExpr_AST;
2324 currentAST.child = assignExpr_AST!=null &&assignExpr_AST.getFirstChild()!=null ?
2325 assignExpr_AST.getFirstChild() : assignExpr_AST;
2326 currentAST.advanceChildToEnd();
2327 }
2328 break;
2329 }
2330 case RCURLY:
2331 case SEMI:
2332 case COMMA:
2333 case COLON:
2334 case RPAREN:
2335 case RBRACKET:
2336 {
2337 break;
2338 }
2339 default:
2340 {
2341 throw new NoViableAltException(LT(1), getFilename());
2342 }
2343 }
2344 }
2345 assignExpr_AST = (TNode)currentAST.root;
2346 }
2347 catch (RecognitionException ex) {
2348 if (inputState.guessing==0) {
2349 reportError(ex);
2350 recover(ex,_tokenSet_12);
2351 } else {
2352 throw ex;
2353 }
2354 }
2355 returnAST = assignExpr_AST;
2356 }
2357
2358 public final void initializerList() throws RecognitionException, TokenStreamException {
2359
2360 returnAST = null;
2361 ASTPair currentAST = new ASTPair();
2362 TNode initializerList_AST = null;
2363
2364 try { // for error handling
2365 initializer();
2366 astFactory.addASTChild(currentAST, returnAST);
2367 {
2368 _loop72:
2369 do {
2370 if ((LA(1)==COMMA) && (_tokenSet_34.member(LA(2)))) {
2371 match(COMMA);
2372 initializer();
2373 astFactory.addASTChild(currentAST, returnAST);
2374 }
2375 else {
2376 break _loop72;
2377 }
2378
2379 } while (true);
2380 }
2381 initializerList_AST = (TNode)currentAST.root;
2382 }
2383 catch (RecognitionException ex) {
2384 if (inputState.guessing==0) {
2385 reportError(ex);
2386 recover(ex,_tokenSet_30);
2387 } else {
2388 throw ex;
2389 }
2390 }
2391 returnAST = initializerList_AST;
2392 }
2393
2394 public final void parameterTypeList() throws RecognitionException, TokenStreamException {
2395
2396 returnAST = null;
2397 ASTPair currentAST = new ASTPair();
2398 TNode parameterTypeList_AST = null;
2399
2400 try { // for error handling
2401 parameterDeclaration();
2402 astFactory.addASTChild(currentAST, returnAST);
2403 {
2404 _loop85:
2405 do {
2406 if ((LA(1)==COMMA) && (_tokenSet_2.member(LA(2)))) {
2407 match(COMMA);
2408 parameterDeclaration();
2409 astFactory.addASTChild(currentAST, returnAST);
2410 }
2411 else {
2412 break _loop85;
2413 }
2414
2415 } while (true);
2416 }
2417 {
2418 switch ( LA(1)) {
2419 case COMMA:
2420 {
2421 match(COMMA);
2422 TNode tmp76_AST = null;
2423 tmp76_AST = (TNode)astFactory.create(LT(1));
2424 astFactory.addASTChild(currentAST, tmp76_AST);
2425 match(VARARGS);
2426 break;
2427 }
2428 case RPAREN:
2429 {
2430 break;
2431 }
2432 default:
2433 {
2434 throw new NoViableAltException(LT(1), getFilename());
2435 }
2436 }
2437 }
2438 parameterTypeList_AST = (TNode)currentAST.root;
2439 }
2440 catch (RecognitionException ex) {
2441 if (inputState.guessing==0) {
2442 reportError(ex);
2443 recover(ex,_tokenSet_33);
2444 } else {
2445 throw ex;
2446 }
2447 }
2448 returnAST = parameterTypeList_AST;
2449 }
2450
2451 public final void parameterDeclaration() throws RecognitionException, TokenStreamException {
2452
2453 returnAST = null;
2454 ASTPair currentAST = new ASTPair();
2455 TNode parameterDeclaration_AST = null;
2456 TNode ds_AST = null;
2457 TNode d_AST = null;
2458 String declName;
2459
2460 try { // for error handling
2461 declSpecifiers();
2462 ds_AST = (TNode)returnAST;
2463 astFactory.addASTChild(currentAST, returnAST);
2464 {
2465 boolean synPredMatched90 = false;
2466 if (((_tokenSet_10.member(LA(1))) && (_tokenSet_35.member(LA(2))))) {
2467 int _m90 = mark();
2468 synPredMatched90 = true;
2469 inputState.guessing++;
2470 try {
2471 {
2472 declarator(false);
2473 }
2474 }
2475 catch (RecognitionException pe) {
2476 synPredMatched90 = false;
2477 }
2478 rewind(_m90);
2479inputState.guessing--;
2480 }
2481 if ( synPredMatched90 ) {
2482 declName=declarator(false);
2483 d_AST = (TNode)returnAST;
2484 astFactory.addASTChild(currentAST, returnAST);
2485 if ( inputState.guessing==0 ) {
2486
2487 AST d2, ds2;
2488 d2 = astFactory.dupList(d_AST);
2489 ds2 = astFactory.dupList(ds_AST);
2490 symbolTable.add(declName, (TNode)astFactory.make( (new ASTArray(3)).add(null).add(ds2).add(d2)));
2491
2492 }
2493 }
2494 else if ((_tokenSet_36.member(LA(1))) && (_tokenSet_37.member(LA(2)))) {
2495 nonemptyAbstractDeclarator();
2496 astFactory.addASTChild(currentAST, returnAST);
2497 }
2498 else if ((LA(1)==COMMA||LA(1)==RPAREN)) {
2499 }
2500 else {
2501 throw new NoViableAltException(LT(1), getFilename());
2502 }
2503
2504 }
2505 if ( inputState.guessing==0 ) {
2506 parameterDeclaration_AST = (TNode)currentAST.root;
2507
2508 parameterDeclaration_AST = (TNode)astFactory.make( (new ASTArray(2)).add((TNode)astFactory.create(NParameterDeclaration)).add(parameterDeclaration_AST));
2509
2510 currentAST.root = parameterDeclaration_AST;
2511 currentAST.child = parameterDeclaration_AST!=null &&parameterDeclaration_AST.getFirstChild()!=null ?
2512 parameterDeclaration_AST.getFirstChild() : parameterDeclaration_AST;
2513 currentAST.advanceChildToEnd();
2514 }
2515 parameterDeclaration_AST = (TNode)currentAST.root;
2516 }
2517 catch (RecognitionException ex) {
2518 if (inputState.guessing==0) {
2519 reportError(ex);
2520 recover(ex,_tokenSet_38);
2521 } else {
2522 throw ex;
2523 }
2524 }
2525 returnAST = parameterDeclaration_AST;
2526 }
2527
2528 public final void nonemptyAbstractDeclarator() throws RecognitionException, TokenStreamException {
2529
2530 returnAST = null;
2531 ASTPair currentAST = new ASTPair();
2532 TNode nonemptyAbstractDeclarator_AST = null;
2533
2534 try { // for error handling
2535 {
2536 switch ( LA(1)) {
2537 case STAR:
2538 {
2539 pointerGroup();
2540 astFactory.addASTChild(currentAST, returnAST);
2541 {
2542 _loop184:
2543 do {
2544 switch ( LA(1)) {
2545 case LPAREN:
2546 {
2547 {
2548 TNode tmp77_AST = null;
2549 tmp77_AST = (TNode)astFactory.create(LT(1));
2550 astFactory.addASTChild(currentAST, tmp77_AST);
2551 match(LPAREN);
2552 {
2553 switch ( LA(1)) {
2554 case STAR:
2555 case LPAREN:
2556 case LBRACKET:
2557 {
2558 nonemptyAbstractDeclarator();
2559 astFactory.addASTChild(currentAST, returnAST);
2560 break;
2561 }
2562 case LITERAL_typedef:
2563 case LITERAL_volatile:
2564 case LITERAL_struct:
2565 case LITERAL_union:
2566 case LITERAL_enum:
2567 case LITERAL_auto:
2568 case LITERAL_register:
2569 case LITERAL_extern:
2570 case LITERAL_static:
2571 case LITERAL_const:
2572 case LITERAL_void:
2573 case LITERAL_char:
2574 case LITERAL_short:
2575 case LITERAL_int:
2576 case LITERAL_long:
2577 case LITERAL_float:
2578 case LITERAL_double:
2579 case LITERAL_signed:
2580 case LITERAL_unsigned:
2581 case 27:
2582 case 28:
2583 case 29:
2584 case 30:
2585 case 31:
2586 case 32:
2587 case LITERAL_wchar_t:
2588 case 34:
2589 case 35:
2590 case 36:
2591 case 37:
2592 case LITERAL_ptrdiff_t:
2593 case LITERAL_intptr_t:
2594 case LITERAL_size_t:
2595 case LITERAL_uintptr_t:
2596 case ID:
2597 {
2598 parameterTypeList();
2599 astFactory.addASTChild(currentAST, returnAST);
2600 break;
2601 }
2602 case RPAREN:
2603 {
2604 break;
2605 }
2606 default:
2607 {
2608 throw new NoViableAltException(LT(1), getFilename());
2609 }
2610 }
2611 }
2612 TNode tmp78_AST = null;
2613 tmp78_AST = (TNode)astFactory.create(LT(1));
2614 astFactory.addASTChild(currentAST, tmp78_AST);
2615 match(RPAREN);
2616 }
2617 break;
2618 }
2619 case LBRACKET:
2620 {
2621 {
2622 TNode tmp79_AST = null;
2623 tmp79_AST = (TNode)astFactory.create(LT(1));
2624 astFactory.addASTChild(currentAST, tmp79_AST);
2625 match(LBRACKET);
2626 {
2627 switch ( LA(1)) {
2628 case ID:
2629 case STAR:
2630 case LPAREN:
2631 case BAND:
2632 case PLUS:
2633 case MINUS:
2634 case INC:
2635 case DEC:
2636 case LITERAL_sizeof:
2637 case BNOT:
2638 case LNOT:
2639 case CharLiteral:
2640 case StringLiteral:
2641 case IntOctalConst:
2642 case LongOctalConst:
2643 case UnsignedOctalConst:
2644 case IntIntConst:
2645 case LongIntConst:
2646 case UnsignedIntConst:
2647 case IntHexConst:
2648 case LongHexConst:
2649 case UnsignedHexConst:
2650 case FloatDoubleConst:
2651 case DoubleDoubleConst:
2652 case LongDoubleConst:
2653 {
2654 expr();
2655 astFactory.addASTChild(currentAST, returnAST);
2656 break;
2657 }
2658 case RBRACKET:
2659 {
2660 break;
2661 }
2662 default:
2663 {
2664 throw new NoViableAltException(LT(1), getFilename());
2665 }
2666 }
2667 }
2668 TNode tmp80_AST = null;
2669 tmp80_AST = (TNode)astFactory.create(LT(1));
2670 astFactory.addASTChild(currentAST, tmp80_AST);
2671 match(RBRACKET);
2672 }
2673 break;
2674 }
2675 default:
2676 {
2677 break _loop184;
2678 }
2679 }
2680 } while (true);
2681 }
2682 break;
2683 }
2684 case LPAREN:
2685 case LBRACKET:
2686 {
2687 {
2688 int _cnt190=0;
2689 _loop190:
2690 do {
2691 switch ( LA(1)) {
2692 case LPAREN:
2693 {
2694 {
2695 TNode tmp81_AST = null;
2696 tmp81_AST = (TNode)astFactory.create(LT(1));
2697 astFactory.addASTChild(currentAST, tmp81_AST);
2698 match(LPAREN);
2699 {
2700 switch ( LA(1)) {
2701 case STAR:
2702 case LPAREN:
2703 case LBRACKET:
2704 {
2705 nonemptyAbstractDeclarator();
2706 astFactory.addASTChild(currentAST, returnAST);
2707 break;
2708 }
2709 case LITERAL_typedef:
2710 case LITERAL_volatile:
2711 case LITERAL_struct:
2712 case LITERAL_union:
2713 case LITERAL_enum:
2714 case LITERAL_auto:
2715 case LITERAL_register:
2716 case LITERAL_extern:
2717 case LITERAL_static:
2718 case LITERAL_const:
2719 case LITERAL_void:
2720 case LITERAL_char:
2721 case LITERAL_short:
2722 case LITERAL_int:
2723 case LITERAL_long:
2724 case LITERAL_float:
2725 case LITERAL_double:
2726 case LITERAL_signed:
2727 case LITERAL_unsigned:
2728 case 27:
2729 case 28:
2730 case 29:
2731 case 30:
2732 case 31:
2733 case 32:
2734 case LITERAL_wchar_t:
2735 case 34:
2736 case 35:
2737 case 36:
2738 case 37:
2739 case LITERAL_ptrdiff_t:
2740 case LITERAL_intptr_t:
2741 case LITERAL_size_t:
2742 case LITERAL_uintptr_t:
2743 case ID:
2744 {
2745 parameterTypeList();
2746 astFactory.addASTChild(currentAST, returnAST);
2747 break;
2748 }
2749 case RPAREN:
2750 {
2751 break;
2752 }
2753 default:
2754 {
2755 throw new NoViableAltException(LT(1), getFilename());
2756 }
2757 }
2758 }
2759 TNode tmp82_AST = null;
2760 tmp82_AST = (TNode)astFactory.create(LT(1));
2761 astFactory.addASTChild(currentAST, tmp82_AST);
2762 match(RPAREN);
2763 }
2764 break;
2765 }
2766 case LBRACKET:
2767 {
2768 {
2769 TNode tmp83_AST = null;
2770 tmp83_AST = (TNode)astFactory.create(LT(1));
2771 astFactory.addASTChild(currentAST, tmp83_AST);
2772 match(LBRACKET);
2773 {
2774 switch ( LA(1)) {
2775 case ID:
2776 case STAR:
2777 case LPAREN:
2778 case BAND:
2779 case PLUS:
2780 case MINUS:
2781 case INC:
2782 case DEC:
2783 case LITERAL_sizeof:
2784 case BNOT:
2785 case LNOT:
2786 case CharLiteral:
2787 case StringLiteral:
2788 case IntOctalConst:
2789 case LongOctalConst:
2790 case UnsignedOctalConst:
2791 case IntIntConst:
2792 case LongIntConst:
2793 case UnsignedIntConst:
2794 case IntHexConst:
2795 case LongHexConst:
2796 case UnsignedHexConst:
2797 case FloatDoubleConst:
2798 case DoubleDoubleConst:
2799 case LongDoubleConst:
2800 {
2801 expr();
2802 astFactory.addASTChild(currentAST, returnAST);
2803 break;
2804 }
2805 case RBRACKET:
2806 {
2807 break;
2808 }
2809 default:
2810 {
2811 throw new NoViableAltException(LT(1), getFilename());
2812 }
2813 }
2814 }
2815 TNode tmp84_AST = null;
2816 tmp84_AST = (TNode)astFactory.create(LT(1));
2817 astFactory.addASTChild(currentAST, tmp84_AST);
2818 match(RBRACKET);
2819 }
2820 break;
2821 }
2822 default:
2823 {
2824 if ( _cnt190>=1 ) { break _loop190; } else {throw new NoViableAltException(LT(1), getFilename());}
2825 }
2826 }
2827 _cnt190++;
2828 } while (true);
2829 }
2830 break;
2831 }
2832 default:
2833 {
2834 throw new NoViableAltException(LT(1), getFilename());
2835 }
2836 }
2837 }
2838 if ( inputState.guessing==0 ) {
2839 nonemptyAbstractDeclarator_AST = (TNode)currentAST.root;
2840 nonemptyAbstractDeclarator_AST = (TNode)astFactory.make( (new ASTArray(2)).add((TNode)astFactory.create(NNonemptyAbstractDeclarator)).add(nonemptyAbstractDeclarator_AST));
2841 currentAST.root = nonemptyAbstractDeclarator_AST;
2842 currentAST.child = nonemptyAbstractDeclarator_AST!=null &&nonemptyAbstractDeclarator_AST.getFirstChild()!=null ?
2843 nonemptyAbstractDeclarator_AST.getFirstChild() : nonemptyAbstractDeclarator_AST;
2844 currentAST.advanceChildToEnd();
2845 }
2846 nonemptyAbstractDeclarator_AST = (TNode)currentAST.root;
2847 }
2848 catch (RecognitionException ex) {
2849 if (inputState.guessing==0) {
2850 reportError(ex);
2851 recover(ex,_tokenSet_38);
2852 } else {
2853 throw ex;
2854 }
2855 }
2856 returnAST = nonemptyAbstractDeclarator_AST;
2857 }
2858
2859 public final void functionDeclSpecifiers() throws RecognitionException, TokenStreamException {
2860
2861 returnAST = null;
2862 ASTPair currentAST = new ASTPair();
2863 TNode functionDeclSpecifiers_AST = null;
2864 int specCount = 0;
2865
2866 try { // for error handling
2867 {
2868 int _cnt104=0;
2869 _loop104:
2870 do {
2871 switch ( LA(1)) {
2872 case LITERAL_extern:
2873 case LITERAL_static:
2874 {
2875 functionStorageClassSpecifier();
2876 astFactory.addASTChild(currentAST, returnAST);
2877 break;
2878 }
2879 case LITERAL_volatile:
2880 case LITERAL_const:
2881 {
2882 typeQualifier();
2883 astFactory.addASTChild(currentAST, returnAST);
2884 break;
2885 }
2886 default:
2887 boolean synPredMatched103 = false;
2888 if (((_tokenSet_13.member(LA(1))) && (_tokenSet_9.member(LA(2))))) {
2889 int _m103 = mark();
2890 synPredMatched103 = true;
2891 inputState.guessing++;
2892 try {
2893 {
2894 if ((LA(1)==LITERAL_struct) && (true)) {
2895 match(LITERAL_struct);
2896 }
2897 else if ((LA(1)==LITERAL_union) && (true)) {
2898 match(LITERAL_union);
2899 }
2900 else if ((LA(1)==LITERAL_enum) && (true)) {
2901 match(LITERAL_enum);
2902 }
2903 else if ((_tokenSet_13.member(LA(1))) && (true)) {
2904 typeSpecifier(specCount);
2905 }
2906 else {
2907 throw new NoViableAltException(LT(1), getFilename());
2908 }
2909
2910 }
2911 }
2912 catch (RecognitionException pe) {
2913 synPredMatched103 = false;
2914 }
2915 rewind(_m103);
2916inputState.guessing--;
2917 }
2918 if ( synPredMatched103 ) {
2919 specCount=typeSpecifier(specCount);
2920 astFactory.addASTChild(currentAST, returnAST);
2921 }
2922 else {
2923 if ( _cnt104>=1 ) { break _loop104; } else {throw new NoViableAltException(LT(1), getFilename());}
2924 }
2925 }
2926 _cnt104++;
2927 } while (true);
2928 }
2929 functionDeclSpecifiers_AST = (TNode)currentAST.root;
2930 }
2931 catch (RecognitionException ex) {
2932 if (inputState.guessing==0) {
2933 reportError(ex);
2934 recover(ex,_tokenSet_10);
2935 } else {
2936 throw ex;
2937 }
2938 }
2939 returnAST = functionDeclSpecifiers_AST;
2940 }
2941
2942 public final void compoundStatement(
2943 String scopeName
2944 ) throws RecognitionException, TokenStreamException {
2945
2946 returnAST = null;
2947 ASTPair currentAST = new ASTPair();
2948 TNode compoundStatement_AST = null;
2949
2950 try { // for error handling
2951 match(LCURLY);
2952 if ( inputState.guessing==0 ) {
2953
2954 pushScope(scopeName);
2955
2956 }
2957 {
2958 boolean synPredMatched115 = false;
2959 if (((_tokenSet_2.member(LA(1))) && (_tokenSet_3.member(LA(2))))) {
2960 int _m115 = mark();
2961 synPredMatched115 = true;
2962 inputState.guessing++;
2963 try {
2964 {
2965 declarationPredictor();
2966 }
2967 }
2968 catch (RecognitionException pe) {
2969 synPredMatched115 = false;
2970 }
2971 rewind(_m115);
2972inputState.guessing--;
2973 }
2974 if ( synPredMatched115 ) {
2975 declarationList();
2976 astFactory.addASTChild(currentAST, returnAST);
2977 }
2978 else if ((_tokenSet_39.member(LA(1))) && (_tokenSet_40.member(LA(2)))) {
2979 }
2980 else {
2981 throw new NoViableAltException(LT(1), getFilename());
2982 }
2983
2984 }
2985 {
2986 switch ( LA(1)) {
2987 case LCURLY:
2988 case SEMI:
2989 case ID:
2990 case STAR:
2991 case LPAREN:
2992 case LITERAL_while:
2993 case LITERAL_do:
2994 case LITERAL_for:
2995 case LITERAL_goto:
2996 case LITERAL_continue:
2997 case LITERAL_break:
2998 case LITERAL_return:
2999 case LITERAL_case:
3000 case LITERAL_default:
3001 case LITERAL_if:
3002 case LITERAL_switch:
3003 case BAND:
3004 case PLUS:
3005 case MINUS:
3006 case INC:
3007 case DEC:
3008 case LITERAL_sizeof:
3009 case BNOT:
3010 case LNOT:
3011 case CharLiteral:
3012 case StringLiteral:
3013 case IntOctalConst:
3014 case LongOctalConst:
3015 case UnsignedOctalConst:
3016 case IntIntConst:
3017 case LongIntConst:
3018 case UnsignedIntConst:
3019 case IntHexConst:
3020 case LongHexConst:
3021 case UnsignedHexConst:
3022 case FloatDoubleConst:
3023 case DoubleDoubleConst:
3024 case LongDoubleConst:
3025 {
3026 statementList();
3027 astFactory.addASTChild(currentAST, returnAST);
3028 break;
3029 }
3030 case RCURLY:
3031 {
3032 break;
3033 }
3034 default:
3035 {
3036 throw new NoViableAltException(LT(1), getFilename());
3037 }
3038 }
3039 }
3040 if ( inputState.guessing==0 ) {
3041 popScope();
3042 }
3043 match(RCURLY);
3044 if ( inputState.guessing==0 ) {
3045 compoundStatement_AST = (TNode)currentAST.root;
3046 compoundStatement_AST = (TNode)astFactory.make( (new ASTArray(2)).add((TNode)astFactory.create(NCompoundStatement,scopeName)).add(compoundStatement_AST));
3047 currentAST.root = compoundStatement_AST;
3048 currentAST.child = compoundStatement_AST!=null &&compoundStatement_AST.getFirstChild()!=null ?
3049 compoundStatement_AST.getFirstChild() : compoundStatement_AST;
3050 currentAST.advanceChildToEnd();
3051 }
3052 compoundStatement_AST = (TNode)currentAST.root;
3053 }
3054 catch (RecognitionException ex) {
3055 if (inputState.guessing==0) {
3056 reportError(ex);
3057 recover(ex,_tokenSet_41);
3058 } else {
3059 throw ex;
3060 }
3061 }
3062 returnAST = compoundStatement_AST;
3063 }
3064
3065 public final void declarationList() throws RecognitionException, TokenStreamException {
3066
3067 returnAST = null;
3068 ASTPair currentAST = new ASTPair();
3069 TNode declarationList_AST = null;
3070
3071 try { // for error handling
3072 {
3073 int _cnt109=0;
3074 _loop109:
3075 do {
3076 boolean synPredMatched108 = false;
3077 if (((_tokenSet_2.member(LA(1))) && (_tokenSet_3.member(LA(2))))) {
3078 int _m108 = mark();
3079 synPredMatched108 = true;
3080 inputState.guessing++;
3081 try {
3082 {
3083 declarationPredictor();
3084 }
3085 }
3086 catch (RecognitionException pe) {
3087 synPredMatched108 = false;
3088 }
3089 rewind(_m108);
3090inputState.guessing--;
3091 }
3092 if ( synPredMatched108 ) {
3093 declaration();
3094 astFactory.addASTChild(currentAST, returnAST);
3095 }
3096 else {
3097 if ( _cnt109>=1 ) { break _loop109; } else {throw new NoViableAltException(LT(1), getFilename());}
3098 }
3099
3100 _cnt109++;
3101 } while (true);
3102 }
3103 declarationList_AST = (TNode)currentAST.root;
3104 }
3105 catch (RecognitionException ex) {
3106 if (inputState.guessing==0) {
3107 reportError(ex);
3108 recover(ex,_tokenSet_39);
3109 } else {
3110 throw ex;
3111 }
3112 }
3113 returnAST = declarationList_AST;
3114 }
3115
3116 public final void declarationPredictor() throws RecognitionException, TokenStreamException {
3117
3118 returnAST = null;
3119 ASTPair currentAST = new ASTPair();
3120 TNode declarationPredictor_AST = null;
3121
3122 try { // for error handling
3123 {
3124 if ((LA(1)==LITERAL_typedef) && (LA(2)==EOF)) {
3125 TNode tmp87_AST = null;
3126 tmp87_AST = (TNode)astFactory.create(LT(1));
3127 astFactory.addASTChild(currentAST, tmp87_AST);
3128 match(LITERAL_typedef);
3129 }
3130 else if ((_tokenSet_2.member(LA(1))) && (_tokenSet_3.member(LA(2)))) {
3131 declaration();
3132 astFactory.addASTChild(currentAST, returnAST);
3133 }
3134 else {
3135 throw new NoViableAltException(LT(1), getFilename());
3136 }
3137
3138 }
3139 declarationPredictor_AST = (TNode)currentAST.root;
3140 }
3141 catch (RecognitionException ex) {
3142 if (inputState.guessing==0) {
3143 reportError(ex);
3144 recover(ex,_tokenSet_0);
3145 } else {
3146 throw ex;
3147 }
3148 }
3149 returnAST = declarationPredictor_AST;
3150 }
3151
3152 public final void statementList() throws RecognitionException, TokenStreamException {
3153
3154 returnAST = null;
3155 ASTPair currentAST = new ASTPair();
3156 TNode statementList_AST = null;
3157
3158 try { // for error handling
3159 {
3160 int _cnt119=0;
3161 _loop119:
3162 do {
3163 if ((_tokenSet_42.member(LA(1)))) {
3164 statement();
3165 astFactory.addASTChild(currentAST, returnAST);
3166 }
3167 else {
3168 if ( _cnt119>=1 ) { break _loop119; } else {throw new NoViableAltException(LT(1), getFilename());}
3169 }
3170
3171 _cnt119++;
3172 } while (true);
3173 }
3174 statementList_AST = (TNode)currentAST.root;
3175 }
3176 catch (RecognitionException ex) {
3177 if (inputState.guessing==0) {
3178 reportError(ex);
3179 recover(ex,_tokenSet_21);
3180 } else {
3181 throw ex;
3182 }
3183 }
3184 returnAST = statementList_AST;
3185 }
3186
3187 public final void statement() throws RecognitionException, TokenStreamException {
3188
3189 returnAST = null;
3190 ASTPair currentAST = new ASTPair();
3191 TNode statement_AST = null;
3192 TNode e1_AST = null;
3193 TNode e2_AST = null;
3194 TNode e3_AST = null;
3195 TNode s_AST = null;
3196
3197 try { // for error handling
3198 switch ( LA(1)) {
3199 case SEMI:
3200 {
3201 TNode tmp88_AST = null;
3202 tmp88_AST = (TNode)astFactory.create(LT(1));
3203 astFactory.addASTChild(currentAST, tmp88_AST);
3204 match(SEMI);
3205 statement_AST = (TNode)currentAST.root;
3206 break;
3207 }
3208 case LCURLY:
3209 {
3210 compoundStatement(getAScopeName());
3211 astFactory.addASTChild(currentAST, returnAST);
3212 statement_AST = (TNode)currentAST.root;
3213 break;
3214 }
3215 case LITERAL_while:
3216 {
3217 TNode tmp89_AST = null;
3218 tmp89_AST = (TNode)astFactory.create(LT(1));
3219 astFactory.makeASTRoot(currentAST, tmp89_AST);
3220 match(LITERAL_while);
3221 match(LPAREN);
3222 expr();
3223 astFactory.addASTChild(currentAST, returnAST);
3224 match(RPAREN);
3225 statement();
3226 astFactory.addASTChild(currentAST, returnAST);
3227 statement_AST = (TNode)currentAST.root;
3228 break;
3229 }
3230 case LITERAL_do:
3231 {
3232 TNode tmp92_AST = null;
3233 tmp92_AST = (TNode)astFactory.create(LT(1));
3234 astFactory.makeASTRoot(currentAST, tmp92_AST);
3235 match(LITERAL_do);
3236 statement();
3237 astFactory.addASTChild(currentAST, returnAST);
3238 match(LITERAL_while);
3239 match(LPAREN);
3240 expr();
3241 astFactory.addASTChild(currentAST, returnAST);
3242 match(RPAREN);
3243 match(SEMI);
3244 statement_AST = (TNode)currentAST.root;
3245 break;
3246 }
3247 case LITERAL_for:
3248 {
3249 match(LITERAL_for);
3250 TNode tmp98_AST = null;
3251 tmp98_AST = (TNode)astFactory.create(LT(1));
3252 match(LPAREN);
3253 {
3254 switch ( LA(1)) {
3255 case ID:
3256 case STAR:
3257 case LPAREN:
3258 case BAND:
3259 case PLUS:
3260 case MINUS:
3261 case INC:
3262 case DEC:
3263 case LITERAL_sizeof:
3264 case BNOT:
3265 case LNOT:
3266 case CharLiteral:
3267 case StringLiteral:
3268 case IntOctalConst:
3269 case LongOctalConst:
3270 case UnsignedOctalConst:
3271 case IntIntConst:
3272 case LongIntConst:
3273 case UnsignedIntConst:
3274 case IntHexConst:
3275 case LongHexConst:
3276 case UnsignedHexConst:
3277 case FloatDoubleConst:
3278 case DoubleDoubleConst:
3279 case LongDoubleConst:
3280 {
3281 expr();
3282 e1_AST = (TNode)returnAST;
3283 break;
3284 }
3285 case SEMI:
3286 {
3287 break;
3288 }
3289 default:
3290 {
3291 throw new NoViableAltException(LT(1), getFilename());
3292 }
3293 }
3294 }
3295 TNode tmp99_AST = null;
3296 tmp99_AST = (TNode)astFactory.create(LT(1));
3297 match(SEMI);
3298 {
3299 switch ( LA(1)) {
3300 case ID:
3301 case STAR:
3302 case LPAREN:
3303 case BAND:
3304 case PLUS:
3305 case MINUS:
3306 case INC:
3307 case DEC:
3308 case LITERAL_sizeof:
3309 case BNOT:
3310 case LNOT:
3311 case CharLiteral:
3312 case StringLiteral:
3313 case IntOctalConst:
3314 case LongOctalConst:
3315 case UnsignedOctalConst:
3316 case IntIntConst:
3317 case LongIntConst:
3318 case UnsignedIntConst:
3319 case IntHexConst:
3320 case LongHexConst:
3321 case UnsignedHexConst:
3322 case FloatDoubleConst:
3323 case DoubleDoubleConst:
3324 case LongDoubleConst:
3325 {
3326 expr();
3327 e2_AST = (TNode)returnAST;
3328 break;
3329 }
3330 case SEMI:
3331 {
3332 break;
3333 }
3334 default:
3335 {
3336 throw new NoViableAltException(LT(1), getFilename());
3337 }
3338 }
3339 }
3340 TNode tmp100_AST = null;
3341 tmp100_AST = (TNode)astFactory.create(LT(1));
3342 match(SEMI);
3343 {
3344 switch ( LA(1)) {
3345 case ID:
3346 case STAR:
3347 case LPAREN:
3348 case BAND:
3349 case PLUS:
3350 case MINUS:
3351 case INC:
3352 case DEC:
3353 case LITERAL_sizeof:
3354 case BNOT:
3355 case LNOT:
3356 case CharLiteral:
3357 case StringLiteral:
3358 case IntOctalConst:
3359 case LongOctalConst:
3360 case UnsignedOctalConst:
3361 case IntIntConst:
3362 case LongIntConst:
3363 case UnsignedIntConst:
3364 case IntHexConst:
3365 case LongHexConst:
3366 case UnsignedHexConst:
3367 case FloatDoubleConst:
3368 case DoubleDoubleConst:
3369 case LongDoubleConst:
3370 {
3371 expr();
3372 e3_AST = (TNode)returnAST;
3373 break;
3374 }
3375 case RPAREN:
3376 {
3377 break;
3378 }
3379 default:
3380 {
3381 throw new NoViableAltException(LT(1), getFilename());
3382 }
3383 }
3384 }
3385 TNode tmp101_AST = null;
3386 tmp101_AST = (TNode)astFactory.create(LT(1));
3387 match(RPAREN);
3388 statement();
3389 s_AST = (TNode)returnAST;
3390 if ( inputState.guessing==0 ) {
3391 statement_AST = (TNode)currentAST.root;
3392
3393 if ( e1_AST == null) { e1_AST = (TNode) (TNode)astFactory.create(NEmptyExpression); }
3394 if ( e2_AST == null) { e2_AST = (TNode) (TNode)astFactory.create(NEmptyExpression); }
3395 if ( e3_AST == null) { e3_AST = (TNode) (TNode)astFactory.create(NEmptyExpression); }
3396 statement_AST = (TNode)astFactory.make( (new ASTArray(5)).add((TNode)astFactory.create(LITERAL_for,"for")).add(e1_AST).add(e2_AST).add(e3_AST).add(s_AST));
3397
3398 currentAST.root = statement_AST;
3399 currentAST.child = statement_AST!=null &&statement_AST.getFirstChild()!=null ?
3400 statement_AST.getFirstChild() : statement_AST;
3401 currentAST.advanceChildToEnd();
3402 }
3403 break;
3404 }
3405 case LITERAL_goto:
3406 {
3407 TNode tmp102_AST = null;
3408 tmp102_AST = (TNode)astFactory.create(LT(1));
3409 astFactory.makeASTRoot(currentAST, tmp102_AST);
3410 match(LITERAL_goto);
3411 TNode tmp103_AST = null;
3412 tmp103_AST = (TNode)astFactory.create(LT(1));
3413 astFactory.addASTChild(currentAST, tmp103_AST);
3414 match(ID);
3415 match(SEMI);
3416 statement_AST = (TNode)currentAST.root;
3417 break;
3418 }
3419 case LITERAL_continue:
3420 {
3421 TNode tmp105_AST = null;
3422 tmp105_AST = (TNode)astFactory.create(LT(1));
3423 astFactory.addASTChild(currentAST, tmp105_AST);
3424 match(LITERAL_continue);
3425 match(SEMI);
3426 statement_AST = (TNode)currentAST.root;
3427 break;
3428 }
3429 case LITERAL_break:
3430 {
3431 TNode tmp107_AST = null;
3432 tmp107_AST = (TNode)astFactory.create(LT(1));
3433 astFactory.addASTChild(currentAST, tmp107_AST);
3434 match(LITERAL_break);
3435 match(SEMI);
3436 statement_AST = (TNode)currentAST.root;
3437 break;
3438 }
3439 case LITERAL_return:
3440 {
3441 TNode tmp109_AST = null;
3442 tmp109_AST = (TNode)astFactory.create(LT(1));
3443 astFactory.makeASTRoot(currentAST, tmp109_AST);
3444 match(LITERAL_return);
3445 {
3446 switch ( LA(1)) {
3447 case ID:
3448 case STAR:
3449 case LPAREN:
3450 case BAND:
3451 case PLUS:
3452 case MINUS:
3453 case INC:
3454 case DEC:
3455 case LITERAL_sizeof:
3456 case BNOT:
3457 case LNOT:
3458 case CharLiteral:
3459 case StringLiteral:
3460 case IntOctalConst:
3461 case LongOctalConst:
3462 case UnsignedOctalConst:
3463 case IntIntConst:
3464 case LongIntConst:
3465 case UnsignedIntConst:
3466 case IntHexConst:
3467 case LongHexConst:
3468 case UnsignedHexConst:
3469 case FloatDoubleConst:
3470 case DoubleDoubleConst:
3471 case LongDoubleConst:
3472 {
3473 expr();
3474 astFactory.addASTChild(currentAST, returnAST);
3475 break;
3476 }
3477 case SEMI:
3478 {
3479 break;
3480 }
3481 default:
3482 {
3483 throw new NoViableAltException(LT(1), getFilename());
3484 }
3485 }
3486 }
3487 match(SEMI);
3488 statement_AST = (TNode)currentAST.root;
3489 break;
3490 }
3491 case LITERAL_case:
3492 {
3493 TNode tmp111_AST = null;
3494 tmp111_AST = (TNode)astFactory.create(LT(1));
3495 astFactory.makeASTRoot(currentAST, tmp111_AST);
3496 match(LITERAL_case);
3497 constExpr();
3498 astFactory.addASTChild(currentAST, returnAST);
3499 match(COLON);
3500 statement();
3501 astFactory.addASTChild(currentAST, returnAST);
3502 statement_AST = (TNode)currentAST.root;
3503 break;
3504 }
3505 case LITERAL_default:
3506 {
3507 TNode tmp113_AST = null;
3508 tmp113_AST = (TNode)astFactory.create(LT(1));
3509 astFactory.makeASTRoot(currentAST, tmp113_AST);
3510 match(LITERAL_default);
3511 match(COLON);
3512 statement();
3513 astFactory.addASTChild(currentAST, returnAST);
3514 statement_AST = (TNode)currentAST.root;
3515 break;
3516 }
3517 case LITERAL_if:
3518 {
3519 TNode tmp115_AST = null;
3520 tmp115_AST = (TNode)astFactory.create(LT(1));
3521 astFactory.makeASTRoot(currentAST, tmp115_AST);
3522 match(LITERAL_if);
3523 match(LPAREN);
3524 expr();
3525 astFactory.addASTChild(currentAST, returnAST);
3526 match(RPAREN);
3527 statement();
3528 astFactory.addASTChild(currentAST, returnAST);
3529 {
3530 if ((LA(1)==LITERAL_else) && (_tokenSet_42.member(LA(2)))) {
3531 TNode tmp118_AST = null;
3532 tmp118_AST = (TNode)astFactory.create(LT(1));
3533 astFactory.addASTChild(currentAST, tmp118_AST);
3534 match(LITERAL_else);
3535 statement();
3536 astFactory.addASTChild(currentAST, returnAST);
3537 }
3538 else if ((_tokenSet_43.member(LA(1))) && (_tokenSet_40.member(LA(2)))) {
3539 }
3540 else {
3541 throw new NoViableAltException(LT(1), getFilename());
3542 }
3543
3544 }
3545 statement_AST = (TNode)currentAST.root;
3546 break;
3547 }
3548 case LITERAL_switch:
3549 {
3550 TNode tmp119_AST = null;
3551 tmp119_AST = (TNode)astFactory.create(LT(1));
3552 astFactory.makeASTRoot(currentAST, tmp119_AST);
3553 match(LITERAL_switch);
3554 match(LPAREN);
3555 expr();
3556 astFactory.addASTChild(currentAST, returnAST);
3557 match(RPAREN);
3558 statement();
3559 astFactory.addASTChild(currentAST, returnAST);
3560 statement_AST = (TNode)currentAST.root;
3561 break;
3562 }
3563 default:
3564 if ((_tokenSet_11.member(LA(1))) && (_tokenSet_44.member(LA(2)))) {
3565 expr();
3566 astFactory.addASTChild(currentAST, returnAST);
3567 match(SEMI);
3568 if ( inputState.guessing==0 ) {
3569 statement_AST = (TNode)currentAST.root;
3570 statement_AST = (TNode)astFactory.make( (new ASTArray(2)).add((TNode)astFactory.create(NStatementExpr)).add(statement_AST));
3571 currentAST.root = statement_AST;
3572 currentAST.child = statement_AST!=null &&statement_AST.getFirstChild()!=null ?
3573 statement_AST.getFirstChild() : statement_AST;
3574 currentAST.advanceChildToEnd();
3575 }
3576 statement_AST = (TNode)currentAST.root;
3577 }
3578 else if ((LA(1)==ID) && (LA(2)==COLON)) {
3579 TNode tmp123_AST = null;
3580 tmp123_AST = (TNode)astFactory.create(LT(1));
3581 astFactory.addASTChild(currentAST, tmp123_AST);
3582 match(ID);
3583 match(COLON);
3584 {
3585 if ((_tokenSet_42.member(LA(1))) && (_tokenSet_45.member(LA(2)))) {
3586 statement();
3587 astFactory.addASTChild(currentAST, returnAST);
3588 }
3589 else if ((_tokenSet_43.member(LA(1))) && (_tokenSet_40.member(LA(2)))) {
3590 }
3591 else {
3592 throw new NoViableAltException(LT(1), getFilename());
3593 }
3594
3595 }
3596 if ( inputState.guessing==0 ) {
3597 statement_AST = (TNode)currentAST.root;
3598 statement_AST = (TNode)astFactory.make( (new ASTArray(2)).add((TNode)astFactory.create(NLabel)).add(statement_AST));
3599 currentAST.root = statement_AST;
3600 currentAST.child = statement_AST!=null &&statement_AST.getFirstChild()!=null ?
3601 statement_AST.getFirstChild() : statement_AST;
3602 currentAST.advanceChildToEnd();
3603 }
3604 statement_AST = (TNode)currentAST.root;
3605 }
3606 else {
3607 throw new NoViableAltException(LT(1), getFilename());
3608 }
3609 }
3610 }
3611 catch (RecognitionException ex) {
3612 if (inputState.guessing==0) {
3613 reportError(ex);
3614 recover(ex,_tokenSet_43);
3615 } else {
3616 throw ex;
3617 }
3618 }
3619 returnAST = statement_AST;
3620 }
3621
3622 public final void conditionalExpr() throws RecognitionException, TokenStreamException {
3623
3624 returnAST = null;
3625 ASTPair currentAST = new ASTPair();
3626 TNode conditionalExpr_AST = null;
3627
3628 try { // for error handling
3629 logicalOrExpr();
3630 astFactory.addASTChild(currentAST, returnAST);
3631 {
3632 switch ( LA(1)) {
3633 case QUESTION:
3634 {
3635 TNode tmp125_AST = null;
3636 tmp125_AST = (TNode)astFactory.create(LT(1));
3637 astFactory.makeASTRoot(currentAST, tmp125_AST);
3638 match(QUESTION);
3639 expr();
3640 astFactory.addASTChild(currentAST, returnAST);
3641 match(COLON);
3642 conditionalExpr();
3643 astFactory.addASTChild(currentAST, returnAST);
3644 break;
3645 }
3646 case RCURLY:
3647 case SEMI:
3648 case COMMA:
3649 case COLON:
3650 case ASSIGN:
3651 case RPAREN:
3652 case RBRACKET:
3653 case DIV_ASSIGN:
3654 case PLUS_ASSIGN:
3655 case MINUS_ASSIGN:
3656 case STAR_ASSIGN:
3657 case MOD_ASSIGN:
3658 case RSHIFT_ASSIGN:
3659 case LSHIFT_ASSIGN:
3660 case BAND_ASSIGN:
3661 case BOR_ASSIGN:
3662 case BXOR_ASSIGN:
3663 {
3664 break;
3665 }
3666 default:
3667 {
3668 throw new NoViableAltException(LT(1), getFilename());
3669 }
3670 }
3671 }
3672 conditionalExpr_AST = (TNode)currentAST.root;
3673 }
3674 catch (RecognitionException ex) {
3675 if (inputState.guessing==0) {
3676 reportError(ex);
3677 recover(ex,_tokenSet_46);
3678 } else {
3679 throw ex;
3680 }
3681 }
3682 returnAST = conditionalExpr_AST;
3683 }
3684
3685 public final void assignOperator() throws RecognitionException, TokenStreamException {
3686
3687 returnAST = null;
3688 ASTPair currentAST = new ASTPair();
3689 TNode assignOperator_AST = null;
3690
3691 try { // for error handling
3692 switch ( LA(1)) {
3693 case ASSIGN:
3694 {
3695 TNode tmp127_AST = null;
3696 tmp127_AST = (TNode)astFactory.create(LT(1));
3697 astFactory.addASTChild(currentAST, tmp127_AST);
3698 match(ASSIGN);
3699 assignOperator_AST = (TNode)currentAST.root;
3700 break;
3701 }
3702 case DIV_ASSIGN:
3703 {
3704 TNode tmp128_AST = null;
3705 tmp128_AST = (TNode)astFactory.create(LT(1));
3706 astFactory.addASTChild(currentAST, tmp128_AST);
3707 match(DIV_ASSIGN);
3708 assignOperator_AST = (TNode)currentAST.root;
3709 break;
3710 }
3711 case PLUS_ASSIGN:
3712 {
3713 TNode tmp129_AST = null;
3714 tmp129_AST = (TNode)astFactory.create(LT(1));
3715 astFactory.addASTChild(currentAST, tmp129_AST);
3716 match(PLUS_ASSIGN);
3717 assignOperator_AST = (TNode)currentAST.root;
3718 break;
3719 }
3720 case MINUS_ASSIGN:
3721 {
3722 TNode tmp130_AST = null;
3723 tmp130_AST = (TNode)astFactory.create(LT(1));
3724 astFactory.addASTChild(currentAST, tmp130_AST);
3725 match(MINUS_ASSIGN);
3726 assignOperator_AST = (TNode)currentAST.root;
3727 break;
3728 }
3729 case STAR_ASSIGN:
3730 {
3731 TNode tmp131_AST = null;
3732 tmp131_AST = (TNode)astFactory.create(LT(1));
3733 astFactory.addASTChild(currentAST, tmp131_AST);
3734 match(STAR_ASSIGN);
3735 assignOperator_AST = (TNode)currentAST.root;
3736 break;
3737 }
3738 case MOD_ASSIGN:
3739 {
3740 TNode tmp132_AST = null;
3741 tmp132_AST = (TNode)astFactory.create(LT(1));
3742 astFactory.addASTChild(currentAST, tmp132_AST);
3743 match(MOD_ASSIGN);
3744 assignOperator_AST = (TNode)currentAST.root;
3745 break;
3746 }
3747 case RSHIFT_ASSIGN:
3748 {
3749 TNode tmp133_AST = null;
3750 tmp133_AST = (TNode)astFactory.create(LT(1));
3751 astFactory.addASTChild(currentAST, tmp133_AST);
3752 match(RSHIFT_ASSIGN);
3753 assignOperator_AST = (TNode)currentAST.root;
3754 break;
3755 }
3756 case LSHIFT_ASSIGN:
3757 {
3758 TNode tmp134_AST = null;
3759 tmp134_AST = (TNode)astFactory.create(LT(1));
3760 astFactory.addASTChild(currentAST, tmp134_AST);
3761 match(LSHIFT_ASSIGN);
3762 assignOperator_AST = (TNode)currentAST.root;
3763 break;
3764 }
3765 case BAND_ASSIGN:
3766 {
3767 TNode tmp135_AST = null;
3768 tmp135_AST = (TNode)astFactory.create(LT(1));
3769 astFactory.addASTChild(currentAST, tmp135_AST);
3770 match(BAND_ASSIGN);
3771 assignOperator_AST = (TNode)currentAST.root;
3772 break;
3773 }
3774 case BOR_ASSIGN:
3775 {
3776 TNode tmp136_AST = null;
3777 tmp136_AST = (TNode)astFactory.create(LT(1));
3778 astFactory.addASTChild(currentAST, tmp136_AST);
3779 match(BOR_ASSIGN);
3780 assignOperator_AST = (TNode)currentAST.root;
3781 break;
3782 }
3783 case BXOR_ASSIGN:
3784 {
3785 TNode tmp137_AST = null;
3786 tmp137_AST = (TNode)astFactory.create(LT(1));
3787 astFactory.addASTChild(currentAST, tmp137_AST);
3788 match(BXOR_ASSIGN);
3789 assignOperator_AST = (TNode)currentAST.root;
3790 break;
3791 }
3792 default:
3793 {
3794 throw new NoViableAltException(LT(1), getFilename());
3795 }
3796 }
3797 }
3798 catch (RecognitionException ex) {
3799 if (inputState.guessing==0) {
3800 reportError(ex);
3801 recover(ex,_tokenSet_11);
3802 } else {
3803 throw ex;
3804 }
3805 }
3806 returnAST = assignOperator_AST;
3807 }
3808
3809 public final void logicalOrExpr() throws RecognitionException, TokenStreamException {
3810
3811 returnAST = null;
3812 ASTPair currentAST = new ASTPair();
3813 TNode logicalOrExpr_AST = null;
3814
3815 try { // for error handling
3816 logicalAndExpr();
3817 astFactory.addASTChild(currentAST, returnAST);
3818 {
3819 _loop138:
3820 do {
3821 if ((LA(1)==LOR)) {
3822 TNode tmp138_AST = null;
3823 tmp138_AST = (TNode)astFactory.create(LT(1));
3824 astFactory.makeASTRoot(currentAST, tmp138_AST);
3825 match(LOR);
3826 logicalAndExpr();
3827 astFactory.addASTChild(currentAST, returnAST);
3828 }
3829 else {
3830 break _loop138;
3831 }
3832
3833 } while (true);
3834 }
3835 logicalOrExpr_AST = (TNode)currentAST.root;
3836 }
3837 catch (RecognitionException ex) {
3838 if (inputState.guessing==0) {
3839 reportError(ex);
3840 recover(ex,_tokenSet_47);
3841 } else {
3842 throw ex;
3843 }
3844 }
3845 returnAST = logicalOrExpr_AST;
3846 }
3847
3848 public final void logicalAndExpr() throws RecognitionException, TokenStreamException {
3849
3850 returnAST = null;
3851 ASTPair currentAST = new ASTPair();
3852 TNode logicalAndExpr_AST = null;
3853
3854 try { // for error handling
3855 inclusiveOrExpr();
3856 astFactory.addASTChild(currentAST, returnAST);
3857 {
3858 _loop141:
3859 do {
3860 if ((LA(1)==LAND)) {
3861 TNode tmp139_AST = null;
3862 tmp139_AST = (TNode)astFactory.create(LT(1));
3863 astFactory.makeASTRoot(currentAST, tmp139_AST);
3864 match(LAND);
3865 inclusiveOrExpr();
3866 astFactory.addASTChild(currentAST, returnAST);
3867 }
3868 else {
3869 break _loop141;
3870 }
3871
3872 } while (true);
3873 }
3874 logicalAndExpr_AST = (TNode)currentAST.root;
3875 }
3876 catch (RecognitionException ex) {
3877 if (inputState.guessing==0) {
3878 reportError(ex);
3879 recover(ex,_tokenSet_48);
3880 } else {
3881 throw ex;
3882 }
3883 }
3884 returnAST = logicalAndExpr_AST;
3885 }
3886
3887 public final void inclusiveOrExpr() throws RecognitionException, TokenStreamException {
3888
3889 returnAST = null;
3890 ASTPair currentAST = new ASTPair();
3891 TNode inclusiveOrExpr_AST = null;
3892
3893 try { // for error handling
3894 exclusiveOrExpr();
3895 astFactory.addASTChild(currentAST, returnAST);
3896 {
3897 _loop144:
3898 do {
3899 if ((LA(1)==BOR)) {
3900 TNode tmp140_AST = null;
3901 tmp140_AST = (TNode)astFactory.create(LT(1));
3902 astFactory.makeASTRoot(currentAST, tmp140_AST);
3903 match(BOR);
3904 exclusiveOrExpr();
3905 astFactory.addASTChild(currentAST, returnAST);
3906 }
3907 else {
3908 break _loop144;
3909 }
3910
3911 } while (true);
3912 }
3913 inclusiveOrExpr_AST = (TNode)currentAST.root;
3914 }
3915 catch (RecognitionException ex) {
3916 if (inputState.guessing==0) {
3917 reportError(ex);
3918 recover(ex,_tokenSet_49);
3919 } else {
3920 throw ex;
3921 }
3922 }
3923 returnAST = inclusiveOrExpr_AST;
3924 }
3925
3926 public final void exclusiveOrExpr() throws RecognitionException, TokenStreamException {
3927
3928 returnAST = null;
3929 ASTPair currentAST = new ASTPair();
3930 TNode exclusiveOrExpr_AST = null;
3931
3932 try { // for error handling
3933 bitAndExpr();
3934 astFactory.addASTChild(currentAST, returnAST);
3935 {
3936 _loop147:
3937 do {
3938 if ((LA(1)==BXOR)) {
3939 TNode tmp141_AST = null;
3940 tmp141_AST = (TNode)astFactory.create(LT(1));
3941 astFactory.makeASTRoot(currentAST, tmp141_AST);
3942 match(BXOR);
3943 bitAndExpr();
3944 astFactory.addASTChild(currentAST, returnAST);
3945 }
3946 else {
3947 break _loop147;
3948 }
3949
3950 } while (true);
3951 }
3952 exclusiveOrExpr_AST = (TNode)currentAST.root;
3953 }
3954 catch (RecognitionException ex) {
3955 if (inputState.guessing==0) {
3956 reportError(ex);
3957 recover(ex,_tokenSet_50);
3958 } else {
3959 throw ex;
3960 }
3961 }
3962 returnAST = exclusiveOrExpr_AST;
3963 }
3964
3965 public final void bitAndExpr() throws RecognitionException, TokenStreamException {
3966
3967 returnAST = null;
3968 ASTPair currentAST = new ASTPair();
3969 TNode bitAndExpr_AST = null;
3970
3971 try { // for error handling
3972 equalityExpr();
3973 astFactory.addASTChild(currentAST, returnAST);
3974 {
3975 _loop150:
3976 do {
3977 if ((LA(1)==BAND)) {
3978 TNode tmp142_AST = null;
3979 tmp142_AST = (TNode)astFactory.create(LT(1));
3980 astFactory.makeASTRoot(currentAST, tmp142_AST);
3981 match(BAND);
3982 equalityExpr();
3983 astFactory.addASTChild(currentAST, returnAST);
3984 }
3985 else {
3986 break _loop150;
3987 }
3988
3989 } while (true);
3990 }
3991 bitAndExpr_AST = (TNode)currentAST.root;
3992 }
3993 catch (RecognitionException ex) {
3994 if (inputState.guessing==0) {
3995 reportError(ex);
3996 recover(ex,_tokenSet_51);
3997 } else {
3998 throw ex;
3999 }
4000 }
4001 returnAST = bitAndExpr_AST;
4002 }
4003
4004 public final void equalityExpr() throws RecognitionException, TokenStreamException {
4005
4006 returnAST = null;
4007 ASTPair currentAST = new ASTPair();
4008 TNode equalityExpr_AST = null;
4009
4010 try { // for error handling
4011 relationalExpr();
4012 astFactory.addASTChild(currentAST, returnAST);
4013 {
4014 _loop154:
4015 do {
4016 if ((LA(1)==EQUAL||LA(1)==NOT_EQUAL)) {
4017 {
4018 switch ( LA(1)) {
4019 case EQUAL:
4020 {
4021 TNode tmp143_AST = null;
4022 tmp143_AST = (TNode)astFactory.create(LT(1));
4023 astFactory.makeASTRoot(currentAST, tmp143_AST);
4024 match(EQUAL);
4025 break;
4026 }
4027 case NOT_EQUAL:
4028 {
4029 TNode tmp144_AST = null;
4030 tmp144_AST = (TNode)astFactory.create(LT(1));
4031 astFactory.makeASTRoot(currentAST, tmp144_AST);
4032 match(NOT_EQUAL);
4033 break;
4034 }
4035 default:
4036 {
4037 throw new NoViableAltException(LT(1), getFilename());
4038 }
4039 }
4040 }
4041 relationalExpr();
4042 astFactory.addASTChild(currentAST, returnAST);
4043 }
4044 else {
4045 break _loop154;
4046 }
4047
4048 } while (true);
4049 }
4050 equalityExpr_AST = (TNode)currentAST.root;
4051 }
4052 catch (RecognitionException ex) {
4053 if (inputState.guessing==0) {
4054 reportError(ex);
4055 recover(ex,_tokenSet_52);
4056 } else {
4057 throw ex;
4058 }
4059 }
4060 returnAST = equalityExpr_AST;
4061 }
4062
4063 public final void relationalExpr() throws RecognitionException, TokenStreamException {
4064
4065 returnAST = null;
4066 ASTPair currentAST = new ASTPair();
4067 TNode relationalExpr_AST = null;
4068
4069 try { // for error handling
4070 shiftExpr();
4071 astFactory.addASTChild(currentAST, returnAST);
4072 {
4073 _loop158:
4074 do {
4075 if (((LA(1) >= LT && LA(1) <= GTE))) {
4076 {
4077 switch ( LA(1)) {
4078 case LT:
4079 {
4080 TNode tmp145_AST = null;
4081 tmp145_AST = (TNode)astFactory.create(LT(1));
4082 astFactory.makeASTRoot(currentAST, tmp145_AST);
4083 match(LT);
4084 break;
4085 }
4086 case LTE:
4087 {
4088 TNode tmp146_AST = null;
4089 tmp146_AST = (TNode)astFactory.create(LT(1));
4090 astFactory.makeASTRoot(currentAST, tmp146_AST);
4091 match(LTE);
4092 break;
4093 }
4094 case GT:
4095 {
4096 TNode tmp147_AST = null;
4097 tmp147_AST = (TNode)astFactory.create(LT(1));
4098 astFactory.makeASTRoot(currentAST, tmp147_AST);
4099 match(GT);
4100 break;
4101 }
4102 case GTE:
4103 {
4104 TNode tmp148_AST = null;
4105 tmp148_AST = (TNode)astFactory.create(LT(1));
4106 astFactory.makeASTRoot(currentAST, tmp148_AST);
4107 match(GTE);
4108 break;
4109 }
4110 default:
4111 {
4112 throw new NoViableAltException(LT(1), getFilename());
4113 }
4114 }
4115 }
4116 shiftExpr();
4117 astFactory.addASTChild(currentAST, returnAST);
4118 }
4119 else {
4120 break _loop158;
4121 }
4122
4123 } while (true);
4124 }
4125 relationalExpr_AST = (TNode)currentAST.root;
4126 }
4127 catch (RecognitionException ex) {
4128 if (inputState.guessing==0) {
4129 reportError(ex);
4130 recover(ex,_tokenSet_53);
4131 } else {
4132 throw ex;
4133 }
4134 }
4135 returnAST = relationalExpr_AST;
4136 }
4137
4138 public final void shiftExpr() throws RecognitionException, TokenStreamException {
4139
4140 returnAST = null;
4141 ASTPair currentAST = new ASTPair();
4142 TNode shiftExpr_AST = null;
4143
4144 try { // for error handling
4145 additiveExpr();
4146 astFactory.addASTChild(currentAST, returnAST);
4147 {
4148 _loop162:
4149 do {
4150 if ((LA(1)==LSHIFT||LA(1)==RSHIFT)) {
4151 {
4152 switch ( LA(1)) {
4153 case LSHIFT:
4154 {
4155 TNode tmp149_AST = null;
4156 tmp149_AST = (TNode)astFactory.create(LT(1));
4157 astFactory.makeASTRoot(currentAST, tmp149_AST);
4158 match(LSHIFT);
4159 break;
4160 }
4161 case RSHIFT:
4162 {
4163 TNode tmp150_AST = null;
4164 tmp150_AST = (TNode)astFactory.create(LT(1));
4165 astFactory.makeASTRoot(currentAST, tmp150_AST);
4166 match(RSHIFT);
4167 break;
4168 }
4169 default:
4170 {
4171 throw new NoViableAltException(LT(1), getFilename());
4172 }
4173 }
4174 }
4175 additiveExpr();
4176 astFactory.addASTChild(currentAST, returnAST);
4177 }
4178 else {
4179 break _loop162;
4180 }
4181
4182 } while (true);
4183 }
4184 shiftExpr_AST = (TNode)currentAST.root;
4185 }
4186 catch (RecognitionException ex) {
4187 if (inputState.guessing==0) {
4188 reportError(ex);
4189 recover(ex,_tokenSet_54);
4190 } else {
4191 throw ex;
4192 }
4193 }
4194 returnAST = shiftExpr_AST;
4195 }
4196
4197 public final void additiveExpr() throws RecognitionException, TokenStreamException {
4198
4199 returnAST = null;
4200 ASTPair currentAST = new ASTPair();
4201 TNode additiveExpr_AST = null;
4202
4203 try { // for error handling
4204 multExpr();
4205 astFactory.addASTChild(currentAST, returnAST);
4206 {
4207 _loop166:
4208 do {
4209 if ((LA(1)==PLUS||LA(1)==MINUS)) {
4210 {
4211 switch ( LA(1)) {
4212 case PLUS:
4213 {
4214 TNode tmp151_AST = null;
4215 tmp151_AST = (TNode)astFactory.create(LT(1));
4216 astFactory.makeASTRoot(currentAST, tmp151_AST);
4217 match(PLUS);
4218 break;
4219 }
4220 case MINUS:
4221 {
4222 TNode tmp152_AST = null;
4223 tmp152_AST = (TNode)astFactory.create(LT(1));
4224 astFactory.makeASTRoot(currentAST, tmp152_AST);
4225 match(MINUS);
4226 break;
4227 }
4228 default:
4229 {
4230 throw new NoViableAltException(LT(1), getFilename());
4231 }
4232 }
4233 }
4234 multExpr();
4235 astFactory.addASTChild(currentAST, returnAST);
4236 }
4237 else {
4238 break _loop166;
4239 }
4240
4241 } while (true);
4242 }
4243 additiveExpr_AST = (TNode)currentAST.root;
4244 }
4245 catch (RecognitionException ex) {
4246 if (inputState.guessing==0) {
4247 reportError(ex);
4248 recover(ex,_tokenSet_55);
4249 } else {
4250 throw ex;
4251 }
4252 }
4253 returnAST = additiveExpr_AST;
4254 }
4255
4256 public final void multExpr() throws RecognitionException, TokenStreamException {
4257
4258 returnAST = null;
4259 ASTPair currentAST = new ASTPair();
4260 TNode multExpr_AST = null;
4261
4262 try { // for error handling
4263 castExpr();
4264 astFactory.addASTChild(currentAST, returnAST);
4265 {
4266 _loop170:
4267 do {
4268 if ((_tokenSet_56.member(LA(1)))) {
4269 {
4270 switch ( LA(1)) {
4271 case STAR:
4272 {
4273 TNode tmp153_AST = null;
4274 tmp153_AST = (TNode)astFactory.create(LT(1));
4275 astFactory.makeASTRoot(currentAST, tmp153_AST);
4276 match(STAR);
4277 break;
4278 }
4279 case DIV:
4280 {
4281 TNode tmp154_AST = null;
4282 tmp154_AST = (TNode)astFactory.create(LT(1));
4283 astFactory.makeASTRoot(currentAST, tmp154_AST);
4284 match(DIV);
4285 break;
4286 }
4287 case MOD:
4288 {
4289 TNode tmp155_AST = null;
4290 tmp155_AST = (TNode)astFactory.create(LT(1));
4291 astFactory.makeASTRoot(currentAST, tmp155_AST);
4292 match(MOD);
4293 break;
4294 }
4295 default:
4296 {
4297 throw new NoViableAltException(LT(1), getFilename());
4298 }
4299 }
4300 }
4301 castExpr();
4302 astFactory.addASTChild(currentAST, returnAST);
4303 }
4304 else {
4305 break _loop170;
4306 }
4307
4308 } while (true);
4309 }
4310 multExpr_AST = (TNode)currentAST.root;
4311 }
4312 catch (RecognitionException ex) {
4313 if (inputState.guessing==0) {
4314 reportError(ex);
4315 recover(ex,_tokenSet_57);
4316 } else {
4317 throw ex;
4318 }
4319 }
4320 returnAST = multExpr_AST;
4321 }
4322
4323 public final void castExpr() throws RecognitionException, TokenStreamException {
4324
4325 returnAST = null;
4326 ASTPair currentAST = new ASTPair();
4327 TNode castExpr_AST = null;
4328
4329 try { // for error handling
4330 boolean synPredMatched173 = false;
4331 if (((LA(1)==LPAREN) && (_tokenSet_20.member(LA(2))))) {
4332 int _m173 = mark();
4333 synPredMatched173 = true;
4334 inputState.guessing++;
4335 try {
4336 {
4337 match(LPAREN);
4338 typeName();
4339 match(RPAREN);
4340 }
4341 }
4342 catch (RecognitionException pe) {
4343 synPredMatched173 = false;
4344 }
4345 rewind(_m173);
4346inputState.guessing--;
4347 }
4348 if ( synPredMatched173 ) {
4349 match(LPAREN);
4350 typeName();
4351 astFactory.addASTChild(currentAST, returnAST);
4352 match(RPAREN);
4353 {
4354 castExpr();
4355 astFactory.addASTChild(currentAST, returnAST);
4356 }
4357 if ( inputState.guessing==0 ) {
4358 castExpr_AST = (TNode)currentAST.root;
4359 castExpr_AST = (TNode)astFactory.make( (new ASTArray(2)).add((TNode)astFactory.create(NCast,"(")).add(castExpr_AST));
4360 currentAST.root = castExpr_AST;
4361 currentAST.child = castExpr_AST!=null &&castExpr_AST.getFirstChild()!=null ?
4362 castExpr_AST.getFirstChild() : castExpr_AST;
4363 currentAST.advanceChildToEnd();
4364 }
4365 castExpr_AST = (TNode)currentAST.root;
4366 }
4367 else if ((_tokenSet_11.member(LA(1))) && (_tokenSet_58.member(LA(2)))) {
4368 unaryExpr();
4369 astFactory.addASTChild(currentAST, returnAST);
4370 castExpr_AST = (TNode)currentAST.root;
4371 }
4372 else {
4373 throw new NoViableAltException(LT(1), getFilename());
4374 }
4375
4376 }
4377 catch (RecognitionException ex) {
4378 if (inputState.guessing==0) {
4379 reportError(ex);
4380 recover(ex,_tokenSet_59);
4381 } else {
4382 throw ex;
4383 }
4384 }
4385 returnAST = castExpr_AST;
4386 }
4387
4388 public final void typeName() throws RecognitionException, TokenStreamException {
4389
4390 returnAST = null;
4391 ASTPair currentAST = new ASTPair();
4392 TNode typeName_AST = null;
4393
4394 try { // for error handling
4395 specifierQualifierList();
4396 astFactory.addASTChild(currentAST, returnAST);
4397 {
4398 switch ( LA(1)) {
4399 case STAR:
4400 case LPAREN:
4401 case LBRACKET:
4402 {
4403 nonemptyAbstractDeclarator();
4404 astFactory.addASTChild(currentAST, returnAST);
4405 break;
4406 }
4407 case RPAREN:
4408 {
4409 break;
4410 }
4411 default:
4412 {
4413 throw new NoViableAltException(LT(1), getFilename());
4414 }
4415 }
4416 }
4417 typeName_AST = (TNode)currentAST.root;
4418 }
4419 catch (RecognitionException ex) {
4420 if (inputState.guessing==0) {
4421 reportError(ex);
4422 recover(ex,_tokenSet_33);
4423 } else {
4424 throw ex;
4425 }
4426 }
4427 returnAST = typeName_AST;
4428 }
4429
4430 public final void unaryExpr() throws RecognitionException, TokenStreamException {
4431
4432 returnAST = null;
4433 ASTPair currentAST = new ASTPair();
4434 TNode unaryExpr_AST = null;
4435 TNode u_AST = null;
4436
4437 try { // for error handling
4438 switch ( LA(1)) {
4439 case ID:
4440 case LPAREN:
4441 case CharLiteral:
4442 case StringLiteral:
4443 case IntOctalConst:
4444 case LongOctalConst:
4445 case UnsignedOctalConst:
4446 case IntIntConst:
4447 case LongIntConst:
4448 case UnsignedIntConst:
4449 case IntHexConst:
4450 case LongHexConst:
4451 case UnsignedHexConst:
4452 case FloatDoubleConst:
4453 case DoubleDoubleConst:
4454 case LongDoubleConst:
4455 {
4456 postfixExpr();
4457 astFactory.addASTChild(currentAST, returnAST);
4458 unaryExpr_AST = (TNode)currentAST.root;
4459 break;
4460 }
4461 case INC:
4462 {
4463 TNode tmp158_AST = null;
4464 tmp158_AST = (TNode)astFactory.create(LT(1));
4465 astFactory.makeASTRoot(currentAST, tmp158_AST);
4466 match(INC);
4467 unaryExpr();
4468 astFactory.addASTChild(currentAST, returnAST);
4469 unaryExpr_AST = (TNode)currentAST.root;
4470 break;
4471 }
4472 case DEC:
4473 {
4474 TNode tmp159_AST = null;
4475 tmp159_AST = (TNode)astFactory.create(LT(1));
4476 astFactory.makeASTRoot(currentAST, tmp159_AST);
4477 match(DEC);
4478 unaryExpr();
4479 astFactory.addASTChild(currentAST, returnAST);
4480 unaryExpr_AST = (TNode)currentAST.root;
4481 break;
4482 }
4483 case STAR:
4484 case BAND:
4485 case PLUS:
4486 case MINUS:
4487 case BNOT:
4488 case LNOT:
4489 {
4490 unaryOperator();
4491 u_AST = (TNode)returnAST;
4492 astFactory.addASTChild(currentAST, returnAST);
4493 castExpr();
4494 astFactory.addASTChild(currentAST, returnAST);
4495 if ( inputState.guessing==0 ) {
4496 unaryExpr_AST = (TNode)currentAST.root;
4497 unaryExpr_AST = (TNode)astFactory.make( (new ASTArray(2)).add((TNode)astFactory.create(NUnaryExpr)).add(unaryExpr_AST));
4498 currentAST.root = unaryExpr_AST;
4499 currentAST.child = unaryExpr_AST!=null &&unaryExpr_AST.getFirstChild()!=null ?
4500 unaryExpr_AST.getFirstChild() : unaryExpr_AST;
4501 currentAST.advanceChildToEnd();
4502 }
4503 unaryExpr_AST = (TNode)currentAST.root;
4504 break;
4505 }
4506 case LITERAL_sizeof:
4507 {
4508 TNode tmp160_AST = null;
4509 tmp160_AST = (TNode)astFactory.create(LT(1));
4510 astFactory.makeASTRoot(currentAST, tmp160_AST);
4511 match(LITERAL_sizeof);
4512 {
4513 boolean synPredMatched194 = false;
4514 if (((LA(1)==LPAREN) && (_tokenSet_20.member(LA(2))))) {
4515 int _m194 = mark();
4516 synPredMatched194 = true;
4517 inputState.guessing++;
4518 try {
4519 {
4520 match(LPAREN);
4521 typeName();
4522 }
4523 }
4524 catch (RecognitionException pe) {
4525 synPredMatched194 = false;
4526 }
4527 rewind(_m194);
4528inputState.guessing--;
4529 }
4530 if ( synPredMatched194 ) {
4531 TNode tmp161_AST = null;
4532 tmp161_AST = (TNode)astFactory.create(LT(1));
4533 astFactory.addASTChild(currentAST, tmp161_AST);
4534 match(LPAREN);
4535 typeName();
4536 astFactory.addASTChild(currentAST, returnAST);
4537 TNode tmp162_AST = null;
4538 tmp162_AST = (TNode)astFactory.create(LT(1));
4539 astFactory.addASTChild(currentAST, tmp162_AST);
4540 match(RPAREN);
4541 }
4542 else if ((_tokenSet_11.member(LA(1))) && (_tokenSet_58.member(LA(2)))) {
4543 unaryExpr();
4544 astFactory.addASTChild(currentAST, returnAST);
4545 }
4546 else {
4547 throw new NoViableAltException(LT(1), getFilename());
4548 }
4549
4550 }
4551 unaryExpr_AST = (TNode)currentAST.root;
4552 break;
4553 }
4554 default:
4555 {
4556 throw new NoViableAltException(LT(1), getFilename());
4557 }
4558 }
4559 }
4560 catch (RecognitionException ex) {
4561 if (inputState.guessing==0) {
4562 reportError(ex);
4563 recover(ex,_tokenSet_59);
4564 } else {
4565 throw ex;
4566 }
4567 }
4568 returnAST = unaryExpr_AST;
4569 }
4570
4571 public final void postfixExpr() throws RecognitionException, TokenStreamException {
4572
4573 returnAST = null;
4574 ASTPair currentAST = new ASTPair();
4575 TNode postfixExpr_AST = null;
4576
4577 try { // for error handling
4578 primaryExpr();
4579 astFactory.addASTChild(currentAST, returnAST);
4580 {
4581 switch ( LA(1)) {
4582 case LPAREN:
4583 case LBRACKET:
4584 case INC:
4585 case DEC:
4586 case PTR:
4587 case DOT:
4588 {
4589 postfixSuffix();
4590 astFactory.addASTChild(currentAST, returnAST);
4591 if ( inputState.guessing==0 ) {
4592 postfixExpr_AST = (TNode)currentAST.root;
4593 postfixExpr_AST = (TNode)astFactory.make( (new ASTArray(2)).add((TNode)astFactory.create(NPostfixExpr)).add(postfixExpr_AST));
4594 currentAST.root = postfixExpr_AST;
4595 currentAST.child = postfixExpr_AST!=null &&postfixExpr_AST.getFirstChild()!=null ?
4596 postfixExpr_AST.getFirstChild() : postfixExpr_AST;
4597 currentAST.advanceChildToEnd();
4598 }
4599 break;
4600 }
4601 case RCURLY:
4602 case SEMI:
4603 case COMMA:
4604 case COLON:
4605 case ASSIGN:
4606 case STAR:
4607 case RPAREN:
4608 case RBRACKET:
4609 case DIV_ASSIGN:
4610 case PLUS_ASSIGN:
4611 case MINUS_ASSIGN:
4612 case STAR_ASSIGN:
4613 case MOD_ASSIGN:
4614 case RSHIFT_ASSIGN:
4615 case LSHIFT_ASSIGN:
4616 case BAND_ASSIGN:
4617 case BOR_ASSIGN:
4618 case BXOR_ASSIGN:
4619 case QUESTION:
4620 case LOR:
4621 case LAND:
4622 case BOR:
4623 case BXOR:
4624 case BAND:
4625 case EQUAL:
4626 case NOT_EQUAL:
4627 case LT:
4628 case LTE:
4629 case GT:
4630 case GTE:
4631 case LSHIFT:
4632 case RSHIFT:
4633 case PLUS:
4634 case MINUS:
4635 case DIV:
4636 case MOD:
4637 {
4638 break;
4639 }
4640 default:
4641 {
4642 throw new NoViableAltException(LT(1), getFilename());
4643 }
4644 }
4645 }
4646 postfixExpr_AST = (TNode)currentAST.root;
4647 }
4648 catch (RecognitionException ex) {
4649 if (inputState.guessing==0) {
4650 reportError(ex);
4651 recover(ex,_tokenSet_59);
4652 } else {
4653 throw ex;
4654 }
4655 }
4656 returnAST = postfixExpr_AST;
4657 }
4658
4659 public final void unaryOperator() throws RecognitionException, TokenStreamException {
4660
4661 returnAST = null;
4662 ASTPair currentAST = new ASTPair();
4663 TNode unaryOperator_AST = null;
4664
4665 try { // for error handling
4666 switch ( LA(1)) {
4667 case BAND:
4668 {
4669 TNode tmp163_AST = null;
4670 tmp163_AST = (TNode)astFactory.create(LT(1));
4671 astFactory.addASTChild(currentAST, tmp163_AST);
4672 match(BAND);
4673 unaryOperator_AST = (TNode)currentAST.root;
4674 break;
4675 }
4676 case STAR:
4677 {
4678 TNode tmp164_AST = null;
4679 tmp164_AST = (TNode)astFactory.create(LT(1));
4680 astFactory.addASTChild(currentAST, tmp164_AST);
4681 match(STAR);
4682 unaryOperator_AST = (TNode)currentAST.root;
4683 break;
4684 }
4685 case PLUS:
4686 {
4687 TNode tmp165_AST = null;
4688 tmp165_AST = (TNode)astFactory.create(LT(1));
4689 astFactory.addASTChild(currentAST, tmp165_AST);
4690 match(PLUS);
4691 unaryOperator_AST = (TNode)currentAST.root;
4692 break;
4693 }
4694 case MINUS:
4695 {
4696 TNode tmp166_AST = null;
4697 tmp166_AST = (TNode)astFactory.create(LT(1));
4698 astFactory.addASTChild(currentAST, tmp166_AST);
4699 match(MINUS);
4700 unaryOperator_AST = (TNode)currentAST.root;
4701 break;
4702 }
4703 case BNOT:
4704 {
4705 TNode tmp167_AST = null;
4706 tmp167_AST = (TNode)astFactory.create(LT(1));
4707 astFactory.addASTChild(currentAST, tmp167_AST);
4708 match(BNOT);
4709 unaryOperator_AST = (TNode)currentAST.root;
4710 break;
4711 }
4712 case LNOT:
4713 {
4714 TNode tmp168_AST = null;
4715 tmp168_AST = (TNode)astFactory.create(LT(1));
4716 astFactory.addASTChild(currentAST, tmp168_AST);
4717 match(LNOT);
4718 unaryOperator_AST = (TNode)currentAST.root;
4719 break;
4720 }
4721 default:
4722 {
4723 throw new NoViableAltException(LT(1), getFilename());
4724 }
4725 }
4726 }
4727 catch (RecognitionException ex) {
4728 if (inputState.guessing==0) {
4729 reportError(ex);
4730 recover(ex,_tokenSet_11);
4731 } else {
4732 throw ex;
4733 }
4734 }
4735 returnAST = unaryOperator_AST;
4736 }
4737
4738 public final void primaryExpr() throws RecognitionException, TokenStreamException {
4739
4740 returnAST = null;
4741 ASTPair currentAST = new ASTPair();
4742 TNode primaryExpr_AST = null;
4743
4744 try { // for error handling
4745 switch ( LA(1)) {
4746 case ID:
4747 {
4748 TNode tmp169_AST = null;
4749 tmp169_AST = (TNode)astFactory.create(LT(1));
4750 astFactory.addASTChild(currentAST, tmp169_AST);
4751 match(ID);
4752 primaryExpr_AST = (TNode)currentAST.root;
4753 break;
4754 }
4755 case CharLiteral:
4756 {
4757 charConst();
4758 astFactory.addASTChild(currentAST, returnAST);
4759 primaryExpr_AST = (TNode)currentAST.root;
4760 break;
4761 }
4762 case IntOctalConst:
4763 case LongOctalConst:
4764 case UnsignedOctalConst:
4765 case IntIntConst:
4766 case LongIntConst:
4767 case UnsignedIntConst:
4768 case IntHexConst:
4769 case LongHexConst:
4770 case UnsignedHexConst:
4771 {
4772 intConst();
4773 astFactory.addASTChild(currentAST, returnAST);
4774 primaryExpr_AST = (TNode)currentAST.root;
4775 break;
4776 }
4777 case FloatDoubleConst:
4778 case DoubleDoubleConst:
4779 case LongDoubleConst:
4780 {
4781 floatConst();
4782 astFactory.addASTChild(currentAST, returnAST);
4783 primaryExpr_AST = (TNode)currentAST.root;
4784 break;
4785 }
4786 case StringLiteral:
4787 {
4788 stringConst();
4789 astFactory.addASTChild(currentAST, returnAST);
4790 primaryExpr_AST = (TNode)currentAST.root;
4791 break;
4792 }
4793 case LPAREN:
4794 {
4795 match(LPAREN);
4796 expr();
4797 astFactory.addASTChild(currentAST, returnAST);
4798 match(RPAREN);
4799 if ( inputState.guessing==0 ) {
4800 primaryExpr_AST = (TNode)currentAST.root;
4801 primaryExpr_AST = (TNode)astFactory.make( (new ASTArray(2)).add((TNode)astFactory.create(NExpressionGroup,"(")).add(primaryExpr_AST));
4802 currentAST.root = primaryExpr_AST;
4803 currentAST.child = primaryExpr_AST!=null &&primaryExpr_AST.getFirstChild()!=null ?
4804 primaryExpr_AST.getFirstChild() : primaryExpr_AST;
4805 currentAST.advanceChildToEnd();
4806 }
4807 primaryExpr_AST = (TNode)currentAST.root;
4808 break;
4809 }
4810 default:
4811 {
4812 throw new NoViableAltException(LT(1), getFilename());
4813 }
4814 }
4815 }
4816 catch (RecognitionException ex) {
4817 if (inputState.guessing==0) {
4818 reportError(ex);
4819 recover(ex,_tokenSet_60);
4820 } else {
4821 throw ex;
4822 }
4823 }
4824 returnAST = primaryExpr_AST;
4825 }
4826
4827 public final void postfixSuffix() throws RecognitionException, TokenStreamException {
4828
4829 returnAST = null;
4830 ASTPair currentAST = new ASTPair();
4831 TNode postfixSuffix_AST = null;
4832
4833 try { // for error handling
4834 {
4835 int _cnt200=0;
4836 _loop200:
4837 do {
4838 switch ( LA(1)) {
4839 case PTR:
4840 {
4841 TNode tmp172_AST = null;
4842 tmp172_AST = (TNode)astFactory.create(LT(1));
4843 astFactory.addASTChild(currentAST, tmp172_AST);
4844 match(PTR);
4845 TNode tmp173_AST = null;
4846 tmp173_AST = (TNode)astFactory.create(LT(1));
4847 astFactory.addASTChild(currentAST, tmp173_AST);
4848 match(ID);
4849 break;
4850 }
4851 case DOT:
4852 {
4853 TNode tmp174_AST = null;
4854 tmp174_AST = (TNode)astFactory.create(LT(1));
4855 astFactory.addASTChild(currentAST, tmp174_AST);
4856 match(DOT);
4857 TNode tmp175_AST = null;
4858 tmp175_AST = (TNode)astFactory.create(LT(1));
4859 astFactory.addASTChild(currentAST, tmp175_AST);
4860 match(ID);
4861 break;
4862 }
4863 case LPAREN:
4864 {
4865 functionCall();
4866 astFactory.addASTChild(currentAST, returnAST);
4867 break;
4868 }
4869 case LBRACKET:
4870 {
4871 TNode tmp176_AST = null;
4872 tmp176_AST = (TNode)astFactory.create(LT(1));
4873 astFactory.addASTChild(currentAST, tmp176_AST);
4874 match(LBRACKET);
4875 expr();
4876 astFactory.addASTChild(currentAST, returnAST);
4877 TNode tmp177_AST = null;
4878 tmp177_AST = (TNode)astFactory.create(LT(1));
4879 astFactory.addASTChild(currentAST, tmp177_AST);
4880 match(RBRACKET);
4881 break;
4882 }
4883 case INC:
4884 {
4885 TNode tmp178_AST = null;
4886 tmp178_AST = (TNode)astFactory.create(LT(1));
4887 astFactory.addASTChild(currentAST, tmp178_AST);
4888 match(INC);
4889 break;
4890 }
4891 case DEC:
4892 {
4893 TNode tmp179_AST = null;
4894 tmp179_AST = (TNode)astFactory.create(LT(1));
4895 astFactory.addASTChild(currentAST, tmp179_AST);
4896 match(DEC);
4897 break;
4898 }
4899 default:
4900 {
4901 if ( _cnt200>=1 ) { break _loop200; } else {throw new NoViableAltException(LT(1), getFilename());}
4902 }
4903 }
4904 _cnt200++;
4905 } while (true);
4906 }
4907 postfixSuffix_AST = (TNode)currentAST.root;
4908 }
4909 catch (RecognitionException ex) {
4910 if (inputState.guessing==0) {
4911 reportError(ex);
4912 recover(ex,_tokenSet_59);
4913 } else {
4914 throw ex;
4915 }
4916 }
4917 returnAST = postfixSuffix_AST;
4918 }
4919
4920 public final void functionCall() throws RecognitionException, TokenStreamException {
4921
4922 returnAST = null;
4923 ASTPair currentAST = new ASTPair();
4924 TNode functionCall_AST = null;
4925 TNode a_AST = null;
4926
4927 try { // for error handling
4928 TNode tmp180_AST = null;
4929 tmp180_AST = (TNode)astFactory.create(LT(1));
4930 astFactory.makeASTRoot(currentAST, tmp180_AST);
4931 match(LPAREN);
4932 {
4933 switch ( LA(1)) {
4934 case ID:
4935 case STAR:
4936 case LPAREN:
4937 case BAND:
4938 case PLUS:
4939 case MINUS:
4940 case INC:
4941 case DEC:
4942 case LITERAL_sizeof:
4943 case BNOT:
4944 case LNOT:
4945 case CharLiteral:
4946 case StringLiteral:
4947 case IntOctalConst:
4948 case LongOctalConst:
4949 case UnsignedOctalConst:
4950 case IntIntConst:
4951 case LongIntConst:
4952 case UnsignedIntConst:
4953 case IntHexConst:
4954 case LongHexConst:
4955 case UnsignedHexConst:
4956 case FloatDoubleConst:
4957 case DoubleDoubleConst:
4958 case LongDoubleConst:
4959 {
4960 argExprList();
4961 a_AST = (TNode)returnAST;
4962 astFactory.addASTChild(currentAST, returnAST);
4963 break;
4964 }
4965 case RPAREN:
4966 {
4967 break;
4968 }
4969 default:
4970 {
4971 throw new NoViableAltException(LT(1), getFilename());
4972 }
4973 }
4974 }
4975 TNode tmp181_AST = null;
4976 tmp181_AST = (TNode)astFactory.create(LT(1));
4977 astFactory.addASTChild(currentAST, tmp181_AST);
4978 match(RPAREN);
4979 if ( inputState.guessing==0 ) {
4980 functionCall_AST = (TNode)currentAST.root;
4981
4982 functionCall_AST.setType( NFunctionCallArgs );
4983
4984 }
4985 functionCall_AST = (TNode)currentAST.root;
4986 }
4987 catch (RecognitionException ex) {
4988 if (inputState.guessing==0) {
4989 reportError(ex);
4990 recover(ex,_tokenSet_60);
4991 } else {
4992 throw ex;
4993 }
4994 }
4995 returnAST = functionCall_AST;
4996 }
4997
4998 public final void argExprList() throws RecognitionException, TokenStreamException {
4999
5000 returnAST = null;
5001 ASTPair currentAST = new ASTPair();
5002 TNode argExprList_AST = null;
5003
5004 try { // for error handling
5005 assignExpr();
5006 astFactory.addASTChild(currentAST, returnAST);
5007 {
5008 _loop206:
5009 do {
5010 if ((LA(1)==COMMA)) {
5011 match(COMMA);
5012 assignExpr();
5013 astFactory.addASTChild(currentAST, returnAST);
5014 }
5015 else {
5016 break _loop206;
5017 }
5018
5019 } while (true);
5020 }
5021 argExprList_AST = (TNode)currentAST.root;
5022 }
5023 catch (RecognitionException ex) {
5024 if (inputState.guessing==0) {
5025 reportError(ex);
5026 recover(ex,_tokenSet_33);
5027 } else {
5028 throw ex;
5029 }
5030 }
5031 returnAST = argExprList_AST;
5032 }
5033
5034 protected final void charConst() throws RecognitionException, TokenStreamException {
5035
5036 returnAST = null;
5037 ASTPair currentAST = new ASTPair();
5038 TNode charConst_AST = null;
5039
5040 try { // for error handling
5041 TNode tmp183_AST = null;
5042 tmp183_AST = (TNode)astFactory.create(LT(1));
5043 astFactory.addASTChild(currentAST, tmp183_AST);
5044 match(CharLiteral);
5045 charConst_AST = (TNode)currentAST.root;
5046 }
5047 catch (RecognitionException ex) {
5048 if (inputState.guessing==0) {
5049 reportError(ex);
5050 recover(ex,_tokenSet_60);
5051 } else {
5052 throw ex;
5053 }
5054 }
5055 returnAST = charConst_AST;
5056 }
5057
5058 protected final void intConst() throws RecognitionException, TokenStreamException {
5059
5060 returnAST = null;
5061 ASTPair currentAST = new ASTPair();
5062 TNode intConst_AST = null;
5063
5064 try { // for error handling
5065 switch ( LA(1)) {
5066 case IntOctalConst:
5067 {
5068 TNode tmp184_AST = null;
5069 tmp184_AST = (TNode)astFactory.create(LT(1));
5070 astFactory.addASTChild(currentAST, tmp184_AST);
5071 match(IntOctalConst);
5072 intConst_AST = (TNode)currentAST.root;
5073 break;
5074 }
5075 case LongOctalConst:
5076 {
5077 TNode tmp185_AST = null;
5078 tmp185_AST = (TNode)astFactory.create(LT(1));
5079 astFactory.addASTChild(currentAST, tmp185_AST);
5080 match(LongOctalConst);
5081 intConst_AST = (TNode)currentAST.root;
5082 break;
5083 }
5084 case UnsignedOctalConst:
5085 {
5086 TNode tmp186_AST = null;
5087 tmp186_AST = (TNode)astFactory.create(LT(1));
5088 astFactory.addASTChild(currentAST, tmp186_AST);
5089 match(UnsignedOctalConst);
5090 intConst_AST = (TNode)currentAST.root;
5091 break;
5092 }
5093 case IntIntConst:
5094 {
5095 TNode tmp187_AST = null;
5096 tmp187_AST = (TNode)astFactory.create(LT(1));
5097 astFactory.addASTChild(currentAST, tmp187_AST);
5098 match(IntIntConst);
5099 intConst_AST = (TNode)currentAST.root;
5100 break;
5101 }
5102 case LongIntConst:
5103 {
5104 TNode tmp188_AST = null;
5105 tmp188_AST = (TNode)astFactory.create(LT(1));
5106 astFactory.addASTChild(currentAST, tmp188_AST);
5107 match(LongIntConst);
5108 intConst_AST = (TNode)currentAST.root;
5109 break;
5110 }
5111 case UnsignedIntConst:
5112 {
5113 TNode tmp189_AST = null;
5114 tmp189_AST = (TNode)astFactory.create(LT(1));
5115 astFactory.addASTChild(currentAST, tmp189_AST);
5116 match(UnsignedIntConst);
5117 intConst_AST = (TNode)currentAST.root;
5118 break;
5119 }
5120 case IntHexConst:
5121 {
5122 TNode tmp190_AST = null;
5123 tmp190_AST = (TNode)astFactory.create(LT(1));
5124 astFactory.addASTChild(currentAST, tmp190_AST);
5125 match(IntHexConst);
5126 intConst_AST = (TNode)currentAST.root;
5127 break;
5128 }
5129 case LongHexConst:
5130 {
5131 TNode tmp191_AST = null;
5132 tmp191_AST = (TNode)astFactory.create(LT(1));
5133 astFactory.addASTChild(currentAST, tmp191_AST);
5134 match(LongHexConst);
5135 intConst_AST = (TNode)currentAST.root;
5136 break;
5137 }
5138 case UnsignedHexConst:
5139 {
5140 TNode tmp192_AST = null;
5141 tmp192_AST = (TNode)astFactory.create(LT(1));
5142 astFactory.addASTChild(currentAST, tmp192_AST);
5143 match(UnsignedHexConst);
5144 intConst_AST = (TNode)currentAST.root;
5145 break;
5146 }
5147 default:
5148 {
5149 throw new NoViableAltException(LT(1), getFilename());
5150 }
5151 }
5152 }
5153 catch (RecognitionException ex) {
5154 if (inputState.guessing==0) {
5155 reportError(ex);
5156 recover(ex,_tokenSet_60);
5157 } else {
5158 throw ex;
5159 }
5160 }
5161 returnAST = intConst_AST;
5162 }
5163
5164 protected final void floatConst() throws RecognitionException, TokenStreamException {
5165
5166 returnAST = null;
5167 ASTPair currentAST = new ASTPair();
5168 TNode floatConst_AST = null;
5169
5170 try { // for error handling
5171 switch ( LA(1)) {
5172 case FloatDoubleConst:
5173 {
5174 TNode tmp193_AST = null;
5175 tmp193_AST = (TNode)astFactory.create(LT(1));
5176 astFactory.addASTChild(currentAST, tmp193_AST);
5177 match(FloatDoubleConst);
5178 floatConst_AST = (TNode)currentAST.root;
5179 break;
5180 }
5181 case DoubleDoubleConst:
5182 {
5183 TNode tmp194_AST = null;
5184 tmp194_AST = (TNode)astFactory.create(LT(1));
5185 astFactory.addASTChild(currentAST, tmp194_AST);
5186 match(DoubleDoubleConst);
5187 floatConst_AST = (TNode)currentAST.root;
5188 break;
5189 }
5190 case LongDoubleConst:
5191 {
5192 TNode tmp195_AST = null;
5193 tmp195_AST = (TNode)astFactory.create(LT(1));
5194 astFactory.addASTChild(currentAST, tmp195_AST);
5195 match(LongDoubleConst);
5196 floatConst_AST = (TNode)currentAST.root;
5197 break;
5198 }
5199 default:
5200 {
5201 throw new NoViableAltException(LT(1), getFilename());
5202 }
5203 }
5204 }
5205 catch (RecognitionException ex) {
5206 if (inputState.guessing==0) {
5207 reportError(ex);
5208 recover(ex,_tokenSet_60);
5209 } else {
5210 throw ex;
5211 }
5212 }
5213 returnAST = floatConst_AST;
5214 }
5215
5216 protected final void stringConst() throws RecognitionException, TokenStreamException {
5217
5218 returnAST = null;
5219 ASTPair currentAST = new ASTPair();
5220 TNode stringConst_AST = null;
5221
5222 try { // for error handling
5223 {
5224 int _cnt210=0;
5225 _loop210:
5226 do {
5227 if ((LA(1)==StringLiteral)) {
5228 TNode tmp196_AST = null;
5229 tmp196_AST = (TNode)astFactory.create(LT(1));
5230 astFactory.addASTChild(currentAST, tmp196_AST);
5231 match(StringLiteral);
5232 }
5233 else {
5234 if ( _cnt210>=1 ) { break _loop210; } else {throw new NoViableAltException(LT(1), getFilename());}
5235 }
5236
5237 _cnt210++;
5238 } while (true);
5239 }
5240 if ( inputState.guessing==0 ) {
5241 stringConst_AST = (TNode)currentAST.root;
5242 stringConst_AST = (TNode)astFactory.make( (new ASTArray(2)).add((TNode)astFactory.create(NStringSeq)).add(stringConst_AST));
5243 currentAST.root = stringConst_AST;
5244 currentAST.child = stringConst_AST!=null &&stringConst_AST.getFirstChild()!=null ?
5245 stringConst_AST.getFirstChild() : stringConst_AST;
5246 currentAST.advanceChildToEnd();
5247 }
5248 stringConst_AST = (TNode)currentAST.root;
5249 }
5250 catch (RecognitionException ex) {
5251 if (inputState.guessing==0) {
5252 reportError(ex);
5253 recover(ex,_tokenSet_60);
5254 } else {
5255 throw ex;
5256 }
5257 }
5258 returnAST = stringConst_AST;
5259 }
5260
5261 public final void dummy() throws RecognitionException, TokenStreamException {
5262
5263 returnAST = null;
5264 ASTPair currentAST = new ASTPair();
5265 TNode dummy_AST = null;
5266
5267 try { // for error handling
5268 switch ( LA(1)) {
5269 case NTypedefName:
5270 {
5271 TNode tmp197_AST = null;
5272 tmp197_AST = (TNode)astFactory.create(LT(1));
5273 astFactory.addASTChild(currentAST, tmp197_AST);
5274 match(NTypedefName);
5275 dummy_AST = (TNode)currentAST.root;
5276 break;
5277 }
5278 case NInitDecl:
5279 {
5280 TNode tmp198_AST = null;
5281 tmp198_AST = (TNode)astFactory.create(LT(1));
5282 astFactory.addASTChild(currentAST, tmp198_AST);
5283 match(NInitDecl);
5284 dummy_AST = (TNode)currentAST.root;
5285 break;
5286 }
5287 case NDeclarator:
5288 {
5289 TNode tmp199_AST = null;
5290 tmp199_AST = (TNode)astFactory.create(LT(1));
5291 astFactory.addASTChild(currentAST, tmp199_AST);
5292 match(NDeclarator);
5293 dummy_AST = (TNode)currentAST.root;
5294 break;
5295 }
5296 case NStructDeclarator:
5297 {
5298 TNode tmp200_AST = null;
5299 tmp200_AST = (TNode)astFactory.create(LT(1));
5300 astFactory.addASTChild(currentAST, tmp200_AST);
5301 match(NStructDeclarator);
5302 dummy_AST = (TNode)currentAST.root;
5303 break;
5304 }
5305 case NDeclaration:
5306 {
5307 TNode tmp201_AST = null;
5308 tmp201_AST = (TNode)astFactory.create(LT(1));
5309 astFactory.addASTChild(currentAST, tmp201_AST);
5310 match(NDeclaration);
5311 dummy_AST = (TNode)currentAST.root;
5312 break;
5313 }
5314 case NCast:
5315 {
5316 TNode tmp202_AST = null;
5317 tmp202_AST = (TNode)astFactory.create(LT(1));
5318 astFactory.addASTChild(currentAST, tmp202_AST);
5319 match(NCast);
5320 dummy_AST = (TNode)currentAST.root;
5321 break;
5322 }
5323 case NPointerGroup:
5324 {
5325 TNode tmp203_AST = null;
5326 tmp203_AST = (TNode)astFactory.create(LT(1));
5327 astFactory.addASTChild(currentAST, tmp203_AST);
5328 match(NPointerGroup);
5329 dummy_AST = (TNode)currentAST.root;
5330 break;
5331 }
5332 case NExpressionGroup:
5333 {
5334 TNode tmp204_AST = null;
5335 tmp204_AST = (TNode)astFactory.create(LT(1));
5336 astFactory.addASTChild(currentAST, tmp204_AST);
5337 match(NExpressionGroup);
5338 dummy_AST = (TNode)currentAST.root;
5339 break;
5340 }
5341 case NFunctionCallArgs:
5342 {
5343 TNode tmp205_AST = null;
5344 tmp205_AST = (TNode)astFactory.create(LT(1));
5345 astFactory.addASTChild(currentAST, tmp205_AST);
5346 match(NFunctionCallArgs);
5347 dummy_AST = (TNode)currentAST.root;
5348 break;
5349 }
5350 case NNonemptyAbstractDeclarator:
5351 {
5352 TNode tmp206_AST = null;
5353 tmp206_AST = (TNode)astFactory.create(LT(1));
5354 astFactory.addASTChild(currentAST, tmp206_AST);
5355 match(NNonemptyAbstractDeclarator);
5356 dummy_AST = (TNode)currentAST.root;
5357 break;
5358 }
5359 case NInitializer:
5360 {
5361 TNode tmp207_AST = null;
5362 tmp207_AST = (TNode)astFactory.create(LT(1));
5363 astFactory.addASTChild(currentAST, tmp207_AST);
5364 match(NInitializer);
5365 dummy_AST = (TNode)currentAST.root;
5366 break;
5367 }
5368 case NStatementExpr:
5369 {
5370 TNode tmp208_AST = null;
5371 tmp208_AST = (TNode)astFactory.create(LT(1));
5372 astFactory.addASTChild(currentAST, tmp208_AST);
5373 match(NStatementExpr);
5374 dummy_AST = (TNode)currentAST.root;
5375 break;
5376 }
5377 case NEmptyExpression:
5378 {
5379 TNode tmp209_AST = null;
5380 tmp209_AST = (TNode)astFactory.create(LT(1));
5381 astFactory.addASTChild(currentAST, tmp209_AST);
5382 match(NEmptyExpression);
5383 dummy_AST = (TNode)currentAST.root;
5384 break;
5385 }
5386 case NParameterTypeList:
5387 {
5388 TNode tmp210_AST = null;
5389 tmp210_AST = (TNode)astFactory.create(LT(1));
5390 astFactory.addASTChild(currentAST, tmp210_AST);
5391 match(NParameterTypeList);
5392 dummy_AST = (TNode)currentAST.root;
5393 break;
5394 }
5395 case NFunctionDef:
5396 {
5397 TNode tmp211_AST = null;
5398 tmp211_AST = (TNode)astFactory.create(LT(1));
5399 astFactory.addASTChild(currentAST, tmp211_AST);
5400 match(NFunctionDef);
5401 dummy_AST = (TNode)currentAST.root;
5402 break;
5403 }
5404 case NCompoundStatement:
5405 {
5406 TNode tmp212_AST = null;
5407 tmp212_AST = (TNode)astFactory.create(LT(1));
5408 astFactory.addASTChild(currentAST, tmp212_AST);
5409 match(NCompoundStatement);
5410 dummy_AST = (TNode)currentAST.root;
5411 break;
5412 }
5413 case NParameterDeclaration:
5414 {
5415 TNode tmp213_AST = null;
5416 tmp213_AST = (TNode)astFactory.create(LT(1));
5417 astFactory.addASTChild(currentAST, tmp213_AST);
5418 match(NParameterDeclaration);
5419 dummy_AST = (TNode)currentAST.root;
5420 break;
5421 }
5422 case NCommaExpr:
5423 {
5424 TNode tmp214_AST = null;
5425 tmp214_AST = (TNode)astFactory.create(LT(1));
5426 astFactory.addASTChild(currentAST, tmp214_AST);
5427 match(NCommaExpr);
5428 dummy_AST = (TNode)currentAST.root;
5429 break;
5430 }
5431 case NUnaryExpr:
5432 {
5433 TNode tmp215_AST = null;
5434 tmp215_AST = (TNode)astFactory.create(LT(1));
5435 astFactory.addASTChild(currentAST, tmp215_AST);
5436 match(NUnaryExpr);
5437 dummy_AST = (TNode)currentAST.root;
5438 break;
5439 }
5440 case NLabel:
5441 {
5442 TNode tmp216_AST = null;
5443 tmp216_AST = (TNode)astFactory.create(LT(1));
5444 astFactory.addASTChild(currentAST, tmp216_AST);
5445 match(NLabel);
5446 dummy_AST = (TNode)currentAST.root;
5447 break;
5448 }
5449 case NPostfixExpr:
5450 {
5451 TNode tmp217_AST = null;
5452 tmp217_AST = (TNode)astFactory.create(LT(1));
5453 astFactory.addASTChild(currentAST, tmp217_AST);
5454 match(NPostfixExpr);
5455 dummy_AST = (TNode)currentAST.root;
5456 break;
5457 }
5458 case NRangeExpr:
5459 {
5460 TNode tmp218_AST = null;
5461 tmp218_AST = (TNode)astFactory.create(LT(1));
5462 astFactory.addASTChild(currentAST, tmp218_AST);
5463 match(NRangeExpr);
5464 dummy_AST = (TNode)currentAST.root;
5465 break;
5466 }
5467 case NStringSeq:
5468 {
5469 TNode tmp219_AST = null;
5470 tmp219_AST = (TNode)astFactory.create(LT(1));
5471 astFactory.addASTChild(currentAST, tmp219_AST);
5472 match(NStringSeq);
5473 dummy_AST = (TNode)currentAST.root;
5474 break;
5475 }
5476 case NInitializerElementLabel:
5477 {
5478 TNode tmp220_AST = null;
5479 tmp220_AST = (TNode)astFactory.create(LT(1));
5480 astFactory.addASTChild(currentAST, tmp220_AST);
5481 match(NInitializerElementLabel);
5482 dummy_AST = (TNode)currentAST.root;
5483 break;
5484 }
5485 case NLcurlyInitializer:
5486 {
5487 TNode tmp221_AST = null;
5488 tmp221_AST = (TNode)astFactory.create(LT(1));
5489 astFactory.addASTChild(currentAST, tmp221_AST);
5490 match(NLcurlyInitializer);
5491 dummy_AST = (TNode)currentAST.root;
5492 break;
5493 }
5494 case NAsmAttribute:
5495 {
5496 TNode tmp222_AST = null;
5497 tmp222_AST = (TNode)astFactory.create(LT(1));
5498 astFactory.addASTChild(currentAST, tmp222_AST);
5499 match(NAsmAttribute);
5500 dummy_AST = (TNode)currentAST.root;
5501 break;
5502 }
5503 case NGnuAsmExpr:
5504 {
5505 TNode tmp223_AST = null;
5506 tmp223_AST = (TNode)astFactory.create(LT(1));
5507 astFactory.addASTChild(currentAST, tmp223_AST);
5508 match(NGnuAsmExpr);
5509 dummy_AST = (TNode)currentAST.root;
5510 break;
5511 }
5512 case NTypeMissing:
5513 {
5514 TNode tmp224_AST = null;
5515 tmp224_AST = (TNode)astFactory.create(LT(1));
5516 astFactory.addASTChild(currentAST, tmp224_AST);
5517 match(NTypeMissing);
5518 dummy_AST = (TNode)currentAST.root;
5519 break;
5520 }
5521 default:
5522 {
5523 throw new NoViableAltException(LT(1), getFilename());
5524 }
5525 }
5526 }
5527 catch (RecognitionException ex) {
5528 if (inputState.guessing==0) {
5529 reportError(ex);
5530 recover(ex,_tokenSet_0);
5531 } else {
5532 throw ex;
5533 }
5534 }
5535 returnAST = dummy_AST;
5536 }
5537
5538
5539 public static final String[] _tokenNames = {
5540 "<0>",
5541 "EOF",
5542 "<2>",
5543 "NULL_TREE_LOOKAHEAD",
5544 "\"typedef\"",
5545 "\"asm\"",
5546 "\"volatile\"",
5547 "LCURLY",
5548 "RCURLY",
5549 "SEMI",
5550 "\"struct\"",
5551 "\"union\"",
5552 "\"enum\"",
5553 "\"auto\"",
5554 "\"register\"",
5555 "\"extern\"",
5556 "\"static\"",
5557 "\"const\"",
5558 "\"void\"",
5559 "\"char\"",
5560 "\"short\"",
5561 "\"int\"",
5562 "\"long\"",
5563 "\"float\"",
5564 "\"double\"",
5565 "\"signed\"",
5566 "\"unsigned\"",
5567 "\"int8_t\"",
5568 "\"uint8_t\"",
5569 "\"int16_t\"",
5570 "\"uint16_t\"",
5571 "\"__int32\"",
5572 "\"int32_t\"",
5573 "\"wchar_t\"",
5574 "\"uint32_t\"",
5575 "\"__int64\"",
5576 "\"int64_t\"",
5577 "\"uint64_t\"",
5578 "\"ptrdiff_t\"",
5579 "\"intptr_t\"",
5580 "\"size_t\"",
5581 "\"uintptr_t\"",
5582 "ID",
5583 "COMMA",
5584 "COLON",
5585 "ASSIGN",
5586 "STAR",
5587 "LPAREN",
5588 "RPAREN",
5589 "LBRACKET",
5590 "RBRACKET",
5591 "VARARGS",
5592 "\"while\"",
5593 "\"do\"",
5594 "\"for\"",
5595 "\"goto\"",
5596 "\"continue\"",
5597 "\"break\"",
5598 "\"return\"",
5599 "\"case\"",
5600 "\"default\"",
5601 "\"if\"",
5602 "\"else\"",
5603 "\"switch\"",
5604 "DIV_ASSIGN",
5605 "PLUS_ASSIGN",
5606 "MINUS_ASSIGN",
5607 "STAR_ASSIGN",
5608 "MOD_ASSIGN",
5609 "RSHIFT_ASSIGN",
5610 "LSHIFT_ASSIGN",
5611 "BAND_ASSIGN",
5612 "BOR_ASSIGN",
5613 "BXOR_ASSIGN",
5614 "QUESTION",
5615 "LOR",
5616 "LAND",
5617 "BOR",
5618 "BXOR",
5619 "BAND",
5620 "EQUAL",
5621 "NOT_EQUAL",
5622 "LT",
5623 "LTE",
5624 "GT",
5625 "GTE",
5626 "LSHIFT",
5627 "RSHIFT",
5628 "PLUS",
5629 "MINUS",
5630 "DIV",
5631 "MOD",
5632 "INC",
5633 "DEC",
5634 "\"sizeof\"",
5635 "BNOT",
5636 "LNOT",
5637 "PTR",
5638 "DOT",
5639 "CharLiteral",
5640 "StringLiteral",
5641 "IntOctalConst",
5642 "LongOctalConst",
5643 "UnsignedOctalConst",
5644 "IntIntConst",
5645 "LongIntConst",
5646 "UnsignedIntConst",
5647 "IntHexConst",
5648 "LongHexConst",
5649 "UnsignedHexConst",
5650 "FloatDoubleConst",
5651 "DoubleDoubleConst",
5652 "LongDoubleConst",
5653 "NTypedefName",
5654 "NInitDecl",
5655 "NDeclarator",
5656 "NStructDeclarator",
5657 "NDeclaration",
5658 "NCast",
5659 "NPointerGroup",
5660 "NExpressionGroup",
5661 "NFunctionCallArgs",
5662 "NNonemptyAbstractDeclarator",
5663 "NInitializer",
5664 "NStatementExpr",
5665 "NEmptyExpression",
5666 "NParameterTypeList",
5667 "NFunctionDef",
5668 "NCompoundStatement",
5669 "NParameterDeclaration",
5670 "NCommaExpr",
5671 "NUnaryExpr",
5672 "NLabel",
5673 "NPostfixExpr",
5674 "NRangeExpr",
5675 "NStringSeq",
5676 "NInitializerElementLabel",
5677 "NLcurlyInitializer",
5678 "NAsmAttribute",
5679 "NGnuAsmExpr",
5680 "NTypeMissing",
5681 "Vocabulary",
5682 "Whitespace",
5683 "Comment",
5684 "CPPComment",
5685 "NonWhitespace",
5686 "a line directive",
5687 "DefineExpr",
5688 "DefineExpr2",
5689 "Space",
5690 "LineDirective",
5691 "BadStringLiteral",
5692 "Escape",
5693 "Digit",
5694 "LongSuffix",
5695 "UnsignedSuffix",
5696 "FloatSuffix",
5697 "Exponent",
5698 "Number"
5699 };
5700
5701 protected void buildTokenTypeASTClassMap() {
5702 tokenTypeToASTClassMap=null;
5703 };
5704
5705 private static final long[] mk_tokenSet_0() {
5706 long[] data = { 2L, 0L, 0L};
5707 return data;
5708 }
5709 public static final BitSet _tokenSet_0 = new BitSet(mk_tokenSet_0());
5710 private static final long[] mk_tokenSet_1() {
5711 long[] data = { 219902325554288L, 0L, 0L};
5712 return data;
5713 }
5714 public static final BitSet _tokenSet_1 = new BitSet(mk_tokenSet_1());
5715 private static final long[] mk_tokenSet_2() {
5716 long[] data = { 8796093021264L, 0L, 0L};
5717 return data;
5718 }
5719 public static final BitSet _tokenSet_2 = new BitSet(mk_tokenSet_2());
5720 private static final long[] mk_tokenSet_3() {
5721 long[] data = { 219902325554896L, 0L, 0L};
5722 return data;
5723 }
5724 public static final BitSet _tokenSet_3 = new BitSet(mk_tokenSet_3());
5725 private static final long[] mk_tokenSet_4() {
5726 long[] data = { 219902325529664L, 0L, 0L};
5727 return data;
5728 }
5729 public static final BitSet _tokenSet_4 = new BitSet(mk_tokenSet_4());
5730 private static final long[] mk_tokenSet_5() {
5731 long[] data = { 3034652092661456L, 0L, 0L};
5732 return data;
5733 }
5734 public static final BitSet _tokenSet_5 = new BitSet(mk_tokenSet_5());
5735 private static final long[] mk_tokenSet_6() {
5736 long[] data = { 219902325554290L, 0L, 0L};
5737 return data;
5738 }
5739 public static final BitSet _tokenSet_6 = new BitSet(mk_tokenSet_6());
5740 private static final long[] mk_tokenSet_7() {
5741 long[] data = { -4613717915915517966L, 562923965546496L, 0L, 0L};
5742 return data;
5743 }
5744 public static final BitSet _tokenSet_7 = new BitSet(mk_tokenSet_7());
5745 private static final long[] mk_tokenSet_8() {
5746 long[] data = { 8796092996672L, 0L, 0L};
5747 return data;
5748 }
5749 public static final BitSet _tokenSet_8 = new BitSet(mk_tokenSet_8());
5750 private static final long[] mk_tokenSet_9() {
5751 long[] data = { 219902325529792L, 0L, 0L};
5752 return data;
5753 }
5754 public static final BitSet _tokenSet_9 = new BitSet(mk_tokenSet_9());
5755 private static final long[] mk_tokenSet_10() {
5756 long[] data = { 215504279044096L, 0L, 0L};
5757 return data;
5758 }
5759 public static final BitSet _tokenSet_10 = new BitSet(mk_tokenSet_10());
5760 private static final long[] mk_tokenSet_11() {
5761 long[] data = { 215504279044096L, 562923965546496L, 0L, 0L};
5762 return data;
5763 }
5764 public static final BitSet _tokenSet_11 = new BitSet(mk_tokenSet_11());
5765 private static final long[] mk_tokenSet_12() {
5766 long[] data = { 1433763162620672L, 0L, 0L};
5767 return data;
5768 }
5769 public static final BitSet _tokenSet_12 = new BitSet(mk_tokenSet_12());
5770 private static final long[] mk_tokenSet_13() {
5771 long[] data = { 8796092767232L, 0L, 0L};
5772 return data;
5773 }
5774 public static final BitSet _tokenSet_13 = new BitSet(mk_tokenSet_13());
5775 private static final long[] mk_tokenSet_14() {
5776 long[] data = { 1073123348709072L, 0L, 0L};
5777 return data;
5778 }
5779 public static final BitSet _tokenSet_14 = new BitSet(mk_tokenSet_14());
5780 private static final long[] mk_tokenSet_15() {
5781 long[] data = { 1068725302198784L, 0L, 0L};
5782 return data;
5783 }
5784 public static final BitSet _tokenSet_15 = new BitSet(mk_tokenSet_15());
5785 private static final long[] mk_tokenSet_16() {
5786 long[] data = { 512L, 0L, 0L};
5787 return data;
5788 }
5789 public static final BitSet _tokenSet_16 = new BitSet(mk_tokenSet_16());
5790 private static final long[] mk_tokenSet_17() {
5791 long[] data = { 1073123348708944L, 0L, 0L};
5792 return data;
5793 }
5794 public static final BitSet _tokenSet_17 = new BitSet(mk_tokenSet_17());
5795 private static final long[] mk_tokenSet_18() {
5796 long[] data = { 1090715534753360L, 0L, 0L};
5797 return data;
5798 }
5799 public static final BitSet _tokenSet_18 = new BitSet(mk_tokenSet_18());
5800 private static final long[] mk_tokenSet_19() {
5801 long[] data = { 4398046511232L, 0L, 0L};
5802 return data;
5803 }
5804 public static final BitSet _tokenSet_19 = new BitSet(mk_tokenSet_19());
5805 private static final long[] mk_tokenSet_20() {
5806 long[] data = { 8796092898368L, 0L, 0L};
5807 return data;
5808 }
5809 public static final BitSet _tokenSet_20 = new BitSet(mk_tokenSet_20());
5810 private static final long[] mk_tokenSet_21() {
5811 long[] data = { 256L, 0L, 0L};
5812 return data;
5813 }
5814 public static final BitSet _tokenSet_21 = new BitSet(mk_tokenSet_21());
5815 private static final long[] mk_tokenSet_22() {
5816 long[] data = { 8796092898624L, 0L, 0L};
5817 return data;
5818 }
5819 public static final BitSet _tokenSet_22 = new BitSet(mk_tokenSet_22());
5820 private static final long[] mk_tokenSet_23() {
5821 long[] data = { 1081919441607872L, 0L, 0L};
5822 return data;
5823 }
5824 public static final BitSet _tokenSet_23 = new BitSet(mk_tokenSet_23());
5825 private static final long[] mk_tokenSet_24() {
5826 long[] data = { 1077521395220480L, 0L, 0L};
5827 return data;
5828 }
5829 public static final BitSet _tokenSet_24 = new BitSet(mk_tokenSet_24());
5830 private static final long[] mk_tokenSet_25() {
5831 long[] data = { 8796093022720L, 0L, 0L};
5832 return data;
5833 }
5834 public static final BitSet _tokenSet_25 = new BitSet(mk_tokenSet_25());
5835 private static final long[] mk_tokenSet_26() {
5836 long[] data = { 1152288185910016L, 0L, 0L};
5837 return data;
5838 }
5839 public static final BitSet _tokenSet_26 = new BitSet(mk_tokenSet_26());
5840 private static final long[] mk_tokenSet_27() {
5841 long[] data = { 1073123348708560L, 0L, 0L};
5842 return data;
5843 }
5844 public static final BitSet _tokenSet_27 = new BitSet(mk_tokenSet_27());
5845 private static final long[] mk_tokenSet_28() {
5846 long[] data = { 3307330976349904L, 0L, 0L};
5847 return data;
5848 }
5849 public static final BitSet _tokenSet_28 = new BitSet(mk_tokenSet_28());
5850 private static final long[] mk_tokenSet_29() {
5851 long[] data = { 2603643534573264L, 0L, 0L};
5852 return data;
5853 }
5854 public static final BitSet _tokenSet_29 = new BitSet(mk_tokenSet_29());
5855 private static final long[] mk_tokenSet_30() {
5856 long[] data = { 8796093022464L, 0L, 0L};
5857 return data;
5858 }
5859 public static final BitSet _tokenSet_30 = new BitSet(mk_tokenSet_30());
5860 private static final long[] mk_tokenSet_31() {
5861 long[] data = { 8796093022976L, 0L, 0L};
5862 return data;
5863 }
5864 public static final BitSet _tokenSet_31 = new BitSet(mk_tokenSet_31());
5865 private static final long[] mk_tokenSet_32() {
5866 long[] data = { 998356558020608L, 0L, 0L};
5867 return data;
5868 }
5869 public static final BitSet _tokenSet_32 = new BitSet(mk_tokenSet_32());
5870 private static final long[] mk_tokenSet_33() {
5871 long[] data = { 281474976710656L, 0L, 0L};
5872 return data;
5873 }
5874 public static final BitSet _tokenSet_33 = new BitSet(mk_tokenSet_33());
5875 private static final long[] mk_tokenSet_34() {
5876 long[] data = { 215504279044224L, 562923965546496L, 0L, 0L};
5877 return data;
5878 }
5879 public static final BitSet _tokenSet_34 = new BitSet(mk_tokenSet_34());
5880 private static final long[] mk_tokenSet_35() {
5881 long[] data = { 1068725302329408L, 0L, 0L};
5882 return data;
5883 }
5884 public static final BitSet _tokenSet_35 = new BitSet(mk_tokenSet_35());
5885 private static final long[] mk_tokenSet_36() {
5886 long[] data = { 774056185954304L, 0L, 0L};
5887 return data;
5888 }
5889 public static final BitSet _tokenSet_36 = new BitSet(mk_tokenSet_36());
5890 private static final long[] mk_tokenSet_37() {
5891 long[] data = { 2199023255551056L, 562923965546496L, 0L, 0L};
5892 return data;
5893 }
5894 public static final BitSet _tokenSet_37 = new BitSet(mk_tokenSet_37());
5895 private static final long[] mk_tokenSet_38() {
5896 long[] data = { 290271069732864L, 0L, 0L};
5897 return data;
5898 }
5899 public static final BitSet _tokenSet_38 = new BitSet(mk_tokenSet_38());
5900 private static final long[] mk_tokenSet_39() {
5901 long[] data = { -4615974113775713408L, 562923965546496L, 0L, 0L};
5902 return data;
5903 }
5904 public static final BitSet _tokenSet_39 = new BitSet(mk_tokenSet_39());
5905 private static final long[] mk_tokenSet_40() {
5906 long[] data = { -3659174697238542L, 562949953421311L, 0L, 0L};
5907 return data;
5908 }
5909 public static final BitSet _tokenSet_40 = new BitSet(mk_tokenSet_40());
5910 private static final long[] mk_tokenSet_41() {
5911 long[] data = { -4283697301815310L, 562923965546496L, 0L, 0L};
5912 return data;
5913 }
5914 public static final BitSet _tokenSet_41 = new BitSet(mk_tokenSet_41());
5915 private static final long[] mk_tokenSet_42() {
5916 long[] data = { -4615974113775713664L, 562923965546496L, 0L, 0L};
5917 return data;
5918 }
5919 public static final BitSet _tokenSet_42 = new BitSet(mk_tokenSet_42());
5920 private static final long[] mk_tokenSet_43() {
5921 long[] data = { -4288095348325504L, 562923965546496L, 0L, 0L};
5922 return data;
5923 }
5924 public static final BitSet _tokenSet_43 = new BitSet(mk_tokenSet_43());
5925 private static final long[] mk_tokenSet_44() {
5926 long[] data = { 826832743964224L, 562949953421311L, 0L, 0L};
5927 return data;
5928 }
5929 public static final BitSet _tokenSet_44 = new BitSet(mk_tokenSet_44());
5930 private static final long[] mk_tokenSet_45() {
5931 long[] data = { -3659174697238576L, 562949953421311L, 0L, 0L};
5932 return data;
5933 }
5934 public static final BitSet _tokenSet_45 = new BitSet(mk_tokenSet_45());
5935 private static final long[] mk_tokenSet_46() {
5936 long[] data = { 1468947534709504L, 1023L, 0L, 0L};
5937 return data;
5938 }
5939 public static final BitSet _tokenSet_46 = new BitSet(mk_tokenSet_46());
5940 private static final long[] mk_tokenSet_47() {
5941 long[] data = { 1468947534709504L, 2047L, 0L, 0L};
5942 return data;
5943 }
5944 public static final BitSet _tokenSet_47 = new BitSet(mk_tokenSet_47());
5945 private static final long[] mk_tokenSet_48() {
5946 long[] data = { 1468947534709504L, 4095L, 0L, 0L};
5947 return data;
5948 }
5949 public static final BitSet _tokenSet_48 = new BitSet(mk_tokenSet_48());
5950 private static final long[] mk_tokenSet_49() {
5951 long[] data = { 1468947534709504L, 8191L, 0L, 0L};
5952 return data;
5953 }
5954 public static final BitSet _tokenSet_49 = new BitSet(mk_tokenSet_49());
5955 private static final long[] mk_tokenSet_50() {
5956 long[] data = { 1468947534709504L, 16383L, 0L, 0L};
5957 return data;
5958 }
5959 public static final BitSet _tokenSet_50 = new BitSet(mk_tokenSet_50());
5960 private static final long[] mk_tokenSet_51() {
5961 long[] data = { 1468947534709504L, 32767L, 0L, 0L};
5962 return data;
5963 }
5964 public static final BitSet _tokenSet_51 = new BitSet(mk_tokenSet_51());
5965 private static final long[] mk_tokenSet_52() {
5966 long[] data = { 1468947534709504L, 65535L, 0L, 0L};
5967 return data;
5968 }
5969 public static final BitSet _tokenSet_52 = new BitSet(mk_tokenSet_52());
5970 private static final long[] mk_tokenSet_53() {
5971 long[] data = { 1468947534709504L, 262143L, 0L, 0L};
5972 return data;
5973 }
5974 public static final BitSet _tokenSet_53 = new BitSet(mk_tokenSet_53());
5975 private static final long[] mk_tokenSet_54() {
5976 long[] data = { 1468947534709504L, 4194303L, 0L, 0L};
5977 return data;
5978 }
5979 public static final BitSet _tokenSet_54 = new BitSet(mk_tokenSet_54());
5980 private static final long[] mk_tokenSet_55() {
5981 long[] data = { 1468947534709504L, 16777215L, 0L, 0L};
5982 return data;
5983 }
5984 public static final BitSet _tokenSet_55 = new BitSet(mk_tokenSet_55());
5985 private static final long[] mk_tokenSet_56() {
5986 long[] data = { 70368744177664L, 201326592L, 0L, 0L};
5987 return data;
5988 }
5989 public static final BitSet _tokenSet_56 = new BitSet(mk_tokenSet_56());
5990 private static final long[] mk_tokenSet_57() {
5991 long[] data = { 1468947534709504L, 67108863L, 0L, 0L};
5992 return data;
5993 }
5994 public static final BitSet _tokenSet_57 = new BitSet(mk_tokenSet_57());
5995 private static final long[] mk_tokenSet_58() {
5996 long[] data = { 2247401767174912L, 562949953421311L, 0L, 0L};
5997 return data;
5998 }
5999 public static final BitSet _tokenSet_58 = new BitSet(mk_tokenSet_58());
6000 private static final long[] mk_tokenSet_59() {
6001 long[] data = { 1539316278887168L, 268435455L, 0L, 0L};
6002 return data;
6003 }
6004 public static final BitSet _tokenSet_59 = new BitSet(mk_tokenSet_59());
6005 private static final long[] mk_tokenSet_60() {
6006 long[] data = { 2243003720663808L, 26843545599L, 0L, 0L};
6007 return data;
6008 }
6009 public static final BitSet _tokenSet_60 = new BitSet(mk_tokenSet_60());
6010
6011 }
com.jogamp.gluegen.cgram.CSymbolTable
Definition: CSymbolTable.java:8
com.jogamp.gluegen.cgram.CSymbolTable.popScope
void popScope()
pop the last scope off the scope stack.
Definition: CSymbolTable.java:31
com.jogamp.gluegen.cgram.CSymbolTable.add
TNode add(final String name, final TNode node)
add a node to the table with it's key as the current scope and the name
Definition: CSymbolTable.java:86
com.jogamp.gluegen.cgram.CSymbolTable.lookupNameInCurrentScope
TNode lookupNameInCurrentScope(final String name)
lookup an unscoped name in the table by prepending the current scope.
Definition: CSymbolTable.java:100
com.jogamp.gluegen.cgram.CSymbolTable.pushScope
void pushScope(final String s)
push a new scope onto the scope stack.
Definition: CSymbolTable.java:24
com.jogamp.gluegen.cgram.StdCParser
Definition: StdCParser.java:30
com.jogamp.gluegen.cgram.StdCParser._tokenSet_57
static final BitSet _tokenSet_57
Definition: StdCParser.java:5994
com.jogamp.gluegen.cgram.StdCParser.match
void match(int t)
Definition: StdCParser.java:93
com.jogamp.gluegen.cgram.StdCParser._tokenSet_31
static final BitSet _tokenSet_31
Definition: StdCParser.java:5864
com.jogamp.gluegen.cgram.StdCParser._tokenSet_13
static final BitSet _tokenSet_13
Definition: StdCParser.java:5774
com.jogamp.gluegen.cgram.StdCParser._tokenSet_60
static final BitSet _tokenSet_60
Definition: StdCParser.java:6009
com.jogamp.gluegen.cgram.StdCParser.declaration
final void declaration()
Definition: StdCParser.java:352
com.jogamp.gluegen.cgram.StdCParser.postfixExpr
final void postfixExpr()
Definition: StdCParser.java:4571
com.jogamp.gluegen.cgram.StdCParser._tokenSet_12
static final BitSet _tokenSet_12
Definition: StdCParser.java:5769
com.jogamp.gluegen.cgram.StdCParser.unaryExpr
final void unaryExpr()
Definition: StdCParser.java:4430
com.jogamp.gluegen.cgram.StdCParser.structDeclarator
final void structDeclarator()
Definition: StdCParser.java:1586
com.jogamp.gluegen.cgram.StdCParser._tokenSet_40
static final BitSet _tokenSet_40
Definition: StdCParser.java:5909
com.jogamp.gluegen.cgram.StdCParser._tokenSet_42
static final BitSet _tokenSet_42
Definition: StdCParser.java:5919
com.jogamp.gluegen.cgram.StdCParser.StdCParser
StdCParser(TokenStream lexer)
Definition: StdCParser.java:164
com.jogamp.gluegen.cgram.StdCParser._tokenSet_53
static final BitSet _tokenSet_53
Definition: StdCParser.java:5974
com.jogamp.gluegen.cgram.StdCParser.charConst
final void charConst()
Definition: StdCParser.java:5034
com.jogamp.gluegen.cgram.StdCParser.CPPComments
static boolean CPPComments
Definition: StdCParser.java:33
com.jogamp.gluegen.cgram.StdCParser.initializer
final void initializer()
Definition: StdCParser.java:2100
com.jogamp.gluegen.cgram.StdCParser.conditionalExpr
final void conditionalExpr()
Definition: StdCParser.java:3622
com.jogamp.gluegen.cgram.StdCParser._tokenSet_3
static final BitSet _tokenSet_3
Definition: StdCParser.java:5724
com.jogamp.gluegen.cgram.StdCParser.unaryOperator
final void unaryOperator()
Definition: StdCParser.java:4659
com.jogamp.gluegen.cgram.StdCParser.initDeclList
final void initDeclList(AST declarationSpecifiers)
Definition: StdCParser.java:713
com.jogamp.gluegen.cgram.StdCParser._tokenSet_48
static final BitSet _tokenSet_48
Definition: StdCParser.java:5949
com.jogamp.gluegen.cgram.StdCParser.structDeclarationList
final void structDeclarationList()
Definition: StdCParser.java:1406
com.jogamp.gluegen.cgram.StdCParser.externalDef
final void externalDef()
Definition: StdCParser.java:289
com.jogamp.gluegen.cgram.StdCParser.traceOut
void traceOut(String rname)
Definition: StdCParser.java:134
com.jogamp.gluegen.cgram.StdCParser._tokenSet_52
static final BitSet _tokenSet_52
Definition: StdCParser.java:5969
com.jogamp.gluegen.cgram.StdCParser._tokenSet_49
static final BitSet _tokenSet_49
Definition: StdCParser.java:5954
com.jogamp.gluegen.cgram.StdCParser.parameterTypeList
final void parameterTypeList()
Definition: StdCParser.java:2394
com.jogamp.gluegen.cgram.StdCParser.functionDeclSpecifiers
final void functionDeclSpecifiers()
Definition: StdCParser.java:2859
com.jogamp.gluegen.cgram.StdCParser._tokenSet_43
static final BitSet _tokenSet_43
Definition: StdCParser.java:5924
com.jogamp.gluegen.cgram.StdCParser.inclusiveOrExpr
final void inclusiveOrExpr()
Definition: StdCParser.java:3887
com.jogamp.gluegen.cgram.StdCParser._tokenSet_33
static final BitSet _tokenSet_33
Definition: StdCParser.java:5874
com.jogamp.gluegen.cgram.StdCParser._tokenSet_16
static final BitSet _tokenSet_16
Definition: StdCParser.java:5789
com.jogamp.gluegen.cgram.StdCParser.functionStorageClassSpecifier
final void functionStorageClassSpecifier()
Definition: StdCParser.java:1096
com.jogamp.gluegen.cgram.StdCParser.shiftExpr
final void shiftExpr()
Definition: StdCParser.java:4138
com.jogamp.gluegen.cgram.StdCParser.logicalAndExpr
final void logicalAndExpr()
Definition: StdCParser.java:3848
com.jogamp.gluegen.cgram.StdCParser.translationUnit
final void translationUnit()
Definition: StdCParser.java:175
com.jogamp.gluegen.cgram.StdCParser.StdCParser
StdCParser(TokenStream lexer, int k)
Definition: StdCParser.java:157
com.jogamp.gluegen.cgram.StdCParser._tokenSet_39
static final BitSet _tokenSet_39
Definition: StdCParser.java:5904
com.jogamp.gluegen.cgram.StdCParser.postfixSuffix
final void postfixSuffix()
Definition: StdCParser.java:4827
com.jogamp.gluegen.cgram.StdCParser._tokenSet_44
static final BitSet _tokenSet_44
Definition: StdCParser.java:5929
com.jogamp.gluegen.cgram.StdCParser._tokenSet_36
static final BitSet _tokenSet_36
Definition: StdCParser.java:5889
com.jogamp.gluegen.cgram.StdCParser._tokenSet_51
static final BitSet _tokenSet_51
Definition: StdCParser.java:5964
com.jogamp.gluegen.cgram.StdCParser.typeName
final void typeName()
Definition: StdCParser.java:4388
com.jogamp.gluegen.cgram.StdCParser.compoundStatement
final void compoundStatement(String scopeName)
Definition: StdCParser.java:2942
com.jogamp.gluegen.cgram.StdCParser._tokenSet_25
static final BitSet _tokenSet_25
Definition: StdCParser.java:5834
com.jogamp.gluegen.cgram.StdCParser._tokenSet_37
static final BitSet _tokenSet_37
Definition: StdCParser.java:5894
com.jogamp.gluegen.cgram.StdCParser._tokenSet_4
static final BitSet _tokenSet_4
Definition: StdCParser.java:5729
com.jogamp.gluegen.cgram.StdCParser.idList
final void idList()
Definition: StdCParser.java:2252
com.jogamp.gluegen.cgram.StdCParser._tokenSet_28
static final BitSet _tokenSet_28
Definition: StdCParser.java:5849
com.jogamp.gluegen.cgram.StdCParser.assignExpr
final void assignExpr()
Definition: StdCParser.java:2292
com.jogamp.gluegen.cgram.StdCParser.stringConst
final void stringConst()
Definition: StdCParser.java:5216
com.jogamp.gluegen.cgram.StdCParser._tokenSet_55
static final BitSet _tokenSet_55
Definition: StdCParser.java:5984
com.jogamp.gluegen.cgram.StdCParser.enumList
final void enumList(String enumName)
Definition: StdCParser.java:1930
com.jogamp.gluegen.cgram.StdCParser._tokenSet_21
static final BitSet _tokenSet_21
Definition: StdCParser.java:5814
com.jogamp.gluegen.cgram.StdCParser.specifierQualifierList
final void specifierQualifierList()
Definition: StdCParser.java:1479
com.jogamp.gluegen.cgram.StdCParser.isTypedefName
boolean isTypedefName(String name)
Definition: StdCParser.java:41
com.jogamp.gluegen.cgram.StdCParser.exclusiveOrExpr
final void exclusiveOrExpr()
Definition: StdCParser.java:3926
com.jogamp.gluegen.cgram.StdCParser._tokenNames
static final String[] _tokenNames
Definition: StdCParser.java:5539
com.jogamp.gluegen.cgram.StdCParser._tokenSet_45
static final BitSet _tokenSet_45
Definition: StdCParser.java:5934
com.jogamp.gluegen.cgram.StdCParser._tokenSet_29
static final BitSet _tokenSet_29
Definition: StdCParser.java:5854
com.jogamp.gluegen.cgram.StdCParser._tokenSet_0
static final BitSet _tokenSet_0
Definition: StdCParser.java:5709
com.jogamp.gluegen.cgram.StdCParser.logicalOrExpr
final void logicalOrExpr()
Definition: StdCParser.java:3809
com.jogamp.gluegen.cgram.StdCParser.initializerList
final void initializerList()
Definition: StdCParser.java:2358
com.jogamp.gluegen.cgram.StdCParser._tokenSet_24
static final BitSet _tokenSet_24
Definition: StdCParser.java:5829
com.jogamp.gluegen.cgram.StdCParser.structDeclaration
final void structDeclaration()
Definition: StdCParser.java:1441
com.jogamp.gluegen.cgram.StdCParser.multExpr
final void multExpr()
Definition: StdCParser.java:4256
com.jogamp.gluegen.cgram.StdCParser._tokenSet_34
static final BitSet _tokenSet_34
Definition: StdCParser.java:5879
com.jogamp.gluegen.cgram.StdCParser._tokenSet_58
static final BitSet _tokenSet_58
Definition: StdCParser.java:5999
com.jogamp.gluegen.cgram.StdCParser.typeSpecifier
final int typeSpecifier(int specCount)
Definition: StdCParser.java:854
com.jogamp.gluegen.cgram.StdCParser.getDebug
boolean getDebug()
Definition: StdCParser.java:68
com.jogamp.gluegen.cgram.StdCParser.storageClassSpecifier
final void storageClassSpecifier()
Definition: StdCParser.java:751
com.jogamp.gluegen.cgram.StdCParser._tokenSet_32
static final BitSet _tokenSet_32
Definition: StdCParser.java:5869
com.jogamp.gluegen.cgram.StdCParser._tokenSet_6
static final BitSet _tokenSet_6
Definition: StdCParser.java:5739
com.jogamp.gluegen.cgram.StdCParser.setDebug
void setDebug(boolean debug)
Definition: StdCParser.java:72
com.jogamp.gluegen.cgram.StdCParser.additiveExpr
final void additiveExpr()
Definition: StdCParser.java:4197
com.jogamp.gluegen.cgram.StdCParser._tokenSet_46
static final BitSet _tokenSet_46
Definition: StdCParser.java:5939
com.jogamp.gluegen.cgram.StdCParser.structOrUnion
final void structOrUnion()
Definition: StdCParser.java:1363
com.jogamp.gluegen.cgram.StdCParser.StdCParser
StdCParser(TokenBuffer tokenBuf, int k)
Definition: StdCParser.java:146
com.jogamp.gluegen.cgram.StdCParser.structOrUnionSpecifier
final void structOrUnionSpecifier()
Definition: StdCParser.java:1139
com.jogamp.gluegen.cgram.StdCParser._tokenSet_30
static final BitSet _tokenSet_30
Definition: StdCParser.java:5859
com.jogamp.gluegen.cgram.StdCParser.enumSpecifier
final void enumSpecifier()
Definition: StdCParser.java:1250
com.jogamp.gluegen.cgram.StdCParser.StdCParser
StdCParser(ParserSharedInputState state)
Definition: StdCParser.java:168
com.jogamp.gluegen.cgram.StdCParser.assignOperator
final void assignOperator()
Definition: StdCParser.java:3685
com.jogamp.gluegen.cgram.StdCParser._tokenSet_2
static final BitSet _tokenSet_2
Definition: StdCParser.java:5719
com.jogamp.gluegen.cgram.StdCParser.enumerator
final void enumerator(String enumName)
Definition: StdCParser.java:1968
com.jogamp.gluegen.cgram.StdCParser._tokenSet_35
static final BitSet _tokenSet_35
Definition: StdCParser.java:5884
com.jogamp.gluegen.cgram.StdCParser._tokenSet_10
static final BitSet _tokenSet_10
Definition: StdCParser.java:5759
com.jogamp.gluegen.cgram.StdCParser.argExprList
final void argExprList()
Definition: StdCParser.java:4998
com.jogamp.gluegen.cgram.StdCParser.typedefName
final void typedefName()
Definition: StdCParser.java:1327
com.jogamp.gluegen.cgram.StdCParser.pointerGroup
final void pointerGroup()
Definition: StdCParser.java:2194
com.jogamp.gluegen.cgram.StdCParser._tokenSet_8
static final BitSet _tokenSet_8
Definition: StdCParser.java:5749
com.jogamp.gluegen.cgram.StdCParser.structDeclaratorList
final void structDeclaratorList()
Definition: StdCParser.java:1550
com.jogamp.gluegen.cgram.StdCParser.relationalExpr
final void relationalExpr()
Definition: StdCParser.java:4063
com.jogamp.gluegen.cgram.StdCParser._tokenSet_14
static final BitSet _tokenSet_14
Definition: StdCParser.java:5779
com.jogamp.gluegen.cgram.StdCParser.StdCParser
StdCParser(TokenBuffer tokenBuf)
Definition: StdCParser.java:153
com.jogamp.gluegen.cgram.StdCParser.typeQualifier
final void typeQualifier()
Definition: StdCParser.java:811
com.jogamp.gluegen.cgram.StdCParser._tokenSet_18
static final BitSet _tokenSet_18
Definition: StdCParser.java:5799
com.jogamp.gluegen.cgram.StdCParser.declarationList
final void declarationList()
Definition: StdCParser.java:3065
com.jogamp.gluegen.cgram.StdCParser.dummy
final void dummy()
Definition: StdCParser.java:5261
com.jogamp.gluegen.cgram.StdCParser.castExpr
final void castExpr()
Definition: StdCParser.java:4323
com.jogamp.gluegen.cgram.StdCParser.statement
final void statement()
Definition: StdCParser.java:3187
com.jogamp.gluegen.cgram.StdCParser._tokenSet_50
static final BitSet _tokenSet_50
Definition: StdCParser.java:5959
com.jogamp.gluegen.cgram.StdCParser.popScope
void popScope()
Definition: StdCParser.java:62
com.jogamp.gluegen.cgram.StdCParser._tokenSet_56
static final BitSet _tokenSet_56
Definition: StdCParser.java:5989
com.jogamp.gluegen.cgram.StdCParser.equalityExpr
final void equalityExpr()
Definition: StdCParser.java:4004
com.jogamp.gluegen.cgram.StdCParser.bitAndExpr
final void bitAndExpr()
Definition: StdCParser.java:3965
com.jogamp.gluegen.cgram.StdCParser._tokenSet_17
static final BitSet _tokenSet_17
Definition: StdCParser.java:5794
com.jogamp.gluegen.cgram.StdCParser.pushScope
void pushScope(String scopeName)
Definition: StdCParser.java:58
com.jogamp.gluegen.cgram.StdCParser.intConst
final void intConst()
Definition: StdCParser.java:5058
com.jogamp.gluegen.cgram.StdCParser.statementList
final void statementList()
Definition: StdCParser.java:3152
com.jogamp.gluegen.cgram.StdCParser.reportError
void reportError(String s)
Definition: StdCParser.java:87
com.jogamp.gluegen.cgram.StdCParser.functionCall
final void functionCall()
Definition: StdCParser.java:4920
com.jogamp.gluegen.cgram.StdCParser._tokenSet_9
static final BitSet _tokenSet_9
Definition: StdCParser.java:5754
com.jogamp.gluegen.cgram.StdCParser.floatConst
final void floatConst()
Definition: StdCParser.java:5164
com.jogamp.gluegen.cgram.StdCParser._tokenSet_38
static final BitSet _tokenSet_38
Definition: StdCParser.java:5899
com.jogamp.gluegen.cgram.StdCParser.asm_expr
final void asm_expr()
Definition: StdCParser.java:532
com.jogamp.gluegen.cgram.StdCParser._tokenSet_7
static final BitSet _tokenSet_7
Definition: StdCParser.java:5744
com.jogamp.gluegen.cgram.StdCParser._tokenSet_26
static final BitSet _tokenSet_26
Definition: StdCParser.java:5839
com.jogamp.gluegen.cgram.StdCParser._tokenSet_1
static final BitSet _tokenSet_1
Definition: StdCParser.java:5714
com.jogamp.gluegen.cgram.StdCParser.parameterDeclaration
final void parameterDeclaration()
Definition: StdCParser.java:2451
com.jogamp.gluegen.cgram.StdCParser._tokenSet_41
static final BitSet _tokenSet_41
Definition: StdCParser.java:5914
com.jogamp.gluegen.cgram.StdCParser._tokenSet_54
static final BitSet _tokenSet_54
Definition: StdCParser.java:5979
com.jogamp.gluegen.cgram.StdCParser._tokenSet_5
static final BitSet _tokenSet_5
Definition: StdCParser.java:5734
com.jogamp.gluegen.cgram.StdCParser.symbolTable
CSymbolTable symbolTable
Definition: StdCParser.java:36
com.jogamp.gluegen.cgram.StdCParser.constExpr
final void constExpr()
Definition: StdCParser.java:1663
com.jogamp.gluegen.cgram.StdCParser.declarator
final String declarator(boolean isFunctionDefinition)
Definition: StdCParser.java:1685
com.jogamp.gluegen.cgram.StdCParser.declarationPredictor
final void declarationPredictor()
Definition: StdCParser.java:3116
com.jogamp.gluegen.cgram.StdCParser._tokenSet_15
static final BitSet _tokenSet_15
Definition: StdCParser.java:5784
com.jogamp.gluegen.cgram.StdCParser.declSpecifiers
final void declSpecifiers()
Definition: StdCParser.java:625
com.jogamp.gluegen.cgram.StdCParser.unnamedScopeCounter
int unnamedScopeCounter
Definition: StdCParser.java:39
com.jogamp.gluegen.cgram.StdCParser.debugging
boolean debugging
Definition: StdCParser.java:66
com.jogamp.gluegen.cgram.StdCParser.getAScopeName
String getAScopeName()
Definition: StdCParser.java:54
com.jogamp.gluegen.cgram.StdCParser._tokenSet_20
static final BitSet _tokenSet_20
Definition: StdCParser.java:5809
com.jogamp.gluegen.cgram.StdCParser.initDecl
final void initDecl(AST declarationSpecifiers)
Definition: StdCParser.java:2025
com.jogamp.gluegen.cgram.StdCParser.reportWarning
void reportWarning(String s)
Definition: StdCParser.java:90
com.jogamp.gluegen.cgram.StdCParser.traceIn
void traceIn(String rname)
Definition: StdCParser.java:124
com.jogamp.gluegen.cgram.StdCParser._tokenSet_59
static final BitSet _tokenSet_59
Definition: StdCParser.java:6004
com.jogamp.gluegen.cgram.StdCParser.buildTokenTypeASTClassMap
void buildTokenTypeASTClassMap()
Definition: StdCParser.java:5701
com.jogamp.gluegen.cgram.StdCParser._tokenSet_11
static final BitSet _tokenSet_11
Definition: StdCParser.java:5764
com.jogamp.gluegen.cgram.StdCParser.externalList
final void externalList()
Definition: StdCParser.java:254
com.jogamp.gluegen.cgram.StdCParser._tokenSet_27
static final BitSet _tokenSet_27
Definition: StdCParser.java:5844
com.jogamp.gluegen.cgram.StdCParser.functionDef
final void functionDef()
Definition: StdCParser.java:409
com.jogamp.gluegen.cgram.StdCParser._tokenSet_19
static final BitSet _tokenSet_19
Definition: StdCParser.java:5804
com.jogamp.gluegen.cgram.StdCParser.primaryExpr
final void primaryExpr()
Definition: StdCParser.java:4738
com.jogamp.gluegen.cgram.StdCParser.expr
final void expr()
Definition: StdCParser.java:581
com.jogamp.gluegen.cgram.StdCParser._tokenSet_22
static final BitSet _tokenSet_22
Definition: StdCParser.java:5819
com.jogamp.gluegen.cgram.StdCParser.reportError
void reportError(RecognitionException ex)
Definition: StdCParser.java:77
com.jogamp.gluegen.cgram.StdCParser._tokenSet_47
static final BitSet _tokenSet_47
Definition: StdCParser.java:5944
com.jogamp.gluegen.cgram.StdCParser._tokenSet_23
static final BitSet _tokenSet_23
Definition: StdCParser.java:5824
com.jogamp.gluegen.cgram.StdCParser.nonemptyAbstractDeclarator
final void nonemptyAbstractDeclarator()
Definition: StdCParser.java:2528
com.jogamp.gluegen.cgram.TNode
Class TNode is an implementation of the AST interface and adds many useful features:
Definition: TNode.java:38
com.jogamp.gluegen.cgram.TNode.getType
int getType()
Get the token type for this node.
Definition: TNode.java:97
com.jogamp.gluegen.cgram.TNode.setText
void setText(final String text_)
Set the token text for this node.
Definition: TNode.java:179
com.jogamp.gluegen.cgram.TNode.getText
String getText()
Get the token text for this node.
Definition: TNode.java:175
com.jogamp.gluegen.cgram.TNode.setType
void setType(final int ttype_)
Set the token type for this node.
Definition: TNode.java:101
com.jogamp.gluegen.cgram.STDCTokenTypes
Definition: STDCTokenTypes.java:10
com.jogamp.gluegen.cgram.STDCTokenTypes.BAND_ASSIGN
int BAND_ASSIGN
Definition: STDCTokenTypes.java:80
com.jogamp.gluegen.cgram.STDCTokenTypes.MOD
int MOD
Definition: STDCTokenTypes.java:100
com.jogamp.gluegen.cgram.STDCTokenTypes.GTE
int GTE
Definition: STDCTokenTypes.java:94
com.jogamp.gluegen.cgram.STDCTokenTypes.CharLiteral
int CharLiteral
Definition: STDCTokenTypes.java:108
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_void
int LITERAL_void
Definition: STDCTokenTypes.java:27
com.jogamp.gluegen.cgram.STDCTokenTypes.ID
int ID
Definition: STDCTokenTypes.java:51
com.jogamp.gluegen.cgram.STDCTokenTypes.PLUS_ASSIGN
int PLUS_ASSIGN
Definition: STDCTokenTypes.java:74
com.jogamp.gluegen.cgram.STDCTokenTypes.BOR
int BOR
Definition: STDCTokenTypes.java:86
com.jogamp.gluegen.cgram.STDCTokenTypes.VARARGS
int VARARGS
Definition: STDCTokenTypes.java:60
com.jogamp.gluegen.cgram.STDCTokenTypes.IntHexConst
int IntHexConst
Definition: STDCTokenTypes.java:116
com.jogamp.gluegen.cgram.STDCTokenTypes.FloatDoubleConst
int FloatDoubleConst
Definition: STDCTokenTypes.java:119
com.jogamp.gluegen.cgram.STDCTokenTypes.NFunctionCallArgs
int NFunctionCallArgs
Definition: STDCTokenTypes.java:130
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_break
int LITERAL_break
Definition: STDCTokenTypes.java:66
com.jogamp.gluegen.cgram.STDCTokenTypes.NRangeExpr
int NRangeExpr
Definition: STDCTokenTypes.java:143
com.jogamp.gluegen.cgram.STDCTokenTypes.UnsignedIntConst
int UnsignedIntConst
Definition: STDCTokenTypes.java:115
com.jogamp.gluegen.cgram.STDCTokenTypes.NCommaExpr
int NCommaExpr
Definition: STDCTokenTypes.java:139
com.jogamp.gluegen.cgram.STDCTokenTypes.BXOR
int BXOR
Definition: STDCTokenTypes.java:87
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_do
int LITERAL_do
Definition: STDCTokenTypes.java:62
com.jogamp.gluegen.cgram.STDCTokenTypes.NFunctionDef
int NFunctionDef
Definition: STDCTokenTypes.java:136
com.jogamp.gluegen.cgram.STDCTokenTypes.DEC
int DEC
Definition: STDCTokenTypes.java:102
com.jogamp.gluegen.cgram.STDCTokenTypes.EOF
int EOF
Definition: STDCTokenTypes.java:11
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_float
int LITERAL_float
Definition: STDCTokenTypes.java:32
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_for
int LITERAL_for
Definition: STDCTokenTypes.java:63
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_ptrdiff_t
int LITERAL_ptrdiff_t
Definition: STDCTokenTypes.java:47
com.jogamp.gluegen.cgram.STDCTokenTypes.NTypeMissing
int NTypeMissing
Definition: STDCTokenTypes.java:149
com.jogamp.gluegen.cgram.STDCTokenTypes.MOD_ASSIGN
int MOD_ASSIGN
Definition: STDCTokenTypes.java:77
com.jogamp.gluegen.cgram.STDCTokenTypes.DoubleDoubleConst
int DoubleDoubleConst
Definition: STDCTokenTypes.java:120
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_static
int LITERAL_static
Definition: STDCTokenTypes.java:25
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_continue
int LITERAL_continue
Definition: STDCTokenTypes.java:65
com.jogamp.gluegen.cgram.STDCTokenTypes.INC
int INC
Definition: STDCTokenTypes.java:101
com.jogamp.gluegen.cgram.STDCTokenTypes.RPAREN
int RPAREN
Definition: STDCTokenTypes.java:57
com.jogamp.gluegen.cgram.STDCTokenTypes.LT
int LT
Definition: STDCTokenTypes.java:91
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_union
int LITERAL_union
Definition: STDCTokenTypes.java:20
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_const
int LITERAL_const
Definition: STDCTokenTypes.java:26
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_else
int LITERAL_else
Definition: STDCTokenTypes.java:71
com.jogamp.gluegen.cgram.STDCTokenTypes.LongIntConst
int LongIntConst
Definition: STDCTokenTypes.java:114
com.jogamp.gluegen.cgram.STDCTokenTypes.RSHIFT
int RSHIFT
Definition: STDCTokenTypes.java:96
com.jogamp.gluegen.cgram.STDCTokenTypes.QUESTION
int QUESTION
Definition: STDCTokenTypes.java:83
com.jogamp.gluegen.cgram.STDCTokenTypes.NOT_EQUAL
int NOT_EQUAL
Definition: STDCTokenTypes.java:90
com.jogamp.gluegen.cgram.STDCTokenTypes.StringLiteral
int StringLiteral
Definition: STDCTokenTypes.java:109
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_return
int LITERAL_return
Definition: STDCTokenTypes.java:67
com.jogamp.gluegen.cgram.STDCTokenTypes.NParameterTypeList
int NParameterTypeList
Definition: STDCTokenTypes.java:135
com.jogamp.gluegen.cgram.STDCTokenTypes.NCompoundStatement
int NCompoundStatement
Definition: STDCTokenTypes.java:137
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_unsigned
int LITERAL_unsigned
Definition: STDCTokenTypes.java:35
com.jogamp.gluegen.cgram.STDCTokenTypes.EQUAL
int EQUAL
Definition: STDCTokenTypes.java:89
com.jogamp.gluegen.cgram.STDCTokenTypes.NStatementExpr
int NStatementExpr
Definition: STDCTokenTypes.java:133
com.jogamp.gluegen.cgram.STDCTokenTypes.NTypedefName
int NTypedefName
Definition: STDCTokenTypes.java:122
com.jogamp.gluegen.cgram.STDCTokenTypes.NDeclaration
int NDeclaration
Definition: STDCTokenTypes.java:126
com.jogamp.gluegen.cgram.STDCTokenTypes.NCast
int NCast
Definition: STDCTokenTypes.java:127
com.jogamp.gluegen.cgram.STDCTokenTypes.BAND
int BAND
Definition: STDCTokenTypes.java:88
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_signed
int LITERAL_signed
Definition: STDCTokenTypes.java:34
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_intptr_t
int LITERAL_intptr_t
Definition: STDCTokenTypes.java:48
com.jogamp.gluegen.cgram.STDCTokenTypes.PTR
int PTR
Definition: STDCTokenTypes.java:106
com.jogamp.gluegen.cgram.STDCTokenTypes.LongDoubleConst
int LongDoubleConst
Definition: STDCTokenTypes.java:121
com.jogamp.gluegen.cgram.STDCTokenTypes.NPointerGroup
int NPointerGroup
Definition: STDCTokenTypes.java:128
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_size_t
int LITERAL_size_t
Definition: STDCTokenTypes.java:49
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_double
int LITERAL_double
Definition: STDCTokenTypes.java:33
com.jogamp.gluegen.cgram.STDCTokenTypes.IntIntConst
int IntIntConst
Definition: STDCTokenTypes.java:113
com.jogamp.gluegen.cgram.STDCTokenTypes.NParameterDeclaration
int NParameterDeclaration
Definition: STDCTokenTypes.java:138
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_short
int LITERAL_short
Definition: STDCTokenTypes.java:29
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_char
int LITERAL_char
Definition: STDCTokenTypes.java:28
com.jogamp.gluegen.cgram.STDCTokenTypes.LPAREN
int LPAREN
Definition: STDCTokenTypes.java:56
com.jogamp.gluegen.cgram.STDCTokenTypes.MINUS_ASSIGN
int MINUS_ASSIGN
Definition: STDCTokenTypes.java:75
com.jogamp.gluegen.cgram.STDCTokenTypes.NDeclarator
int NDeclarator
Definition: STDCTokenTypes.java:124
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_asm
int LITERAL_asm
Definition: STDCTokenTypes.java:14
com.jogamp.gluegen.cgram.STDCTokenTypes.UnsignedHexConst
int UnsignedHexConst
Definition: STDCTokenTypes.java:118
com.jogamp.gluegen.cgram.STDCTokenTypes.DIV_ASSIGN
int DIV_ASSIGN
Definition: STDCTokenTypes.java:73
com.jogamp.gluegen.cgram.STDCTokenTypes.PLUS
int PLUS
Definition: STDCTokenTypes.java:97
com.jogamp.gluegen.cgram.STDCTokenTypes.NStringSeq
int NStringSeq
Definition: STDCTokenTypes.java:144
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_default
int LITERAL_default
Definition: STDCTokenTypes.java:69
com.jogamp.gluegen.cgram.STDCTokenTypes.NStructDeclarator
int NStructDeclarator
Definition: STDCTokenTypes.java:125
com.jogamp.gluegen.cgram.STDCTokenTypes.BNOT
int BNOT
Definition: STDCTokenTypes.java:104
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_wchar_t
int LITERAL_wchar_t
Definition: STDCTokenTypes.java:42
com.jogamp.gluegen.cgram.STDCTokenTypes.MINUS
int MINUS
Definition: STDCTokenTypes.java:98
com.jogamp.gluegen.cgram.STDCTokenTypes.NExpressionGroup
int NExpressionGroup
Definition: STDCTokenTypes.java:129
com.jogamp.gluegen.cgram.STDCTokenTypes.NAsmAttribute
int NAsmAttribute
Definition: STDCTokenTypes.java:147
com.jogamp.gluegen.cgram.STDCTokenTypes.NEmptyExpression
int NEmptyExpression
Definition: STDCTokenTypes.java:134
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_typedef
int LITERAL_typedef
Definition: STDCTokenTypes.java:13
com.jogamp.gluegen.cgram.STDCTokenTypes.COLON
int COLON
Definition: STDCTokenTypes.java:53
com.jogamp.gluegen.cgram.STDCTokenTypes.NLcurlyInitializer
int NLcurlyInitializer
Definition: STDCTokenTypes.java:146
com.jogamp.gluegen.cgram.STDCTokenTypes.DIV
int DIV
Definition: STDCTokenTypes.java:99
com.jogamp.gluegen.cgram.STDCTokenTypes.NUnaryExpr
int NUnaryExpr
Definition: STDCTokenTypes.java:140
com.jogamp.gluegen.cgram.STDCTokenTypes.COMMA
int COMMA
Definition: STDCTokenTypes.java:52
com.jogamp.gluegen.cgram.STDCTokenTypes.NGnuAsmExpr
int NGnuAsmExpr
Definition: STDCTokenTypes.java:148
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_extern
int LITERAL_extern
Definition: STDCTokenTypes.java:24
com.jogamp.gluegen.cgram.STDCTokenTypes.RCURLY
int RCURLY
Definition: STDCTokenTypes.java:17
com.jogamp.gluegen.cgram.STDCTokenTypes.NNonemptyAbstractDeclarator
int NNonemptyAbstractDeclarator
Definition: STDCTokenTypes.java:131
com.jogamp.gluegen.cgram.STDCTokenTypes.BOR_ASSIGN
int BOR_ASSIGN
Definition: STDCTokenTypes.java:81
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_goto
int LITERAL_goto
Definition: STDCTokenTypes.java:64
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_switch
int LITERAL_switch
Definition: STDCTokenTypes.java:72
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_case
int LITERAL_case
Definition: STDCTokenTypes.java:68
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_while
int LITERAL_while
Definition: STDCTokenTypes.java:61
com.jogamp.gluegen.cgram.STDCTokenTypes.NLabel
int NLabel
Definition: STDCTokenTypes.java:141
com.jogamp.gluegen.cgram.STDCTokenTypes.STAR
int STAR
Definition: STDCTokenTypes.java:55
com.jogamp.gluegen.cgram.STDCTokenTypes.RSHIFT_ASSIGN
int RSHIFT_ASSIGN
Definition: STDCTokenTypes.java:78
com.jogamp.gluegen.cgram.STDCTokenTypes.NInitDecl
int NInitDecl
Definition: STDCTokenTypes.java:123
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_volatile
int LITERAL_volatile
Definition: STDCTokenTypes.java:15
com.jogamp.gluegen.cgram.STDCTokenTypes.LongHexConst
int LongHexConst
Definition: STDCTokenTypes.java:117
com.jogamp.gluegen.cgram.STDCTokenTypes.IntOctalConst
int IntOctalConst
Definition: STDCTokenTypes.java:110
com.jogamp.gluegen.cgram.STDCTokenTypes.SEMI
int SEMI
Definition: STDCTokenTypes.java:18
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_register
int LITERAL_register
Definition: STDCTokenTypes.java:23
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_sizeof
int LITERAL_sizeof
Definition: STDCTokenTypes.java:103
com.jogamp.gluegen.cgram.STDCTokenTypes.STAR_ASSIGN
int STAR_ASSIGN
Definition: STDCTokenTypes.java:76
com.jogamp.gluegen.cgram.STDCTokenTypes.NInitializer
int NInitializer
Definition: STDCTokenTypes.java:132
com.jogamp.gluegen.cgram.STDCTokenTypes.LTE
int LTE
Definition: STDCTokenTypes.java:92
com.jogamp.gluegen.cgram.STDCTokenTypes.LCURLY
int LCURLY
Definition: STDCTokenTypes.java:16
com.jogamp.gluegen.cgram.STDCTokenTypes.LBRACKET
int LBRACKET
Definition: STDCTokenTypes.java:58
com.jogamp.gluegen.cgram.STDCTokenTypes.BXOR_ASSIGN
int BXOR_ASSIGN
Definition: STDCTokenTypes.java:82
com.jogamp.gluegen.cgram.STDCTokenTypes.NInitializerElementLabel
int NInitializerElementLabel
Definition: STDCTokenTypes.java:145
com.jogamp.gluegen.cgram.STDCTokenTypes.RBRACKET
int RBRACKET
Definition: STDCTokenTypes.java:59
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_struct
int LITERAL_struct
Definition: STDCTokenTypes.java:19
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_auto
int LITERAL_auto
Definition: STDCTokenTypes.java:22
com.jogamp.gluegen.cgram.STDCTokenTypes.NPostfixExpr
int NPostfixExpr
Definition: STDCTokenTypes.java:142
com.jogamp.gluegen.cgram.STDCTokenTypes.ASSIGN
int ASSIGN
Definition: STDCTokenTypes.java:54
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_int
int LITERAL_int
Definition: STDCTokenTypes.java:30
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_if
int LITERAL_if
Definition: STDCTokenTypes.java:70
com.jogamp.gluegen.cgram.STDCTokenTypes.LSHIFT
int LSHIFT
Definition: STDCTokenTypes.java:95
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_enum
int LITERAL_enum
Definition: STDCTokenTypes.java:21
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_long
int LITERAL_long
Definition: STDCTokenTypes.java:31
com.jogamp.gluegen.cgram.STDCTokenTypes.GT
int GT
Definition: STDCTokenTypes.java:93
com.jogamp.gluegen.cgram.STDCTokenTypes.LongOctalConst
int LongOctalConst
Definition: STDCTokenTypes.java:111
com.jogamp.gluegen.cgram.STDCTokenTypes.LAND
int LAND
Definition: STDCTokenTypes.java:85
com.jogamp.gluegen.cgram.STDCTokenTypes.LITERAL_uintptr_t
int LITERAL_uintptr_t
Definition: STDCTokenTypes.java:50
com.jogamp.gluegen.cgram.STDCTokenTypes.LOR
int LOR
Definition: STDCTokenTypes.java:84
com.jogamp.gluegen.cgram.STDCTokenTypes.LSHIFT_ASSIGN
int LSHIFT_ASSIGN
Definition: STDCTokenTypes.java:79
com.jogamp.gluegen.cgram.STDCTokenTypes.DOT
int DOT
Definition: STDCTokenTypes.java:107
com.jogamp.gluegen.cgram.STDCTokenTypes.UnsignedOctalConst
int UnsignedOctalConst
Definition: STDCTokenTypes.java:112
com.jogamp.gluegen.cgram.STDCTokenTypes.LNOT
int LNOT
Definition: STDCTokenTypes.java:105