[Haskell-beginners] Prelude source code

Doug McIlroy doug at cs.dartmouth.edu
Thu Feb 27 23:53:19 UTC 2020


> Thank you. Ive also found other references online, but I want to see the
> one installed locally in my system.
>
> I come from Smalltalk where everything is accessible and modifiable.
>
> Is the Prelude and other base modules distributed in compiled form only?

One of the joys of Hugs is that it includes the H98 Prelude,
a real vade mecum for both beginners and experts.  It is one
of the reasons that for everyday use I resort more often to
Hugs than to ghci.

The modern Prelude, spread over dozens of files, and programmed
at a higher level of abstraction, will not be as useful to a
beginner as the H98 Prelude is. Nevertheless it's a valuable
and fundamental resource. And it's real code, snatches of which
one may borrow as a basis for special modification. That is
not true of stuff served up by Hoogle.

Quite properly, the ghc distribution contains a compiled
version of the Prelude. But that doesn't preclude including
the source. It would be a public service to do so.

["You can always get it with Cabal" is unreasonably
dismissive. Why should beginners have to master another arcane
subject just to get a handbook for their newest toy?]

Doug McIlroy


More information about the Beginners mailing list