From a1b09497f2f198e6ea523637321a0e11fa310d9c Mon Sep 17 00:00:00 2001 From: Friedemann Kleint Date: Thu, 19 Jul 2018 13:40:34 +0200 Subject: libshiboken: Use std::set::find() instead of searching the set Task-number: PYSIDE-727 Change-Id: Ia79f34ed466eb7652946e49db6ef6db8dd9fa03d Reviewed-by: Alexandru Croitor --- sources/shiboken2/libshiboken/basewrapper.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sources/shiboken2/libshiboken/basewrapper.cpp b/sources/shiboken2/libshiboken/basewrapper.cpp index 122e60e41..43c162dec 100644 --- a/sources/shiboken2/libshiboken/basewrapper.cpp +++ b/sources/shiboken2/libshiboken/basewrapper.cpp @@ -1302,7 +1302,7 @@ void removeParent(SbkObject* child, bool giveOwnershipBack, bool keepReference) ChildrenList& oldBrothers = pInfo->parent->d->parentInfo->children; // Verify if this child is part of parent list - ChildrenList::iterator iChild = std::find(oldBrothers.begin(), oldBrothers.end(), child); + auto iChild = oldBrothers.find(child); if (iChild == oldBrothers.end()) return; -- cgit v1.2.3