1// RUN: %clang_cc1 -fsyntax-only -verify %s
2// Test instantiation of member functions of class templates defined out-of-line
3template<typename T, typename U>
4struct X0 {
5  void f(T *t, const U &u);
6  void f(T *);
7};
8
9template<typename T, typename U>
10void X0<T, U>::f(T *t, const U &u) {
11  *t = u; // expected-warning{{indirection on operand of type 'void *'}} expected-error{{not assignable}}
12}
13
14void test_f(X0<float, int> xfi, X0<void, int> xvi, float *fp, void *vp, int i) {
15  xfi.f(fp, i);
16  xvi.f(vp, i); // expected-note{{instantiation}}
17}
18