Exemple #1
1
 public final java_cup.runtime.Symbol do_action(
     int CUP$parser$act_num,
     java_cup.runtime.lr_parser CUP$parser$parser,
     java.util.Stack CUP$parser$stack,
     int CUP$parser$top,
     parser parser)
     throws java.lang.Exception {
   java_cup.runtime.Symbol CUP$parser$result;
   // c_pointer ::= P_STAR c_pointer
   {
     Pointer RESULT = null;
     Token rl =
         (Token) ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 1)).value;
     Pointer p = (Pointer) ((java_cup.runtime.Symbol) CUP$parser$stack.peek()).value;
     RESULT = new Pointer(null, p);
     RESULT.setLeft(rl.getLeft());
     CUP$parser$result =
         parser
             .getSymbolFactory()
             .newSymbol(
                 "c_pointer",
                 105,
                 ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 1)),
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 RESULT);
   }
   return CUP$parser$result;
 }
Exemple #2
0
 public final java_cup.runtime.Symbol do_action(
     int CUP$parser$act_num,
     java_cup.runtime.lr_parser CUP$parser$parser,
     java.util.Stack CUP$parser$stack,
     int CUP$parser$top,
     parser parser)
     throws java.lang.Exception {
   java_cup.runtime.Symbol CUP$parser$result;
   // c_designator ::= P_POINT error
   {
     Designator RESULT = null;
     Token rl =
         (Token) ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 1)).value;
     FieldDesignator result =
         new FieldDesignator(parser.errorNode("field designator", "identifier"));
     RESULT = result;
     result.setLeft(rl.getLeft());
     CUP$parser$result =
         parser
             .getSymbolFactory()
             .newSymbol(
                 "c_designator",
                 120,
                 ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 1)),
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 RESULT);
   }
   return CUP$parser$result;
 }
Exemple #3
0
 public final java_cup.runtime.Symbol do_action(
     int CUP$parser$act_num,
     java_cup.runtime.lr_parser CUP$parser$parser,
     java.util.Stack CUP$parser$stack,
     int CUP$parser$top,
     parser parser)
     throws java.lang.Exception {
   java_cup.runtime.Symbol CUP$parser$result;
   // c_declaration_specifiers_notp_tn_nosc ::= c_declaration_specifiers_notp_tn_nosc_norg
   {
     DeclarationSpecifierList RESULT = null;
     DeclarationSpecifierList d =
         (DeclarationSpecifierList) ((java_cup.runtime.Symbol) CUP$parser$stack.peek()).value;
     RESULT = d;
     CUP$parser$result =
         parser
             .getSymbolFactory()
             .newSymbol(
                 "c_declaration_specifiers_notp_tn_nosc",
                 64,
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 RESULT);
   }
   return CUP$parser$result;
 }
Exemple #4
0
 public final java_cup.runtime.Symbol do_action(
     int CUP$parser$act_num,
     java_cup.runtime.lr_parser CUP$parser$parser,
     java.util.Stack CUP$parser$stack,
     int CUP$parser$top,
     parser parser)
     throws java.lang.Exception {
   java_cup.runtime.Symbol CUP$parser$result;
   // c_type_qualifier ::= K_RESTRICT
   {
     TypeQualifier RESULT = null;
     Token k = (Token) ((java_cup.runtime.Symbol) CUP$parser$stack.peek()).value;
     RESULT = new TypeQualifier(k, TypeQualifier.Qualifier.RESTRICT);
     CUP$parser$result =
         parser
             .getSymbolFactory()
             .newSymbol(
                 "c_type_qualifier",
                 98,
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 RESULT);
   }
   return CUP$parser$result;
 }
Exemple #5
0
 public final java_cup.runtime.Symbol do_action(
     int CUP$parser$act_num,
     java_cup.runtime.lr_parser CUP$parser$parser,
     java.util.Stack CUP$parser$stack,
     int CUP$parser$top,
     parser parser)
     throws java.lang.Exception {
   java_cup.runtime.Symbol CUP$parser$result;
   // c_storage_class_specifier_norg ::= K_TYPEDEF
   {
     StorageClass RESULT = null;
     Token k = (Token) ((java_cup.runtime.Symbol) CUP$parser$stack.peek()).value;
     parser.scopes().typedef();
     RESULT = new StorageClass(k, StorageClass.Storage.TYPEDEF);
     CUP$parser$result =
         parser
             .getSymbolFactory()
             .newSymbol(
                 "c_storage_class_specifier_norg",
                 84,
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 RESULT);
   }
   return CUP$parser$result;
 }
Exemple #6
0
 public final java_cup.runtime.Symbol do_action(
     int CUP$parser$act_num,
     java_cup.runtime.lr_parser CUP$parser$parser,
     java.util.Stack CUP$parser$stack,
     int CUP$parser$top,
     parser parser)
     throws java.lang.Exception {
   java_cup.runtime.Symbol CUP$parser$result;
   // c_equality_operator ::= P_NOT_EQ
   {
     ArithmeticOperator RESULT = null;
     Token p = (Token) ((java_cup.runtime.Symbol) CUP$parser$stack.peek()).value;
     RESULT = new ArithmeticOperator(p, ArithmeticOperator.Operator.NOT_EQ);
     CUP$parser$result =
         parser
             .getSymbolFactory()
             .newSymbol(
                 "c_equality_operator",
                 48,
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 RESULT);
   }
   return CUP$parser$result;
 }
Exemple #7
0
 public final java_cup.runtime.Symbol do_action(
     int CUP$parser$act_num,
     java_cup.runtime.lr_parser CUP$parser$parser,
     java.util.Stack CUP$parser$stack,
     int CUP$parser$top,
     parser parser)
     throws java.lang.Exception {
   java_cup.runtime.Symbol CUP$parser$result;
   // n_module_head ::= n_module_generic
   {
     Module RESULT = null;
     Module h = (Module) ((java_cup.runtime.Symbol) CUP$parser$stack.peek()).value;
     RESULT = h;
     h.setField(Module.NAME, parser.missing("module", "identifier", h.getRange().getRight()));
     CUP$parser$result =
         parser
             .getSymbolFactory()
             .newSymbol(
                 "n_module_head",
                 157,
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 RESULT);
   }
   return CUP$parser$result;
 }
Exemple #8
0
 public final java_cup.runtime.Symbol do_action(
     int CUP$parser$act_num,
     java_cup.runtime.lr_parser CUP$parser$parser,
     java.util.Stack CUP$parser$stack,
     int CUP$parser$top,
     parser parser)
     throws java.lang.Exception {
   java_cup.runtime.Symbol CUP$parser$result;
   // c_type_name ::= c_declaration_specifiers
   {
     TypeName RESULT = null;
     DeclarationSpecifierList s =
         (DeclarationSpecifierList) ((java_cup.runtime.Symbol) CUP$parser$stack.peek()).value;
     RESULT = new TypeName(s, null);
     CUP$parser$result =
         parser
             .getSymbolFactory()
             .newSymbol(
                 "c_type_name",
                 112,
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 RESULT);
   }
   return CUP$parser$result;
 }
Exemple #9
0
 public final java_cup.runtime.Symbol do_action(
     int CUP$parser$act_num,
     java_cup.runtime.lr_parser CUP$parser$parser,
     java.util.Stack CUP$parser$stack,
     int CUP$parser$top,
     parser parser)
     throws java.lang.Exception {
   java_cup.runtime.Symbol CUP$parser$result;
   // n_interface_type ::= NK_INTERFACE c_identifier c_arrow_open error c_arrow_close
   {
     InterfaceType RESULT = null;
     Token rl =
         (Token) ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 4)).value;
     Identifier i =
         (Identifier)
             ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 3)).value;
     Token rr = (Token) ((java_cup.runtime.Symbol) CUP$parser$stack.peek()).value;
     RESULT = new InterfaceType(i, parser.errorNode("interface", "type list"));
     RESULT.setRanges(rl, rr);
     CUP$parser$result =
         parser
             .getSymbolFactory()
             .newSymbol(
                 "n_interface_type",
                 171,
                 ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 4)),
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 RESULT);
   }
   return CUP$parser$result;
 }
Exemple #10
0
 public final java_cup.runtime.Symbol do_action(
     int CUP$parser$act_num,
     java_cup.runtime.lr_parser CUP$parser$parser,
     java.util.Stack CUP$parser$stack,
     int CUP$parser$top,
     parser parser)
     throws java.lang.Exception {
   java_cup.runtime.Symbol CUP$parser$result;
   // c_declaration_specifiers_notp_tn_nosc_rg ::= c_declaration_specifiers_notp_tn_nosc_rg
   // c_storage_class_specifier_rg
   {
     DeclarationSpecifierList RESULT = null;
     DeclarationSpecifierList d =
         (DeclarationSpecifierList)
             ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 1)).value;
     StorageClass e = (StorageClass) ((java_cup.runtime.Symbol) CUP$parser$stack.peek()).value;
     RESULT = d.add(e);
     CUP$parser$result =
         parser
             .getSymbolFactory()
             .newSymbol(
                 "c_declaration_specifiers_notp_tn_nosc_rg",
                 74,
                 ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 1)),
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 RESULT);
   }
   return CUP$parser$result;
 }
Exemple #11
0
 public final java_cup.runtime.Symbol do_action(
     int CUP$parser$act_num,
     java_cup.runtime.lr_parser CUP$parser$parser,
     java.util.Stack CUP$parser$stack,
     int CUP$parser$top,
     parser parser)
     throws java.lang.Exception {
   java_cup.runtime.Symbol CUP$parser$result;
   // c_abstract_declarator ::= c_pointer c_direct_abstract_declarator
   {
     AbstractDeclarator RESULT = null;
     Pointer p =
         (Pointer)
             ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 1)).value;
     AbstractDeclarator d =
         (AbstractDeclarator) ((java_cup.runtime.Symbol) CUP$parser$stack.peek()).value;
     RESULT = new PointerAbstractDeclarator(p, d);
     CUP$parser$result =
         parser
             .getSymbolFactory()
             .newSymbol(
                 "c_abstract_declarator",
                 113,
                 ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 1)),
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 RESULT);
   }
   return CUP$parser$result;
 }
Exemple #12
0
 public final java_cup.runtime.Symbol do_action(
     int CUP$parser$act_num,
     java_cup.runtime.lr_parser CUP$parser$parser,
     java.util.Stack CUP$parser$stack,
     int CUP$parser$top,
     parser parser)
     throws java.lang.Exception {
   java_cup.runtime.Symbol CUP$parser$result;
   // c_postfix_expression ::= c_compound_literal
   {
     Expression RESULT = null;
     CompoundLiteral c =
         (CompoundLiteral) ((java_cup.runtime.Symbol) CUP$parser$stack.peek()).value;
     RESULT = c;
     CUP$parser$result =
         parser
             .getSymbolFactory()
             .newSymbol(
                 "c_postfix_expression",
                 32,
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 RESULT);
   }
   return CUP$parser$result;
 }
Exemple #13
0
 public final java_cup.runtime.Symbol do_action(
     int CUP$parser$act_num,
     java_cup.runtime.lr_parser CUP$parser$parser,
     java.util.Stack CUP$parser$stack,
     int CUP$parser$top,
     parser parser)
     throws java.lang.Exception {
   java_cup.runtime.Symbol CUP$parser$result;
   // n_template_parameters ::= n_template_parameters P_COMMA error
   {
     TemplateParameterList RESULT = null;
     TemplateParameterList s =
         (TemplateParameterList)
             ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 2)).value;
     RESULT = s;
     s.addError(parser.errorNode("template parameter list", "template parameter"));
     CUP$parser$result =
         parser
             .getSymbolFactory()
             .newSymbol(
                 "n_template_parameters",
                 160,
                 ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 2)),
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 RESULT);
   }
   return CUP$parser$result;
 }
Exemple #14
0
 public final java_cup.runtime.Symbol do_action(
     int CUP$parser$act_num,
     java_cup.runtime.lr_parser CUP$parser$parser,
     java.util.Stack CUP$parser$stack,
     int CUP$parser$top,
     parser parser)
     throws java.lang.Exception {
   java_cup.runtime.Symbol CUP$parser$result;
   // n_binary_component ::= NK_COMPONENT c_curly_open c_curly_close
   {
     BinaryComponent RESULT = null;
     Token rl =
         (Token) ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 2)).value;
     Token rr = (Token) ((java_cup.runtime.Symbol) CUP$parser$stack.peek()).value;
     RESULT =
         new BinaryComponent(
             parser.missing("binary component", "identifier", rl.getRight()), null, null);
     RESULT.setLeft(rl.getLeft());
     RESULT.setRight(rr.getRight());
     CUP$parser$result =
         parser
             .getSymbolFactory()
             .newSymbol(
                 "n_binary_component",
                 194,
                 ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 2)),
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 RESULT);
   }
   return CUP$parser$result;
 }
Exemple #15
0
 public final java_cup.runtime.Symbol do_action(
     int CUP$parser$act_num,
     java_cup.runtime.lr_parser CUP$parser$parser,
     java.util.Stack CUP$parser$stack,
     int CUP$parser$top,
     parser parser)
     throws java.lang.Exception {
   java_cup.runtime.Symbol CUP$parser$result;
   // c_type_specifier_notn ::= K_CHAR
   {
     TypeSpecifier RESULT = null;
     Token k = (Token) ((java_cup.runtime.Symbol) CUP$parser$stack.peek()).value;
     RESULT = new PrimitiveSpecifier(k, PrimitiveSpecifier.Type.CHAR);
     CUP$parser$result =
         parser
             .getSymbolFactory()
             .newSymbol(
                 "c_type_specifier_notn",
                 88,
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 RESULT);
   }
   return CUP$parser$result;
 }
Exemple #16
0
 public final java_cup.runtime.Symbol do_action(
     int CUP$parser$act_num,
     java_cup.runtime.lr_parser CUP$parser$parser,
     java.util.Stack CUP$parser$stack,
     int CUP$parser$top,
     parser parser)
     throws java.lang.Exception {
   java_cup.runtime.Symbol CUP$parser$result;
   // c_selection_statement ::= K_SWITCH error c_statement
   {
     Statement RESULT = null;
     Token rl =
         (Token) ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 2)).value;
     Statement s = (Statement) ((java_cup.runtime.Symbol) CUP$parser$stack.peek()).value;
     SwitchStatement result =
         new SwitchStatement(
             parser.errorNode(
                 "switch header", "expression", rl.getRight(), s.getRange().getLeft()),
             s);
     RESULT = result;
     result.setLeft(rl.getLeft());
     CUP$parser$result =
         parser
             .getSymbolFactory()
             .newSymbol(
                 "c_selection_statement",
                 128,
                 ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 2)),
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 RESULT);
   }
   return CUP$parser$result;
 }
Exemple #17
0
 public final java_cup.runtime.Symbol do_action(
     int CUP$parser$act_num,
     java_cup.runtime.lr_parser CUP$parser$parser,
     java.util.Stack CUP$parser$stack,
     int CUP$parser$top,
     parser parser)
     throws java.lang.Exception {
   java_cup.runtime.Symbol CUP$parser$result;
   // n_component_list ::= n_component_list P_COMMA n_component_ref
   {
     ComponentList RESULT = null;
     ComponentList s =
         (ComponentList)
             ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 2)).value;
     Component i = (Component) ((java_cup.runtime.Symbol) CUP$parser$stack.peek()).value;
     RESULT = s.add(i);
     CUP$parser$result =
         parser
             .getSymbolFactory()
             .newSymbol(
                 "n_component_list",
                 189,
                 ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 2)),
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 RESULT);
   }
   return CUP$parser$result;
 }
Exemple #18
0
 public final java_cup.runtime.Symbol do_action(
     int CUP$parser$act_num,
     java_cup.runtime.lr_parser CUP$parser$parser,
     java.util.Stack CUP$parser$stack,
     int CUP$parser$top,
     parser parser)
     throws java.lang.Exception {
   java_cup.runtime.Symbol CUP$parser$result;
   // c_compound_statement ::= c_curly_open c_curly_close
   {
     CompoundStatement RESULT = null;
     Token lr =
         (Token) ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 1)).value;
     Token rr = (Token) ((java_cup.runtime.Symbol) CUP$parser$stack.peek()).value;
     CompoundStatement result = new CompoundStatement();
     RESULT = result;
     result.setRanges(lr, rr);
     CUP$parser$result =
         parser
             .getSymbolFactory()
             .newSymbol(
                 "c_compound_statement",
                 124,
                 ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 1)),
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 RESULT);
   }
   return CUP$parser$result;
 }
Exemple #19
0
 public final java_cup.runtime.Symbol do_action(
     int CUP$parser$act_num,
     java_cup.runtime.lr_parser CUP$parser$parser,
     java.util.Stack CUP$parser$stack,
     int CUP$parser$top,
     parser parser)
     throws java.lang.Exception {
   java_cup.runtime.Symbol CUP$parser$result;
   // c_expression_statement ::= c_semicolon
   {
     Statement RESULT = null;
     Token s = (Token) ((java_cup.runtime.Symbol) CUP$parser$stack.peek()).value;
     RESULT = new EmptyStatement(s);
     CUP$parser$result =
         parser
             .getSymbolFactory()
             .newSymbol(
                 "c_expression_statement",
                 127,
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 RESULT);
   }
   return CUP$parser$result;
 }
Exemple #20
0
 public final java_cup.runtime.Symbol do_action(
     int CUP$parser$act_num,
     java_cup.runtime.lr_parser CUP$parser$parser,
     java.util.Stack CUP$parser$stack,
     int CUP$parser$top,
     parser parser)
     throws java.lang.Exception {
   java_cup.runtime.Symbol CUP$parser$result;
   // c_external_declaration ::= n_module
   {
     ExternalDeclaration RESULT = null;
     Module d = (Module) ((java_cup.runtime.Symbol) CUP$parser$stack.peek()).value;
     parser.scopes().clean();
     RESULT = d;
     CUP$parser$result =
         parser
             .getSymbolFactory()
             .newSymbol(
                 "c_external_declaration",
                 136,
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 RESULT);
   }
   return CUP$parser$result;
 }
Exemple #21
0
 public final java_cup.runtime.Symbol do_action(
     int CUP$parser$act_num,
     java_cup.runtime.lr_parser CUP$parser$parser,
     java.util.Stack CUP$parser$stack,
     int CUP$parser$top,
     parser parser)
     throws java.lang.Exception {
   java_cup.runtime.Symbol CUP$parser$result;
   // n_module_implementation ::= NK_IMPLEMENTATION c_curly_open_recycle n_external_definitions
   // c_curly_close
   {
     NesCExternalDefinitionList RESULT = null;
     Token rl =
         (Token) ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 3)).value;
     NesCExternalDefinitionList e =
         (NesCExternalDefinitionList)
             ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 1)).value;
     Token rr = (Token) ((java_cup.runtime.Symbol) CUP$parser$stack.peek()).value;
     RESULT = e;
     RESULT.setRanges(rl, rr);
     CUP$parser$result =
         parser
             .getSymbolFactory()
             .newSymbol(
                 "n_module_implementation",
                 177,
                 ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 3)),
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 RESULT);
   }
   return CUP$parser$result;
 }
Exemple #22
0
 public final java_cup.runtime.Symbol do_action(
     int CUP$parser$act_num,
     java_cup.runtime.lr_parser CUP$parser$parser,
     java.util.Stack CUP$parser$stack,
     int CUP$parser$top,
     parser parser)
     throws java.lang.Exception {
   java_cup.runtime.Symbol CUP$parser$result;
   // c_compound_literal_head ::= c_round_open c_round_close
   {
     CompoundLiteral RESULT = null;
     Token rl =
         (Token) ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 1)).value;
     Token rr = (Token) ((java_cup.runtime.Symbol) CUP$parser$stack.peek()).value;
     RESULT =
         new CompoundLiteral(
             parser.missing("compound literal", "type name", rl.getLeft(), rr.getRight()), null);
     CUP$parser$result =
         parser
             .getSymbolFactory()
             .newSymbol(
                 "c_compound_literal_head",
                 34,
                 ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 1)),
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 RESULT);
   }
   return CUP$parser$result;
 }
Exemple #23
0
 public final java_cup.runtime.Symbol do_action(
     int CUP$parser$act_num,
     java_cup.runtime.lr_parser CUP$parser$parser,
     java.util.Stack CUP$parser$stack,
     int CUP$parser$top,
     parser parser)
     throws java.lang.Exception {
   java_cup.runtime.Symbol CUP$parser$result;
   // n_datadef_list ::= n_datadef
   {
     DatadefList RESULT = null;
     Datadef i = (Datadef) ((java_cup.runtime.Symbol) CUP$parser$stack.peek()).value;
     RESULT = new DatadefList(i);
     CUP$parser$result =
         parser
             .getSymbolFactory()
             .newSymbol(
                 "n_datadef_list",
                 151,
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 RESULT);
   }
   return CUP$parser$result;
 }
Exemple #24
0
 public final java_cup.runtime.Symbol do_action(
     int CUP$parser$act_num,
     java_cup.runtime.lr_parser CUP$parser$parser,
     java.util.Stack CUP$parser$stack,
     int CUP$parser$top,
     parser parser)
     throws java.lang.Exception {
   java_cup.runtime.Symbol CUP$parser$result;
   // c_constant ::= c_enumeration_constant
   {
     Expression RESULT = null;
     EnumerationConstant e =
         (EnumerationConstant) ((java_cup.runtime.Symbol) CUP$parser$stack.peek()).value;
     RESULT = e;
     CUP$parser$result =
         parser
             .getSymbolFactory()
             .newSymbol(
                 "c_constant",
                 4,
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 RESULT);
   }
   return CUP$parser$result;
 }
Exemple #25
0
 public final java_cup.runtime.Symbol do_action(
     int CUP$parser$act_num,
     java_cup.runtime.lr_parser CUP$parser$parser,
     java.util.Stack CUP$parser$stack,
     int CUP$parser$top,
     parser parser)
     throws java.lang.Exception {
   java_cup.runtime.Symbol CUP$parser$result;
   // c_direct_declarator_no_typedef_name ::= c_direct_declarator_no_typedef_name P_RECT_OPEN
   // c_assignment_expression P_RECT_CLOSE
   {
     Declarator RESULT = null;
     Declarator d =
         (Declarator)
             ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 3)).value;
     Expression a =
         (Expression)
             ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 1)).value;
     Token rr = (Token) ((java_cup.runtime.Symbol) CUP$parser$stack.peek()).value;
     ArrayDeclarator result = new ArrayDeclarator(d, null, a);
     RESULT = result;
     result.setRight(rr.getRight());
     CUP$parser$result =
         parser
             .getSymbolFactory()
             .newSymbol(
                 "c_direct_declarator_no_typedef_name",
                 104,
                 ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 3)),
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 RESULT);
   }
   return CUP$parser$result;
 }
Exemple #26
0
 public final java_cup.runtime.Symbol do_action(
     int CUP$parser$act_num,
     java_cup.runtime.lr_parser CUP$parser$parser,
     java.util.Stack CUP$parser$stack,
     int CUP$parser$top,
     parser parser)
     throws java.lang.Exception {
   java_cup.runtime.Symbol CUP$parser$result;
   // c_asm_args_list ::= c_asm_args_list P_COLON c_asm_arg_list
   {
     ASMArgumentsList RESULT = null;
     ASMArgumentsList l =
         (ASMArgumentsList)
             ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 2)).value;
     ASMArgumentList a =
         (ASMArgumentList) ((java_cup.runtime.Symbol) CUP$parser$stack.peek()).value;
     RESULT = l;
     l.add(a);
     CUP$parser$result =
         parser
             .getSymbolFactory()
             .newSymbol(
                 "c_asm_args_list",
                 28,
                 ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 2)),
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 RESULT);
   }
   return CUP$parser$result;
 }
Exemple #27
0
  public final java_cup.runtime.Symbol do_action(
      int CUP$parser$act_num,
      java_cup.runtime.lr_parser CUP$parser$parser,
      java.util.Stack CUP$parser$stack,
      int CUP$parser$top,
      parser parser)
      throws java.lang.Exception {
    java_cup.runtime.Symbol CUP$parser$result;
    // c_all_no_curly ::= c_all_no_curly NK_TASK
    {
      Object RESULT = null;

      CUP$parser$result =
          parser
              .getSymbolFactory()
              .newSymbol(
                  "c_all_no_curly",
                  200,
                  ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 1)),
                  ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                  RESULT);
    }
    return CUP$parser$result;
  }
Exemple #28
0
 public final java_cup.runtime.Symbol do_action(
     int CUP$parser$act_num,
     java_cup.runtime.lr_parser CUP$parser$parser,
     java.util.Stack CUP$parser$stack,
     int CUP$parser$top,
     parser parser)
     throws java.lang.Exception {
   java_cup.runtime.Symbol CUP$parser$result;
   // n_configuration ::= NK_GENERIC NK_CONFIGURATION error n_component_parameters
   // n_attributes_no_init n_uses_or_provides_block
   {
     Configuration RESULT = null;
     Token rl =
         (Token) ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 5)).value;
     Token rr =
         (Token) ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 4)).value;
     TemplateParameterList p =
         (TemplateParameterList)
             ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 2)).value;
     AttributeList a =
         (AttributeList)
             ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 1)).value;
     AccessList u = (AccessList) ((java_cup.runtime.Symbol) CUP$parser$stack.peek()).value;
     RESULT =
         new Configuration(
             true,
             parser.errorNode("configuration", "identifier"),
             p,
             a,
             u,
             parser.missing("configuration", "implementation", u.getRange().getRight()));
     RESULT.setLeft(rl.getLeft());
     CUP$parser$result =
         parser
             .getSymbolFactory()
             .newSymbol(
                 "n_configuration",
                 180,
                 ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 5)),
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 RESULT);
   }
   return CUP$parser$result;
 }
Exemple #29
0
 public final java_cup.runtime.Symbol do_action(
     int CUP$parser$act_num,
     java_cup.runtime.lr_parser CUP$parser$parser,
     java.util.Stack CUP$parser$stack,
     int CUP$parser$top,
     parser parser)
     throws java.lang.Exception {
   java_cup.runtime.Symbol CUP$parser$result;
   // n_configuration ::= NK_CONFIGURATION error n_component_parameters n_uses_or_provides_block
   // n_configuration_implementation
   {
     Configuration RESULT = null;
     Token k =
         (Token) ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 4)).value;
     TemplateParameterList p =
         (TemplateParameterList)
             ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 2)).value;
     AccessList u =
         (AccessList)
             ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 1)).value;
     ConfigurationDeclarationList c =
         (ConfigurationDeclarationList) ((java_cup.runtime.Symbol) CUP$parser$stack.peek()).value;
     RESULT =
         new Configuration(false, parser.errorNode("configuration", "identifier"), p, null, u, c);
     RESULT.setLeft(k.getLeft());
     CUP$parser$result =
         parser
             .getSymbolFactory()
             .newSymbol(
                 "n_configuration",
                 180,
                 ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 4)),
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 RESULT);
   }
   return CUP$parser$result;
 }
Exemple #30
0
 public final java_cup.runtime.Symbol do_action(
     int CUP$parser$act_num,
     java_cup.runtime.lr_parser CUP$parser$parser,
     java.util.Stack CUP$parser$stack,
     int CUP$parser$top,
     parser parser)
     throws java.lang.Exception {
   java_cup.runtime.Symbol CUP$parser$result;
   // n_parameterised_interface ::= n_interface_ref n_parameters n_attributes_no_init c_semicolon
   {
     ASTNode RESULT = null;
     InterfaceReference i =
         (InterfaceReference)
             ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 3)).value;
     IdentifierParameterList p =
         (IdentifierParameterList)
             ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 2)).value;
     AttributeList a =
         (AttributeList)
             ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 1)).value;
     Token rr = (Token) ((java_cup.runtime.Symbol) CUP$parser$stack.peek()).value;
     ParameterizedInterface result = new ParameterizedInterface(i, p, a);
     RESULT = result;
     result.setRight(rr.getRight());
     CUP$parser$result =
         parser
             .getSymbolFactory()
             .newSymbol(
                 "n_parameterised_interface",
                 169,
                 ((java_cup.runtime.Symbol) CUP$parser$stack.elementAt(CUP$parser$top - 3)),
                 ((java_cup.runtime.Symbol) CUP$parser$stack.peek()),
                 RESULT);
   }
   return CUP$parser$result;
 }