re PR c++/59916 (constructors and destructors can cause "control reaches end of non...
commit8ae90330f06696b7ae591f9391651223e09f749a
authorJason Merrill <jason@redhat.com>
Wed, 29 Jan 2014 17:13:01 +0000 (29 12:13 -0500)
committerJason Merrill <jason@gcc.gnu.org>
Wed, 29 Jan 2014 17:13:01 +0000 (29 12:13 -0500)
treee0f98d2c3992a14e7100fdfc1fcc2f24d5e2550d
parent4f7c83caa328ea011365f786c19953af274bb0c8
re PR c++/59916 (constructors and destructors can cause "control reaches end of non-void function" warnings with -Os)

PR c++/59916
* optimize.c (maybe_thunk_body): Build a RETURN_EXPR for
cdtor_returns_this case.

From-SVN: r207271
gcc/cp/ChangeLog
gcc/cp/optimize.c
gcc/testsuite/g++.dg/warn/Wreturn-type-10.C [new file with mode: 0644]