summaryrefslogtreecommitdiff
path: root/vendor/github.com/klauspost/compress/fse/bytereader.go
diff options
context:
space:
mode:
authorLibravatar dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>2025-04-14 09:46:09 +0200
committerLibravatar GitHub <noreply@github.com>2025-04-14 09:46:09 +0200
commitf8d17a7e76d475e97580ef49fc076607d590bc27 (patch)
treec4be51de44a67e3af0ac497350e440e919b92e4b /vendor/github.com/klauspost/compress/fse/bytereader.go
parent[chore]: Bump github.com/miekg/dns from 1.1.64 to 1.1.65 (#4001) (diff)
downloadgotosocial-f8d17a7e76d475e97580ef49fc076607d590bc27.tar.xz
[chore]: Bump github.com/prometheus/client_golang from 1.21.1 to 1.22.0 (#4003)
Bumps [github.com/prometheus/client_golang](https://github.com/prometheus/client_golang) from 1.21.1 to 1.22.0. - [Release notes](https://github.com/prometheus/client_golang/releases) - [Changelog](https://github.com/prometheus/client_golang/blob/main/CHANGELOG.md) - [Commits](https://github.com/prometheus/client_golang/compare/v1.21.1...v1.22.0) --- updated-dependencies: - dependency-name: github.com/prometheus/client_golang dependency-version: 1.22.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Diffstat (limited to 'vendor/github.com/klauspost/compress/fse/bytereader.go')
-rw-r--r--vendor/github.com/klauspost/compress/fse/bytereader.go47
1 files changed, 0 insertions, 47 deletions
diff --git a/vendor/github.com/klauspost/compress/fse/bytereader.go b/vendor/github.com/klauspost/compress/fse/bytereader.go
deleted file mode 100644
index abade2d60..000000000
--- a/vendor/github.com/klauspost/compress/fse/bytereader.go
+++ /dev/null
@@ -1,47 +0,0 @@
-// Copyright 2018 Klaus Post. All rights reserved.
-// Use of this source code is governed by a BSD-style
-// license that can be found in the LICENSE file.
-// Based on work Copyright (c) 2013, Yann Collet, released under BSD License.
-
-package fse
-
-// byteReader provides a byte reader that reads
-// little endian values from a byte stream.
-// The input stream is manually advanced.
-// The reader performs no bounds checks.
-type byteReader struct {
- b []byte
- off int
-}
-
-// init will initialize the reader and set the input.
-func (b *byteReader) init(in []byte) {
- b.b = in
- b.off = 0
-}
-
-// advance the stream b n bytes.
-func (b *byteReader) advance(n uint) {
- b.off += int(n)
-}
-
-// Uint32 returns a little endian uint32 starting at current offset.
-func (b byteReader) Uint32() uint32 {
- b2 := b.b[b.off:]
- b2 = b2[:4]
- v3 := uint32(b2[3])
- v2 := uint32(b2[2])
- v1 := uint32(b2[1])
- v0 := uint32(b2[0])
- return v0 | (v1 << 8) | (v2 << 16) | (v3 << 24)
-}
-
-// unread returns the unread portion of the input.
-func (b byteReader) unread() []byte {
- return b.b[b.off:]
-}
-
-// remain will return the number of bytes remaining.
-func (b byteReader) remain() int {
- return len(b.b) - b.off
-}