https://llvm.org/bugs/show_bug.cgi?id=24030
Bug ID: 24030
Summary: Class declaration in the same declarative region as
using declaration - Missing diagnostic message
Product: clang
Version: trunk
Hardware: All
OS: All
Status: NEW
Severity: normal
Priority: P
Component: C++
Assignee: [email protected]
Reporter: [email protected]
CC: [email protected], [email protected]
Classification: Unclassified
The following program should give a diagnostic message when trying to compile
it.
namespace X { class A; }
namespace Y { using X::A; class A {}; }
int main() {}
This is because it violates [basic.scope.declarative]/4 in the c++ standard:
http://eel.is/c++draft/basic.scope.declarative#4
The diagnostic message is missing. MSVS gives a diagnostic message for this
program, but clang does not.
Stack overflow post confirming the bug:
http://stackoverflow.com/questions/31220154/class-declaration-in-same-scope-as-using-declaration-compiles-in-gcc-but-not-msv
--
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
LLVMbugs mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs