id,summary,reporter,owner,description,type,status,milestone,component,version,severity,resolution,keywords,cc 1133,compile error for parsing a string on vc2005,pop.atry@…,Joel de Guzman,"{{{ #include #include extern std::string s; extern boost::spirit::rule<> r; void compile_failed() { boost::spirit::parse(s.begin(), s.end(), r); } /**/ }}} This is the error message the compiler reported: {{{ 1>parse.cpp 1>c:\documents and settings\yangbo\桌面\work\research\boost\boost\spirit\core\non_terminal\impl\rule.ipp(190) : error C2664: “boost::spirit::impl::abstract_parser::do_parse_virtual”: 不能将参数 1 从“const boost::spirit::scanner”转换为“const boost::spirit::scanner<> &” 1> with 1> [ 1> ScannerT=boost::spirit::scanner<>, 1> AttrT=boost::spirit::nil_t 1> ] 1> and 1> [ 1> IteratorT=std::_String_iterator,std::allocator>, 1> PoliciesT=boost::spirit::scanner_policies<> 1> ] 1> 原因如下: 无法从“const boost::spirit::scanner”转换为“const boost::spirit::scanner<>” 1> with 1> [ 1> IteratorT=std::_String_iterator,std::allocator>, 1> PoliciesT=boost::spirit::scanner_policies<> 1> ] 1> 没有可用于执行该转换的用户定义的转换运算符,或者无法调用该运算符 1> c:\documents and settings\yangbo\桌面\work\research\boost\boost\spirit\core\non_terminal\impl\rule.ipp(172): 参见对正在编译的函数 模板 实例化“boost::spirit::match boost::spirit::impl::rule_base::parse_main(const ScannerT &) const”的引用 1> with 1> [ 1> DerivedT=boost::spirit::rule<>, 1> EmbedT=const boost::spirit::rule<> &, 1> T0=boost::spirit::nil_t, 1> T1=boost::spirit::nil_t, 1> T2=boost::spirit::nil_t, 1> ScannerT=boost::spirit::scanner,std::allocator>,boost::spirit::scanner_policies<>> 1> ] 1> c:\documents and settings\yangbo\桌面\work\research\boost\boost\spirit\core\impl\parser.ipp(28): 参见对正在编译的函数 模板 实例化“boost::spirit::match boost::spirit::impl::rule_base::parse>(const ScannerT &) const”的引用 1> with 1> [ 1> DerivedT=boost::spirit::rule<>, 1> EmbedT=const boost::spirit::rule<> &, 1> T0=boost::spirit::nil_t, 1> T1=boost::spirit::nil_t, 1> T2=boost::spirit::nil_t, 1> IteratorT=std::_String_iterator,std::allocator>, 1> PoliciesT=boost::spirit::scanner_policies<>, 1> ScannerT=boost::spirit::scanner,std::allocator>,boost::spirit::scanner_policies<>> 1> ] 1> c:\documents and settings\yangbo\桌面\work\research\http_client\parse.cpp(6): 参见对正在编译的函数 模板 实例化“boost::spirit::parse_info boost::spirit::parse,DerivedT>(const IteratorT &,const IteratorT &,const boost::spirit::parser &)”的引用 1> with 1> [ 1> IteratorT=std::_String_iterator,std::allocator>, 1> _Elem=char, 1> _Traits=std::char_traits, 1> _Alloc=std::allocator, 1> DerivedT=boost::spirit::rule<> 1> ] }}} ",Bugs,closed,To Be Determined,spirit,Boost 1.34.1,Problem,wontfix,,