
5 Dec
2011
5 Dec
'11
9:11 p.m.
On Dec 5, 2011, at 12:53 PM, Marshall Clow wrote:
But if I add the following code:
bool comp ( int x ) { return x > 10; } and res = Foo ( v, comp );
I get a bunch of compilation errors.
My bad. Since the range-based versions of Foo take the range by const &, they return pairs of const_iterators. res is a pair of non-const iterators; you can't assign one to the other. Never mind. Thanks, everyone, for your help! -- Marshall