func()

in cborl/parse.go [398:425]


func (p *Parser) stepUint(in []byte) (b []byte, done bool, err error) {
	b = in
	switch p.state.current.minor {
	case len8b:
		b, done, err = b[1:], true, p.visitor.OnUint8(b[0])
	case len16b:
		var v uint16
		if b, done, v = p.getUint16(b); done {
			err = p.visitor.OnUint16(v)
		}
	case len32b:
		var v uint32
		if b, done, v = p.getUint32(b); done {
			err = p.visitor.OnUint32(v)
		}
	case len64b:
		var v uint64
		if b, done, v = p.getUint64(b); done {
			err = p.visitor.OnUint64(v)
		}
	}

	if done && err == nil {
		done, err = p.popState()
	}

	return
}