Improved exceptions and reporting exceptions for command-line compiler.

You are right, and the next commit will partly improve that. Yet I don't want to catch just Exception here (I'm not sure if you suggested that), since any exception apart from ParserError is not expected here and should perhaps be handled differently. The situation is similar below.