strange behavior with ghci version 5.02.2

Simon Marlow simonmar@microsoft.com
Fri, 15 Feb 2002 09:48:47 -0000


> > After loading a module with
> >
> > :l Module
> >
> > you can't use the Prelude functions unqualified, you just get things
> > like
> >
> > <interactive>:1: Variable not in scope: `show'
> >
> > I am pretty sure that this worked some days ago, and I was using the
> > same version then.
> >
> > I feel totally confused. Has this happened to anyone else?
>=20
> Yes, for some modules it happens for others it doesn't. Kind=20
> of strange.
> SuSE 7.3 rpms here, v. 5.02.2
> J.A.

You're probably loading compiled versions of these modules.  GHC 5.02.2 =
will only give you the exports of a compiled module when it is selected =
with :module.

This is one of the issues we've addressed recently, and the snapshot =
5.03 release does a much better job.  There was some discussion about =
how exactly we should handle scope at the prompt in GHCi; take a look at =
the archives:

	=
http://www.haskell.org/pipermail/glasgow-haskell-users/2002-January/00277=
9.html

Cheers,
	Simon