[clang] [Clang] Static and explicit object member functions with the same parameter-type-lists (PR #93430)
via cfe-commits
cfe-commits at lists.llvm.org
Mon May 27 09:57:55 PDT 2024
================
@@ -16333,7 +16387,7 @@ ExprResult Sema::FixOverloadedFunctionReference(Expr *E, DeclAccessPair Found,
assert(UnOp->getOpcode() == UO_AddrOf &&
"Can only take the address of an overloaded function");
if (CXXMethodDecl *Method = dyn_cast<CXXMethodDecl>(Fn)) {
- if (Method->isStatic()) {
+ if (!Method->isImplicitObjectMemberFunction()) {
// Do nothing: static member functions aren't any different
// from non-member functions.
----------------
Sirraide wrote:
nit: maybe update the comment too to indicate that this is also intended to handle explicit object member functions.
https://github.com/llvm/llvm-project/pull/93430
More information about the cfe-commits
mailing list