|
Boost : |
Subject: [boost] [xpressive] Compiler error on VC7.1
From: Robert Dailey (rcdailey.lists_at_[hidden])
Date: 2012-05-10 17:45:02
Hi,
I'm using Boost 1.49 Xpressive on VC7.1. When I compile the following code,
I get compiler errors (these do not appear on VC9):
sregex const& rex = bos >> _serverName >> !as_xpr("_GWDomino") >>
".diagnostics" >> *(as_xpr(".base")|".renamed");
'rex' is really a function parameter in my real world use case. I'm passing
the entire static regex into a function that takes a 'sregex const&'. I get
the compiler error below. Anyone know why this is happening?
C:\Code\work\cmake-decomp\build-vc7\third_party\boost\1.49.0-stlport-5.2.1\include\boost\proto\traits.hpp(691)
: error C2664: 'boost::proto::exprns_::expr<Tag,Args,Arity>::expr(const
boost::proto::exprns_::expr<Tag,Args,Arity> &)' : cannot convert parameter
1 from
'boost::proto::detail::as_expr<T,Generator,WantsBasicExpr>::result_type' to
'const boost::proto::exprns_::expr<Tag,Args,Arity> &'
with
[
Tag=boost::proto::tagns_::tag::terminal,
Args=boost::proto::argsns_::term<boost::proto::detail::as_expr<const char
[10],boost::proto::detail::base_generator<boost::proto::default_generator>::type,false>::value_type>,
Arity=0
]
and
[
T=const char [10],
Generator=boost::proto::detail::base_generator<boost::proto::default_generator>::type,
WantsBasicExpr=false
]
and
[
Tag=boost::proto::tagns_::tag::terminal,
Args=boost::proto::argsns_::term<boost::proto::detail::as_expr<const char
[10],boost::proto::detail::base_generator<boost::proto::default_generator>::type,false>::value_type>,
Arity=0
]
Reason: cannot convert from
'boost::proto::detail::as_expr<T,Generator,WantsBasicExpr>::result_type' to
'const boost::proto::exprns_::expr<Tag,Args,Arity>'
with
[
T=const char [10],
Generator=boost::proto::detail::base_generator<boost::proto::default_generator>::type,
WantsBasicExpr=false
]
and
[
Tag=boost::proto::tagns_::tag::terminal,
Args=boost::proto::argsns_::term<boost::proto::detail::as_expr<const char
[10],boost::proto::detail::base_generator<boost::proto::default_generator>::type,false>::value_type>,
Arity=0
]
No constructor could take the source type, or constructor overload
resolution was ambiguous
\Code\work\cmake-decomp\server\exchange\tools\uploadlog\uploader.cpp(1372)
: see reference to function template instantiation 'const
boost::add_const<T>::type boost::proto::functional::as_expr<>::operator
()<char,10>(const char (&)[10]) const' being compiled
with
[
T=boost::proto::detail::as_expr<const char
[10],boost::proto::detail::base_generator<boost::proto::default_generator>::type,false>::result_type
]
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk