https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66934
Bug ID: 66934 Summary: Compiler accepting ill-formed program with extern variable declarations and using-declaration Product: gcc Version: unknown Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: anders.granlund.0 at gmail dot com Target Milestone: --- The following program is ill-formed since the two declarations in main are conflicting. namespace N { extern int x; } int main() { using N::x; extern int x; } GCC compiles with program without errors. The expected behaviour is to get a compiler error.