aboutsummaryrefslogtreecommitdiffstats
path: root/sources/shiboken6/ApiExtractor/abstractmetafunction.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'sources/shiboken6/ApiExtractor/abstractmetafunction.cpp')
-rw-r--r--sources/shiboken6/ApiExtractor/abstractmetafunction.cpp10
1 files changed, 7 insertions, 3 deletions
diff --git a/sources/shiboken6/ApiExtractor/abstractmetafunction.cpp b/sources/shiboken6/ApiExtractor/abstractmetafunction.cpp
index 79c542f26..df0ce2a1c 100644
--- a/sources/shiboken6/ApiExtractor/abstractmetafunction.cpp
+++ b/sources/shiboken6/ApiExtractor/abstractmetafunction.cpp
@@ -1108,11 +1108,15 @@ QString AbstractMetaFunction::modifiedName() const
return d->modifiedName(this);
}
-AbstractMetaFunction *
-AbstractMetaFunction::find(const AbstractMetaFunctionList &haystack,
+AbstractMetaFunctionCPtr
+AbstractMetaFunction::find(const AbstractMetaFunctionCList &haystack,
const QString &needle)
{
- return findByName(haystack, needle);
+ for (const auto &f : haystack) {
+ if (f->name() == needle)
+ return f;
+ }
+ return {};
}
void AbstractMetaFunction::setAllowThreadModification(TypeSystem::AllowThread am)