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] Interfacing C++ and Ocaml
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2001-03-30 (09:14)
From: Bruce Hoult <bruce@h...>
Subject: Re: [Caml-list] Interfacing C++ and Ocaml
At 10:54 AM +0200 3/30/01, David Chemouil wrote:
>I am in the situation where I would like to write an Ocaml program which
>makes use of some C++ classes. It seems to me some people had said there
>were some problems doing so, but I can't recall what these problems may
>be, and didn't find anything precise in the ML archive.
>So, I would like to know what may prevent me to reuse C++ code from
>Ocaml, if anything may. I am sure some arrangements can be done, as
>there exists an Ocaml implementation on BeOS, which is programmed in

I'm no expert on Caml, so maybe the wizards have done something 
clever, but interfacing other languages to C++ is normally best done 
by writing an adaptor in C++ that provides a pure C interface to the 
C++ code (usable by C code, compiled by a C compiler, not C++), and 
then call *that* from your favourite language.

-- Bruce
To unsubscribe, mail caml-list-request@inria.fr.  Archives: http://caml.inria.fr