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
Estimating the size of the ocaml community
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2005-02-06 (02:56)
From: skaller <skaller@u...>
Subject: Re: Why can't types and exceptions be nested (was: Re: [Caml-list] Estimating the size of the ocaml community)
On Sun, 2005-02-06 at 03:37, Richard Jones wrote:

> Is there a reason why types (and exceptions) can't appear nested?  

This kind of lack of transparency is annoying. The main reason
is probably historical..

Felix allows anything to be nested anywhere,
modules, type definitions, etc can all be put
inside functions, it uses a unified namespace like C++.
[You can even put expressions inside types, using
the 'typeof()' operator]

Ocaml has separate namespaces for types
and variables. A module wraps both, which is why
you actually CAN nest types in functions in Ocaml,
but you have to use a local module to do it.
A new feature added to solve the problem you
mention, although not entirely transparently.

Whilst this kind of quirkery is annoying,
that's about all it is -- annoying. It isn't
really a show stopper.

John Skaller, mailto:skaller@users.sf.net
voice: 061-2-9660-0850, 
snail: PO BOX 401 Glebe NSW 2037 Australia
Checkout the Felix programming language http://felix.sf.net