Re:The Zen of Go
by throwaway894345 on Tuesday February 25, 2020 @07:26PM
(#22419079)
I do wish Go would adopt sum types, but in practice errors like you describe are vanishingly rare. It’s mostly a theoretical problem.
Regardless, the fundamental point stands. Using tuples to return “meaningless” values alongside errors allows developers to mistakenly use those meaningless values.