------- Additional Comments From mmitchel at gcc dot gnu dot org 2004-10-29 01:42 ------- The problem here is an ordering issue.
When we see A<C>, we instantiate it, and call gen_type_die for A<C>. That causes us to generate DIEs for all members of A<C>, including A<C>::t. The type of A<C>::t is C, so we now go to generate a DIE for C. C is not presently marked as DECL_ABSTRACT, so we do not enter it in the decl->DIE table. Later, we realize that B::B() is an abstract instance, so we go ahead and mark C as DECL_ABSTRACT -- but it's too late, we've already dealt with its DIE. Then, we process one of the clones of B::B(), encounter a copy of the typedef, go back to the abstract origin of the typedef, and try to look it up -- but it's not in the table. In GCC 3.4, this worked because we did not actually copy the typedef into the clone. Therefore, there was never a second typedef pointing back at the original typedef. However, remap_decl has been changed to make a copy of all declarations, even static variables and typedefs. So, now we have a problem. I'm working on a fix. -- What |Removed |Added ---------------------------------------------------------------------------- AssignedTo|unassigned at gcc dot gnu |mark at codesourcery dot com |dot org | Status|NEW |ASSIGNED http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17695