ginal Message-
| From: Thomas Hallgren [mailto:[EMAIL PROTECTED]
| Sent: 18 January 2005 22:12
| To: Simon Peyton-Jones; glasgow-haskell-users@haskell.org
| Cc: [EMAIL PROTECTED]
| Subject: Re: self-import
|
| Simon Peyton-Jones wrote:
|
| >I quite liked this idea until I thought of this:
| >
Simon Peyton-Jones wrote:
I quite liked this idea until I thought of this:
module Doc.Pretty.Long( M.f, f ) where
import qualified M( f )
import Doc.Pretty.Long as M
f x = x
The second import decl imports all the things exported by
Doc.Pretty.Long. But what doe
On Tue, 2005-01-18 at 10:43 +, Simon Peyton-Jones wrote:
> | And if it turns out we are in the mood to look at extending the
> | inport/export/module syntax perhaps we could also consider the
> qualified
> | export idea posted a few weeks ago.
> |
> | That was so that you could say:
> |
> |
| And if it turns out we are in the mood to look at extending the
| inport/export/module syntax perhaps we could also consider the
qualified
| export idea posted a few weeks ago.
|
| That was so that you could say:
|
| import Graphics.UI.Gtk
|
| and then use Button.setText (rather than buttonSet
On Tue, 2005-01-18 at 10:13 +, Simon Peyton-Jones wrote:
> I think what you want is actually more directly stated thus:
>
> module Doc.Pretty.Long( ... ) as M where
> ...
>
> The 'as M' in the module header gives an alias for Doc.Pretty.Long just
> as it does for an import stat
| It would be useful to be able to do a
|
| module Doc.Pretty.Long.Name where
|
| import Doc.Pretty.Long.Name as This
|
| so within the module we can refer to itself as 'This' without having
to
| write out the full name, however ghc complains that the hi file for
the
| module it is trying to co