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=0.0 required=5.0 tests=AWL autolearn=disabled version=3.1.3 Received: from mail4-relais-sop.national.inria.fr (mail4-relais-sop.national.inria.fr [192.134.164.105]) by yquem.inria.fr (Postfix) with ESMTP id 53F9ABB84 for ; Thu, 11 Sep 2008 14:09:35 +0200 (CEST) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AiUCADynyEjAXQImiGdsb2JhbACSZAEBAQ8gpS6BZA X-IronPort-AV: E=Sophos;i="4.32,379,1217800800"; d="scan'208";a="29062691" Received: from discorde.inria.fr ([192.93.2.38]) by mail4-smtp-sop.national.inria.fr with ESMTP; 11 Sep 2008 14:09:35 +0200 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 m8BC9Y5v018431 (version=TLSv1/SSLv3 cipher=RC4-SHA bits=128 verify=OK) for ; Thu, 11 Sep 2008 14:09:34 +0200 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: ApoEADynyEhREHR+/2dsb2JhbAC4RIFk X-IronPort-AV: E=Sophos;i="4.32,379,1217800800"; d="scan'208";a="14826705" Received: from unknown (HELO office.stork.ru) ([81.16.116.126]) by mail2-smtp-roc.national.inria.fr with ESMTP/TLS/DHE-RSA-AES256-SHA; 11 Sep 2008 14:09:34 +0200 Received: from [192.168.21.130] (serp [192.168.21.130]) by office.stork.ru (8.13.5/8.13.5) with ESMTP id m8BC9QSv009722; Thu, 11 Sep 2008 16:09:31 +0400 Subject: Re: [Caml-list] Camlp4. print variable value to target source. From: =?UTF-8?Q?=D0=A1=D0=B5=D1=80=D0=B3=D0=B5=D0=B9_?= =?UTF-8?Q?=D0=9F=D0=BB=D0=B0=D0=BA=D1=81=D0=B8=D0=BD?= To: David Teller Cc: Caml List In-Reply-To: <1221134550.6226.10.camel@Blefuscu> References: <1221128186.15737.10.camel@serphost.localdomain> <1221134550.6226.10.camel@Blefuscu> Content-Type: text/plain; charset=utf-8 Date: Thu, 11 Sep 2008 16:09:24 +0400 Message-Id: <1221134964.15737.14.camel@serphost.localdomain> Mime-Version: 1.0 X-Mailer: Evolution 2.22.3.1 Content-Transfer-Encoding: 8bit X-Miltered: at discorde with ID 48C90A7E.000 by Joe's j-chkmail (http://j-chkmail . ensmp . fr)! X-Spam: no; 0.00; camlp:01 0100,:01 ctyp:01 cheers:01 ctyp:01 camlp:01 syntax:01 syntax:01 expr:01 expr:01 exited:01 W12:98 W14:98 W12:98 W14:98 On Thu, 2008-09-11 at 13:02 +0100, David Teller wrote: > On Thu, 2008-09-11 at 14:16 +0400, Сергей Плаксин wrote: > > Exitst any way to do such things? > > > > ------ > > let t = <:ctyp> in > > <:str_item> > > ---- > > || > > ----- > > let t = Ast.TyId (_loc, Ast.IdLid (_loc, "int")); > > ----- > > That doesn't look correctly typed. However, you can try > replacing ?contents of t here? with $t$. > > Cheers, > David > let t = <:ctyp> in <:str_item> ===== This expression has type Camlp4.PreCast.Syntax.Ast.ctyp = Camlp4.PreCast.Ast.ctyp but is here used with type Camlp4.PreCast.Syntax.Ast.expr = Camlp4.PreCast.Ast.expr Command exited with code 2.