go/src/log/slog/example_wrap_test.go

// Infof is an example of a user-defined logging function that wraps slog.
// The log record contains the source position of the caller of Infof.
func Infof(logger *slog.Logger, format string, args ...any) {}

func Example_wrapping() {}