[clang] Thread Safety Analysis: Support reentrant capabilities (PR #137133)
Marco Elver via cfe-commits
cfe-commits at lists.llvm.org
Fri Apr 25 06:01:46 PDT 2025
================
@@ -1831,15 +1852,15 @@ void BuildLockset::handleCall(const Expr *Exp, const NamedDecl *D,
assert(!Self);
const auto *TagT = Exp->getType()->getAs<TagType>();
if (D->hasAttrs() && TagT && Exp->isPRValue()) {
- std::pair<til::LiteralPtr *, StringRef> Placeholder =
- Analyzer->SxBuilder.createThisPlaceholder(Exp);
+ auto Placeholder = Analyzer->SxBuilder.createThisPlaceholder(Exp);
----------------
melver wrote:
Growing this pair/tuple become a little too complex, so I just made createThisPlaceholder return a CapabilityExpr struct right away.
https://github.com/llvm/llvm-project/pull/137133
More information about the cfe-commits
mailing list