Inline namespace definitions are a feature proposed under C++0x. The feature is not part of the C++98/03 standards. Code that uses it under -std=c++98 -Wall -Wextra -pedantic should get at least a warning.
berg...@etna:~/gcc/BUGS/> cat t.cpp inline namespace A { } berg...@etna:~/gcc/BUGS/> g++ -std=c++98 -Wall -Wextra -pedantic -c t.cpp berg...@etna:~/gcc/BUGS/> echo $? 0 This seems to also be the case for GCC 4.4 and 4.5. -- Summary: C++0x feature "inline namespace" enabled under - std=c++98; no warnings Product: gcc Version: 4.6.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: bergner at gcc dot gnu dot org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43824