MCPcopy
hub / github.com/tinylib/msgp / NewWriter

Function NewWriter

msgp/write.go:122–127  ·  view source on GitHub ↗

NewWriter returns a new *Writer.

(w io.Writer)

Source from the content-addressed store, hash-verified

120
121// NewWriter returns a new *Writer.
122func NewWriter(w io.Writer) *Writer {
123 if wr, ok := w.(*Writer); ok {
124 return wr
125 }
126 return popWriter(w)
127}
128
129// NewWriterSize returns a writer with a custom buffer size.
130func NewWriterSize(w io.Writer, sz int) *Writer {

Callers 15

TestString_RoundTripFunction · 0.92
TestString_NilHandlingFunction · 0.92
TestString_EmptySetFunction · 0.92
TestInt_RoundTripFunction · 0.92
TestInt_NilHandlingFunction · 0.92

Calls 1

popWriterFunction · 0.85

Tested by 15

TestString_RoundTripFunction · 0.74
TestString_NilHandlingFunction · 0.74
TestString_EmptySetFunction · 0.74
TestInt_RoundTripFunction · 0.74
TestInt_NilHandlingFunction · 0.74

Used in the wild real call sites across dependent graphs

searching dependent graphs…