4 ms·
Just because the languages en vogue right now use result tuples does not invalidate exception handling altogether, no matter how strongly you may prefer them. I
by 9dev 2y ago
Just because the languages en vogue right now use result tuples does not invalidate exception handling altogether, no matter how strongly you may prefer them. It’s tradeoffs all the way down.
- bedobi 2y agoWhat a shallow critique. Object oriented error handling (which is what returning objects instead of exceptions is) isn’t used because it’s trendy, it’s used because it’s objectively (badumtish) better.
- 9dev 2y agoYou didn’t get the point, then. It isn’t objectively better, but some people argue it is. Having an opinion doesn’t necessarily mean it’s true.
- stoperaticless 2y agoThe fact that exceptions are used is testament that they do have some utility. Same can be said of either/result. ‘Objectively better’ is appropriate either in very simple choice scenario, or in a case where one is throwing away ones integrity.