modify bugs in grammar file parser