mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-05-01 22:55:41 +08:00
Merge with master for fix of remove in containers
This commit is contained in:
@@ -253,7 +253,7 @@ namespace BlackMisc
|
|||||||
template <class Predicate>
|
template <class Predicate>
|
||||||
void removeIf(Predicate p)
|
void removeIf(Predicate p)
|
||||||
{
|
{
|
||||||
std::remove_if(begin(), end(), p);
|
erase(std::remove_if(begin(), end(), p), end());
|
||||||
}
|
}
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
@@ -272,7 +272,7 @@ namespace BlackMisc
|
|||||||
*/
|
*/
|
||||||
void remove(const T &object)
|
void remove(const T &object)
|
||||||
{
|
{
|
||||||
std::remove(begin(), end(), object);
|
erase(std::remove(begin(), end(), object), end());
|
||||||
}
|
}
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
|
|||||||
Reference in New Issue
Block a user