This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/67200] Copy elision and implicit move in return performed in cases not allowed by standard


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

TC <rs2740 at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |FIXED

--- Comment #1 from TC <rs2740 at gmail dot com> ---
Appears to be fixed in GCC 6, presumably by the delayed folding changes:

main.cpp: In function 'A f()':
main.cpp:9:23: error: use of deleted function 'A::A(const A&)'
     return true ? a : a;
                       ^
main.cpp:3:5: note: declared here
     A(const A&) = delete;
     ^

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]