15 Nov
2017
15 Nov
'17
6:58 a.m.
On 15/11/2017 19:27, Gevorg Voskanyan wrote:
On 11/15/17 03:04, Gavin Lambert wrote:
Given that NRVO is mandatory now, <snip>
It is? Since when? AFAIK C++17 makes RVO mandatory, but not NRVO.
True, I was thinking of a different case and misspoke. The rest of the post still stands though; any optimiser worth its salt should be able to apply NVRO there and elide most if not all of the copies, and it should be safer without sacrificing performance. Granted that I have not actually measured this, and so might end up surprised.