Discussion:
"Safer" implementation of Data.List.NonEmpty (and some other suggestions)
박신환
2018-08-30 09:09:07 UTC
Permalink
Those implementations using the nontotal `fromList`seem inefficient and potentially dangerous.

To eliminate those, I wrote a modification of the original file, which is enclosed.

Some other suggestions:

`insertBy` for `NonEmpty`s

`NonEmpty [a]` to `[NonEmpty a]` transposition

Add fixity for (:|) as `infixl 4 :|`

Loading...