$ cat >test.cxx namespace m { namespace n { } } namespace n { }
namespace o { namespace n = ::m::n; } $ g++-3.4 test.cxx test.cxx:14: error: declaration of `namespace n' conflicts with test.cxx:9: error: previous declaration of `namespace n' here BTW, this bug in combination with #16468 ( http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16468 ) makes any non-trivial use of c++ namespaces in g++ 3.4, well, really non-trivial. Good job. Cheers! -- Summary: bogus conflict in namespace aliasing Product: gcc Version: 3.4.2 Status: UNCONFIRMED Severity: normal Priority: P2 Component: c++ AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: boris at kolpackov dot net CC: gcc-bugs at gcc dot gnu dot org GCC build triplet: i686-linux GCC host triplet: i686-linux GCC target triplet: i686-linux http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18093