| 1 |
// PR c++/98929 |
| 2 |
// { dg-do compile { target c++17 } } |
| 3 |
|
| 4 |
template <typename T> |
| 5 |
struct A { |
| 6 |
void foo (); |
| 7 |
using c = decltype (foo ()); |
| 8 |
A (c); // { dg-message {decltype \(A<T>::foo} } |
| 9 |
}; |
| 10 |
A d; // { dg-error "deduction failed" } |
| 11 |
// { dg-error "no match" "" { target *-*-* } .-1 } |