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
Compiler feature - useful or not?
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2007-11-16 (00:31)
From: Brian Hurt <bhurt@s...>
Subject: Re: [Caml-list] Compiler feature - useful or not?

On Thu, 15 Nov 2007, Fernando Alegre wrote:

> The main problem I have with abstract types is that they are heavyweight
> since they need to be defined inside modules. In that particular, the
> proposed private types are also heavyweight.

I don't see modules as being that heavyweight.  Absent functors, they're 
just namespaces.  And Ocaml's cross-module inlining eliminates even most 
of that overhead- identity conversions are generally inlined and become 
no-ops.  Even with functors, the overhead is small, approximately that of 
calling a virtual function in C++ or Java.

Just my $0.02.