3 ms·
Correct me if I'm wrong, but I believe with sum types you can chain together multiple calls then pattern match once at the end. In Go you have to check at each
by jshen 12y ago
Correct me if I'm wrong, but I believe with sum types you can chain together multiple calls then pattern match once at the end. In Go you have to check at each call.
- burntsushi 12y agoIf you have an unusual amount of error handling cluttering up your code in Go, then you can use `panic` (with `defer` and `recover` to convert panics to errors in the public interface).