|
Boost : |
From: yahoo_at_[hidden]
Date: 2001-02-28 03:39:24
--- In boost_at_y..., Gary Powell <Gary.Powell_at_s...> wrote:
> Well if your compiler has partial specialization, lambda does this
very
> nicely.
>
> std::for_each(c.begin(), c.end(),
ll::for_each(free1->(&CType::begin),
>
free1->(&CType::end),
> _Fn);
>
> Where _Fn can be another Lambda statement or a functor.
> -gary-
As much as I enjoy LL (I demand LL support to even consider using a
compiler !), I think it's more a job for an iterator adaptor
based on a pair<OuterContainerIterator, InnerContainerIterator>
( I've hastly crafted some ugly code to do that),
but maybe a deep_view would be even better :-)
Bernard
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk