drop for negative argument

Daniel Fischer daniel.is.fischer at web.de
Thu Feb 17 09:12:34 EST 2005


Hello,

I found that in GHC.List, drop is defined so that

drop (-1) ls = [],

which probably is a typing-error, since it disobeys the

splitAt n ls == (take n ls, drop n ls)

rule. I suggest changing that in future releases.

Regards,
Daniel Fischer



More information about the Glasgow-haskell-bugs mailing list