]> Cypherpunks repositories - gostls13.git/commit
log/slog: add json struct tags to Source
authorJonathan Amsterdam <jba@google.com>
Tue, 9 May 2023 20:22:09 +0000 (16:22 -0400)
committerJonathan Amsterdam <jba@google.com>
Wed, 10 May 2023 11:51:03 +0000 (11:51 +0000)
commita3efb96aafc2e8d8a7c7bfc673d59158b692c355
tree258091d42813876d95ed1f37918741f8a5bfe56b
parent2ca4104f0519027c55266d48b47ea16ee4da6915
log/slog: add json struct tags to Source

Add tags to the fields of Source that lower-cases their names for JSON.
The implementation still treats Source specially for performance, but
now the result would be identical if it did not.

Change-Id: I5fd2e500f1a301db62af87be8b877ecd954a26ec
Reviewed-on: https://go-review.googlesource.com/c/go/+/494035
Run-TryBot: Jonathan Amsterdam <jba@google.com>
Reviewed-by: Alan Donovan <adonovan@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
src/log/slog/record.go