// Copyright (C) 2004 Free Software Foundation, Inc. // Contributed by Nathan Sidwell 1 Apr 2004 void Baz (); template void Foo1 (T *); // #1 template void Foo1 (T const *a) {a (1);} // #2 template T const *Foo2 (T *); template void Foo3 (T *, T const * = 0); // { dg-message "candidate" } void Bar () { Foo1 (&Baz); // #1 Foo2 (&Baz); Foo3 (&Baz); Foo3 (&Baz, &Baz); // { dg-error "no matching function" "" } }