migrate ebnf2yacc code to new parser base