While groupBy no longer crashes, it does seem to still have a strange Char
ordering bug that makes it effectively unusable. Looking at the nearly identical
code of group, it's likely that group also suffers from this, but the user
would never notice since group always uses == and thus element reordering
within a group would never matter.
This PR fixes this bug and adds tests to prove it.
While
groupBy
no longer crashes, it does seem to still have a strangeChar
ordering bug that makes it effectively unusable. Looking at the nearly identical code ofgroup
, it's likely thatgroup
also suffers from this, but the user would never notice sincegroup
always uses==
and thus element reordering within a group would never matter.This PR fixes this bug and adds tests to prove it.