completed refactoring to use new parser