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 X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from discorde.inria.fr (discorde.inria.fr [192.93.2.38]) by yquem.inria.fr (Postfix) with ESMTP id 0AFAEBC69 for ; Mon, 30 Apr 2007 16:07:55 +0200 (CEST) Received: from ug-out-1314.google.com (ug-out-1314.google.com [66.249.92.175]) by discorde.inria.fr (8.13.6/8.13.6) with ESMTP id l3UE7sj7016979 for ; Mon, 30 Apr 2007 16:07:54 +0200 Received: by ug-out-1314.google.com with SMTP id k3so1040951ugf for ; Mon, 30 Apr 2007 07:07: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=n+JixHR4akIEaklWpWDl3esLmuUzVAFiVSLF0jFGFOdN25vdD+tm2qkUUCbao9osngpU2GTVIMdnhGVSb++jnqvKoMWwjLx0aDMf8O2F1vW6JZcgQk5W1o0HTnqX0vO6ZkICz4B8jWQf/Hrpw8lIdxN/uMKdPm3AgiSIGAepdjg= 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=Dy9q1yYa0oLmMtLoh+8zuQnc6JGVZbsldVvGNmMv2UuUX21YeGmKSCN1we3oPXzTjBQJpbxGpdAoqwqZqXMPdLz+hdfkyUxZgAoSjfCQVQuAQgoKloAAm2XJPnms1NQNjd41QCB7E5n65ToYvNNjomRiA+mi0Z5QAjRQMbNSqOk= Received: by 10.67.106.3 with SMTP id i3mr5449358ugm.1177942074442; Mon, 30 Apr 2007 07:07:54 -0700 (PDT) Received: from ?192.168.1.34? ( [83.52.237.136]) by mx.google.com with ESMTP id b35sm12718332ugd.2007.04.30.07.07.53; Mon, 30 Apr 2007 07:07:53 -0700 (PDT) In-Reply-To: References: <220DCCF0-FD2D-4116-8E30-992C1AD3FE95@gmail.com> Mime-Version: 1.0 (Apple Message framework v752.3) Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Message-Id: Cc: "Caml List" Content-Transfer-Encoding: 7bit From: Joel Reymont Subject: Re: Upgrading sexplib-2.7.0 to camlp4 3.10 Date: Mon, 30 Apr 2007 15:07:50 +0100 To: "Nicolas Pouillard" X-Mailer: Apple Mail (2.752.3) X-j-chkmail-Score: MSGID : 4635F83A.001 on discorde : j-chkmail score : XXX : 5/20 1 0.000 -> 3 X-Miltered: at discorde with ID 4635F83A.001 by Joe's j-chkmail (http://j-chkmail . ensmp . fr)! X-Spam: no; 0.00; camlp:01 ctyp:01 camlp:01 ctyp:01 2007,:98 wrote:01 rec:01 matched:01 assert:01 ident:02 ident:02 match:02 arg:03 lid:03 let:03 On Apr 30, 2007, at 3:01 PM, Nicolas Pouillard wrote: > So you have to take the case <:ctyp< $id:i$ >> and then play with `i' > that is an ident and can be matched with <:ident< ... >> It looks like this is being taken care of by the first pattern. It also looks like the second pattern is matching a list type (in the old camlp4). Does this sound correct? let rec tp_path = function | <:ctyp< $lid:id$ >> | <:ctyp< $uid:id$ >> -> [id] | <:ctyp< $tp1$ . $tp2$ >> -> (match tp_path tp2 with [n] -> n | _ -> assert false) :: tp_path tp1 | _ -> invalid_arg "tp_path" Thanks, Joel -- http://wagerlabs.com/