[Haskell] Read Instances for Data.Map and Data.Set

Christian Maeder maeder at tzi.de
Fri Oct 21 06:52:30 EDT 2005

Malcolm Wallace wrote:
>     module Some.Very.Long.Module.Name where
>     import Prelude hiding (map)
>     map = ...
>     foo = ...... map ....
> Now, do I really want to be forced to write
>     Some.Very.Long.Module.Name.map
> on the right-hand-side of the defn of foo?
> There is no easy way currently for me to create a
> short synonym for the defining module name.  e.g.
>     import Some.Very.Long.Module.Name as Local
> At least, such a recursive module import would be
> possible, but tricky to set up and maintain when the
> module changes over time.

I'ld rather suggest a (small) language extension:

  "module" modid ["as" modid] [exports] "where" body


More information about the Libraries mailing list