default for quotRem in terms of divMod?

Isaac Dupree isaacdupree at charter.net
Tue Aug 7 17:08:57 EDT 2007


In class Integral, divMod has a default in terms of quotRem. 
(quot,rem,div,mod all have defaults as the both-function they're part 
of.)  I'm sure divMod is more natural than quotRem to implement for some 
types... so why doesn't quotRem have a default in terms of divMod? it 
has no default! Then the "minimal to implement" will change from 
(toInteger and quotRem) to (toInteger and (quotRem or divMod)).

Isaac


More information about the Haskell-prime mailing list