* dwarf2out.c (prune_unused_types): Handle unused top-level limbo
dies.
From-SVN: r224391
+2015-06-11 Jason Merrill <jason@redhat.com>
+
+ * dwarf2out.c (prune_unused_types): Handle unused top-level limbo
+ dies.
+
2015-06-11 Marek Polacek <polacek@redhat.com>
* match.pd ((x & y) ^ (x | y)): Don't check for single_use.
if (skeleton_debug_str_hash)
skeleton_debug_str_hash->empty ();
prune_unused_types_prune (comp_unit_die ());
- for (node = limbo_die_list; node; node = node->next)
- prune_unused_types_prune (node->die);
+ for (limbo_die_node **pnode = &limbo_die_list; *pnode; )
+ {
+ node = *pnode;
+ if (!node->die->die_mark)
+ *pnode = node->next;
+ else
+ {
+ prune_unused_types_prune (node->die);
+ pnode = &node->next;
+ }
+ }
for (ctnode = comdat_type_list; ctnode; ctnode = ctnode->next)
prune_unused_types_prune (ctnode->root_die);