From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by yquem.inria.fr (Postfix) with ESMTP id ED8CEBC2F for ; Sat, 27 Nov 2004 15:55:08 +0100 (CET) Received: from pauillac.inria.fr (pauillac.inria.fr [128.93.11.35]) by concorde.inria.fr (8.13.0/8.13.0) with ESMTP id iAREt8x8032351 for ; Sat, 27 Nov 2004 15:55:08 +0100 Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id PAA17457 for ; Sat, 27 Nov 2004 15:55:08 +0100 (MET) Received: from smtp1.adl2.internode.on.net (smtp1.adl2.internode.on.net [203.16.214.181]) by nez-perce.inria.fr (8.13.0/8.13.0) with ESMTP id iAREt5ih030034 for ; Sat, 27 Nov 2004 15:55:07 +0100 Received: from [192.168.1.200] (ppp217-171.lns1.syd3.internode.on.net [203.122.217.171]) by smtp1.adl2.internode.on.net (8.12.9/8.12.9) with ESMTP id iAREt34Y076007 for ; Sun, 28 Nov 2004 01:25:04 +1030 (CST) Subject: Re: [Caml-list] ocamlyacc loop? From: skaller Reply-To: skaller@users.sourceforge.net To: caml-list In-Reply-To: <1101547134.9291.605.camel@pelican.wigram> References: <1101547134.9291.605.camel@pelican.wigram> Content-Type: text/plain Message-Id: <1101567302.5409.13.camel@pelican.wigram> Mime-Version: 1.0 X-Mailer: Ximian Evolution 1.2.2 (1.2.2-4) Date: 28 Nov 2004 01:55:03 +1100 Content-Transfer-Encoding: 7bit X-Miltered: at concorde with ID 41A8954C.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Miltered: at nez-perce with ID 41A89549.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Spam: no; 0.00; caml-list:01 ocamlyacc:01 sourceforge:01 wrote:01 unambiguous:01 ocamlyacc:01 grammar:01 stack:01 argg:01 rec:01 expr:01 ast:01 expr:01 'q':01 glebe:01 X-Spam-Checker-Version: SpamAssassin 3.0.0 (2004-09-13) on yquem.inria.fr X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=disabled version=3.0.0 X-Spam-Level: On Sat, 2004-11-27 at 20:18, skaller wrote: > I have an unambiguous ocamlyacc grammar which is dying > on a particular input term with a stack overflow. Argg. no it isn't. Please ignore my message. The problem was actually in the routine *printing* the parse tree. It said the (moral equivalent of): let rec string_of_expr e = match e with | `AST_the q -> "the " ^ string_of_expr e It should have said 'q' not 'e'... :) -- John Skaller, mailto:skaller@users.sf.net voice: 061-2-9660-0850, snail: PO BOX 401 Glebe NSW 2037 Australia Checkout the Felix programming language http://felix.sf.net