1// DR 115
2
3// 14.8.1: In contexts where deduction is done and fails, or in contexts
4// where deduction is not done, if a template argument list is specified
5// and it, along with any default template arguments, identifies a single
6// function template specialization, then the template-id is an lvalue for
7// the function template specialization.
8
9// Here, deduction is not done to resolve fn<int> because the target type
10// is a template parameter, so we resolve to the second template, and then
11// the call to def fails because we deduce different values of Fn for the
12// two function arguments.
13
14template <class Fn> void def(Fn fn, Fn fn2);
15
16template <class T1, class T2> T2 fn(T1, T2);
17template <class T1> int fn(T1);
18
19int f(int,int);
20
21int main()
22{
23  def(fn<int>,f);		// { dg-error "" }
24}
25