[PATCH] D149516: [Sema] `setInvalidDecl` for error deduction declaration
Congcong Cai via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Sun Apr 30 22:48:48 PDT 2023
HerrCai0907 marked 2 inline comments as done.
HerrCai0907 added inline comments.
================
Comment at: clang/lib/Sema/SemaDeclCXX.cpp:11196
if (D.isFunctionDefinition())
Diag(D.getIdentifierLoc(), diag::err_deduction_guide_defines_function);
+ return IsValid;
----------------
rsmith wrote:
> Should we return that we had an error after this one too?
if `D.isFunctionDefinition()`, we can still create valid deduction guide. I think keeping it can avoid lots of meaningless error later.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D149516/new/
https://reviews.llvm.org/D149516
More information about the cfe-commits
mailing list