mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-10 21:03:04 +00:00
* data/bison.c++: s/b4_item_number_max/b4_rhs_number_max/.
Adding #line. Remove the duplicate `typedefs'. (RhsNumberType): Fix the declaration and various other typos. Use __ofile__. * data/bison.simple: Use __ofile__. * src/scan-skel.l: Handle __ofile__.
This commit is contained in:
@@ -26,16 +26,20 @@
|
||||
#include "files.h"
|
||||
int skel_lex PARAMS ((void));
|
||||
static int yylineno = 1;
|
||||
static char *yyoutname = NULL;
|
||||
%}
|
||||
%%
|
||||
/* This is an approximation, but we don't need more. */
|
||||
^"#output \""[^\"]+\"\n {
|
||||
yytext[yyleng - 2] = '\0';
|
||||
skel_out = xfopen (yytext + strlen ("#output \""), "w");
|
||||
XFREE (yyoutname);
|
||||
yyoutname = xstrdup (yytext + strlen ("#output \""));
|
||||
yyout = xfopen (yyoutname, "w");
|
||||
yylineno = 1;
|
||||
}
|
||||
|
||||
"__oline__" fprintf (yyout, "%d", yylineno);
|
||||
"__ofile__" fprintf (yyout, "%s", yyoutname);
|
||||
[^_\n]+ ECHO;
|
||||
\n+ yylineno += yyleng; ECHO;
|
||||
. ECHO;
|
||||
|
||||
Reference in New Issue
Block a user