"Safer" implementation of Data.List.NonEmpty (and some other suggestions)
박신환
ndospark320 at naver.com
Thu Aug 30 09:09:07 UTC 2018
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 :|`
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/libraries/attachments/20180830/8181246b/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: NonEmpty.hs
Type: text/x-haskell
Size: 17848 bytes
Desc: not available
URL: <http://mail.haskell.org/pipermail/libraries/attachments/20180830/8181246b/attachment.hs>
More information about the Libraries
mailing list