[lambda] std::string::find

First, sorry for this total newbie question,
i'm trying to do something like this:
std::for_each
(
std::istream_iteratorstd::string(ss),
std::istream_iteratorstd::string(),
boost::lambda::if_then
(
!(boost::lambda::bind(&std::string::substr, boost::lambda::_1, 0, 1) ==
_ignore) &&
!boost::lambda::bind(&std::string::empty, boost::lambda::_1),
(boost::lambda::bind(&std::string::find, boost::lambda::_1, _ignore),
// compiler complains here
---------------------------------<snip>----------------------------------------------------------------------
i'm getting the following error:
Error 23 error C2784: 'const
boost::lambda::lambda_functor

On Sun, 11 Feb 2007 21:24:42 -0000, Bob Quampen <0377521021@iol.cz> wrote:
(boost::lambda::bind(&std::string::find, boost::lambda::_1, _ignore),
[snip]
boost::lambda::lambda_functor Arg1,const Arg2,const Arg3>::type>> boost::lambda::bind(const Arg1
&,const
Arg2 &,const Arg3 &)' : could not deduce template argument for
'overloaded
function type' from 'overloaded function type' am i not supplying the correct amount of parameters to the find method? Sort of, there are actually two problems here. The first is that
std::string::find has 2 overloads with one parameter and the compiler
doesn't know which one to use. The solution is to cast it to the correct
type, ie.
static_cast
participants (2)
-
Bob Quampen
-
Daniel James