[Haskell-cafe] Yet more type confusion
cgibbard at gmail.com
Mon Nov 20 05:51:02 EST 2006
Never use (/= "") or (/= ), use (not . null), which doesn't have the
On 20/11/06, Daniel McAllansmith <dm.maillists at gmail.com> wrote:
> On Monday 20 November 2006 20:44, chris moline wrote:
> > Hey all, I'm thoroughly confused by the type error
> > produced by the following:
> > > sep :: (a -> Bool) -> [a] -> [[a]]
> > > sep p = takeWhile (/= "") . iterT (breakDrop p)
> It'll be the "" in (/= "").
> Maybe you want to be using (/= ) ?
> That will work for any type a in the Eq class.
> Haskell-Cafe mailing list
> Haskell-Cafe at haskell.org
More information about the Haskell-Cafe