4 ms·
Certainly, and go already comes pretty close that explicitness via returned errors. At that point, we are down to a style choice between exceptions and error re
by jacobr1 3y ago
Certainly, and go already comes pretty close that explicitness via returned errors. At that point, we are down to a style choice between exceptions and error returns.
Honestly I'm not sure it matters and depends upon other factors being balanced in the ergonomics of the language. I don't see any reason why you couldn't accomplish the objective in either style of language.
My point is that Go today, both as matter of language features and how it tends to be used via communal norms, incentivizes explicit error handling. The parent comment stated, "You are less likely to silently/accidentally drop an exception vs Go's tuple return values" and while I could easily imagine language features that discourage bubbling exceptions ... in practice, I think that tends to be more the norm than explicit handling of tuple returns.