Test and fix the #line outputs.

* tests/atlocal.at (GCC): New.
* tests/synclines.at (AT_TEST_SYNCLINE): New macro.
(Prologue synch line, ,%union synch line, Postprologue synch line)
(Action synch line, Epilogue synch line): New tests.
* src/reader.c (parse_union_decl): Define the muscle stype_line.
* data/bison.simple, data/bison.c++: Use it.
This commit is contained in:
Akim Demaille
2002-03-19 08:16:25 +00:00
parent 3c31a486e7
commit 642cb8f829
8 changed files with 150 additions and 1 deletions

View File

@@ -109,6 +109,9 @@ b4_token_defines
#endif
#ifndef YYSTYPE
m4_ifdef([b4_stype_line],
[#line b4_stype_line "b4_filename"
])dnl
typedef b4_stype
yystype;
# define YYSTYPE yystype

View File

@@ -110,6 +110,9 @@ b4_prologue
#endif
#ifndef YYSTYPE
m4_ifdef([b4_stype_line],
[#line b4_stype_line "b4_filename"
])dnl
typedef b4_stype yystype;
# define YYSTYPE yystype
#endif
@@ -1161,6 +1164,9 @@ m4_if(b4_defines_flag, 0, [],
b4_token_defines(b4_tokens)
#ifndef YYSTYPE
m4_ifdef([b4_stype_line],
[#line b4_stype_line "b4_filename"
])dnl
typedef b4_stype
yystype;
# define YYSTYPE yystype