diff options
author | Tom Tromey <tom@tromey.com> | 2018-05-29 12:54:59 -0600 |
---|---|---|
committer | Tom Tromey <tom@tromey.com> | 2018-06-01 10:46:49 -0600 |
commit | 98e69eb381347eb06dfedaa0b185ad26818ce5cd (patch) | |
tree | 719099bec637a87ba4fef2267e9cd6c0abdbff9d /gdb | |
parent | 49265499d81d40ed07b71481749f35f209521f5a (diff) | |
download | gdb-98e69eb381347eb06dfedaa0b185ad26818ce5cd.zip gdb-98e69eb381347eb06dfedaa0b185ad26818ce5cd.tar.gz gdb-98e69eb381347eb06dfedaa0b185ad26818ce5cd.tar.bz2 |
Include parser-defs.h in cp-name-parser.y
This changes cp-name-parser.y to include parser-defs.h, removing the
copy-pasted declaration of parser_fprintf. This can be done now that
cp-name-parser.y does not define any global variables.
gdb/ChangeLog
2018-06-01 Tom Tromey <tom@tromey.com>
* cp-name-parser.y: Include parser-defs.h.
(parser_fprintf): Remove declaration.
Diffstat (limited to 'gdb')
-rw-r--r-- | gdb/ChangeLog | 5 | ||||
-rw-r--r-- | gdb/cp-name-parser.y | 6 |
2 files changed, 6 insertions, 5 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 7bb56db..0c50d83 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,5 +1,10 @@ 2018-06-01 Tom Tromey <tom@tromey.com> + * cp-name-parser.y: Include parser-defs.h. + (parser_fprintf): Remove declaration. + +2018-06-01 Tom Tromey <tom@tromey.com> + * cp-name-parser.y: Use %pure-parser, %lex-param, and %parse-param. (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info) diff --git a/gdb/cp-name-parser.y b/gdb/cp-name-parser.y index b662575..169a92d 100644 --- a/gdb/cp-name-parser.y +++ b/gdb/cp-name-parser.y @@ -44,11 +44,7 @@ #include "demangle.h" #include "cp-support.h" #include "c-support.h" - -/* Function used to avoid direct calls to fprintf - in the code generated by the bison parser. */ - -extern void parser_fprintf (FILE *, const char *, ...) ATTRIBUTE_PRINTF (2, 3); +#include "parser-defs.h" #define GDB_YY_REMAP_PREFIX cpname #include "yy-remap.h" |