   Boost phoenix find_if?
  I am trying to learn boost phoenix.Here I am trying to find the test object based on their name using a property. This is a small test case:#include <boost/spirit/home/phoenix/algorithm.hpp>#include <boost/spirit/home/phoenix/stl/algorithm/querying.hpp>#include <boost/spirit/include/phoenix_core.hpp>#include <boost/spirit/include/phoenix_operator.hpp>#include <boost/spirit/home/phoenix/bind/bind_member_function.hpp>#include <vector>class Test{public:Test(const std::string& _name = "");const std::string& Name() const;void Name(const std::string& _name);protected:private:std::string name;};Test::Test(const std::string& _name) : name(_name) {}const std::string& Test::Name() const {return name;}void Test::Name(const std::string& _name) {name = _name;}typedef std::vector<Test> ChildVector;void fetch() {std::string name = "bob";ChildVector children;   // Here comes the evil error codeChildVector::iterator it = std::find_if( children.begin(), children.end(),((Test&)(boost::phoenix::arg_names::_1)).Name()  == name);}I get lots of error. I am using Visual Studio 2010.   
Quote:((Test&)(boost::phoenix::arg_names::_1)).Name()  == name);Shouldn't this be:boost::phoenic::arg_names::arg1;Quote:Original post by AntheusQuote:((Test&)(boost::phoenix::arg_names::_1)).Name()  == name);Shouldn't this be:boost::phoenic::arg_names::arg1I tested and i got:1>c:\program files (x86)\microsoft visual studio 10.0\vc\include\algorithm(83): error C2064: term does not evaluate to a function taking 1 arguments1>c:\program files (x86)\microsoft visual studio 10.0\vc\include\algorithm(95) : see reference to function template instantiation '_InIt std::_Find_if<Test*,_Pr>(_InIt,_InIt,_Pr)' being compiled1>with1>[1>    _InIt=Test *,1>    _Pr=bool1>]1>test.cpp(67) : see reference to function template instantiation '_InIt std::find_if<std::_Vector_iterator<_Myvec>,bool>(_InIt,_InIt,_Pr)' being compiled1>with1>[1>    _InIt=std::_Vector_iterator<std::_Vector_val<Test,std::allocator<Test>>>,1>    _Myvec=std::_Vector_val<Test,std::allocator<Test>>,1>    _Pr=bool1>]   