Error handling in Go is uniquely designed to be explicit in the intent. You should return possible errors from functions and check/handle those returns. This, in contrast with other programming languages, might seem verbose and unfriendly, but it isn’t really so. Let’s go over some basic examples and move on to something less trivial.
Non errors
Go actually has a concept of a non-error. It’s a language feature and not something that you could use by writing your own functio...
Published on November 13, 2017 10:00