[jhc] confusion on library source
David Roundy
roundyd at physics.oregonstate.edu
Sun Aug 30 09:56:38 EDT 2009
On Sat, Aug 29, 2009 at 6:58 PM, John Meacham<john at repetae.net> wrote:
>> $ cat lib/haskell98/System.hs
>> module System (
>> ExitCode(ExitSuccess,ExitFailure),
>> getArgs, getProgName, getEnv, system, exitWith, exitFailure
>> ) where
>>
>> import System.Exit
>> import System.Environment
>> import System.Cmd
>>
>> So it looks like System.Exit should exist somewhere. But I can't for
>> the life of me (or the grep of me...) figure out where. :( I had
>> been thinking that adding System.Exit would be an easy way to
>> contribute a bit towards jhc, and at the same time learn a bit about
>> how jhc works. Is System.Exit defined somewhere? If so, how can I
>> convince jhc to use it in my code? I am very puzzled.
>
> Ah, that is because the haskell98 package is the one pulled straight
> from the darcs repo that ghc uses. In jhc, System is provided by base,
> so is in lib/base/System.hs, the System provided by haskell98 is
> ignored.
Would it be feasible/desirable for me to split lib/base/System.hs into
System.Exit, System.Environment and System.Cmd? It would make a few
more of my programs more easily usable, and then we could use the
System.hs from the haskell98 package. Thanks!
--
David Roundy
More information about the jhc
mailing list