4 ms·
You're absolutely technically correct, in the "spherical cow in a vacuum" sense. In reality though, essentially all Go code out there handles errors through the
by Mawr 2y ago
You're absolutely technically correct, in the "spherical cow in a vacuum" sense. In reality though, essentially all Go code out there handles errors through the pattern of checking if the error in a `(value, error)` tuple returned from a function is `nil` or not. That is what the discussion here is about - the way errors are handled in a language in practice, not in theory. Therefore, pedantry.
Basically, discussions have context and I have no intention of prepending 10 disclaimers to every statement I make to preemptively guard against people interpreting my comments as absolutes in a vacuum.
- randomdata 2y agoThat's a lot of pedantry you've got there for someone who claims it is not welcome. Rules for thee, not for me? But, if you'd kindly come back to the topic at hand: > That is what the discussion here is about - the way errors are handled in a language in practice, not in theory. While I'm not entirely convinced that is accurate, I will accept it. Now, how does: - "That said, suggesting adding exceptions to Go is about as reasonable as adding a GC to Zig." Relate to that assertion? What does "suggesting adding exceptions to Go" have to do with a common pattern that has emerged?
- mplewis 2y agoIt’s not simply a common pattern. It is a way of doing things in the community. The stdlib uses it, the libraries use it, and if you do not use it, people will not use your software.
- randomdata 2y agoOkay, but how does that relate to what was said?
- demi56 2y agoYou’re just complaining because the compiler isn’t complaining
- randomdata 2y agoAnd you're panicking because the other commenters haven't helped recover for you. Try as you might, sadly they are not here to catch you. No need to throw a fit over it. You are not as exceptional as you think you are.
- demi56 2y agoDude you tried, there’s no need for 50000 word essay against a sentence
- deleted 2y ago[deleted]
- randomdata 2y agoThe output of software cares not for whether it be a sentence or even just a word. The output of software has no care at all. What lead you to believe otherwise?
- throwaway2037 2y ago"spherical cow in a vacuum" I only learned about this recently. Very funny to me, and appropriately used here. Ref: https://en.wikipedia.org/wiki/Spherical_cow https://en.wikipedia.org/wiki/Spherical_cow