1// Contributed by Dodji Seketeli <dodji@redhat.com> 2// Origin PR debug/40109 3// { dg-do compile } 4// { dg-options "-g -dA -O0" } 5 6namespace A 7{ 8 9 class B 10 { 11 }; 12 typedef A::B AB; 13}; 14 15int 16main() 17{ 18 A::AB ab; 19 return 0; 20} 21 22// { dg-final { scan-assembler "DW_TAG_typedef" } } 23// 24// What we want to do here is to be sure that the DIE of A::AB is generated 25// as a child of the DIE of the namespace A declaration. 26// So this test won't catch a regression on this fix yet. To write a proper 27// test for this fix, we would need a dwarf reader written in tcl, 28// or something along those lines. 29 30