diff options
author | Aldy Hernandez <aldyh@redhat.com> | 2018-01-31 10:42:52 +0000 |
---|---|---|
committer | Aldy Hernandez <aldyh@gcc.gnu.org> | 2018-01-31 10:42:52 +0000 |
commit | 7aec1b82097e03a40f8d6818d0321cea5883abdb (patch) | |
tree | b3a5bb4256fa4eb5c301e9b5a1cd99a9a9649044 | |
parent | 73df9303b7a4cbe5bef8420a8584e9e1c3d3548f (diff) | |
download | gcc-7aec1b82097e03a40f8d6818d0321cea5883abdb.zip gcc-7aec1b82097e03a40f8d6818d0321cea5883abdb.tar.gz gcc-7aec1b82097e03a40f8d6818d0321cea5883abdb.tar.bz2 |
re PR lto/84105 (Segmentation fault in pp_tree_identifier() during LTO)
PR lto/84105
* tree-pretty-print.c (dump_generic_node): Handle a TYPE_NAME with
an IDENTIFIER_NODE for FUNCTION_TYPE's.
From-SVN: r257228
-rw-r--r-- | gcc/ChangeLog | 6 | ||||
-rw-r--r-- | gcc/tree-pretty-print.c | 4 |
2 files changed, 9 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 84efedd..9b9a1c3 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2018-01-29 Aldy Hernandez <aldyh@redhat.com> + + PR lto/84105 + * tree-pretty-print.c (dump_generic_node): Handle a TYPE_NAME with + an IDENTIFIER_NODE for FUNCTION_TYPE's. + 2018-01-31 Eric Botcazou <ebotcazou@adacore.com> Revert diff --git a/gcc/tree-pretty-print.c b/gcc/tree-pretty-print.c index 54a8dfa..73eb27c 100644 --- a/gcc/tree-pretty-print.c +++ b/gcc/tree-pretty-print.c @@ -1822,7 +1822,9 @@ dump_generic_node (pretty_printer *pp, tree node, int spc, dump_flags_t flags, pp_string (pp, "<null method basetype>"); pp_colon_colon (pp); } - if (TYPE_NAME (node) && DECL_NAME (TYPE_NAME (node))) + if (TYPE_IDENTIFIER (node)) + dump_generic_node (pp, TYPE_NAME (node), spc, flags, false); + else if (TYPE_NAME (node) && DECL_NAME (TYPE_NAME (node))) dump_decl_name (pp, TYPE_NAME (node), flags); else if (flags & TDF_NOUID) pp_printf (pp, "<Txxxx>"); |