[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
parse error in gcc 3.2 with bison 1.875
From: |
sigbert |
Subject: |
parse error in gcc 3.2 with bison 1.875 |
Date: |
Tue, 17 Jun 2003 09:16:41 +0200 |
Hi,
it seems I have a problem with bison 1.875 and gcc 3.2. If I compile my y.tab.c
file I get the
error message:
g++ -c -x c++ y.tab.c
y.tab.c: In function `int yyparse()':
y.tab.c:1548: parse error before `goto'
make: *** [skwin] Error 1
This happens under Cygwin & MinGW as well as under Solaris 2.8. It does not
happen
under MinGW 2.95.3 & bison 1.35. If uncomment the line
__attribute__ ((__unused__))
then y.tab.c compiles also under gcc 3.2.
Sigbert Klinke
----- Makefile ----
skwin:
flex parser-1.l
bison -y -d parser-1.y
g++ -c -x c++ YCommand.c
g++ -c -x c++ YMain.c
g++ -c -x c++ lex.yy.c
g++ -c -x c++ y.tab.c
--- Error message ----
$ make skwin
flex parser-1.l
bison -y -d parser-1.y
conflicts: 25 shift/reduce, 10 reduce/reduce
g++ -c -x c++ YCommand.c
g++ -c -x c++ YMain.c
g++ -c -x c++ lex.yy.c
g++ -c -x c++ y.tab.c
y.tab.c: In function `int yyparse()':
y.tab.c:1548: parse error before `goto'
make: *** [skwin] Error 1
---- source code of y.tab.c -----
yyerrlab1:
/* Suppress GCC warning that yyerrlab1 is unused when no action
invokes YYERROR. */
#if defined (__GNUC_MINOR__) && 2093 <= (__GNUC__ * 1000 + __GNUC_MINOR__)
__attribute__ ((__unused__))
#endif
// this line is line 1548
goto yyerrlab2;
--------------
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- parse error in gcc 3.2 with bison 1.875,
sigbert <=