From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from majordomo@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id UAA14405; Wed, 6 Feb 2002 20:17:23 +0100 (MET) X-Authentication-Warning: pauillac.inria.fr: majordomo set sender to owner-caml-list@pauillac.inria.fr using -f Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id UAA13902 for ; Wed, 6 Feb 2002 20:17:22 +0100 (MET) Received: from scaup.prod.itd.earthlink.net (scaup.mail.pas.earthlink.net [207.217.120.49]) by concorde.inria.fr (8.11.1/8.11.1) with ESMTP id g16JHLn17522; Wed, 6 Feb 2002 20:17:21 +0100 (MET) Received: from user-0cceggg.cable.mindspring.com ([24.199.66.16] helo=flapdragon.homeip.net) by scaup.prod.itd.earthlink.net with esmtp (Exim 3.33 #1) id 16YXZH-0005hV-00; Wed, 06 Feb 2002 11:17:19 -0800 Subject: Re: [Caml-list] camlp4o problem (was: otags problem) From: "Yaron M. Minsky" To: Daniel de Rauglaudre Cc: caml-list@inria.fr In-Reply-To: <20020205171311.R23898@verdot.inria.fr> References: <9BE7FA48-1771-11D6-A336-003065BDAA76@ece.ucsb.edu> <15454.38553.300800.53941@gargle.gargle.HOWL> <20020204155242.B2338@verdot.inria.fr> <15455.62821.983393.899624@gargle.gargle.HOWL> <20020205171311.R23898@verdot.inria.fr> Content-Type: text/plain Content-Transfer-Encoding: 7bit X-Mailer: Evolution/1.0.2 Date: 06 Feb 2002 14:17:17 -0500 Message-Id: <1013023039.1488.4.camel@dragonfly.localdomain> Mime-Version: 1.0 Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk I've found a similar oddity with respect to camlp4 and the % infix operator. In particular: dragonfly: yminsky $ ocaml Objective Caml version 3.04 # #load "camlp4o.cma";; Camlp4 Parsing version 3.04 # let ( % ) x y = x + y;; val ( % ) : int -> int -> int = # 3 % 4;; Toplevel input: # 3 % 4;; ^ Parse error: ';;' expected after [phrase] (in [top_phrase]) # The above works normally if you don't load camlp4o first. Any clues as to what might be going on? y On Tue, 2002-02-05 at 11:13, Daniel de Rauglaudre wrote: > Hi, > > On Tue, Feb 05, 2002 at 04:08:21PM +0100, Hendrik Tews wrote: > > > I would like to have this flag. > > Ok, I added it: > > $ ocaml > Objective Caml version 3.04+5 (2002-02-01) > > # #load "camlp4o.cma";; > Camlp4 Parsing version 3.04+5 (2002-02-01) > > # let ( <:> ) x y = x + y;; > Toplevel input: > # let ( <:> ) x y = x + y;; > ^ > Lexing error: character '<' expected > # Plexer.no_quotations := true;; > - : unit = () > # let ( <:> ) x y = x + y;; > > > Well, what I meant is that > > - camlp4o parses a file if and only if ocamlc parses it, and > > - the resulting ast's are semantically equivalent. > > And what I meant is: > - this is impossible > - I can just try to be as close as possible > > > Further there is no grammar for the revised syntax. > > BTW, is there a grammar for the normal syntax? I didn't find it in > the documentation. > > With Camlp4, you can print the syntax of expressions by typing: > Grammar.Entry.print Pcaml.expr > > Well, I am thinking of using this function to print the syntax of all > grammar in LateX or HTML or so. > > -- > Daniel de RAUGLAUDRE > daniel.de_rauglaudre@inria.fr > http://cristal.inria.fr/~ddr/ > ------------------- > Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/ > To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr > -- |--------/ Yaron M. Minsky \--------| |--------\ http://www.cs.cornell.edu/home/yminsky/ /--------| Open PGP --- KeyID B1FFD916 (new key as of Dec 4th) Fingerprint: 5BF6 83E1 0CE3 1043 95D8 F8D5 9F12 B3A9 B1FF D916 ------------------- Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/ To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr