Hacker News new | ask | show | jobs
by alphaalpha101 3218 days ago
That's exactly what you have to do in Rust anyway though.

Except instead of just writing `throws SomeError` in the declaration line of the function, you have to annotate virtually every line of your function with `?` and wrap the return line in `Ok(...)`.

1 comments

The ? RFC did include a "catch" construct, and there's been some discussion about doing something more like "throws SomeError." We'll see!
It's far too late for "we'll see".