Debian Codegraph @

gcc/testsuite/g++.dg/cpp2a/concepts-lambda5.C

raw
1 // PR c++/92556
2 // { dg-do compile { target c++20 } }
3
4 // Having this as a hard error is consistent with template argument deduction;
5 // it's an open core issue (jason 2020-02-14).
6 template <class T> concept has_value
7 = requires { []{T::value;}; }; // { dg-error "" }
8 template <has_value T> void f() { }
9 template <class T> void f() { }
10 void q() { f<int>(); }