From af4751738db89a142a8880c782d12d4201b222a8 Mon Sep 17 00:00:00 2001 From: Corentin Jabot Date: Thu, 27 Jan 2022 13:55:08 +0100 Subject: [C++] Implement "Deducing this" (P0847R7) This patch implements P0847R7 (partially), CWG2561 and CWG2653. Reviewed By: aaron.ballman, #clang-language-wg Differential Revision: https://reviews.llvm.org/D140828 --- clang/lib/Analysis/ThreadSafetyCommon.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'clang/lib/Analysis/ThreadSafetyCommon.cpp') diff --git a/clang/lib/Analysis/ThreadSafetyCommon.cpp b/clang/lib/Analysis/ThreadSafetyCommon.cpp index 63cc668..2fe0f85 100644 --- a/clang/lib/Analysis/ThreadSafetyCommon.cpp +++ b/clang/lib/Analysis/ThreadSafetyCommon.cpp @@ -154,7 +154,9 @@ CapabilityExpr SExprBuilder::translateAttrExpr(const Expr *AttrExp, // If the attribute has no arguments, then assume the argument is "this". if (!AttrExp) return CapabilityExpr( - Self, ClassifyDiagnostic(cast(D)->getThisObjectType()), + Self, + ClassifyDiagnostic( + cast(D)->getFunctionObjectParameterType()), false); else // For most attributes. return translateAttrExpr(AttrExp, &Ctx); -- cgit v1.1