id,summary,reporter,owner,description,type,status,priority,milestone,component,version,resolution,keywords,cc,os,architecture,failure,testcase,blockedby,blocking,related,differential
2281,properFraction implemented with modf primitive?,guest,,"I need a fast 'fraction' function for Double.
I can use 'properFraction', but its Double instance uses 'decodeFloat', which is rather slow.
It's also clumsy to use, because I have to provide an Integral type, although I'm not interested in the integral part.
I can use (x - int2Double (double2Int x)) but this fails for x beyond the Int number range, and it is hard to fix that for an unknown implementation of Double.
What about a 'modf' primitive which either calls 'modf' from standard C library
or invokes an appropriate FPU command?
If Double is in IEEE format the 'fraction' command could also be implemented quite efficiently by some bit masking without the FPU.
",bug,closed,normal,7.2.1,libraries/base,6.8.2,wontfix,,ghc@…,Unknown/Multiple,Unknown/Multiple,None/Unknown,,,,,