[Bug c++/57176] copy elision with function arguments passed by value

daniel.kruegler at googlemail dot com gcc-bugzilla@gcc.gnu.org
Mon May 6 13:11:00 GMT 2013


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57176

--- Comment #3 from Daniel Krügler <daniel.kruegler at googlemail dot com> 2013-05-06 13:11:15 UTC ---
(In reply to comment #2)
> Do you have a link to the discussion, or happen to remember the arguments? 
> I can see that there are more possible issues with the parameter (it lives 
> a little longer in the caller, which gives more chances to reuse it), but 
> the permission to move probably already breaks most such examples.

I couldn't find any discussion in regard to this specific issue, but looking at

http://www.open-std.org/jtc1/sc22/wg21/docs/cwg_active.html#6

it seems that they would prefer to see a paper before the committee would
perform any further action. It seems that inline functions are possibly less
controversial and

http://www.open-std.org/jtc1/sc22/wg21/docs/cwg_active.html#1049

addresses a similar problem in regard to inline functions with reference
parameters.


More information about the Gcc-bugs mailing list