-
Notifications
You must be signed in to change notification settings - Fork 72
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
groupBy
has unexpected l
argument for a -> a -> Boolean
predicate
#229
Comments
This comes down to the definition of "equivalence relation". |
It may be a useful relation, but (To be clear the proposed change to operate only on successive pairs does not change behaviour if the relation is an equivalence relation and I'm happy with that change in principle) |
So, should the PR I have open for this #230 be accepted? Or should a new function be defined that has #230's implementation? |
See https://try.purescript.org/?gist=26968458c1261226b33e574128ba9aae
For a given array like
[0, 1, 2]
, I expect thel
andr
arguments to be0
and1
1
and2
However, in the second run,
l
is0
rather than1
.I'd argue that the behavior here is unexpected.
The text was updated successfully, but these errors were encountered: