assembly name collisions in C++

Alex Samuel samuel@codesourcery.com
Wed Jul 26 11:05:00 GMT 2000


Ken Raeburn <raeburn@raeburn.org> writes:

  Ken> I don't know the C++ standard well enough to say with
  Ken> authority whether namespaces and classes are supposed to have
  Ken> distinct, uh, name spaces

I believe that your code sample is illegal -- you can't declare both a
class and a namespace foo in the same scope.  The problem isn't in the
mangling; however, it is a bug that gcc doesn't catch the double
declaration of foo.

Regards
Alex Samuel
CodeSourcery LLC


More information about the Gcc-bugs mailing list