[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: type clash on default action: <NONE> != <>
From: |
Paul Eggert |
Subject: |
Re: type clash on default action: <NONE> != <> |
Date: |
Sun, 8 Dec 2002 20:52:57 -0800 (PST) |
> Date: Sun, 8 Dec 2002 12:57:29 +0100 (CET)
> From: Martin MOKREJS <address@hidden>
> $ dbx /software/@sys/usr/bin/bison ./core
Ah, I see the problem now; Bison mishandles the case where you install
Bison into a directory whose name contains '@'. Thanks for following
this up with more details. I have installed the following patch,
which should appear in the next Bison version.
2002-12-08 Paul Eggert <address@hidden>
* data/glr.c, data/lalr1.cc, data/yacc.c: Do not use __file__,
since this causes problems when __file__ contains character
sequences like "@" that are treated specially by src/scan-skel.l.
Instead, just use the file's basename. This fixes the bug
reported by Martin Mokrejs in
<http://mail.gnu.org/pipermail/bug-bison/2002-December/001949.html>.
Index: data/glr.c
===================================================================
RCS file: /cvsroot/bison/bison/data/glr.c,v
retrieving revision 1.43
diff -p -u -r1.43 glr.c
--- data/glr.c 7 Dec 2002 05:45:46 -0000 1.43
+++ data/glr.c 9 Dec 2002 04:46:24 -0000
@@ -187,7 +187,7 @@ b4_pre_prologue[
]m4_ifdef([b4_stype],
[b4_syncline([b4_stype_line], [b4_filename])
typedef union b4_stype yystype;
-/* Line __line__ of __file__. */
+/* Line __line__ of glr.c. */
b4_syncline(address@hidden@], address@hidden@])],
[typedef int yystype;])[
# define YYSTYPE yystype
@@ -217,7 +217,7 @@ static YYLTYPE yyloc_default;
/* Copy the second part of user declarations. */
]b4_post_prologue[
-]/* Line __line__ of __file__. */
+]/* Line __line__ of glr.c. */
b4_syncline(address@hidden@], address@hidden@])
[
#if ! defined (__cplusplus)
@@ -671,7 +671,7 @@ yyuserAction (yyRuleNum yyn, int yyrhsle
# undef YYBACKUP
# undef yyclearin
# undef YYRECOVERING
-/* Line __line__ of __file__. */
+/* Line __line__ of glr.c. */
b4_syncline(address@hidden@], address@hidden@])
}
@@ -1959,7 +1959,7 @@ b4_token_defines(b4_tokens)
m4_ifdef([b4_stype],
[b4_syncline([b4_stype_line], [b4_filename])
typedef union b4_stype yystype;
-/* Line __line__ of __file__. */
+/* Line __line__ of glr.c. */
b4_syncline(address@hidden@], address@hidden@])],
[typedef int yystype;])
# define YYSTYPE yystype
Index: data/lalr1.cc
===================================================================
RCS file: /cvsroot/bison/bison/data/lalr1.cc,v
retrieving revision 1.16
diff -p -u -r1.16 lalr1.cc
--- data/lalr1.cc 16 Nov 2002 12:31:35 -0000 1.16
+++ data/lalr1.cc 9 Dec 2002 04:46:25 -0000
@@ -111,7 +111,7 @@ b4_copyright([C++ Skeleton parser for LA
/* Copy the first part of user declarations. */
]b4_pre_prologue[
-]/* Line __line__ of __file__. */
+]/* Line __line__ of lalr1.cc. */
b4_syncline(address@hidden@], address@hidden@])[
/* Enabling traces. */
@@ -128,7 +128,7 @@ b4_syncline(address@hidden@], address@hidden@])[
]m4_ifdef([b4_stype],
[b4_syncline([b4_stype_line], [b4_filename])
typedef union b4_stype yystype;
-/* Line __line__ of __file__. */
+/* Line __line__ of lalr1.cc. */
b4_syncline(address@hidden@], address@hidden@])],
[typedef int yystype;])[
# define YYSTYPE yystype
@@ -137,7 +137,7 @@ b4_syncline(address@hidden@], address@hidden@])],
/* Copy the second part of user declarations. */
]b4_post_prologue[
-]/* Line __line__ of __file__. */
+]/* Line __line__ of lalr1.cc. */
b4_syncline(address@hidden@], address@hidden@])[
#ifndef YYLLOC_DEFAULT
# define YYLLOC_DEFAULT(Current, Rhs, N) \
@@ -445,7 +445,7 @@ yy::]b4_parser_class_name[::parse ()
]b4_actions[
}
-]/* Line __line__ of __file__. */
+]/* Line __line__ of lalr1.cc. */
b4_syncline(address@hidden@], address@hidden@])[
state_stack_.pop (len_);
Index: data/yacc.c
===================================================================
RCS file: /cvsroot/bison/bison/data/yacc.c,v
retrieving revision 1.40
diff -p -u -r1.40 yacc.c
--- data/yacc.c 7 Dec 2002 05:46:30 -0000 1.40
+++ data/yacc.c 9 Dec 2002 04:46:25 -0000
@@ -190,7 +190,7 @@ b4_location_if([#define yylloc b4_prefix
]m4_ifdef([b4_stype],
[b4_syncline([b4_stype_line], [b4_filename])
typedef union b4_stype yystype;
-/* Line __line__ of __file__. */
+/* Line __line__ of yacc.c. */
b4_syncline(address@hidden@], address@hidden@])],
[typedef int yystype;])[
# define YYSTYPE yystype
@@ -212,7 +212,7 @@ typedef struct yyltype
/* Copy the second part of user declarations. */
]b4_post_prologue
-/* Line __line__ of __file__. */
+/* Line __line__ of yacc.c. */
b4_syncline(address@hidden@], address@hidden@])[
#if ! defined (yyoverflow) || YYERROR_VERBOSE
@@ -988,7 +988,7 @@ yyreduce:
b4_actions
}
-/* Line __line__ of __file__. */
+/* Line __line__ of yacc.c. */
b4_syncline(address@hidden@], address@hidden@])
[ yyvsp -= yylen;
@@ -1197,7 +1197,7 @@ b4_token_defines(b4_tokens)
m4_ifdef([b4_stype],
[b4_syncline([b4_stype_line], [b4_filename])
typedef union b4_stype yystype;
-/* Line __line__ of __file__. */
+/* Line __line__ of yacc.c. */
b4_syncline(address@hidden@], address@hidden@])],
[typedef int yystype;])
# define YYSTYPE yystype
- Re: type clash on default action: <NONE> != <>,
Paul Eggert <=