#include <iostream>
#include <vector>
#include <algorithm>
#include <functional>
using namespace std::placeholders;
struct Foo {
        bool condition;
};
int main()
{
        std::vector<Foo> myVector = {{false}, {true}, {false}, {true}, {true}};

        myVector.erase(
            remove_if(myVector.begin(), myVector.end(), std::bind(&Foo::condition, _1))
            , myVector.end());

        for(auto i = myVector.begin(); i!=myVector.end(); ++i)
                std::cout << std::boolalpha << i->condition << '\n';
}
