-
Notifications
You must be signed in to change notification settings - Fork 114
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
Bump golang minimal version to 1.21 and 1.22 #531
Conversation
26f893c
to
6ff1656
Compare
@@ -179,7 +180,7 @@ func convertIntoSequence(value any) []any { | |||
i++ | |||
} | |||
slices.SortFunc(seq, func(a, b any) int { | |||
return compare(a.(string), b.(string)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please also remove this func, as we won't need the conditional build anymore
@@ -179,7 +180,7 @@ func convertIntoSequence(value any) []any { | |||
i++ | |||
} | |||
slices.SortFunc(seq, func(a, b any) int { | |||
return compare(a.(string), b.(string)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So, I am not sure, should we use compare
or cmp.Compare
? @ndeloof
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cmp.Compare
should be safe (?), at least we already use it on go1.21+, so better just remove the compare/compare120 hack
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done!
eb4780b
to
8d96c65
Compare
Signed-off-by: jhrotko <[email protected]>
8d96c65
to
22508c3
Compare
In order to update the version of https://pkg.go.dev/golang.org/x/[email protected]/slices we need to update the
slices.SortFunc
to be compatible withy the latest version.Related with #519