I have a vector of callbacks and I'd like to execute them. This is what I do:
typedef boost::function<void (void)> FCallBack; std::vector<FCallBack> c; // Execute every callback std::for_each(c.begin(), c.end(), boost::bind(&FCallBack::operator(), _1));
This works, but is there an easier way to do so? For some reason reference to operator() bothers me. Am I missing something simple?