]> git.saurik.com Git - bison.git/blob - src/files.h
* doc/bison.texinfo (Push Decl): Document the push parser.
[bison.git] / src / files.h
1 /* File names and variables for bison,
2
3 Copyright (C) 1984, 1989, 2000, 2001, 2002, 2006, 2007 Free Software
4 Foundation, Inc.
5
6 This file is part of Bison, the GNU Compiler Compiler.
7
8 This program is free software: you can redistribute it and/or modify
9 it under the terms of the GNU General Public License as published by
10 the Free Software Foundation, either version 3 of the License, or
11 (at your option) any later version.
12
13 This program is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 GNU General Public License for more details.
17
18 You should have received a copy of the GNU General Public License
19 along with this program. If not, see <http://www.gnu.org/licenses/>. */
20
21 #ifndef FILES_H_
22 # define FILES_H_
23
24 # include "uniqstr.h"
25
26 /* File name specified with -o for the output file, or 0 if no -o. */
27 extern char const *spec_outfile;
28
29 /* File name for the parser (i.e., the one above, or its default.) */
30 extern char *parser_file_name;
31
32 /* Symbol prefix specified with -p, or 0 if no -p. */
33 extern const char *spec_name_prefix;
34
35 /* File name prefix specified with -b, or 0 if no -b. */
36 extern char const *spec_file_prefix;
37
38 /* --verbose. */
39 extern char *spec_verbose_file;
40
41 /* File name specified for the output graph. */
42 extern char *spec_graph_file;
43
44 /* File name specified with --defines. */
45 extern char *spec_defines_file;
46
47 /* Directory prefix of output file names. */
48 extern char *dir_prefix;
49
50 /* The file name as given on the command line.
51 Not named "input_file" because Flex uses this name for an argument,
52 and therefore GCC warns about a name clash. */
53 extern uniqstr grammar_file;
54
55 /* The current file name. Might change with %include, or with #line. */
56 extern uniqstr current_file;
57
58 /* The computed base for output file names. */
59 extern char *all_but_ext;
60
61 void compute_output_file_names (void);
62 void output_file_names_free (void);
63 void output_file_name_check (char const *file_name);
64
65 FILE *xfopen (const char *name, const char *mode);
66 void xfclose (FILE *ptr);
67
68 #endif /* !FILES_H_ */