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_NEUTRAL autolearn=disabled version=3.1.3 Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by yquem.inria.fr (Postfix) with ESMTP id 408F6BC69 for ; Mon, 30 Apr 2007 15:06:55 +0200 (CEST) Received: from ug-out-1314.google.com (ug-out-1314.google.com [66.249.92.169]) by concorde.inria.fr (8.13.6/8.13.6) with ESMTP id l3UD6sVE000438 for ; Mon, 30 Apr 2007 15:06:55 +0200 Received: by ug-out-1314.google.com with SMTP id k3so1031838ugf for ; Mon, 30 Apr 2007 06:06:54 -0700 (PDT) DKIM-Signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:in-reply-to:references:mime-version:content-type:message-id:cc:content-transfer-encoding:from:subject:date:to:x-mailer; b=XI89AClFzSn9J43HyfkoLHmVdd9fe7xXcX2KPQvUGoC3eZXAVCu2uCGM346qjs0TEoFVIqP5ANIGplRlc9bh1fHy7b4L9R1tnry6RG+iuo/WiVXd34P0uvg8dQfowEWNVioQzapNFvUVlTwccVp1mC7XEBVfl1JZKNEbu4vTdcE= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:in-reply-to:references:mime-version:content-type:message-id:cc:content-transfer-encoding:from:subject:date:to:x-mailer; b=GGFhaVfyQpH7KKlTyiIMMgbVwS2TvDCer6jnU1CqaNj48RqKeYBE83XR7SWx153YnkLn0pi7xCnCeXqW0oPzIt3vrmKTn2sqdp0z0XVjBG3xuVDkitA4aQ+oUSZQyp4wediW5K/qdwzHUjK8IK+CsDwj6IRQkhq4jnAT6Emy06U= Received: by 10.67.15.15 with SMTP id s15mr5426037ugi.1177938414429; Mon, 30 Apr 2007 06:06:54 -0700 (PDT) Received: from ?192.168.1.34? ( [83.52.237.136]) by mx.google.com with ESMTP id e33sm6827528ugd.2007.04.30.06.06.53; Mon, 30 Apr 2007 06:06:53 -0700 (PDT) In-Reply-To: References: <0DF43C61-05DE-4129-A5F6-06AF8722A8D5@gmail.com> <57FA2AAF-8F53-48B5-BF13-35BC9C825CE9@gmail.com> Mime-Version: 1.0 (Apple Message framework v752.3) Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Message-Id: <98D023E9-E13C-477B-B397-8AD5758CA416@gmail.com> Cc: "Caml List" Content-Transfer-Encoding: 7bit From: Joel Reymont Subject: Re: [Caml-list] AST transformation and scrapping boilerplate code Date: Mon, 30 Apr 2007 14:06:50 +0100 To: "Nicolas Pouillard" X-Mailer: Apple Mail (2.752.3) X-j-chkmail-Score: MSGID : 4635E9EE.004 on concorde : j-chkmail score : XXX : 5/20 1 0.000 -> 3 X-Miltered: at concorde with ID 4635E9EE.004 by Joe's j-chkmail (http://j-chkmail . ensmp . fr)! X-Spam: no; 0.00; camlp:01 camlp:01 ocamlfind:01 ocamlc:01 -package:01 -pp:01 cmo:01 decl:01 decl:01 expr:01 2007,:98 unbound:01 wrote:01 constructor:01 caml-list:01 On Apr 30, 2007, at 1:58 PM, Nicolas Pouillard wrote: > Use camlp4of (since INCLUDE is provided by camlp4 macros). > Also add -filter trash to the camlp4 options (after map and fold), in > order to remove the Camlp4Trash module. Including the AST module worked and I'm almost there. + ocamlfind ocamlc -package ounit -c -I +camlp4 -pp 'camlp4of -filter map -filter fold -filter trash ' -o easy_strip.cmo easy_strip.ml File "ghost-location", line 1, characters 0-0: Unbound type constructor var_decl This is surprising since the AST looks like this, i.e. var_decl is part of it. What is the explanation for this and how should I fix it? ... and statement = [ ... | `VarDecls of var_decl list ... ] ... and var_decl = [ | `VarDecl of id * ty * expr ] Thanks, Joel -- http://wagerlabs.com/