Open nbn opened 6 years ago
Related but not quite the same problem: https://github.com/golang/tour/issues/382
I suspect it is a powerful feature, specific to Go and the example is too simplistic.
Although the next page solve part of your problem, it uses Lazy args but it doesn't explain why and how.
Context: https://tour.golang.org/flowcontrol/12
Adding a small paragraph about when defer is useful might make it Easier to understand. Especially why the Args Are not lazy evaluated too.