hirarchical modules

Simon Marlow simonmar@microsoft.com
Fri, 30 May 2003 10:27:06 +0100


Iavor Diatchki writes:=20
> hmm... what should i do?  implement 50 libraries using the=20
> broken system just to illustrate that it is broken?

Complaining doesn't achieve anything.  May I suggest that proposing a
solution, getting agreement from folks on this list, writing it up and
implementing it are much more productive things to be doing.

It's about time we had a proper Haskell 98 addendum for the hierarchical
module extension: I'll split out what's in the current document into an
addendum later today, and put it in CVS along with the FFI addendum so
we have somewhere to record the outcome of the dicussion.

Now, there are two separate issues here.

1) Relative imports.  I don't see any problem with this at all, beyond
   choosing a syntax.

2) Not specifying the full module name in the module source.

Several people have asked for (2), but the reason we have held off so
far is because it makes a fundamental change to the language, namely
that

   The meaning of a module would not be completely specified
   by its source code.

The current design has this rather nice property, and it means the
Haskell Report can avoid talking about filesystems or any other way to
specify the full module name for a module.  I'm sure this argument came
up recently on the libraries list, so I won't say any more about it now.

That's not to say it isn't possible to find a solution, but we should
bear in mind this property before adopting any design that requires the
filesystem to play a part in specifying the name of a module.

Cheers,
	Simon