12 Aug
2010
12 Aug
'10
7:47 a.m.
Nathan Crookston wrote:
To do what you'd like with Boost.Phoenix (#include
to get all of it) you could replace most of operator<< with the following: namespace bp = boost::phoenix; std::for_each(points.begin(), points.end(), stream << *bp::bind(&DataPoint::m_Time, bp::arg_names::_1) << " ");
Much cleaner, if that option's available to you.
Good luck,
Nate
Thanks for the alternative. It does look much cleaner. I've seen boost Phoenix around but haven't really gotten into to it. Is there a web article that describes the pros and cons of using Phoenix versus Lambda. From an outside perspective it looks like they do the same things. This of course leads me to ask why there are two libraries. Ryan