// RUN: %clang_cc1 -fsyntax-only -verify %s template struct A { A(); }; template int &f(T); template float &f(T*); template double &f(const T*); template void g(T); // expected-note{{candidate}} template void g(T&); // expected-note{{candidate}} template int &h(const T&); template float &h(A&); void m() { const int *p; double &dr1 = f(p); float x; g(x); // expected-error{{ambiguous}} A z; float &fr1 = h(z); const A z2; int &ir1 = h(z2); }