by zik · 13y ago · 0 comments
http://stackoverflow.com/questions/1853243/c-do-you-really-w...
Some more reasons why exceptions are problematic:
http://mortoray.com/2012/04/02/everything-wrong-with-excepti...
Go's choice I think is very well considered. If reliability is important to you then I believe handling errors explicitly leads to clearer, more correct code.
But writing exception-safe code IS trivial, in basically any language except C++. Garbage collection is all you need in most cases, and try-with-resources/RAII/etc takes care of closing I/O.
Note that Go still needs defer() to reliably take care of the latter, so it's not clear to me what is gained by the omission (or rather, strong deprecation) of exceptions.