The content is good, and it is accurate, but even though defer can be a bit tricky this blog post series seems to literally be describing the entire semantics of "defer" as "gotchas". It's not that tricky!
Re:More Gotchas of Defer in Go, Part II
by inancgumus on Thursday December 21, 2017 @02:40PM
(#15982103)
Well, it depends. Upgoing posts will go deeper on defer.
Re:More Gotchas of Defer in Go, Part II
by inancgumus on Thursday December 21, 2017 @02:42PM
(#15982125)
Thanks! That post definitely a must read.
Btw, the first part was more advanced (but again for beginners and intermediate gophers) -> https://blog.learngoprogramming.com/gotchas-of-defer-in-go-1...
It covers about half of these gotchas by laying out how the defer statement works in plain English. The other half (like how closures work inside loops in Go) are covered elsewhere in the language tour.
I do really like the visualizations! Makes it very clear how these mechanics work.