Circular wisdom – A personal note
-
Once upon a time, error handling in code was simple: just good old if-else checks. No drama, no flair.
-
Then came try-catch, promoted as a cleaner, more elegant way to handle errors. And it quickly became the new standard in many languages.
-
Fast forward a few decades, and the creators of Go took a step back and basically said, "Actually... that old if-else style is kinda better. More explicit. Easier to follow."
So they left try-catch out entirely.
-
However, for critical failures Go still sticks to "try-catch"-like mechanism, just under a different name: "panic and recover".
So... what the heck is going on? 😄
These "great" minds love to introduces their personal brand of wisdom and masses love to follow them like crazy.
(Still trying to make sense of all this circular wisdom.)