From d6b3c79757281c980f71f24d62d5b68a0b933d09 Mon Sep 17 00:00:00 2001 From: Jakub Jelinek Date: Tue, 21 Aug 2007 19:11:20 +0200 Subject: re PR debug/32610 (ICE in gen_tagged_type_instantiation_die, at dwarf2out.c:12762) PR debug/32610 * dwarf2out.c (gen_decl_die): Don't call gen_tagged_type_instantiation_die if decl doesn't have tagged type. * gcc.dg/debug/pr32610.c: New test. From-SVN: r127669 --- gcc/dwarf2out.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'gcc/dwarf2out.c') diff --git a/gcc/dwarf2out.c b/gcc/dwarf2out.c index ec6e121..a03b81a 100644 --- a/gcc/dwarf2out.c +++ b/gcc/dwarf2out.c @@ -13622,7 +13622,8 @@ gen_decl_die (tree decl, dw_die_ref context_die) was generated within the original definition of an inline function) we have to generate a special (abbreviated) DW_TAG_structure_type, DW_TAG_union_type, or DW_TAG_enumeration_type DIE here. */ - if (TYPE_DECL_IS_STUB (decl) && decl_ultimate_origin (decl) != NULL_TREE) + if (TYPE_DECL_IS_STUB (decl) && decl_ultimate_origin (decl) != NULL_TREE + && is_tagged_type (TREE_TYPE (decl))) { gen_tagged_type_instantiation_die (TREE_TYPE (decl), context_die); break; -- cgit v1.1