modify parser method and make first for grammar