peelonet / tempearly

Minimal scripting language / templating engine.
2 stars 0 forks source link

Throw statement. #86

Closed RauliL closed 9 years ago

RauliL commented 9 years ago
  1. Add support for throw statement which can be used to throw exceptions. Not very useful until we have a try exception which can catch them.

    throw statement can be used to throw new exceptions or previouly caught exceptions. Only objects which are instance of Exception class can be thrown, otherwise an TypeError is thrown.

  2. Add support for Interpreter class to track caught exceptions, alongside with uncaught exceptions. Required for throw statement.
  3. Fix minor yet annoying bugs where the number of required arguments was not properly converted to string in error messages.