mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-21 10:13:03 +00:00
* src/output.c (output): Topological sort of the functions, in
order to get rid of the `static' prototypes. No longer use `register'. * src/output.h: New file. Propagate its inclusion in files explicitly prototyping functions from output.c.
This commit is contained in:
@@ -1,3 +1,12 @@
|
|||||||
|
2000-10-02 Akim Demaille <akim@epita.fr>
|
||||||
|
|
||||||
|
* src/output.c (output): Topological sort of the functions, in
|
||||||
|
order to get rid of the `static' prototypes.
|
||||||
|
No longer use `register'.
|
||||||
|
* src/output.h: New file.
|
||||||
|
Propagate its inclusion in files explicitly prototyping functions
|
||||||
|
from output.c.
|
||||||
|
|
||||||
2000-09-21 Akim Demaille <akim@epita.fr>
|
2000-09-21 Akim Demaille <akim@epita.fr>
|
||||||
|
|
||||||
* src/atgeneral.m4: Update from Autoconf.
|
* src/atgeneral.m4: Update from Autoconf.
|
||||||
|
|||||||
@@ -21,7 +21,7 @@ EXTRA_bison_SOURCES = vmsgetargs.c
|
|||||||
noinst_HEADERS = alloc.h closure.h complain.h \
|
noinst_HEADERS = alloc.h closure.h complain.h \
|
||||||
derives.h \
|
derives.h \
|
||||||
files.h getargs.h gram.h lex.h \
|
files.h getargs.h gram.h lex.h \
|
||||||
state.h \
|
output.h state.h \
|
||||||
symtab.h system.h types.h
|
symtab.h system.h types.h
|
||||||
|
|
||||||
data_DATA = bison.simple bison.hairy
|
data_DATA = bison.simple bison.hairy
|
||||||
|
|||||||
@@ -25,6 +25,7 @@
|
|||||||
#include "files.h"
|
#include "files.h"
|
||||||
#include "complain.h"
|
#include "complain.h"
|
||||||
#include "derives.h"
|
#include "derives.h"
|
||||||
|
#include "output.h"
|
||||||
|
|
||||||
#if 0 /* XXX currently unused. */
|
#if 0 /* XXX currently unused. */
|
||||||
/* Nonzero means failure has been detected; don't write a parser file. */
|
/* Nonzero means failure has been detected; don't write a parser file. */
|
||||||
@@ -35,7 +36,6 @@ static int failure;
|
|||||||
char *program_name;
|
char *program_name;
|
||||||
|
|
||||||
extern char *printable_version PARAMS ((int));
|
extern char *printable_version PARAMS ((int));
|
||||||
extern void berror PARAMS ((const char *));
|
|
||||||
|
|
||||||
extern void openfiles PARAMS ((void));
|
extern void openfiles PARAMS ((void));
|
||||||
extern void reader PARAMS ((void));
|
extern void reader PARAMS ((void));
|
||||||
@@ -48,7 +48,6 @@ extern void initialize_conflicts PARAMS ((void));
|
|||||||
extern void finalize_conflicts PARAMS ((void));
|
extern void finalize_conflicts PARAMS ((void));
|
||||||
extern void verbose PARAMS ((void));
|
extern void verbose PARAMS ((void));
|
||||||
extern void terse PARAMS ((void));
|
extern void terse PARAMS ((void));
|
||||||
extern void output PARAMS ((void));
|
|
||||||
|
|
||||||
|
|
||||||
/* VMS complained about using `int'. */
|
/* VMS complained about using `int'. */
|
||||||
|
|||||||
818
src/output.c
818
src/output.c
File diff suppressed because it is too large
Load Diff
33
src/output.h
Normal file
33
src/output.h
Normal file
@@ -0,0 +1,33 @@
|
|||||||
|
/* Output the generated parsing program for bison,
|
||||||
|
Copyright (C) 2000 Free Software Foundation, Inc.
|
||||||
|
|
||||||
|
This file is part of Bison, the GNU Compiler Compiler.
|
||||||
|
|
||||||
|
Bison is free software; you can redistribute it and/or modify it
|
||||||
|
under the terms of the GNU General Public License as published by
|
||||||
|
the Free Software Foundation; either version 2, or (at your option)
|
||||||
|
any later version.
|
||||||
|
|
||||||
|
Bison is distributed in the hope that it will be useful, but
|
||||||
|
WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||||
|
General Public License for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License
|
||||||
|
along with Bison; see the file COPYING. If not, write to the Free
|
||||||
|
Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
|
||||||
|
02111-1307, USA. */
|
||||||
|
|
||||||
|
#ifndef OUTPUT_H_
|
||||||
|
# define OUTPUT_H_
|
||||||
|
|
||||||
|
/* Output constant strings to the beginning of certain files. */
|
||||||
|
void output_headers PARAMS ((void));
|
||||||
|
|
||||||
|
/* Output constant strings to the ends of certain files. */
|
||||||
|
void output_trailers PARAMS ((void));
|
||||||
|
|
||||||
|
/* Output the parsing tables and the parser code to FTABLE. */
|
||||||
|
void output PARAMS ((void));
|
||||||
|
|
||||||
|
#endif /* !OUTPUT_H_ */
|
||||||
10
src/reader.c
10
src/reader.c
@@ -35,6 +35,7 @@
|
|||||||
#include "lex.h"
|
#include "lex.h"
|
||||||
#include "gram.h"
|
#include "gram.h"
|
||||||
#include "complain.h"
|
#include "complain.h"
|
||||||
|
#include "output.h"
|
||||||
|
|
||||||
#define LTYPESTR "\
|
#define LTYPESTR "\
|
||||||
\n\
|
\n\
|
||||||
@@ -70,8 +71,6 @@ extern int maxtoken;
|
|||||||
extern void init_lex PARAMS((void));
|
extern void init_lex PARAMS((void));
|
||||||
extern char *grow_token_buffer PARAMS((char *));
|
extern char *grow_token_buffer PARAMS((char *));
|
||||||
extern void tabinit PARAMS((void));
|
extern void tabinit PARAMS((void));
|
||||||
extern void output_headers PARAMS((void));
|
|
||||||
extern void output_trailers PARAMS((void));
|
|
||||||
extern void free_symtab PARAMS((void));
|
extern void free_symtab PARAMS((void));
|
||||||
extern void open_extra_files PARAMS((void));
|
extern void open_extra_files PARAMS((void));
|
||||||
extern char *printable_version PARAMS((int));
|
extern char *printable_version PARAMS((int));
|
||||||
@@ -234,8 +233,11 @@ copy_string (FILE *fin, FILE *fout, int match)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/* Dump the comment from IN to OUT1 and OUT2. C is either `*' or `/',
|
/*---------------------------------------------------------------.
|
||||||
depending upon the type of comments used. OUT2 might be NULL. */
|
| Dump the comment from IN to OUT1 and OUT2. C is either `*' or |
|
||||||
|
| `/', depending upon the type of comments used. OUT2 might be |
|
||||||
|
| NULL. |
|
||||||
|
`---------------------------------------------------------------*/
|
||||||
|
|
||||||
static inline void
|
static inline void
|
||||||
copy_comment2 (FILE *in, FILE *out1, FILE* out2, int c)
|
copy_comment2 (FILE *in, FILE *out1, FILE* out2, int c)
|
||||||
|
|||||||
Reference in New Issue
Block a user