[Bug debug/28460] [4.0/4.1/4.2 Regression] g++ emits bogus namespace DIE

mark at codesourcery dot com gcc-bugzilla@gcc.gnu.org
Sun Jul 23 16:00:00 GMT 2006



------- Comment #2 from mark at codesourcery dot com  2006-07-23 15:59 -------
Subject: Re:  [4.0/4.1/4.2 Regression] g++ emits bogus namespace
 DIE

drow at gcc dot gnu dot org wrote:
> ------- Comment #1 from drow at gcc dot gnu dot org  2006-07-23 00:12 -------
> Mark, did the old C++ parser have TYPE_CONTEXT == NULL for the global scope and
> the new one have it pointing to the global namespace, or something like that?

No, I don't think so.  The representation has "always" (i.e., for as
long as I can remember) been that the global namespace was represented
as NULL_TREE, while other namespaces are represented by NAMESPACE_DECL.
  (One could argue that's a silly non-uniformity, but that's how it's
always been.)

> If so, I guess we'll have to strip that out in dwarf2out.  We can't compare
> against global_namespace, so do you have a recommendation on how to identify
> it?

If we're setting TYPE_CONTEXT to global_namespace, I think that's a C++
front end bug.  Which type is getting set up like that?


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28460



More information about the Gcc-bugs mailing list