On Wed, Aug 24, 2011 at 10:47 AM, Ivan Lazar Miljenovic <ivan.miljeno...@gmail.com> wrote: > On 24 August 2011 11:10, bob zhang <bobzhang1...@gmail.com> wrote: >> Hi, John, there is a space leak problem in ListLike typeclass, >> in the method genericLength >> calclen !accum cl = >> calclen accum cl = > > I _think_ this may cause problems with some data types (e.g. > http://hackage.haskell.org/packages/archive/numbers/2009.8.9/doc/html/Data-Number-Natural.html > ) that require the extra laziness (that is, you can do things like ` 3 > < genericLength [1..] ' and have it return True).
Does the current version support this? The use of an accumulator (that is presumably returned after consuming the complete input) seems to suggest that your example would diverge anyway (but I did not try). Sebastian _______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe