summaryrefslogtreecommitdiff
path: root/vendor/github.com/ulikunitz/xz/lzma/operation.go
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/github.com/ulikunitz/xz/lzma/operation.go')
-rw-r--r--vendor/github.com/ulikunitz/xz/lzma/operation.go25
1 files changed, 0 insertions, 25 deletions
diff --git a/vendor/github.com/ulikunitz/xz/lzma/operation.go b/vendor/github.com/ulikunitz/xz/lzma/operation.go
index a75c9b46c..2f9b78ea5 100644
--- a/vendor/github.com/ulikunitz/xz/lzma/operation.go
+++ b/vendor/github.com/ulikunitz/xz/lzma/operation.go
@@ -5,7 +5,6 @@
package lzma
import (
- "errors"
"fmt"
"unicode"
)
@@ -24,30 +23,6 @@ type match struct {
n int
}
-// verify checks whether the match is valid. If that is not the case an
-// error is returned.
-func (m match) verify() error {
- if !(minDistance <= m.distance && m.distance <= maxDistance) {
- return errors.New("distance out of range")
- }
- if !(1 <= m.n && m.n <= maxMatchLen) {
- return errors.New("length out of range")
- }
- return nil
-}
-
-// l return the l-value for the match, which is the difference of length
-// n and 2.
-func (m match) l() uint32 {
- return uint32(m.n - minMatchLen)
-}
-
-// dist returns the dist value for the match, which is one less of the
-// distance stored in the match.
-func (m match) dist() uint32 {
- return uint32(m.distance - minDistance)
-}
-
// Len returns the number of bytes matched.
func (m match) Len() int {
return m.n