On Sat, Nov 18, 2006 at 04:46:24PM -0500, Peter Tanski wrote: > The simple problem with Haskell and Integer is that, according to the > Standard, Integer is a primitive: it is consequently implemented as > part of the runtime system (RTS), not the Prelude or any library > (though the interface to Integer is in the base library). For GHC, > compiling with -fno-implicit-prelude and explicitly importing only > those functions and types you need the won't get rid of Integer. > Possible solutions would be to implement the Integer 'primitive' as a > separate library and import it into the Prelude or base libraries, > then perform an optimisation step where base functions are only > linked in when needed. Except for the optimisation step, this > actually makes the job easier since Integer functions would be called > using the FFI and held in ForeignPtrs. (I have already done the FFI- > thing for other libraries and a primitive version of the replacement.)
there is no requirement that Integer be a primitive. a plain old implementation in haskell or via the FFI is certainly a valid one. John -- John Meacham - ⑆repetae.net⑆john⑈ _______________________________________________ Glasgow-haskell-users mailing list Glasgow-haskell-users@haskell.org http://www.haskell.org/mailman/listinfo/glasgow-haskell-users