summaryrefslogtreecommitdiff
path: root/vendor/github.com/klauspost/compress/huff0/bitreader.go
diff options
context:
space:
mode:
authorDan Čermák <dcermak@suse.com>2022-03-17 13:40:46 +0100
committerDan Čermák <dcermak@suse.com>2022-03-21 13:21:25 +0100
commit63bf3991ef14959983ecd86c406bd941c908157b (patch)
treede28b99f4c787e284e36df270aac29a1a2b104ca /vendor/github.com/klauspost/compress/huff0/bitreader.go
parent248dbf6089922903d12553497a2faae27d1b503b (diff)
downloadpodman-63bf3991ef14959983ecd86c406bd941c908157b.tar.gz
podman-63bf3991ef14959983ecd86c406bd941c908157b.tar.bz2
podman-63bf3991ef14959983ecd86c406bd941c908157b.zip
vendor containers/storage with https://github.com/containers/storage/pull/1165
Signed-off-by: Dan Čermák <dcermak@suse.com>
Diffstat (limited to 'vendor/github.com/klauspost/compress/huff0/bitreader.go')
-rw-r--r--vendor/github.com/klauspost/compress/huff0/bitreader.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/vendor/github.com/klauspost/compress/huff0/bitreader.go b/vendor/github.com/klauspost/compress/huff0/bitreader.go
index 03562db16..451160edd 100644
--- a/vendor/github.com/klauspost/compress/huff0/bitreader.go
+++ b/vendor/github.com/klauspost/compress/huff0/bitreader.go
@@ -165,6 +165,11 @@ func (b *bitReaderShifted) peekBitsFast(n uint8) uint16 {
return uint16(b.value >> ((64 - n) & 63))
}
+// peekTopBits(n) is equvialent to peekBitFast(64 - n)
+func (b *bitReaderShifted) peekTopBits(n uint8) uint16 {
+ return uint16(b.value >> n)
+}
+
func (b *bitReaderShifted) advance(n uint8) {
b.bitsRead += n
b.value <<= n & 63