X-Spam-Check-By: sourceware.org Message-ID: <442AB769.1040303@maplesoft.com> Date: Wed, 29 Mar 2006 11:35:53 -0500 From: Stefan Vorkoetter User-Agent: Thunderbird 1.5 (Windows/20051201) MIME-Version: 1.0 To: cygwin AT cygwin DOT com Subject: bison bug References: <442AA72A DOT 7040107 AT maplesoft DOT com> <20060329155247 DOT GA4924 AT trixie DOT casa DOT cgf DOT cx> In-Reply-To: <20060329155247.GA4924@trixie.casa.cgf.cx> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com The latest version of bison appears to be broken. Regardless of the grammar input file, the generated y.tab.c file contains a syntax error in the definition of yyparse when __STDC__ and YYPARSE_PARAM are not defined. Specifically, the generated code looks like: int yyparse () ; { int yystate; ... That first ; should not be there. I'm not a bison internals expert, but I see that it's using m4 to do most of its work. I'm no m4 expert either, so I can't tell if the problem is in the bison input file, or a bug in m4. ~ [518] $ bison --version bison (GNU Bison) 2.1 Written by Robert Corbett and Richard Stallman. ~ [519] $ m4 --version GNU M4 1.4.4 Written by Rene' Seindal. I used the following trivial grammar file, grammar.y, to reproduce the bug: %{ #define YYMAXDEPTH 1024 %} %token A B %% C: A B { } ; Then, the command line bison -y -d grammar.y produces a y.tab.c file with the offending error on line 828. -- Stefan Vorkoetter Maplesoft -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/