MCPcopy Create free account
hub / github.com/chain/txvm / SetOutput

Function SetOutput

log/log.go:55–59  ·  view source on GitHub ↗

SetOutput sets the log output to w. If SetOutput hasn't been called, the default behavior is to write to stdout.

(w io.Writer)

Source from the content-addressed store, hash-verified

53// If SetOutput hasn't been called,
54// the default behavior is to write to stdout.
55func SetOutput(w io.Writer) {
56 logWriterMu.Lock()
57 logWriter = w
58 logWriterMu.Unlock()
59}
60
61func appendPrefix(b []byte, keyval ...interface{}) []byte {
62 // Invariant: len(keyval) is always even.

Callers 9

TestSetOutputFunction · 0.85
TestPrefixFunction · 0.85
TestPrintkvFunction · 0.85
TestMessagefFunction · 0.85
TestPrintkvStackFunction · 0.85
TestErrorFunction · 0.85
TestRawStackFunction · 0.85
TestHelperStackFunction · 0.85

Calls

no outgoing calls

Tested by 9

TestSetOutputFunction · 0.68
TestPrefixFunction · 0.68
TestPrintkvFunction · 0.68
TestMessagefFunction · 0.68
TestPrintkvStackFunction · 0.68
TestErrorFunction · 0.68
TestRawStackFunction · 0.68
TestHelperStackFunction · 0.68