diff options
Diffstat (limited to 'vendor/github.com/ugorji/go/codec/reader.go')
-rw-r--r-- | vendor/github.com/ugorji/go/codec/reader.go | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/vendor/github.com/ugorji/go/codec/reader.go b/vendor/github.com/ugorji/go/codec/reader.go index 802938c7d..a683d9a2a 100644 --- a/vendor/github.com/ugorji/go/codec/reader.go +++ b/vendor/github.com/ugorji/go/codec/reader.go @@ -8,9 +8,11 @@ import "io" // decReader abstracts the reading source, allowing implementations that can // read from an io.Reader or directly off a byte slice with zero-copying. type decReader interface { - // readx will use the implementation scratch buffer if possible i.e. n < len(scratchbuf), OR - // just return a view of the []byte being decoded from. + // readx will return a view of the []byte if decoding from a []byte, OR + // read into the implementation scratch buffer if possible i.e. n < len(scratchbuf), OR + // create a new []byte and read into that readx(n uint) []byte + readb([]byte) readn1() byte |