I have a config file as shown below.(tmp.conf)
[ main ]
e_type=0x1B
My yacc file (test.y) as follows
%%
config_file_sections
: main
;
main
: main_attribute_list
{
e_parse_debug_log_message(E_DEBUG_AT,"Found main_section\n");
e_parse_found_main_section_complete();
}
;
main_attribute_list
: T_E_TYPE number
{
e_parse_debug_log_message(E_DEBUG_AT,"Found main section token T_E_TYPE:\n");
}
;
number
: NUMBER { $$ = $1; }
;
%%
If I pass the file to program it is hanging without any output.My question is the grammar given above to parse the config file shown above.