| Safe Haskell | Safe-Inferred |
|---|---|
| Language | Haskell2010 |
Matterhorn.Util
Documentation
nubOn :: Ord b => (a -> b) -> [a] -> [a] Source #
The nubOn function removes duplicate elements from a list. In
particular, it keeps only the last occurrence of each
element. The equality of two elements in a call to nub f is
determined using f x == f y, and the resulting elements must have
an Ord instance in order to make this function more efficient.