Daniel Dunbar | a572887 | 2009-12-15 20:14:24 +0000 | [diff] [blame] | 1 | // RUN: %clang_cc1 -fsyntax-only -verify %s |
Douglas Gregor | 7091319 | 2009-05-12 21:43:46 +0000 | [diff] [blame] | 2 | |
| 3 | |
John McCall | 67d22fb | 2010-08-28 20:17:00 +0000 | [diff] [blame] | 4 | namespace test0 { |
| 5 | // p3 |
| 6 | template<typename T> int foo(T), bar(T, T); // expected-error{{single entity}} |
| 7 | } |
| 8 | |
| 9 | // PR7252 |
| 10 | namespace test1 { |
| 11 | namespace A { template<typename T> struct Base { typedef T t; }; } // expected-note {{member found}} |
| 12 | namespace B { template<typename T> struct Base { typedef T t; }; } // expected-note {{member found}} |
| 13 | |
| 14 | template<typename T> struct Derived : A::Base<char>, B::Base<int> { |
| 15 | // FIXME: the syntax error here is unfortunate |
| 16 | typename Derived::Base<float>::t x; // expected-error {{found in multiple base classes of different types}} \ |
| 17 | // expected-error {{expected member name or ';'}} |
| 18 | }; |
| 19 | } |