2533: Generic functions that take integral arguments should work the same way as their prelude counterparts

Neil Mitchell ndmitchell at gmail.com
Sat Aug 23 05:29:43 EDT 2008


>>> I had always just assumed that take and genericTake did the same
>>> thing, so had never even realised this problem existed. I'd call this
>>> a bug, that needs fixing.
>> Maybe the bug is in 'drop', 'take' and 'splitAt' and it was intended to fix
>> it in 'generic' variants. Is there a good reason why to ignore negative
>> number arguments? It may hide bugs.

Too late. There is code depending on this behaviour in the wild, and
we can't break it without a really really really good reason. Changing
undefined to a value is not too bad (some optimisations in ByteString
do it automatically even!), but changing a value to undefined is bad.



More information about the Libraries mailing list