// Verify we check associated constraints when resolving the address of a // template-id. // { dg-do compile { target c++20 } } void id(auto) { } template int f() { return 0; } template requires requires { T::fail(); } auto f() { T::fail(); } int main() { using U = decltype(&f); (void)&f; id(&f); }