|
|
|
|
|
by vetinari
1504 days ago
|
|
> But to me the superb thing about exceptions, is that error handling can be done where it makes sense. Not necessarily. With exceptions, it is easy to be a cause of error and just throw the exception, then expect up the stack to handle it. Which of course has no idea how, it didn't control the cause in the first place. Forcing error handling as near as where error can happen prevents this. |
|
The Rust/Go approach always makes me laugh. Normally in engineering or anything where reliability matters, panicking is understood to be a bad thing to do and people go through extensive training to ensure they don't do it. Somehow these language communities decided that panicking and giving up on the spot is a smart behaviour.