]> Cypherpunks repositories - gostls13.git/commitdiff
doc/next: add release note for vet on Printf(s) with non-const s
authorAlan Donovan <adonovan@google.com>
Tue, 26 Nov 2024 20:31:36 +0000 (15:31 -0500)
committerGopher Robot <gobot@golang.org>
Tue, 26 Nov 2024 20:54:57 +0000 (20:54 +0000)
Fixes #60529
Updates #68545

Change-Id: Ica048e4861f4de22deb7f42a1d76eb3151fee986
Reviewed-on: https://go-review.googlesource.com/c/go/+/631682
Auto-Submit: Alan Donovan <adonovan@google.com>
Reviewed-by: Robert Findley <rfindley@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>

doc/next/3-tools.md

index 5e450c66cedf802d5d7bfe1e47100fe3430739ec..c09cea6d84f2b3fd30305d50ed583616aca15152 100644 (file)
@@ -28,9 +28,14 @@ tests, fuzzers, benchmarks, and examples in test packages, such as
 malformed names, incorrect signatures, or examples that document
 non-existent identifiers. Some of these mistakes may cause tests not
 to run.
-
 This analyzer is among the subset of analyzers that are run by `go test`.
 
+The existing `printf` analyzer now reports a diagnostic for calls of
+the form `fmt.Printf(s)`, where `s` is a non-constant format string,
+with no other arguments. Such calls are nearly always a mistake
+as the value of `s` may contain the `%` symbol; use `fmt.Print` instead.
+See [#60529](/issue/60529).
+
 ### GOCACHEPROG
 
 The `cmd/go` internal binary and test caching mechanism can now be implemented