bytes.Buffer.Bytes (method)
62 uses
bytes (current package)
buffer.go#L54: func (b *Buffer) Bytes() []byte { return b.buf[b.off:] }
crypto/tls
auth.go#L88: return b.Bytes()
conn.go#L586: copy(err.RecordHeader[:], c.rawInput.Bytes())
conn.go#L641: hdr := c.rawInput.Bytes()[:recordHeaderLen]
conn.go#L1092: data := c.hand.Bytes()
conn.go#L1405: recordType(c.rawInput.Bytes()[0]) == recordTypeAlert {
quic.go#L275: b := q.conn.hand.Bytes()
encoding/json
encode.go#L179: buf := append([]byte(nil), e.Bytes()...)
stream.go#L223: b := e.Bytes()
encoding/pem
pem.go#L315: return buf.Bytes()
go.pact.im/x/goupdate
modules.go#L35: if err := json.Unmarshal(buf.Bytes(), &m); err != nil {
report.go#L36: out := bytes.TrimSpace(buf.Bytes())
tests.go#L69: r.Stderr = stderr.Bytes()
workspaces.go#L62: if err := json.Unmarshal(buf.Bytes(), &work); err != nil {
workspaces.go#L113: if err := json.Unmarshal(buf.Bytes(), &out); err != nil {
go.pact.im/x/zapjournal
encoder.go#L214: e.buf = buf.Bytes()
json.go#L83: e.setBuf(buf.Bytes())
go/ast
commentmap.go#L287: bytes := buf.Bytes()
go/doc/comment
html.go#L27: return out.Bytes()
markdown.go#L35: return out.Bytes()
markdown.go#L99: line := bytes.TrimSpace(p.raw.Bytes())
print.go#L188: return out.Bytes()
text.go#L63: return out.Bytes()
text.go#L70: data := out.Bytes()
go/format
format.go#L76: file, err = parser.ParseFile(fset, "", buf.Bytes(), parserMode)
internal.go#L109: return buf.Bytes(), nil
internal.go#L152: out := sourceAdj(buf.Bytes(), cfg.Indent)
go/parser
interface.go#L34: return s.Bytes(), nil
golang.org/x/net/http2
transport.go#L1618: hdrs := cc.hbuf.Bytes()
transport.go#L2059: return cc.hbuf.Bytes(), nil
write.go#L240: headerBlock := buf.Bytes()
write.go#L289: headerBlock := buf.Bytes()
write.go#L320: BlockFragment: buf.Bytes(),
golang.org/x/net/http2/hpack
hpack.go#L257: d.buf = d.saveBuf.Bytes()
huffman.go#L28: return w.Write(buf.Bytes())
golang.org/x/tools/go/packages
external.go#L143: if len(stderr.Bytes()) != 0 && os.Getenv("GOPACKAGESPRINTDRIVERERRORS") != "" {
external.go#L148: if err := json.Unmarshal(buf.Bytes(), &response); err != nil {
golang.org/x/tools/internal/gcimporter
iexport.go#L288: return out.Bytes(), err
golang.org/x/tools/internal/gocommand
vendor.go#L54: goflags := string(bytes.TrimSpace(stdout.Bytes()))
vendor.go#L122: goWork := string(bytes.TrimSpace(stdout.Bytes()))
gotest.tools/v3/internal/source
update.go#L132: if _, err = fh.Write(buf.Bytes()); err != nil {
html/template
escape.go#L815: e.editTextNode(n, b.Bytes())
mime/multipart
formdata.go#L183: if _, err := file.Write(b.Bytes()); err != nil {
formdata.go#L206: fh.content = b.Bytes()
net/http
h2_bundle.go#L9691: return cc.hbuf.Bytes(), nil
h2_bundle.go#L9744: return cc.hbuf.Bytes(), nil
h2_bundle.go#L11226: headerBlock := buf.Bytes()
h2_bundle.go#L11275: headerBlock := buf.Bytes()
h2_bundle.go#L11306: BlockFragment: buf.Bytes(),
request.go#L927: buf := v.Bytes()
server.go#L3842: w.Write(tw.wbuf.Bytes())
net/http/httputil
dump.go#L37: return io.NopCloser(&buf), io.NopCloser(bytes.NewReader(buf.Bytes())), nil
dump.go#L155: dump := buf.Bytes()
dump.go#L285: return b.Bytes(), nil
dump.go#L336: return b.Bytes(), nil
net/http/pprof
pprof.go#L239: w.Write(buf.Bytes())
pprof.go#L467: _, err := w.Write(b.Bytes())
os/exec
exec.go#L1024: return stdout.Bytes(), err
exec.go#L1040: return b.Bytes(), err
exec.go#L1183: return buf.Bytes()
vendor/golang.org/x/net/http2/hpack
hpack.go#L257: d.buf = d.saveBuf.Bytes()
huffman.go#L28: return w.Write(buf.Bytes())