Boost logo

Boost Users :

Subject: [Boost-users] Problem with nested bind
From: przemyslaw.sliwa_at_[hidden]
Date: 2010-08-17 12:05:50


I am trying to make a simple nested bind in boost. I have the fillowing

        struct eventInterval
                double start, finish, weight;
and a typedef

typedef boost::shared_ptr<eventInterval> eventIntervalPtr;

and then I am trying to copy (actually push back to a vector) all elements
which have weight > 0.0. I cannot sompile this bit of code:

std::vector<eventIntervalPtr> posIntervals, negIntervals,
intervals(eventPtr->decomposeIntervals(anchorDate, today));

std::transform(intervals.begin(), intervals.end(),
std::back_inserter(posIntervals), boost::bind(std::greater<double>(),
boost::bind(&eventInterval::weight, _1), 0.0));

Could someone help me with this issue?


This e-mail may contain confidential and/or privileged information. If you are not the intended recipient (or have received this e-mail in error) please notify the sender immediately and delete this e-mail. Any unauthorised copying, disclosure or distribution of the material in this e-mail is prohibited.

Please refer to for additional disclosures.

Boost-users list run by williamkempf at, kalb at, bjorn.karlsson at, gregod at, wekempf at