Report parse errors with template filenames

Closes #492