Boost logo

Boost Users :

Subject: Re: [Boost-users] lambda control structures
From: Nat Goodspeed (nat_at_[hidden])
Date: 2010-02-05 17:24:55


Archie14 wrote:

> What I am trying to achieve is to stop for_each if "getParamValue" returns
> false. However I can't find a way to use "return" in the second part of
> boost::lambda::if_, so I am using a dummy var "a" to check it after the loop
> completes.
>
> My question is: what is the right way to use lambda control structure in this
> case?

Maybe you want std::find_if instead of std::for_each?


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