1 // RUN: %clang_cc1 -std=c++11 -fsyntax-only -verify %s
2 
3 // rdar://problem/11120365
4 namespace test0 {
5   template <class T> struct A {
6     static void foo(const T &t) {}
7     static void foo(T &&t) {
8       t.foo(); // expected-error {{member reference base type 'int' is not a structure or union}}
9     }
10   };
11 
12   void test() {
13     A<int>::foo({}); // expected-note {{requested here}}
14   }
15 }
16