p3.cpp revision 762bb9d0ad20320b9f97a841dce57ba5e8e48b07
1// RUN: %clang_cc1 -fsyntax-only -verify -std=c++11 %s 2 3// Classes. 4namespace Class { 5 namespace NS { 6 class C {}; // expected-note {{candidate}} 7 } 8 using namespace NS; 9 class C : C {}; // expected-error {{reference to 'C' is ambiguous}} \ 10 expected-note {{candidate}} 11} 12 13// Enumerations. 14enum E { 15 EPtrSize = sizeof((E*)0) // ok, E is already declared 16}; 17 18// Alias declarations. clang implements the proposed resolution to N1044. 19namespace Alias { 20 namespace NS { 21 class C; 22 } 23 using namespace NS; 24 using C = C; // ok, C = B::C 25 using C = NS::C; // ok, same type 26} 27