Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ require (
go.lsp.dev/protocol v0.12.0
go.lsp.dev/uri v0.3.0
go.uber.org/zap v1.27.1
golang.org/x/crypto v0.50.0
golang.org/x/mod v0.35.0
golang.org/x/sync v0.20.0
golang.org/x/term v0.42.0
Expand Down Expand Up @@ -97,6 +96,7 @@ require (
go.opentelemetry.io/otel/trace v1.43.0 // indirect
go.uber.org/multierr v1.11.0 // indirect
go.yaml.in/yaml/v3 v3.0.4 // indirect
golang.org/x/crypto v0.50.0 // indirect
golang.org/x/exp v0.0.0-20260410095643-746e56fc9e2f // indirect
golang.org/x/net v0.53.0 // indirect
golang.org/x/sys v0.43.0 // indirect
Expand Down
7 changes: 2 additions & 5 deletions private/pkg/shake256/shake256.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,10 @@
package shake256

import (
"crypto/sha3"
"fmt"
"io"
"slices"

"golang.org/x/crypto/sha3"
)

const shake256Length = 64
Expand All @@ -39,9 +38,7 @@ func NewDigest(value []byte) (Digest, error) {

// NewDigestForContent returns a new Digest for the content read from the Reader.
func NewDigestForContent(reader io.Reader) (Digest, error) {
shakeHash := sha3.NewShake256()
// TODO FUTURE: remove in the future, this should have no effect
shakeHash.Reset()
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wasn't sure why this was there since we were creating it just before.

shakeHash := sha3.NewSHAKE256()
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if _, err := io.Copy(shakeHash, reader); err != nil {
return nil, err
}
Expand Down
Loading