]> Cypherpunks.ru repositories - gostls13.git/commitdiff
log/slog: fix method name in docs
authorKevin Burke <kevin@burke.dev>
Tue, 7 Nov 2023 21:43:23 +0000 (13:43 -0800)
committerJonathan Amsterdam <jba@google.com>
Wed, 8 Nov 2023 16:30:56 +0000 (16:30 +0000)
My hunch is the method was renamed during the development process but
the code comment was not updated to match.

Change-Id: Ib7aafc863f82a6bbe09e68dc3c5e087e16f228a9
Reviewed-on: https://go-review.googlesource.com/c/go/+/540536
Reviewed-by: Jonathan Amsterdam <jba@google.com>
Reviewed-by: Damien Neil <dneil@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>

src/log/slog/record.go

index 8afe253bc83389416943ac97f2b762f36523fe20..97c87019a6aff5bbee9a96c4084ab815f0737f66 100644 (file)
@@ -193,7 +193,7 @@ type Source struct {
        Line int    `json:"line"`
 }
 
-// attrs returns the non-zero fields of s as a slice of attrs.
+// group returns the non-zero fields of s as a slice of attrs.
 // It is similar to a LogValue method, but we don't want Source
 // to implement LogValuer because it would be resolved before
 // the ReplaceAttr function was called.