use flex and bison to parse some rules