/*14:*/ #line 212 "/usr/local//yacco2/grammar-testsuite/testout_prog.w" /*2:*/ #line 54 "/usr/local//yacco2/grammar-testsuite/testout_comments.w" /*3:*/ #line 11 "/usr/local//yacco2/grammar-testsuite/testout_includes.w" #include "testout.h" /*:3*/ #line 55 "/usr/local//yacco2/grammar-testsuite/testout_comments.w" ; #line 1 "/usr/local//yacco2/grammar-testsuite/testout_includes.w" /*:2*//*5:*/ #line 13 "/usr/local//yacco2/grammar-testsuite/testout_prog.w" #define Max_buf_size 2*1024 std::string Holding_file("testout_holding_file.cmd"); std::string To_parse_file; YACCO2_define_trace_variables(); yacco2::TOKEN_GAGGLE JUNK_tokens; yacco2::TOKEN_GAGGLE IP_tokens; yacco2::TOKEN_GAGGLE Error_queue; /*:5*//*7:*/ #line 64 "/usr/local//yacco2/grammar-testsuite/testout_prog.w" void GET_CMD_LINE(int argc,char*argv[] ,const char*Holding ,std::string&File_to_parse ,yacco2::TOKEN_GAGGLE&Errors) { using namespace std; using namespace NS_testout_err_symbols; using namespace yacco2; ofstream ofile; ofile.open(Holding,ios_base::out|ios::trunc); if(!ofile){ CAbs_lr1_sym*sym= new Err_bad_filename(Holding); sym->set_external_file_id(1); sym->set_line_no(1); sym->set_pos_in_line(1); Errors.push_back(*sym); return; } if(argc==1){ char cmd_line[Max_buf_size]; cout<<"Please enter Command line to process: "; cin.get(cmd_line,Max_buf_size,'\n'); ofile< Cmd1_tokens(Holding); ifstream ifile; ifile.open(File_to_parse.c_str()); if(!ifile){ CAbs_lr1_sym*sym= new Err_bad_filename(File_to_parse.c_str()); sym->set_external_file_id(1); sym->set_line_no(1); sym->set_pos_in_line(1); Errors.push_back(*sym); return; } ifile.close(); return; } /*:7*//*8:*/ #line 114 "/usr/local//yacco2/grammar-testsuite/testout_prog.w" void DUMP_ERROR_QUEUE(yacco2::TOKEN_GAGGLE&Errors) { using namespace NS_yacco2_k_symbols; using namespace yacco2; Errors.push_back(*yacco2::PTR_LR1_eog__); Errors.push_back(*yacco2::PTR_LR1_eog__); using namespace NS_testout_err_hdlr; Ctestout_err_hdlr fsm; Parser pass_errors(fsm,&Errors,0); pass_errors.parse(); yacco2::Parallel_threads_shutdown(pass_errors); } /*:8*//*9:*/ #line 148 "/usr/local//yacco2/grammar-testsuite/testout_prog.w" int main(int argc,char*argv[]) { std::cout<<"testout start"< cmd_line(To_parse_file.c_str()); Cpager_1 pager_1_fsm; Parser testout_parse(pager_1_fsm,&cmd_line,&IP_tokens,0,&Error_queue,&JUNK_tokens,0); if(testout_parse.parse()==Parser::erred){ std::cout<<"===============>ERROR OCCURRED"<