blob: a2bc8c54edc78f2557834256961a100177bba914 [file] [log] [blame]
John Thompson59cbea92009-10-13 05:45:19 +00001// FIXME: Disabled, appears to have undefined behavior, and needs to be updated to match new warnings.
Daniel Dunbar2475d762009-11-08 01:47:25 +00002// RUN: clang-cc -fsyntax-only -verify %s
3// XFAIL: *
John Thompson59cbea92009-10-13 05:45:19 +00004
5namespace A {
6 int VA;
7 void FA() {}
8 struct SA { int V; };
9}
10
11using A::VA;
12using A::FA;
13using typename A::SA;
14
15void main()
16{
17 VA = 1;
18 FA();
19 SA x; //Still needs handling.
20}
21
22struct B {
23 void f(char){};
24 void g(char){};
25};
26struct D : B {
27 using B::f;
28 void f(int);
29 void g(int);
30};
31void D::f(int) { f('c'); } // calls B::f(char)
32void D::g(int) { g('c'); } // recursively calls D::g(int)
33
34namespace E {
35 template <typename TYPE> int funcE(TYPE arg) { return(arg); }
36}
37
38using E::funcE<int>; // expected-error{{use of template specialization in using directive not allowed}}
39
40namespace F {
41 struct X;
42}
43
44using F::X;
45// Should have some errors here. Waiting for implementation.
46void X(int);
47struct X *x;