Name allocation

Peter Simons simons@cryp.to
30 May 2003 04:45:05 +0200


Simon Marlow writes:

 > The only way (currently) to have such a guarantee is to use
 > User.To.Cryp.Simons as the root of your library tree.

Does this really guarantee uniqueness?

What if I don't own a domain name personally? What if I give up
my domain and somebody else buys it? What if somebody doesn't
know of this convention and simply uses this exact name because
he likes it?

As far as I can tell, you cannot guarantee unique names at all if
your name space system has an absolute root -- like Haskell does.
Whatever you come up with may potentially clash with someone
else's name -- and probably will. :-)

The only way to guarantee unique names -- without requiring
people to abide to some "arbitrary" convention -- is the module
names to be relative. If I import a module "Foo.Bar", and I am
"Peter.Simons.ToolXY", then this module will be
"Peter.Simons.Foo.Bar" for me. In such a system I can uniquely
access any module, no matter how it's called.

So if we _need_ a convention to guarantee unique names (within
our convention), any one is as good any other -- technically
speaking. And IHMO the simplest possible convention for a source
repository we could provide is: Call it whatever you like, as
long as it begins with "Unstable" and it is not taken yet.

To refer to current practice one more: This is exactly the way
domain names are handled, and despite all the problems, it has
worked pretty good so far.


 > Perhaps there's a demand for a part of the hierarchy that is a
 > "free for all", with no formal process for acquiring names,
 > where collision is "at your own risk". Suggestions for the
 > root name for this hierarchy are welcome: Unstable or Temp
 > perhaps?

I think "Unstable" is a pretty descriptive name. Or maybe "User"?
The latter is probably better for psychological reasons. :-)

Peter