Exit from src/compiler.js with a nonzero return code on exception. Replaces #2453.
Revice src/compiler.js to try process.exit() only if running in node. Make the compiler error more user friendly along the lines of #2497.
Merge pull request #2497 from juj/compiler_nonzero_exit

Exit from src/compiler.js with a nonzero return code on exception.