mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-13 06:13:02 +00:00
* src/getargs.c (longopts): Declare --defines and --graph as options
with optional arguments. * src/files.h: Add extern declarations. * src/files.c (spec_graph_file, spec_defines_file): New. (output_files): Update. Remove CPP-outed code.
This commit is contained in:
@@ -60,11 +60,11 @@ static struct option longopts[] =
|
||||
{"token-table", no_argument, 0, 'k'},
|
||||
|
||||
/* Output. */
|
||||
{"defines", no_argument, 0, 'd'},
|
||||
{"defines", optional_argument, 0, 'd'},
|
||||
{"verbose", no_argument, 0, 'v'},
|
||||
{"file-prefix", required_argument, 0, 'b'},
|
||||
{"output-file", required_argument, 0, 'o'},
|
||||
{"graph", no_argument, 0, 'g'},
|
||||
{"graph", optional_argument, 0, 'g'},
|
||||
|
||||
/* Hidden. */
|
||||
{"statistics", no_argument, &statistics_flag, 1},
|
||||
@@ -183,7 +183,9 @@ getargs (int argc, char *argv[])
|
||||
exit (0);
|
||||
|
||||
case 'g':
|
||||
/* Here, the -g and --graph=FILE options are differentiated. */
|
||||
graph_flag = 1;
|
||||
spec_graph_file = optarg;
|
||||
break;
|
||||
|
||||
case 'v':
|
||||
@@ -195,7 +197,9 @@ getargs (int argc, char *argv[])
|
||||
break;
|
||||
|
||||
case 'd':
|
||||
/* Here, the -d and --defines options are differentiated. */
|
||||
defines_flag = 1;
|
||||
spec_defines_file = optarg;
|
||||
break;
|
||||
|
||||
case 'l':
|
||||
|
||||
Reference in New Issue
Block a user