[clang] [Sema] Fix parameter index checks on explicit object member functions (PR #165586)
Mariya Podchishchaeva via cfe-commits
cfe-commits at lists.llvm.org
Thu Oct 30 05:01:19 PDT 2025
================
@@ -123,6 +123,13 @@ inline bool isInstanceMethod(const Decl *D) {
return false;
}
+inline bool hasImplicitObjectParameter(const Decl *D) {
+ if (const auto *MethodDecl = dyn_cast<CXXMethodDecl>(D))
+ return MethodDecl->isInstance() &&
+ !MethodDecl->hasCXXExplicitFunctionObjectParameter();
+ return false;
+}
----------------
Fznamznon wrote:
Ah, ok, I missed that the suggestion has `isImplicitObjectMemberFunction`, nvm :)
https://github.com/llvm/llvm-project/pull/165586
More information about the cfe-commits
mailing list