paularmstrong/swig — pull request #131 by nsaun (2012-10-25 05:07:26+00:00)
Title: Fix for allowError = false resulting in incorrect error reporting

Added fix for an incorrect error message getting generated when allowError was set to false and the extended file failed compilation. Errors don't get propagated up to derived files, so the correct error message is not shown.

To reproduce:
-Set allowError to false on the top-level Swig configuration options. This will exercise the path where compileFile doesn't intercept exceptions.
-Compile a file which calls out a non-existent file (e.g. {% extends "invalid.html" %})
-This will result in an unintended code path getting traversed and the file failure never making it to the error output.

This pull request includes a fix for this case which forces compileFile to carry errors up to the derived file's compilation. This resolves this issue and will result in the correct error message getting reported.