News for hackers. Stuff that matters.
Re:My Struggles with Rust by hota_mazi on Sunday May 07, 2017 @10:15AM (#14285556)
> Monads are a superior form of error handling than exceptions

No, they're not, not by a long shot. As soon as you start having multiple monads returned by functions and you need to combine them, you need to introduce monad transformers and your code turns into a giant untractactable spaghetti mess.

Exceptions have issues but they are the sanest way to handle errors today.

Re:My Struggles with Rust by marcosdumay on Sunday May 07, 2017 @12:11PM (#14286109)
Well, if you start doing more with monads than error handling, you will have complex interactions between them.

They are still superior for error handling, exceptions would have a more complex interaction with them.

Re:My Struggles with Rust by placeybordeaux on Sunday May 07, 2017 @12:28PM (#14286180)
I honestly found error codes in go to be pretty pragmatic. You pay a small cost on the writing side, but it's very clear and straight forward.