top | item 33488947

(no title)

typical_gopher | 3 years ago

> C++ and Java exceptions have non-local flow and it's hard to determine what function can throw what, so if you do want to add error handling cases you would have to inspect every function to know if it throws or not

In general I agree with you, but Rust is already having this problem by people making liberal use of unwrap.

discuss

order

potatochup|3 years ago

I haven't seen such a problem with unwrap. Newer people use it but are quickly taught to use Err instead. The only times I use it is unreachable!()