data List a = Nil | Cons a (List a) listLength Nil = 0 listLength (Cons x xs) = 1 + (listLength xs) ------------------------------------------------------------------------------------- *Blah> listLength(Cons 1) :1:11: Couldn't match `List a' against `t -> t1' Expected type: List a Inferred type: t -> t1 Expected type: List a Inferred type: List a1 -> List a1 Probable cause: `Cons' is applied to too few arguments in the call (Cons 1)