Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: issue with slices.SortFunc #168

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

major0
Copy link

@major0 major0 commented Jan 16, 2025

address.go:21:33: in call to slices.SortFunc, type func(a Address, b Address) bool of func(a, b Address) bool {…} does not match inferred type func(a Address, b Address) int for func(a E, b E) int

@major0
Copy link
Author

major0 commented Jan 18, 2025

go-proton-api imports golang.org/x/exp/slices which had this issue associated to it: golang/go#61374

So go-proton-api's SortFunc was written against the experimental slices behavior. The experimental line was rewritten to match the production slices, and go-proton-api was never updated to deal with it.

> address.go:21:33: in call to slices.SortFunc, type func(a Address, b Address) bool of func(a, b Address) bool {…} does not match inferred type func(a Address, b Address) int for func(a E, b E) int
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant