[PATCH] D156993: [clang] Error on substitution failure within lambda body inside a requires-expression
Corentin Jabot via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Aug 3 05:40:55 PDT 2023
cor3ntin accepted this revision.
cor3ntin added a comment.
This revision is now accepted and ready to land.
Thanks for the PR!
Can you add a test in `dr26xx` ?
Also, i think the intent is that only the body is in the immediate context.
maybe we need a test like
cpp
requires {
decltype([] -> T {})::foo();
}
Because I think the intent is for that to work (@rsmith?)
================
Comment at: clang/lib/Sema/SemaTemplateInstantiate.cpp:1100-1102
// A lambda-expression appearing in a function type or a template
// parameter is not considered part of the immediate context for the
// purposes of template argument deduction.
----------------
Can you also add
// CWG2672: A lambda-expression body is never in the immediate context ?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D156993/new/
https://reviews.llvm.org/D156993
More information about the cfe-commits
mailing list