diff options
Diffstat (limited to 'gcc/c-family')
-rw-r--r-- | gcc/c-family/ChangeLog | 6 | ||||
-rw-r--r-- | gcc/c-family/c-pretty-print.c | 7 | ||||
-rw-r--r-- | gcc/c-family/c-pretty-print.h | 1 |
3 files changed, 14 insertions, 0 deletions
diff --git a/gcc/c-family/ChangeLog b/gcc/c-family/ChangeLog index 9d48855..b264c38 100644 --- a/gcc/c-family/ChangeLog +++ b/gcc/c-family/ChangeLog @@ -1,3 +1,9 @@ +2019-12-11 David Malcolm <dmalcolm@redhat.com> + + * c-pretty-print.c (c_pretty_printer::clone): New vfunc + implementation. + * c-pretty-print.h (c_pretty_printer::clone): New vfunc decl. + 2019-12-09 David Malcolm <dmalcolm@redhat.com> * c-format.c (range_label_for_format_type_mismatch::get_text): diff --git a/gcc/c-family/c-pretty-print.c b/gcc/c-family/c-pretty-print.c index bc73545..e5e898a 100644 --- a/gcc/c-family/c-pretty-print.c +++ b/gcc/c-family/c-pretty-print.c @@ -2372,6 +2372,13 @@ c_pretty_printer::c_pretty_printer () parameter_list = pp_c_parameter_type_list; } +/* c_pretty_printer's implementation of pretty_printer::clone vfunc. */ + +pretty_printer * +c_pretty_printer::clone () const +{ + return new c_pretty_printer (*this); +} /* Print the tree T in full, on file FILE. */ diff --git a/gcc/c-family/c-pretty-print.h b/gcc/c-family/c-pretty-print.h index 8d69620..df21e21 100644 --- a/gcc/c-family/c-pretty-print.h +++ b/gcc/c-family/c-pretty-print.h @@ -51,6 +51,7 @@ class c_pretty_printer : public pretty_printer { public: c_pretty_printer (); + pretty_printer *clone () const OVERRIDE; // Format string, possibly translated. void translate_string (const char *); |