2 ms·
OK, so I don't think we're disagreeing at all then, except possibly about the difficulty / commonality of writing the correct exception handling code.
by NateDad 12y ago
OK, so I don't think we're disagreeing at all then, except possibly about the difficulty / commonality of writing the correct exception handling code.
- dragonwriter 12y agoI think its difficult to do right and frequently done wrong. I'm just not completely convinced that Go makes that significantly better (there is an advantage to being more explicit, but it comes at the cost of making what is usually right -- propagating errors back up the chain -- easy to omit, and lots of sample code silently swallows errors to avoid distraction, which has value for what it is trying to teach but might incidentally also breed bad habits.) It probably makes the most common mistakes in error handling in Go different than with languages where the preferred method is more "traditional" exceptions, because the easiest mistakes to make are different.