4 ms·
> No, what you are showing is how an API designer could enforce a particular API design decision. That's fine, but what I'm talking about is how a language desi
by catnaroek 10y ago
> No, what you are showing is how an API designer could enforce a particular API design decision. That's fine, but what I'm talking about is how a language designer could enforce the invariants of a particular error handling concept. I think that sum types alone are not sufficient to do that.
Different APIs have different ways to handle errors. The language designer's job is to allow the programmer to express his intention in the most precise way possible.