Refactoring for failed parsing, need to find a way to report file name.