Prelude not in haskell98?

Malcolm Wallace Malcolm.Wallace at cs.york.ac.uk
Fri Jun 8 06:50:47 EDT 2007


> Iavor Diatchki wrote:
> > Just curious, what external modules does the Prelude depend on?
> 
> I'm not really sure what you mean by "external modules".  In GHC the
> Prelude is  comprised almost entirely of re-exports from other
> modules.

Just to note that, although ghc's inversion of the expected dependency
relationship is mildly confusing the first time you come across it, that
design decision is not the only one possible.  Other compilers, such as
nhc98, treat the haskell98 Prelude more like it is specified in the
Report, as a stand-alone module that depends on nothing else.  In such a
compiler, the 'base' package does not (and cannot) contain the Prelude,
which necessarily lives at a lower more basic level in the library
hierarchy.

Regards,
    Malcolm


More information about the Glasgow-haskell-users mailing list