https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94034

Jason Merrill <jason at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |jason at gcc dot gnu.org

--- Comment #6 from Jason Merrill <jason at gcc dot gnu.org> ---
(In reply to Patrick Palka from comment #5)
> Here is a rejects-valid testcase caused by the same underlying issue:

Actually, A does not have guaranteed copy elision in function argument passing
or return.  Which is a good thing, since it can't have it under the current
ABI.

http://eel.is/c++draft/class.temporary#3 

"When an object of class type X is passed to or returned from a function, if X
has at least one eligible copy or move constructor ([special]), each such
constructor is trivial, and the destructor of X is either trivial or deleted,
implementations are permitted to create a temporary object to hold the function
parameter or result object."

So I suppose my comment on Paolo's patch was wrong, and this is only a
diagnostic quality issue after all.

Reply via email to