3 ms·
That's fair! My point is that being forced to check exceptions can be beneficial. Go does not have any mechanism for this. If you want to use a Result/Optional
by shepherdjerred 2y ago
That's fair! My point is that being forced to check exceptions can be beneficial. Go does not have any mechanism for this.
If you want to use a Result/Optional type I think that is way better than exceptions. As long as the compiler can enforce that you are acknowledging (or explicitly ignoring) both the happy and error cases. Ideally the error case for the Result/Optional type would also have an attached stack trace.