mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-10 04:43:03 +00:00
* src/output.h: And put its extern declaration here.
* src/output.c (error_verbose): Define here. (prepare): Echo name modification. * src/getargs.h: Clean its extern declaration. * src/getargs.c (error_verbose_flag): Remove. (getargs): Remove case 'e'. * src/options.c (option_table): 'error-verbose' is now seen as simple percent option. Include output.h. * src/reader.c (read_declarations): Remove case tok_include. (parse_include_decl): Remove. * src/lex.h (token_t): Remove tok_include. * src/options.c (option_table): 'include' is now a simple command line option.
This commit is contained in:
18
ChangeLog
18
ChangeLog
@@ -1,3 +1,21 @@
|
|||||||
|
2001-11-28 Marc Autret <autret_m@epita.fr>
|
||||||
|
|
||||||
|
* src/output.h: And put its extern declaration here.
|
||||||
|
* src/output.c (error_verbose): Define here.
|
||||||
|
(prepare): Echo name modification.
|
||||||
|
* src/getargs.h: Clean its extern declaration.
|
||||||
|
* src/getargs.c (error_verbose_flag): Remove.
|
||||||
|
(getargs): Remove case 'e'.
|
||||||
|
* src/options.c (option_table): 'error-verbose' is now seen as simple
|
||||||
|
percent option.
|
||||||
|
Include output.h.
|
||||||
|
|
||||||
|
* src/reader.c (read_declarations): Remove case tok_include.
|
||||||
|
(parse_include_decl): Remove.
|
||||||
|
* src/lex.h (token_t): Remove tok_include.
|
||||||
|
* src/options.c (option_table): 'include' is now a simple command line
|
||||||
|
option.
|
||||||
|
|
||||||
2001-11-28 Marc Autret <autret_m@epita.fr>
|
2001-11-28 Marc Autret <autret_m@epita.fr>
|
||||||
|
|
||||||
* src/bison.simple: Adjust muscle names.
|
* src/bison.simple: Adjust muscle names.
|
||||||
|
|||||||
@@ -34,7 +34,6 @@ int no_lines_flag = 0;
|
|||||||
int no_parser_flag = 0;
|
int no_parser_flag = 0;
|
||||||
int token_table_flag = 0;
|
int token_table_flag = 0;
|
||||||
int verbose_flag = 0;
|
int verbose_flag = 0;
|
||||||
int error_verbose_flag = 0;
|
|
||||||
int yacc_flag = 0; /* for -y */
|
int yacc_flag = 0; /* for -y */
|
||||||
int graph_flag = 0;
|
int graph_flag = 0;
|
||||||
int trace_flag = 0;
|
int trace_flag = 0;
|
||||||
@@ -166,10 +165,6 @@ getargs (int argc, char *argv[])
|
|||||||
verbose_flag = 1;
|
verbose_flag = 1;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 'e':
|
|
||||||
error_verbose_flag = 1;
|
|
||||||
break;
|
|
||||||
|
|
||||||
case 'S':
|
case 'S':
|
||||||
skeleton = optarg;
|
skeleton = optarg;
|
||||||
break;
|
break;
|
||||||
|
|||||||
@@ -34,7 +34,6 @@ extern int no_lines_flag; /* for -l */
|
|||||||
extern int no_parser_flag; /* for -n */
|
extern int no_parser_flag; /* for -n */
|
||||||
extern int token_table_flag; /* for -k */
|
extern int token_table_flag; /* for -k */
|
||||||
extern int verbose_flag; /* for -v */
|
extern int verbose_flag; /* for -v */
|
||||||
extern int error_verbose_flag; /* for -e */
|
|
||||||
extern int graph_flag; /* for -g */
|
extern int graph_flag; /* for -g */
|
||||||
extern int yacc_flag; /* for -y */
|
extern int yacc_flag; /* for -y */
|
||||||
extern int trace_flag;
|
extern int trace_flag;
|
||||||
|
|||||||
@@ -50,7 +50,6 @@ typedef enum token_e
|
|||||||
tok_thong,
|
tok_thong,
|
||||||
tok_define,
|
tok_define,
|
||||||
tok_skel,
|
tok_skel,
|
||||||
tok_include,
|
|
||||||
tok_noop,
|
tok_noop,
|
||||||
tok_intopt,
|
tok_intopt,
|
||||||
tok_stropt,
|
tok_stropt,
|
||||||
|
|||||||
@@ -27,6 +27,7 @@
|
|||||||
#include "gram.h"
|
#include "gram.h"
|
||||||
#include "symtab.h"
|
#include "symtab.h"
|
||||||
#include "lex.h"
|
#include "lex.h"
|
||||||
|
#include "output.h"
|
||||||
#include "options.h"
|
#include "options.h"
|
||||||
|
|
||||||
/* Shorts options. */
|
/* Shorts options. */
|
||||||
@@ -50,6 +51,7 @@ const struct option_table_struct option_table[] =
|
|||||||
/* Parser. */
|
/* Parser. */
|
||||||
/* was 'a'; apparently unused -wjh */
|
/* was 'a'; apparently unused -wjh */
|
||||||
{opt_cmd_line, "name-prefix", required_argument, 0, 0, 'p'},
|
{opt_cmd_line, "name-prefix", required_argument, 0, 0, 'p'},
|
||||||
|
{opt_cmd_line, "include", required_argument, 0, 0, 'I'},
|
||||||
|
|
||||||
/* Output. */
|
/* Output. */
|
||||||
{opt_cmd_line, "file-prefix", required_argument, 0, 0, 'b'},
|
{opt_cmd_line, "file-prefix", required_argument, 0, 0, 'b'},
|
||||||
@@ -80,6 +82,7 @@ const struct option_table_struct option_table[] =
|
|||||||
{opt_percent, "nonassoc", 0, NULL, tok_nonassoc, 0},
|
{opt_percent, "nonassoc", 0, NULL, tok_nonassoc, 0},
|
||||||
{opt_percent, "binary", 0, NULL, tok_nonassoc, 0},
|
{opt_percent, "binary", 0, NULL, tok_nonassoc, 0},
|
||||||
{opt_percent, "prec", 0, NULL, tok_prec, 0},
|
{opt_percent, "prec", 0, NULL, tok_prec, 0},
|
||||||
|
{opt_percent, "error-verbose", 0, &error_verbose, tok_intopt, 0},
|
||||||
|
|
||||||
/* FIXME: semantic parsers will output an `include' of an
|
/* FIXME: semantic parsers will output an `include' of an
|
||||||
output file: be sure that the naem included is indeed the name of
|
output file: be sure that the naem included is indeed the name of
|
||||||
@@ -104,7 +107,6 @@ const struct option_table_struct option_table[] =
|
|||||||
/* Output. */
|
/* Output. */
|
||||||
{opt_both, "defines", optional_argument, &defines_flag, tok_intopt, 'd'},
|
{opt_both, "defines", optional_argument, &defines_flag, tok_intopt, 'd'},
|
||||||
{opt_both, "verbose", no_argument, &verbose_flag, tok_intopt, 'v'},
|
{opt_both, "verbose", no_argument, &verbose_flag, tok_intopt, 'v'},
|
||||||
{opt_both, "error-verbose", no_argument,&error_verbose_flag, tok_intopt, 'e'},
|
|
||||||
|
|
||||||
/* Operation modes. */
|
/* Operation modes. */
|
||||||
{opt_both, "fixed-output-files", no_argument, &yacc_flag, tok_intopt, 'y'},
|
{opt_both, "fixed-output-files", no_argument, &yacc_flag, tok_intopt, 'y'},
|
||||||
@@ -117,7 +119,6 @@ const struct option_table_struct option_table[] =
|
|||||||
{opt_both, "no-parser", no_argument, &no_parser_flag, tok_intopt, 'n'},
|
{opt_both, "no-parser", no_argument, &no_parser_flag, tok_intopt, 'n'},
|
||||||
{opt_both, "raw", no_argument, 0, tok_obsolete, 'r'},
|
{opt_both, "raw", no_argument, 0, tok_obsolete, 'r'},
|
||||||
{opt_both, "skeleton", required_argument, 0, tok_skel, 'S'},
|
{opt_both, "skeleton", required_argument, 0, tok_skel, 'S'},
|
||||||
{opt_both, "include", required_argument, 0, tok_include, 'I'},
|
|
||||||
{opt_both, "token-table", no_argument, &token_table_flag, tok_intopt, 'k'},
|
{opt_both, "token-table", no_argument, &token_table_flag, tok_intopt, 'k'},
|
||||||
|
|
||||||
{0, 0, 0, 0, 0, 0}
|
{0, 0, 0, 0, 0, 0}
|
||||||
|
|||||||
@@ -125,6 +125,8 @@ static int high;
|
|||||||
struct obstack muscle_obstack;
|
struct obstack muscle_obstack;
|
||||||
struct obstack output_obstack;
|
struct obstack output_obstack;
|
||||||
|
|
||||||
|
int error_verbose = 0;
|
||||||
|
|
||||||
/* FIXME. */
|
/* FIXME. */
|
||||||
|
|
||||||
static inline void
|
static inline void
|
||||||
@@ -1052,7 +1054,7 @@ prepare (void)
|
|||||||
MUSCLE_INSERT_INT ("final", final_state);
|
MUSCLE_INSERT_INT ("final", final_state);
|
||||||
MUSCLE_INSERT_INT ("maxtok", max_user_token_number);
|
MUSCLE_INSERT_INT ("maxtok", max_user_token_number);
|
||||||
MUSCLE_INSERT_INT ("ntbase", ntokens);
|
MUSCLE_INSERT_INT ("ntbase", ntokens);
|
||||||
MUSCLE_INSERT_INT ("error-verbose", error_verbose_flag);
|
MUSCLE_INSERT_INT ("error-verbose", error_verbose);
|
||||||
|
|
||||||
MUSCLE_INSERT_INT ("nnts", nvars);
|
MUSCLE_INSERT_INT ("nnts", nvars);
|
||||||
MUSCLE_INSERT_INT ("nrules", nrules);
|
MUSCLE_INSERT_INT ("nrules", nrules);
|
||||||
|
|||||||
@@ -21,6 +21,8 @@
|
|||||||
#ifndef OUTPUT_H_
|
#ifndef OUTPUT_H_
|
||||||
# define OUTPUT_H_
|
# define OUTPUT_H_
|
||||||
|
|
||||||
|
extern int error_verbose;
|
||||||
|
|
||||||
/* Output the parsing tables and the parser code to FTABLE. */
|
/* Output the parsing tables and the parser code to FTABLE. */
|
||||||
void output PARAMS ((void));
|
void output PARAMS ((void));
|
||||||
|
|
||||||
|
|||||||
14
src/reader.c
14
src/reader.c
@@ -974,16 +974,6 @@ parse_skel_decl (void)
|
|||||||
/* Complete with parse_dquoted_param () on the CVS branch 1.29. */
|
/* Complete with parse_dquoted_param () on the CVS branch 1.29. */
|
||||||
}
|
}
|
||||||
|
|
||||||
/*---------------------------------------.
|
|
||||||
| Parse what comes after %skeleton_path. |
|
|
||||||
`---------------------------------------*/
|
|
||||||
|
|
||||||
void
|
|
||||||
parse_include_decl (void)
|
|
||||||
{
|
|
||||||
/* Complete with parse_dquoted_param () on the CVS branch 1.29. */
|
|
||||||
}
|
|
||||||
|
|
||||||
/*----------------------------------------------------------------.
|
/*----------------------------------------------------------------.
|
||||||
| Read from finput until `%%' is seen. Discard the `%%'. Handle |
|
| Read from finput until `%%' is seen. Discard the `%%'. Handle |
|
||||||
| any `%' declarations, and copy the contents of any `%{ ... %}' |
|
| any `%' declarations, and copy the contents of any `%{ ... %}' |
|
||||||
@@ -1058,10 +1048,6 @@ read_declarations (void)
|
|||||||
parse_skel_decl ();
|
parse_skel_decl ();
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case tok_include:
|
|
||||||
parse_include_decl ();
|
|
||||||
break;
|
|
||||||
|
|
||||||
case tok_noop:
|
case tok_noop:
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user