From: Jake Bailey Date: Sat, 22 Mar 2025 05:34:52 +0000 (-0700) Subject: testing: remove redundant variable capture from subtest example X-Git-Tag: go1.25rc1~620 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=710476495a94892f1a07ca4a253101d1e00b4dec;p=gostls13.git testing: remove redundant variable capture from subtest example Loop variable capturing hasn't been needed like this since Go 1.21; remove it from the example. Change-Id: I231dcfdb57832e32d524f156a605ba36d1c9d6d9 Reviewed-on: https://go-review.googlesource.com/c/go/+/660176 Reviewed-by: Alan Donovan Auto-Submit: Alan Donovan LUCI-TryBot-Result: Go LUCI Reviewed-by: Dmitri Shuralyov --- diff --git a/src/testing/testing.go b/src/testing/testing.go index 471046e89d..5b0a33f28d 100644 --- a/src/testing/testing.go +++ b/src/testing/testing.go @@ -345,7 +345,6 @@ // // func TestGroupedParallel(t *testing.T) { // for _, tc := range tests { -// tc := tc // capture range variable // t.Run(tc.Name, func(t *testing.T) { // t.Parallel() // ...