$include_dir="/home/hyper-archives/boost-users/include"; include("$include_dir/msg-header.inc") ?>
Subject: Re: [Boost-users] [lambda] lambda member access
From: Steven Watanabe (watanabesj_at_[hidden])
Date: 2009-01-29 14:00:40
AMDG
Micha³ Nowotka wrote:
> void clean_data (MyMap& map)
> {
> remove_if(map.begin(), map.end(), (&lambda::_1 )->*(&pair< X* const,
> double >::second) <= m_epsilon);
> }
>
> where:
>
> typedef std::map<const X*,double> MyMap;
>
The keys in a map are immutable. remove_if tries to assign to the
sequence elements.
In Christ,
Steven Watanabe