/*
 File: rules_phrase_th.h
 Date and Time: Fri Jan 30 18:55:23 2015 
*/
#ifndef __rules_phrase_th_h__
#define __rules_phrase_th_h__ 1
#include "yacco2.h"
#include "yacco2_T_enumeration.h"
#include "yacco2_k_symbols.h"
#include "yacco2_err_symbols.h"
#include "yacco2_terminals.h"
#include "yacco2_characters.h"

#include "ws.h"
#include "eol.h"
#include "c_comments.h"
#include "cweb_or_c_k.h"

#include "rule_def_phrase.h"
#include "o2_externs.h"
  
extern yacco2::Thread_entry ITH_rules_phrase_th;

extern yacco2::State S1_Crules_phrase_th;
namespace NS_rules_phrase_th {
yacco2::THR _YACCO2_CALL_TYPE
TH_rules_phrase_th(yacco2::Parser* Caller);// called thread
yacco2::THR_result _YACCO2_CALL_TYPE
PROC_TH_rules_phrase_th(yacco2::Parser* Caller);// called thread's twin the procedure
using namespace NS_yacco2_T_enum;// enumerate
using namespace yacco2;
struct fsm_rules_reuse_table_type{
 fsm_rules_reuse_table_type();
 int no_rules_entries_;
 Per_rule_s_reuse_table* per_rule_s_table_[11];
};
class Crules_phrase_th: public yacco2::CAbs_fsm {
 public:
  enum rules_and_subrules{
   start_of_rule_list = NS_yacco2_T_enum::T_Enum::sum_total_T
   ,R_Rrules_phrase_ = 569//start_of_rule_list + 0
    ,rhs1_Rrules_phrase_ = 1
   ,R_Rrule_defs_phrase_ = 570//start_of_rule_list + 2
    ,rhs1_Rrule_defs_phrase_ = 2
   ,R_Rrule_defs_ = 571//start_of_rule_list + 4
    ,rhs1_Rrule_defs_ = 3
    ,rhs2_Rrule_defs_ = 4
   ,R_Rrule_def_ = 572//start_of_rule_list + 6
    ,rhs1_Rrule_def_ = 5
    ,rhs2_Rrule_def_ = 6
    ,rhs3_Rrule_def_ = 7
   ,R_Rrule_def1_ = 573//start_of_rule_list + 8
    ,rhs1_Rrule_def1_ = 8
    ,rhs2_Rrule_def1_ = 9
   ,R_Ropen_brace_ = 574//start_of_rule_list + 10
    ,rhs1_Ropen_brace_ = 10
    ,rhs2_Ropen_brace_ = 11
   ,R_Rclose_brace_ = 575//start_of_rule_list + 12
    ,rhs1_Rclose_brace_ = 12
    ,rhs2_Rclose_brace_ = 13
   ,R_Rlint_or_cweb_or_error_ = 576//start_of_rule_list + 14
    ,rhs1_Rlint_or_cweb_or_error_ = 14
    ,rhs2_Rlint_or_cweb_or_error_ = 15
    ,rhs3_Rlint_or_cweb_or_error_ = 16
   ,R_Rlint_or_cweb_ = 577//start_of_rule_list + 16
    ,rhs1_Rlint_or_cweb_ = 17
    ,rhs2_Rlint_or_cweb_ = 18
   ,R_Rfluffs_or_cweb_ = 578//start_of_rule_list + 18
    ,rhs1_Rfluffs_or_cweb_ = 19
    ,rhs2_Rfluffs_or_cweb_ = 20
   ,R_Rfluff_or_cweb_ = 579//start_of_rule_list + 20
    ,rhs1_Rfluff_or_cweb_ = 21
    ,rhs2_Rfluff_or_cweb_ = 22
    ,rhs3_Rfluff_or_cweb_ = 23
    ,rhs4_Rfluff_or_cweb_ = 24
    ,rhs5_Rfluff_or_cweb_ = 25
  };
  //no of la sets = 6
  //no of states = 36
  Crules_phrase_th();
  ~Crules_phrase_th();
  void op();
  bool failed();
  void reduce_rhs_of_rule
      (yacco2::UINT Sub_rule_no,yacco2::Rule_s_reuse_entry** Recycled_rule);
  fsm_rules_reuse_table_type fsm_rules_reuse_table;
  static int rhs_to_rules_mapping_[26];
  
    public:
    T_rules_phrase* rules_phrase_;
    AST* end_rules_t_;
  
 };
struct Rrules_phrase;
struct Rrule_defs_phrase;
struct Rrule_defs;
struct Rrule_def;
struct Rrule_def1;
struct Ropen_brace;
struct Rclose_brace;
struct Rlint_or_cweb_or_error;
struct Rlint_or_cweb;
struct Rfluffs_or_cweb;
struct Rfluff_or_cweb;
struct Rrules_phrase:public yacco2::CAbs_lr1_sym {
  Rrules_phrase(yacco2::Parser* P);
  public:
  void sr1();
};

struct Rrule_defs_phrase:public yacco2::CAbs_lr1_sym {
  Rrule_defs_phrase(yacco2::Parser* P);
  public:
};

struct Rrule_defs:public yacco2::CAbs_lr1_sym {
  Rrule_defs(yacco2::Parser* P);
  public:
};

struct Rrule_def:public yacco2::CAbs_lr1_sym {
  Rrule_def(yacco2::Parser* P);
  public:
  void sr1();
  void sr2();
  void sr3();
};

struct Rrule_def1:public yacco2::CAbs_lr1_sym {
  Rrule_def1(yacco2::Parser* P);
  public:
  void sr1();
  void sr2();
};

struct Ropen_brace:public yacco2::CAbs_lr1_sym {
  Ropen_brace(yacco2::Parser* P);
  public:
  void sr1();
};

struct Rclose_brace:public yacco2::CAbs_lr1_sym {
  Rclose_brace(yacco2::Parser* P);
  public:
  void sr1();
};

struct Rlint_or_cweb_or_error:public yacco2::CAbs_lr1_sym {
  Rlint_or_cweb_or_error(yacco2::Parser* P);
  public:
  void sr2();
};

struct Rlint_or_cweb:public yacco2::CAbs_lr1_sym {
  Rlint_or_cweb(yacco2::Parser* P);
  public:
};

struct Rfluffs_or_cweb:public yacco2::CAbs_lr1_sym {
  Rfluffs_or_cweb(yacco2::Parser* P);
  public:
};

struct Rfluff_or_cweb:public yacco2::CAbs_lr1_sym {
  Rfluff_or_cweb(yacco2::Parser* P);
  public:
  void sr2();
  void sr3();
  void sr4();
};

} // end of namespace

#endif
