p3.cpp revision 162e1c1b487352434552147967c3dd296ebee2f7
1// RUN: %clang_cc1 -fsyntax-only -verify -std=c++0x %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