Libraries and hierarchies

Simon Marlow simonmar@microsoft.com
Fri, 8 Aug 2003 15:38:55 +0100


=20
> Would you mind illustrating the source-to-source transformation on
> a small example?  Suppose there's a package foo with a module
>=20
> 	module C where f =3D 'a'
>=20
> that this package is grafted in at both A.B and X, and=20
> there's a module
>=20
> 	module Foo (f) where
> 	import A.B.C (f)
> 	import X.C (f)

One possible transformation is this:

   module A.B.C where f =3D 'a'
   module X.C (module A.B.C) where import A.B.C

> I also can't see much to gain from local graftings.  But that=20
> leaves us wanting each combination of
>=20
> 	default root for package + local module name
>=20
> unique across all packages, doesn't it?

No - we don't want globally-unique module names (that's what we were
trying to solve in the first place).  We therefore do want local
grafting.

There are good uses for packages which overlap in their default
installation - versioning is one example.

Cheers,
	Simon