From: Tom Tromey Date: Tue, 29 May 2018 18:54:59 +0000 (-0600) Subject: Include parser-defs.h in cp-name-parser.y X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=98e69eb381347eb06dfedaa0b185ad26818ce5cd;p=binutils-gdb.git 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 * cp-name-parser.y: Include parser-defs.h. (parser_fprintf): Remove declaration. --- diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 7bb56db52bf..0c50d8385cb 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,8 @@ +2018-06-01 Tom Tromey + + * cp-name-parser.y: Include parser-defs.h. + (parser_fprintf): Remove declaration. + 2018-06-01 Tom Tromey * cp-name-parser.y: Use %pure-parser, %lex-param, and diff --git a/gdb/cp-name-parser.y b/gdb/cp-name-parser.y index b66257513d6..169a92df6a7 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"