From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 31006 invoked by alias); 18 May 2010 09:32:57 -0000 Received: (qmail 30939 invoked by uid 48); 18 May 2010 09:32:41 -0000 Date: Tue, 18 May 2010 09:32:00 -0000 Subject: [Bug c++/44188] New: Fails to produce DW_AT_typedef for typedef of anonymous struct X-Bugzilla-Reason: CC Message-ID: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "rguenth at gcc dot gnu dot org" Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2010-05/txt/msg01898.txt.bz2 typedef struct { int i; } AAA; typedef struct BBB { int i; } BBB; int main(void) { BBB bb; AAA aa; return 0; } produces <3>: Abbrev Number: 9 (DW_TAG_variable) DW_AT_name : bb DW_AT_decl_file : 1 DW_AT_decl_line : 13 DW_AT_type : <0x66> DW_AT_location : 2 byte block: 91 60 (DW_OP_fbreg: -32) <3>: Abbrev Number: 9 (DW_TAG_variable) DW_AT_name : aa DW_AT_decl_file : 1 DW_AT_decl_line : 14 DW_AT_type : <0x2d> DW_AT_location : 2 byte block: 91 50 where <1><66>: Abbrev Number: 6 (DW_TAG_typedef) <67> DW_AT_name : BBB <6b> DW_AT_decl_file : 1 <6c> DW_AT_decl_line : 10 <6d> DW_AT_type : <0x4d> (good) <1><2d>: Abbrev Number: 2 (DW_TAG_structure_type) <2e> DW_AT_byte_size : 4 <2f> DW_AT_decl_file : 1 <30> DW_AT_decl_line : 3 <31> DW_AT_name : AAA <35> DW_AT_sibling : <0x46> (bad) This seems to be because in gen_type_die_with_usage we arrive with a type that has a non-typedef type-decl as its name. -- Summary: Fails to produce DW_AT_typedef for typedef of anonymous struct Product: gcc Version: 4.5.0 Status: UNCONFIRMED Keywords: wrong-debug Severity: enhancement Priority: P3 Component: c++ AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: rguenth at gcc dot gnu dot org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44188