================ @@ -1428,10 +1428,18 @@ void ResultBuilder::AddResult(Result R, DeclContext *CurContext, AdjustResultPriorityForDecl(R); + // Account for explicit object parameter + const auto getQualifiers = [&](const CXXMethodDecl *MethodDecl) { + if (MethodDecl->isExplicitObjectMemberFunction()) + return MethodDecl->getFunctionObjectParameterType().getQualifiers(); + else + return MethodDecl->getMethodQualifiers(); + }; ---------------- HighCommander4 wrote:
FWIW, I tried to evaluate whether it would be appropriate for `CXXMethodDecl::getMethodQualifiers()` itself to behave this way, but the code at the call sites of that method in actual semantic analysis code is going a bit over my head. I think keeping this logic local to this call site is fine for now. https://github.com/llvm/llvm-project/pull/154041 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits