
23 Mar
2012
23 Mar
'12
2:44 a.m.
Back to your function - perhaps taking unqualified template parameter is not the best idea, and if you want to take a range you might want to be bit more explicit about it? E.g. like this:
template<typename T1, typename T2> void modifies_range(boost::joined_range<T1, T2> && rng);
I hope users of such "modifies_range" function would find nothing to complain about such an interface.
Unfortunately, the reference collapsing no longer works in this case, so this function will not accept an lvalue joined_range. Regards, Nate