Note that at least for the dropWhile example, there is a specialized function, dropWhileEnd, which is most likely more efficient than reversing the list twice. On Aug 17, 2013 3:35 PM, "Tom Ellis" < [email protected]> wrote:
> On Sat, Aug 17, 2013 at 11:11:07AM +0200, Christopher Done wrote: > > Anyone ever needed this? Me and John Wiegley were discussing a decent > > name for it, John suggested inv as in involution. E.g. > > > > inv reverse (take 10) > > inv reverse (dropWhile isDigit) > > trim = inv reverse (dropWhile isSpace) . dropWhile isSpace > > This sounds like a job for a lens, or similar. > > Tom > > > _______________________________________________ > Haskell-Cafe mailing list > [email protected] > http://www.haskell.org/mailman/listinfo/haskell-cafe >
_______________________________________________ Haskell-Cafe mailing list [email protected] http://www.haskell.org/mailman/listinfo/haskell-cafe
