
27 Aug
2004
27 Aug
'04
12:50 p.m.
On Behalf Of zaufi
Can anybody shed a light on what are we doing wrong in this example?
Try: #include <list> #include <algorithm> #include <boost/lambda/bind.hpp> #include <boost/lambda/lambda.hpp> //added int main() { using namespace boost::lambda; std::list<std::list<int> > l; bool some_are_empty = false; std::for_each(l.begin(), l.end(), var(some_are_empty) = bind(&std::list<int>::empty, _1) || var(some_are_empty)); ^^^^ ^ return 0; }