
10 Apr
2008
10 Apr
'08
1:28 a.m.
Eric Niebler wrote:
IIUC, this has implications for people wanting to write TR1-style function objects today. I think Shunsuke may be right in that we need an rvalue_wrapper so that it is possible to write function objects that will continue to work unmodified in C++0x. That is, my use of reference_wrapper to carry lvalue-ness has it backwards. T const & should be assumed to be a const lvalue, because it will mean that unambiguously in C++0x.
FWIW, I think fusion::make_vector()'s use of reference_wrapper is also incorrect. :-(
Which was taken from Boost.Tuple by Jaakko, FWIW. Interesting... :) Regards, -- Joel de Guzman http://www.boost-consulting.com http://spirit.sf.net