English version
Accueil     Ŕ propos     Téléchargement     Ressources     Contactez-nous    

Ce site est rarement mis ŕ jour. Pour les informations les plus récentes, rendez-vous sur le nouveau site OCaml ŕ l'adresse ocaml.org.

Browse thread
[Caml-list] Completeness of "Unix" run-time library
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2004-03-19 (10:44)
From: Sven Luther <sven.luther@w...>
Subject: Re: [Caml-list] Modules and namespaces
On Fri, Mar 19, 2004 at 10:19:31AM +0000, Richard Jones wrote:
> On Fri, Mar 19, 2004 at 10:49:27AM +0100, Wolfgang Müller wrote:
> > To get back to the perl example:
> [perl example]
> > However, for toplevel namespaces, you have to write to a mailing
> > list, and there is a group of people who decide if to accept the new
> > toplevel namespace or not. This is a (AFAIK also known) bottleneck..
> Actually, getting a toplevel namespace accepted is not necessary with
> Perl.  It's advisable, a nice thing to do, etc., but not necessary for
> uploading a module to CPAN.
> Another thing which is being overlooked here is that ocaml has two
> types of namespace:
> (1) The normal module namespace
> (2) Which paths get searched using -I +subdir
> For instance, I have a module called Dbi which is located in the
> -I +dbi subdirectory.
> It would be quite possible for someone else to write a Dbi module
> located in the -I +anotherdbi directory.  No conflict would arise
> unless some strange person wanted to use both types of Dbi module
> in their program - an unlikely occurrence presumably.

You can achieve this by using the -pack option when creating libraries.
Sure it has still some problems, but it is the way to go to solve this

What is really missing is support for more than one OCAMLLIBDIR, in
order to be able to easily separate the libraries installed by your
package manager (/usr/lib/ocaml/3.07 for debian), by the one installed
locally by the sysadmin (/usr/local/lib/ocaml/3.07 for debian), and the
user specific ones (less important though, but still usefull).


Sven Luther

To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr
Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners