Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Exceptions are second only to proper return types for error handling such as Result<T, E> or Option<T>.

And in order to have those you have to have generics. Once you have generics result types can be used for 99% if error handling.



No, because you are still bubbling these 17 stack frames, as OP was (rightfully) complaining about.

The only downside of exceptions is the loss of equational reasoning, really.

But for everything else, they are a superior approach to result values.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: