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

Method varWriteMapHeader

gen/spec.go:533–539  ·  view source on GitHub ↗
(receiver string, sizeVarname string, maxSize int)

Source from the content-addressed store, hash-verified

531}
532
533func (p *printer) varWriteMapHeader(receiver string, sizeVarname string, maxSize int) {
534 if maxSize <= 15 {
535 p.printf("\nerr = %s.Append(0x80 | uint8(%s))", receiver, sizeVarname)
536 } else {
537 p.printf("\nerr = %s.WriteMapHeader(%s)", receiver, sizeVarname)
538 }
539}
540
541func (p *printer) varAppendMapHeader(sliceVarname string, sizeVarname string, maxSize int) {
542 if maxSize <= 15 {

Callers 1

structmapMethod · 0.80

Calls 1

printfMethod · 0.95

Tested by

no test coverage detected