From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by yquem.inria.fr (Postfix) with ESMTP id 10094BB81 for ; Fri, 18 Nov 2005 15:59:11 +0100 (CET) Received: from uni-sb.de (uni-sb.de [134.96.252.33]) by concorde.inria.fr (8.13.0/8.13.0) with ESMTP id jAIExA9g031622 for ; Fri, 18 Nov 2005 15:59:10 +0100 Received: from mail.cs.uni-sb.de (mail.cs.uni-sb.de [134.96.254.200]) by uni-sb.de (8.13.5/2005092000) with ESMTP id jAIEx01n022025; Fri, 18 Nov 2005 15:59:00 +0100 (CET) Received: from mail.st.cs.uni-sb.de (goscinny.cs.uni-sb.de [134.96.235.32]) by mail.cs.uni-sb.de (8.13.5/2005101700) with ESMTP id jAIEwx45008097; Fri, 18 Nov 2005 15:59:00 +0100 (CET) Received: from [134.96.235.101] (jonagold.cs.uni-sb.de [134.96.235.101]) by mail.st.cs.uni-sb.de (Postfix) with ESMTP id A81631BD80; Fri, 18 Nov 2005 15:58:59 +0100 (CET) In-Reply-To: <1132322923.10869.29.camel@rosella> References: <1132322923.10869.29.camel@rosella> Mime-Version: 1.0 (Apple Message framework v623) Content-Type: text/plain; charset=US-ASCII; format=flowed Message-Id: <2b8098c834c2610cd340979587c81279@cs.uni-sb.de> Content-Transfer-Encoding: 7bit Cc: caml-list@yquem.inria.fr From: Christian Lindig Subject: Re: [Caml-list] ocamlyacc -- can i tell it to be quiet? Date: Fri, 18 Nov 2005 15:58:57 +0100 To: skaller X-Mailer: Apple Mail (2.623) X-Miltered: at concorde with ID 437DEC3E.001 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Spam: no; 0.00; lindig:01 lindig:01 caml-list:01 ocamlyacc:01 parsing:01 foo:01 foo:01 wrote:01 uni-sb:01 precedence:01 precedence:01 yacc:06 file:08 requires:12 kind:12 X-Spam-Checker-Version: SpamAssassin 3.0.3 (2005-04-27) on yquem.inria.fr X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=disabled version=3.0.3 On Nov 18, 2005, at 3:08 PM, skaller wrote: > Is there any way to tell it to shut up? If you have a shift/reduce conflict the default action is to shift. To get rid of the warning declare a higher precedence for the symbol being shifted. Say, there is a conflict when parsing FOO BAR - FOO could be reduced or BAR being shifted; declare in your Yacc file: %nonassoc FOO %nonassoc BAR Nor BAR has higher precedence and gets shifted without creating a conflict. Obviously, this kind of conflict resolution requires some care. -- Christian