diff --git a/test/closure2.go b/test/closure2.go index 785e3ae275..8947450561 100644 --- a/test/closure2.go +++ b/test/closure2.go @@ -54,6 +54,7 @@ func main() { } func() { tmp = w // force capture of w, but do not write to it yet + _ = tmp func() { func() { w++ // write in a nested closure