Refactor lalrparser, add more interfaces