commit | 30ed42f936dd1a1b651da29fa77c81b80a7b54c6 | [log] [tgz] |
---|---|---|
author | Jonathan Amsterdam <jba@google.com> | Tue Feb 14 08:11:25 2023 -0500 |
committer | Jonathan Amsterdam <jba@google.com> | Thu Feb 23 20:15:15 2023 +0000 |
tree | d7d12335d1dc8c96bc9346a25904d386c3622018 | |
parent | 5e25df0256ebe952dfc512107eeae53d2769287b [diff] |
slog: make context an argument of Handle Pass the Logger's context to the Handler via an argument, instead of by putting it in a field of the Record. This makes Handle look more like Enabled. If it's not problematic to pass the context to the Enabled method (because it isn't used for cancellation and may be nil), then it shouldn't be for the Handle method. Change-Id: I80743acac53926322bbbbe9703ed60d173e597fd Reviewed-on: https://go-review.googlesource.com/c/exp/+/467797 TryBot-Result: Gopher Robot <gobot@golang.org> Reviewed-by: Alan Donovan <adonovan@google.com> Run-TryBot: Jonathan Amsterdam <jba@google.com>
This subrepository holds experimental and deprecated (in the old
directory) packages.
The idea for this subrepository originated as the pkg/exp
directory of the main repository, but its presence there made it unavailable to users of the binary downloads of the Go installation. The subrepository has therefore been created to make it possible to go get
these packages.
Warning: Packages here are experimental and unreliable. Some may one day be promoted to the main repository or other subrepository, or they may be modified arbitrarily or even disappear altogether.
In short, code in this subrepository is not subject to the Go 1 compatibility promise. (No subrepo is, but the promise is even more likely to be violated by go.exp than the others.)
Caveat emptor.