1// { dg-do run  }
2// Check that foo<int> isn't resolved too early.
3
4template <class T> void foo(T*);
5template <class T, class U> void foo(T*, U) { }
6
7template <class T, class U> void bar(void (*)(T, U), U) { }
8
9int main() {
10  bar<int*>(&foo, 1);
11  bar<int*>(&foo<int>, 1);
12  bar<int*>(foo, 1);
13  bar<int*>(foo<int>, 1);
14}
15