Open ConorOBrien-Foxx opened 6 years ago
:| still no throw/catch?
I think there is but error handling is horribly mangled right now
It seems that Attache<foo>Error
should subclass AtError
? Or if it's intentional, why?
@somebody1234 AtError I think is another vestige.
So TryCatch
should really be using a Ruby try
/catch
instead of checking result type now?
yes. result type was an awful idea
Hmm. I guess this might need more examples of code using TryCatch
before deciding on anything
Might want to have, say, TryCatch[code, SyntaxError->DoSomething[_1]]
like many languages have, although really it'd just be sugar for an if
/else
Also... 1. until reaching main? and 2. Until reaching a throw-catch works since current implementation uses ruby's errors, although there is no stacktrace yet. Do you want a stacktrace? If you do, you might want to store the filename in every token or something.
Decide on syntax for raising and rescuing errors in Attache
Make a better system of errors (perhaps by propagating errors raised upwards until reaching main or a throw-catch)