Open jmkim opened 1 year ago
x/exp v0.0.0-20230905200255-921286631fa9
(latest):
# github.com/jesseduffield/generics/slices [github.com/jesseduffield/generics/slices.test]
./delegated_sort.go:18:21: type func(a E, b E) bool of less does not match inferred type func(a E, b E) int for func(a E, b E) int
./delegated_sort.go:24:27: type func(a E, b E) bool of less does not match inferred type func(a E, b E) int for func(a E, b E) int
./delegated_sort.go:35:32: type func(a E, b E) bool of less does not match inferred type func(a E, b E) int for func(a E, b E) int
./delegated_sort.go:44:9: too many return values
have (int, bool)
want (int)
./delegated_sort.go:56:9: too many return values
have (int, bool)
want (int)
./delegated_sort.go:56:36: not enough arguments in call to slices.BinarySearchFunc
have ([]E, func(E) bool)
want (S, T, func(E, T) int)
FAIL github.com/jesseduffield/generics/slices [build failed]
x/exp v0.0.0-20230711023510-fffb14384f22
(near the current Debian latest, which is already old):
x/exp
in Debian currently the latest: 0.0~git20230522.2e198f4-1
(upstream vcs)# github.com/jesseduffield/generics/slices [github.com/jesseduffield/generics/slices.test]
./delegated_sort.go:44:9: too many return values
have (int, bool)
want (int)
./delegated_sort.go:56:9: too many return values
have (int, bool)
want (int)
./delegated_sort.go:56:36: not enough arguments in call to slices.BinarySearchFunc
have ([]E, func(E) bool)
want ([]E, T, func(E, T) int)
FAIL github.com/jesseduffield/generics/slices [build failed]
That generics package was intended to add extra functionality that the stdlib package didn't have. It provides wrappers over existing functions so that it can be used as a replacement for the stdlib package. But if you look in lazygit we're now only using the generics package for the sake of the maps and set sub-packages. So we can just remove the slices part of that package if it fixes these issues.
Thanks @jesseduffield \o/
In Debian, this package will be used only by lazygit
, at this time. I am going to remove slices
part for now.
go test
errors withx/exp
.