News for hackers. Stuff that matters.
Re:Where Everything Went Wrong: Error Handling and Error Mes... by simias on Friday February 19, 2021 @01:12PM (#26196028)
That's Go. IMO Rust's approach is vastly saner, since a Result<> type has to be explicitly handled one way or an other. You simply can't access the returned value without unwrapping it.

Of course that leaves function that can fail but don't return any value, but since Result is tagged "must_use" you get a compiler warning if you don't explicitly discard the result with something like `let _ = foo()`.

There are no comments on this comment yet.