From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.1.3 (2006-06-01) on yquem.inria.fr X-Spam-Level: * X-Spam-Status: No, score=1.0 required=5.0 tests=AWL,SPF_FAIL autolearn=disabled version=3.1.3 X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by yquem.inria.fr (Postfix) with ESMTP id 5F5D7BC0A for ; Mon, 19 Feb 2007 15:40:04 +0100 (CET) Received: from mail.gmx.net (mail.gmx.net [213.165.64.20]) by concorde.inria.fr (8.13.6/8.13.6) with SMTP id l1JEe1hI024580 for ; Mon, 19 Feb 2007 15:40:04 +0100 Received: (qmail invoked by alias); 19 Feb 2007 14:40:01 -0000 X-Provags-ID: V01U2FsdGVkX19l6HhaVBplqEDph8ROBx7UbxnT6WnUGEaqdgaLxw A/lg== Message-ID: <45D9B779.2090204@fantasymail.de> Date: Mon, 19 Feb 2007 15:43:05 +0100 From: micha User-Agent: Icedove 1.5.0.9 (X11/20061220) MIME-Version: 1.0 To: Joel Reymont Cc: caml-list@inria.fr Subject: Re: [Caml-list] Examples of creating C++ library bindings References: <3220E2BE-5E8F-4701-9D5E-49C7FD25FC8F@gmail.com> In-Reply-To: <3220E2BE-5E8F-4701-9D5E-49C7FD25FC8F@gmail.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Y-GMX-Trusted: 0 X-Miltered: at concorde with ID 45D9B6C1.003 by Joe's j-chkmail (http://j-chkmail . ensmp . fr)! X-Spam: no; 0.00; bindings:01 bindings:01 lib:01 libs:01 lib:01 ocaml:01 callbacks:01 cheers:01 wrote:01 caml-list:01 functions:01 usable:01 binding:02 inheritance:03 library:03 Joel Reymont wrote: > Are there any examples of creating C++ library bindings? > > Thanks, Joel I have done it few times, mostly just to see how it works. At the moment I'm writing a (hopefully) real usable binding to a c++ lib. For big libs it's better (faster) to generate them but if you want some (small) part, you can do it yourself, it's much writing. I can send my code as an example and answer questions (no docu yet). It mirrors a c++ lib on the ocaml side, with working inheritance and overwritable virtual functions and event callbacks cheers Michael