https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88628
--- Comment #9 from merukun1125 at docomo dot ne.jp ---
Tn Comment 6, not
#include
struct S { // A type that does not depend on template parameter T
auto operator()() const -> decltype(false) {
return false;
}
};
template
T ge
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88628
--- Comment #8 from merukun1125 at docomo dot ne.jp ---
(In reply to Jakub Jelinek from comment #7)
> http://eel.is/c++draft/expr.prim.lambda.closure says:
>
> The type of a lambda-expression (which is also the type of the closure
> object) is a
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88628
--- Comment #7 from Jakub Jelinek ---
http://eel.is/c++draft/expr.prim.lambda.closure says:
The type of a lambda-expression (which is also the type of the closure object)
is a unique, unnamed non-union class type, called the closure type, whose
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88628
merukun1125 at docomo dot ne.jp changed:
What|Removed |Added
Status|UNCONFIRMED |RESOLVED
Resolu
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88628
--- Comment #5 from merukun1125 at docomo dot ne.jp ---
(In reply to Jakub Jelinek from comment #4)
> lambda is AFAIK a local class, so you need to instantiate it. So it is more
> similar to:
> #include
>
> template
> constexpr bool run() { ret
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88628
--- Comment #4 from Jakub Jelinek ---
lambda is AFAIK a local class, so you need to instantiate it. So it is more
similar to:
#include
template
constexpr bool run() { return false; }
template
T get() {
struct S {};
if constexpr (std::
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88628
--- Comment #3 from merukun1125 at docomo dot ne.jp ---
(In reply to Jakub Jelinek from comment #2)
> clang++ agrees with g++ here. The lambda expression needs to be
> instantiated so that it can be evaluated and expressions in discarded
> statem
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88628
--- Comment #2 from Jakub Jelinek ---
clang++ agrees with g++ here. The lambda expression needs to be instantiated
so that it can be evaluated and expressions in discarded statements are not
instantiated.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88628
Jakub Jelinek changed:
What|Removed |Added
CC||jakub at gcc dot gnu.org
--- Comment #1