Blocks building Qt5: class QCocoaWindow {}; class ::QCocoaWindow; int main() { } diagnostics: error: extra qualification on member 'QCocoaWindow' compiles and runs fine on gcc. clang -v clang version 3.3 (trunk 170492) Target: x86_64-apple-darwin12.2.0 Thread model: posix
apple gcc didn't warn nothing... It's seems to be wrong, and also the code sample.
Why invalid?
At the time, I've realized the Qt5 codebase was buggy causing such situation, the problem was solved on Qt5 and as I was not sure about whether this was a true language error or not, I've marked it as invalid.
According to the C++ Standard ( N3485 ) 3.4.4 Elaborated type specifiers [basic.lookup.elab] Example in paragraph 3 ...I think it is right that the compiler emits an error, but I think the error description is incorrect. What do you think? Does the bug should be re-opened? Regards,
I think you're right about it.
Created a review here: http://reviews.llvm.org/D16965