[PATCH] Exploit move semantics in std::accumulate.

Marc Glisse marc.glisse@inria.fr
Sat Jan 8 18:31:00 GMT 2011


On Sat, 8 Jan 2011, Christopher Jefferson wrote:

> Your patch is a really nice idea. I'm not 100% sure it is allowed by the 
> C++0x standard (although, I can't imagine any valid code which would 
> possibly break it).

It has a strong smell of x=move(x); about it...
In some sense, it is too bad accumulate can't use operator+=.

-- 
Marc Glisse



More information about the Libstdc++ mailing list