https://gcc.gnu.org/bugzilla/show_bug.cgi?id=79969
Bug ID: 79969 Summary: C FE emits locus of forward enum declaration rather than definition into debug info Product: gcc Version: 7.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c Assignee: unassigned at gcc dot gnu.org Reporter: jakub at gcc dot gnu.org Target Milestone: --- enum ENUMTAG; enum ENUMTAG { B = 1, C = 2 }; void bar (void) { enum ENUMTAG a = C; } The C FE emits DW_AT_decl_line 1 on the DW_TAG_enumerator_type rather than 3. The C++ FE with added say : int on line 1 and 3 uses line 3.