5323 shaares
127 private links
127 private links
Error handling is an integral part of programming, but in many popular languages, it comes as an afterthought.
The godfather of numerous programming dialects, C, never had a dedicated error or exception mechanism in the first place. It is up to the programmer to accurately report whether the function did what it was intended to do, or threw a tantrum—usually by relying on integers. In case of a segmentation fault—well, all bets are off.
This post goes through the experience of the author in the adaptation to the Golang error management workflow.