3 ms·
Its not really the same though. The two differences I can think of offhand are that 1) you have to manually pass error up the call stack until you want to handl
by dkersten 14y ago
Its not really the same though. The two differences I can think of offhand are that 1) you have to manually pass error up the call stack until you want to handle it, while exceptions are automatically propagated, meaning that you don't have to remember to do this until the point where you actually want to handle the error and 2) exceptions usually contain a stack trace to where they were raised while this method won't (without additional work anyway), so contextual information is lost.