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.2 required=5.0 tests=AWL,PORN_URL_SEX,SPF_NEUTRAL autolearn=disabled version=3.1.3 Received: from discorde.inria.fr (discorde.inria.fr [192.93.2.38]) by yquem.inria.fr (Postfix) with ESMTP id 14B59BC69 for ; Mon, 30 Apr 2007 15:08:37 +0200 (CEST) Received: from nz-out-0506.google.com (nz-out-0506.google.com [64.233.162.237]) by discorde.inria.fr (8.13.6/8.13.6) with ESMTP id l3UD8ZE5004617 for ; Mon, 30 Apr 2007 15:08:36 +0200 Received: by nz-out-0506.google.com with SMTP id l8so2049643nzf for ; Mon, 30 Apr 2007 06:08:35 -0700 (PDT) DKIM-Signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; 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; b=sXyBnuJQ5fs2R8wVEYOer6XNwt6pOeNj4Y19cmcb49aYbxkWykyHbsYQmkMUd6PaA0rxG9JE2v/tKqx51RMWVa+0XEJu+XelB+7IfiOC2wGahtfPN81u/Nf9iBBXCdSQWzgTw2n2v8G3rOSlhA4seyTHuyjWGXLG/6fOx9PJ/NY= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=liUFnt9cFUzHKyMzs8W4Y1CwFsEL8OmEju/Up/9W3CQw1udZvfpAgmDEyxnZyS2pcvzgrMH+ufEIpO/F2qj5h3z35zhAN+SrbsExPj/+boSa5jCWYBm8xcaz0gmGOmredCzDUponbUUu2nlJrfPZxunhtp0VBpjVuzpfRFw39H4= Received: by 10.115.76.1 with SMTP id d1mr2022432wal.1177938514677; Mon, 30 Apr 2007 06:08:34 -0700 (PDT) Received: by 10.114.181.18 with HTTP; Mon, 30 Apr 2007 06:08:34 -0700 (PDT) Message-ID: Date: Mon, 30 Apr 2007 15:08:34 +0200 From: "Nicolas Pouillard" To: "Joel Reymont" Subject: Re: [Caml-list] camlp4 3.10: MLast.type_decl Cc: "Caml List" In-Reply-To: <255FA5A4-FF6D-4360-9CBF-77DD6EE07B26@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <255FA5A4-FF6D-4360-9CBF-77DD6EE07B26@gmail.com> X-j-chkmail-Score: MSGID : 4635EA53.001 on discorde : j-chkmail score : X : 0/20 1 0.000 -> 1 X-Miltered: at discorde with ID 4635EA53.001 by Joe's j-chkmail (http://j-chkmail . ensmp . fr)! X-Spam: no; 0.00; camlp:01 mlast:01 decl:01 mlast:01 camlp:01 struct:01 sexp:01 ocaml:01 val:01 decl:01 expr:01 struct:01 sig:01 2007,:98 wrote:01 On 4/30/07, Joel Reymont wrote: > Nicolas, > > On Apr 30, 2007, at 1:47 PM, Nicolas Pouillard wrote: > > > MLast is the old module that is now replaced by Camlp4.PreCast.Ast > > Just what I've been looking for. > > module Ast = Struct.Camlp4Ast.Make Loc; > > > In fact pa_sexp_conv.ml is not yet up to date for OCaml 3.10. > > I'm trying to update it as a way of learning camlp4. Hum good idea. > The issue is with the following... > > val add_generator : > string -> > (MLast.type_decl -> (MLast.patt * MLast.expr) list * > MLast.type_decl list) > > I'm looking at various *Ast* files under Camlp4/Struct/ but I can't > figure out the types for the above. Could you point me in the right > direction? Look at camlp4/Camlp4/Camlp4Ast.partial.ml for the AST. camlp4/Camlp4/Sig.ml contains almost all signatures. Here is a traduction of a similar extension: http://gallium.inria.fr/~pouillar/pub/camlp4/rosetta/pa_json_static/ -- Nicolas Pouillard