[clang] [clang-tools-extra] [clang] Include explicit object methods in overload suggestions (PR #154041)

Mythreya Kuricheti via cfe-commits cfe-commits at lists.llvm.org
Sun Aug 17 15:52:32 PDT 2025


================
@@ -2288,7 +2288,10 @@ class CXXMethodDecl : public FunctionDecl {
                               const CXXRecordDecl *Decl);
 
   Qualifiers getMethodQualifiers() const {
-    return getType()->castAs<FunctionProtoType>()->getMethodQuals();
+    if (isExplicitObjectMemberFunction())
+      return getFunctionObjectParameterType().getQualifiers();
----------------
MythreyaK wrote:

Not 100% sure if this is the right method to use :thinking:. 

https://github.com/llvm/llvm-project/pull/154041


More information about the cfe-commits mailing list