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.4 required=5.0 tests=SPF_NEUTRAL autolearn=disabled version=3.1.3 X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from mail2-relais-roc.national.inria.fr (mail2-relais-roc.national.inria.fr [192.134.164.83]) by yquem.inria.fr (Postfix) with ESMTP id B2A08BBCA for ; Tue, 26 Feb 2008 23:02:14 +0100 (CET) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AgAAAHMaxEfY7zq8gWdsb2JhbACDIY1HAQEIBQQJChaBD5NNh20 X-IronPort-AV: E=Sophos;i="4.25,409,1199660400"; d="scan'208";a="7736828" Received: from discorde.inria.fr ([192.93.2.38]) by mail2-smtp-roc.national.inria.fr with ESMTP; 26 Feb 2008 23:02:14 +0100 Received: from mail2-relais-roc.national.inria.fr (mail2-relais-roc.national.inria.fr [192.134.164.83]) by discorde.inria.fr (8.13.6/8.13.6) with ESMTP id m1QM2ElN015888 (version=TLSv1/SSLv3 cipher=RC4-SHA bits=128 verify=OK) for ; Tue, 26 Feb 2008 23:02:14 +0100 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AgAAAHMaxEfY7zq8gWdsb2JhbACDIY1HAQEIBQQJChaBD5NNh20 X-IronPort-AV: E=Sophos;i="4.25,409,1199660400"; d="scan'208";a="7736827" Received: from gv-out-0910.google.com ([216.239.58.188]) by mail2-smtp-roc.national.inria.fr with ESMTP; 26 Feb 2008 23:02:14 +0100 Received: by gv-out-0910.google.com with SMTP id i36so851367gve.28 for ; Tue, 26 Feb 2008 14:02:13 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; bh=A7wHvyMScj3K8IEs6h7LNx48aj4oFJ+LFVe1/TDeVnU=; b=TkHs0yfQl42Zea02G+s50ICZ6FiuyOqdGyhk7t3K05tE3v+8mCzRO6HRP3vHyxw4O7M7LM9A/JBRYvxk4eBvO84sxcmG+5m8iPZ90g/iz1lB0wt3pWQ3Yapq4JkGfY+9h+8Gx3cG8jdBt1VPI+lyJEuknQ0UMQJTvqSWUY6vFXc= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=sLuTSCmhFCpKws/ft+3sDNhikBcSVMpbAzefMLKg2PIzALNY2ACZqGaNLeYgbt3BUfqcKWFkhWnUDOdn+uNNpOiPo/Zn9PgxYLLdd+fXTWT+CAtmIfuBR2Qa07U9Z810fnThBHnNW9X2qzkUdVsgRvEpaQjA4SUgiWAfWfCO7Ww= Received: by 10.142.241.10 with SMTP id o10mr4329238wfh.217.1204063319265; Tue, 26 Feb 2008 14:01:59 -0800 (PST) Received: by 10.142.102.3 with HTTP; Tue, 26 Feb 2008 14:01:59 -0800 (PST) Message-ID: Date: Tue, 26 Feb 2008 17:01:59 -0500 From: "Markus Mottl" To: "David Teller" Subject: Re: [Caml-list] Deriving + type-conv + OCaml-Templates + camlp4* = ? Cc: OCaml In-Reply-To: <1204057629.6163.50.camel@Blefuscu> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <1204057629.6163.50.camel@Blefuscu> X-Miltered: at discorde with ID 47C48C66.000 by Joe's j-chkmail (http://j-chkmail . ensmp . fr)! X-Spam: no; 0.00; markus:01 mottl:01 markus:01 mottl:01 camlp:01 ens-lyon:01 ocaml:01 camlp:01 trade-offs:01 variants:01 ocaml:01 26,:98 polymorphic:01 wrote:01 caml-list:01 On Tue, Feb 26, 2008 at 3:27 PM, David Teller wrote: > Browsing around the net, I've found three > "scrap-your-boilerplate"-style projects for OCaml: the simple Type-conv, > the ambitious Deriving and the unmaintained OCaml-Templates, and of > course the ability to use camlp4/camlp5 for the same purpose. I imagine > that there are a number of nice boilerplate-based modules just waiting > to be implemented or adopted. > > As far as I understand, there's no interaction between the project > authors, which is a shame. So this is an open call to whoever is in > charge of each work: do you think it would be possible for you all to > join forces and produce something robust, simple and possible to adopt > as a standard ? I think that different projects have different trade-offs that are hard, if not impossible, to combine. Deriving is a very elegant, general approach, but last time I checked it would be hard to generate highly optimized code with it, and it was also not complete (e.g. handling hard cases like polymorphic variants with inherited types, etc.). Type-conv was mostly factored out of sexplib to make it possible to have different type converters in different preprocessors, because we are planning to release our binary protocol library very soon. Type-conv only combines a few often needed constructs, but in my experience the very vast part of new type converters has to be written by hand anyway (at least if you care about performance / good code generation) so there is little to gain here. I don't know much about OCaml-Templates. Regards, Markus -- Markus Mottl http://www.ocaml.info markus.mottl@gmail.com