15 ms·
Interfaces require casting and hurt performance, though. You could come up with `Either` types, but due to the lack of generic structs you'd have to have a who
by the_duke 10y ago
Interfaces require casting and hurt performance, though.
You could come up with `Either` types, but due to the lack of generic structs you'd have to have a whole lot of those.
Interestingly, Rust has basically the same error handling idiom, but verbosity is considerably reduced by the '?' operator (previously the try! macro).
When I was coding in Go, i would have loved that feature. The mind-numbing error checking in go is hugely annoying.
- tokenizerrr 10y ago> When I was coding in Go, i would have loved that feature. The mind-numbing error checking in go is hugely annoying. Ugh. Yes. I really want to love go. No, I really love go. But this is so annoying.