aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJonathan Amsterdam <jba@google.com>2023-07-14 08:23:18 -0400
committerJonathan Amsterdam <jba@google.com>2023-07-14 21:29:53 +0000
commitfe5af1532ab9c749d880c05e0ffe0e17bf874d7f (patch)
tree41f0fef78215dbf6f4b78941eff38b047ba4a3b4
parent847d40d699832a1e054bc08c498548eff6a73ab6 (diff)
downloadgo-fe5af1532ab9c749d880c05e0ffe0e17bf874d7f.tar.gz
go-fe5af1532ab9c749d880c05e0ffe0e17bf874d7f.zip
log/slog: doc commonHandler.handle
Change-Id: Id301b772e472e1cb7cd8bccaa5a13ff7b6f94711 Reviewed-on: https://go-review.googlesource.com/c/go/+/509596 Run-TryBot: Jonathan Amsterdam <jba@google.com> TryBot-Result: Gopher Robot <gobot@golang.org> Reviewed-by: Bryan Mills <bcmills@google.com>
-rw-r--r--src/log/slog/handler.go2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/log/slog/handler.go b/src/log/slog/handler.go
index 8398b928c1..a73983cda3 100644
--- a/src/log/slog/handler.go
+++ b/src/log/slog/handler.go
@@ -253,6 +253,8 @@ func (h *commonHandler) withGroup(name string) *commonHandler {
return h2
}
+// handle is the internal implementation of Handler.Handle
+// used by TextHandler and JSONHandler.
func (h *commonHandler) handle(r Record) error {
state := h.newHandleState(buffer.New(), true, "")
defer state.free()