/*
 File: T_enum_phrase_thsym.cpp
 Date and Time: Fri Jan 30 18:55:26 2015 
*/
#include "T_enum_phrase_th.h"
using namespace NS_yacco2_T_enum;// enumerate
using namespace NS_yacco2_err_symbols;// error symbols
using namespace NS_yacco2_k_symbols;// lrk 
using namespace NS_yacco2_terminals;// terminals
using namespace NS_yacco2_characters;// rc 
using namespace yacco2;// yacco2 library
using namespace NS_T_enum_phrase_th;// grammar's ns
// first set terminals
yacco2::THR _YACCO2_CALL_TYPE
NS_T_enum_phrase_th::TH_T_enum_phrase_th(yacco2::Parser* Caller_pp){
  yacco2::Thread_entry& pp_thread_entry = ITH_T_enum_phrase_th;
  NS_T_enum_phrase_th::CT_enum_phrase_th CT_enum_phrase_th_;// parallel-parser's parse table
#define ssPARSE_TABLE CT_enum_phrase_th_
#include "wpp_core.h"
}
THR_result _YACCO2_CALL_TYPE
NS_T_enum_phrase_th::PROC_TH_T_enum_phrase_th(yacco2::Parser* Caller_pp){
  char called_proc_name[] = "PROC_TH_T_enum_phrase_th";
  static bool one_time(false);
  static NS_T_enum_phrase_th::CT_enum_phrase_th* NS_T_enum_phrase_th_CT_enum_phrase_th_(0);// parallel-parser's fsm table
  static Parser* NS_T_enum_phrase_th_CT_enum_phrase_th_parser(0);
  Parser* proc_parser(0);
  if(one_time == false){
    one_time = true;
    NS_T_enum_phrase_th_CT_enum_phrase_th_ = new NS_T_enum_phrase_th::CT_enum_phrase_th();// parallel-parser's fsm table
    NS_T_enum_phrase_th_CT_enum_phrase_th_parser = new Parser(*NS_T_enum_phrase_th_CT_enum_phrase_th_,Caller_pp);
  }
 proc_parser = NS_T_enum_phrase_th_CT_enum_phrase_th_parser;
#include "wproc_pp_core.h"
}
void 
CT_enum_phrase_th::reduce_rhs_of_rule
    (yacco2::UINT Sub_rule_no,yacco2::Rule_s_reuse_entry** Recycled_rule){
   int reducing_rule = rhs_to_rules_mapping_[Sub_rule_no];
   Per_rule_s_reuse_table* rule_reuse_tbl_ptr = 
        fsm_rules_reuse_table.per_rule_s_table_[reducing_rule];
   Rule_s_reuse_entry* re(0);
   find_a_recycled_rule(rule_reuse_tbl_ptr,&re);
   (*Recycled_rule) = re;
   fnd_re: switch (Sub_rule_no){
    case rhs1_RT_enum_phrase_:{
       RT_enum_phrase* sym;
     if(re->rule_ == 0){
       sym = new RT_enum_phrase(parser__);
       re->rule_ = sym;
     }else{
       sym = (RT_enum_phrase*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 7;
    

     sym->sr1();
     return;}
    case rhs1_Ropen_par_:{
       Ropen_par* sym;
     if(re->rule_ == 0){
       sym = new Ropen_par(parser__);
       re->rule_ = sym;
     }else{
       sym = (Ropen_par*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 1;
    

     sym->sr1();
     return;}
    case rhs2_Ropen_par_:{
       Ropen_par* sym;
     if(re->rule_ == 0){
       sym = new Ropen_par(parser__);
       re->rule_ = sym;
     }else{
       sym = (Ropen_par*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 1;
    

     return;}
    case rhs1_Rclose_par_:{
       Rclose_par* sym;
     if(re->rule_ == 0){
       sym = new Rclose_par(parser__);
       re->rule_ = sym;
     }else{
       sym = (Rclose_par*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 1;
    

     sym->sr1();
     return;}
    case rhs2_Rclose_par_:{
       Rclose_par* sym;
     if(re->rule_ == 0){
       sym = new Rclose_par(parser__);
       re->rule_ = sym;
     }else{
       sym = (Rclose_par*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 1;
    

     return;}
    case rhs1_Rparameters_:{
       Rparameters* sym;
     if(re->rule_ == 0){
       sym = new Rparameters(parser__);
       re->rule_ = sym;
     }else{
       sym = (Rparameters*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 5;
    

     return;}
    case rhs1_Rfilename_phrase_:{
       Rfilename_phrase* sym;
     if(re->rule_ == 0){
       sym = new Rfilename_phrase(parser__);
       re->rule_ = sym;
     }else{
       sym = (Rfilename_phrase*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 3;
    

     return;}
    case rhs1_Rfilename_:{
       Rfilename* sym;
     if(re->rule_ == 0){
       sym = new Rfilename(parser__);
       re->rule_ = sym;
     }else{
       sym = (Rfilename*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 2;
    

     return;}
    case rhs2_Rfilename_:{
       Rfilename* sym;
     if(re->rule_ == 0){
       sym = new Rfilename(parser__);
       re->rule_ = sym;
     }else{
       sym = (Rfilename*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 2;
    

     sym->sr2();
     return;}
    case rhs3_Rfilename_:{
       Rfilename* sym;
     if(re->rule_ == 0){
       sym = new Rfilename(parser__);
       re->rule_ = sym;
     }else{
       sym = (Rfilename*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 1;
    

     sym->sr3();
     return;}
    case rhs1_Rfilename_id_:{
       Rfilename_id* sym;
     if(re->rule_ == 0){
       sym = new Rfilename_id(parser__);
       re->rule_ = sym;
     }else{
       sym = (Rfilename_id*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 2;
    

     sym->sr1();
     return;}
    case rhs2_Rfilename_id_:{
       Rfilename_id* sym;
     if(re->rule_ == 0){
       sym = new Rfilename_id(parser__);
       re->rule_ = sym;
     }else{
       sym = (Rfilename_id*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 1;
    

     sym->sr2();
     return;}
    case rhs1_Rnamespace_phrase_:{
       Rnamespace_phrase* sym;
     if(re->rule_ == 0){
       sym = new Rnamespace_phrase(parser__);
       re->rule_ = sym;
     }else{
       sym = (Rnamespace_phrase*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 5;
    

     return;}
    case rhs2_Rnamespace_phrase_:{
       Rnamespace_phrase* sym;
     if(re->rule_ == 0){
       sym = new Rnamespace_phrase(parser__);
       re->rule_ = sym;
     }else{
       sym = (Rnamespace_phrase*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 1;
    

     sym->sr2();
     return;}
    case rhs1_Rnamespace_:{
       Rnamespace* sym;
     if(re->rule_ == 0){
       sym = new Rnamespace(parser__);
       re->rule_ = sym;
     }else{
       sym = (Rnamespace*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 2;
    

     return;}
    case rhs2_Rnamespace_:{
       Rnamespace* sym;
     if(re->rule_ == 0){
       sym = new Rnamespace(parser__);
       re->rule_ = sym;
     }else{
       sym = (Rnamespace*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 2;
    

     sym->sr2();
     return;}
    case rhs3_Rnamespace_:{
       Rnamespace* sym;
     if(re->rule_ == 0){
       sym = new Rnamespace(parser__);
       re->rule_ = sym;
     }else{
       sym = (Rnamespace*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 1;
    

     sym->sr3();
     return;}
    case rhs1_Rnamespace_id_:{
       Rnamespace_id* sym;
     if(re->rule_ == 0){
       sym = new Rnamespace_id(parser__);
       re->rule_ = sym;
     }else{
       sym = (Rnamespace_id*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 2;
    

     sym->sr1();
     return;}
    case rhs2_Rnamespace_id_:{
       Rnamespace_id* sym;
     if(re->rule_ == 0){
       sym = new Rnamespace_id(parser__);
       re->rule_ = sym;
     }else{
       sym = (Rnamespace_id*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 1;
    

     sym->sr2();
     return;}
    case rhs1_Rk_defs_phrase_:{
       Rk_defs_phrase* sym;
     if(re->rule_ == 0){
       sym = new Rk_defs_phrase(parser__);
       re->rule_ = sym;
     }else{
       sym = (Rk_defs_phrase*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 5;
    

     return;}
    case rhs1_Rconstant_epi_defs_:{
       Rconstant_epi_defs* sym;
     if(re->rule_ == 0){
       sym = new Rconstant_epi_defs(parser__);
       re->rule_ = sym;
     }else{
       sym = (Rconstant_epi_defs*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 2;
    

     return;}
    case rhs2_Rconstant_epi_defs_:{
       Rconstant_epi_defs* sym;
     if(re->rule_ == 0){
       sym = new Rconstant_epi_defs(parser__);
       re->rule_ = sym;
     }else{
       sym = (Rconstant_epi_defs*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 0;
    

     return;}
    case rhs1_Rconstant_defs_:{
       Rconstant_defs* sym;
     if(re->rule_ == 0){
       sym = new Rconstant_defs(parser__);
       re->rule_ = sym;
     }else{
       sym = (Rconstant_defs*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 2;
    

     sym->sr1();
     return;}
    case rhs2_Rconstant_defs_:{
       Rconstant_defs* sym;
     if(re->rule_ == 0){
       sym = new Rconstant_defs(parser__);
       re->rule_ = sym;
     }else{
       sym = (Rconstant_defs*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 2;
    

     sym->sr2();
     return;}
    case rhs1_Rconstant_defs_code_:{
       Rconstant_defs_code* sym;
     if(re->rule_ == 0){
       sym = new Rconstant_defs_code(parser__);
       re->rule_ = sym;
     }else{
       sym = (Rconstant_defs_code*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 2;
    

     sym->sr1();
     return;}
    case rhs2_Rconstant_defs_code_:{
       Rconstant_defs_code* sym;
     if(re->rule_ == 0){
       sym = new Rconstant_defs_code(parser__);
       re->rule_ = sym;
     }else{
       sym = (Rconstant_defs_code*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 2;
    

     sym->sr2();
     return;}
    case rhs3_Rconstant_defs_code_:{
       Rconstant_defs_code* sym;
     if(re->rule_ == 0){
       sym = new Rconstant_defs_code(parser__);
       re->rule_ = sym;
     }else{
       sym = (Rconstant_defs_code*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 1;
    

     sym->sr3();
     return;}
    case rhs1_Rclose_brace_:{
       Rclose_brace* sym;
     if(re->rule_ == 0){
       sym = new Rclose_brace(parser__);
       re->rule_ = sym;
     }else{
       sym = (Rclose_brace*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 1;
    

     sym->sr1();
     return;}
    case rhs2_Rclose_brace_:{
       Rclose_brace* sym;
     if(re->rule_ == 0){
       sym = new Rclose_brace(parser__);
       re->rule_ = sym;
     }else{
       sym = (Rclose_brace*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 1;
    

     return;}
    case rhs1_Rlint_:{
       Rlint* sym;
     if(re->rule_ == 0){
       sym = new Rlint(parser__);
       re->rule_ = sym;
     }else{
       sym = (Rlint*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 2;
    

     return;}
    case rhs2_Rlint_:{
       Rlint* sym;
     if(re->rule_ == 0){
       sym = new Rlint(parser__);
       re->rule_ = sym;
     }else{
       sym = (Rlint*)re->rule_;
     }
    // no rule's constructor directive
     (*Recycled_rule)->rule_ = sym;
     sym->rule_info__.rhs_no_of_parms__ = 0;
    

     return;}
    default: return;
   }
}
