https://gcc.gnu.org/bugzilla/show_bug.cgi?id=14168
Richard Biener <rguenth at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |rguenth at gcc dot gnu.org Last reconfirmed|2005-11-02 02:12:19 |2024-1-23 --- Comment #3 from Richard Biener <rguenth at gcc dot gnu.org> --- I think the debug reflects the source which is what it should first and foremost do so there is no bug. -feliminate-unused-debug-{symbols,types} which are enabled by default should maybe eliminate everything, but the using declaration, DW_TAG_imported_declaration isn't handled explicitly in prune_unused_types_walk which means we keep it (and referenced things and also its context DIE, the namespace. The question is whether we should handle DW_TAG_imported_declaration based on the imported DIE (typedef or function) or on its own merit.