[clang] [clang][ExprConst] Support virtual bases in C++26 (PR #204289)
Yihan Wang via cfe-commits
cfe-commits at lists.llvm.org
Tue Jul 14 06:59:04 PDT 2026
================
@@ -7454,10 +7562,13 @@ static bool HandleDestructionImpl(EvalInfo &Info, SourceRange CallRange,
CallRef());
// We're now in the period of destruction of this object.
- unsigned BasesLeft = RD->getNumBases();
EvalInfo::EvaluatingDestructorRAII EvalObj(
Info,
ObjectUnderConstruction{This.getLValueBase(), This.Designator.Entries});
+ unsigned NonVirtualBases =
+ llvm::count_if(RD->bases(), [](auto &B) { return !B.isVirtual(); });
----------------
yronglin wrote:
Same as above
https://github.com/llvm/llvm-project/pull/204289
More information about the cfe-commits
mailing list