Boost logo

Boost Users :

From: Sebastian Redl (sebastian.redl_at_[hidden])
Date: 2006-03-15 04:23:04


Meryl Silverburgh wrote:

>Need help in understanding boost lambda compile error:
>
>I have this line of code:
>where grlpVector is vector<GroupResultListProcessor*>
>
>for_each(grlpVector.begin(), grlpVector.end(),
>boost::lambda::bind(&GroupResultListProcessorExecuter::do_process,
>this, *_1));
>
>
This looks a bit like a bug in Lambda to me - it tries to instantiate a
boost::tuple with a member of type GroupResultListProcessor, which fails
because this class is abstract.

As a workaround, try this:

for_each(grlpVector.begin(), grlpVector.end(),
boost::lambda::bind(&GroupResultListProcessorExecuter::do_process,
this, boost::ref(*_1)));

I don't know if that will compile, though.


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net