Earlier quoted context omitted.
And for me having worked in both, errors as return values have been hands down better. The complexity added by an entirely different flow control has resulted in far more bugs for me to track down than anything else. Similarly, it's for good reason that there's a whole other class of languages using things like the Result monad over throwing up all over everything. That's not to say that there isn't better code writt…
I'm pretty sure exceptions are better, for a couple of reasons. The first is that the idea all Go programmers reliably propagate or wrap error codes, without losing important context, is not true. One of my first encounters with a serious Go codebase was at a consulting client, where I had a task to use their API. I sent it some input and got back a 500 Internal Server Error, no other info. OK, not ideal, but it was…
> Error handling in Go is tedious and there's no visible indication if you forget to do it or don't do it properly so sometimes it goes AWOL
This is also true, though I would expect teams to fail on linting so I don't share the concern. Is there an equivalent for unchecked exceptions (honest question)?
I'll take your word on the performance being better for exceptions, but I'm less convinced that Go's performance is a significant sticking point for the language.