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++/64329] Crash when returning reference from lambda with deduced type


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

Jonathan Wakely <redi at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |wrong-code
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2016-04-16
     Ever confirmed|0                           |1

--- Comment #4 from Jonathan Wakely <redi at gcc dot gnu.org> ---
Confirming the original report, which is a real bug.


N.B. for the different issue in comment 1, G++ will warn but only with
-Wsystem-headers, because the problem is inside the <functional> header:

/home/jwakely/gcc/6/include/c++/6.0.0/functional:1726:40: warning: returning
reference to temporary [-Wreturn-local-addr]
      std::forward<_ArgTypes>(__args)...);
                                        ^

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