re PR c++/42370 ([C++0x][lambda] in a void function: "Warning: control reaches end...
authorJason Merrill <jason@redhat.com>
Tue, 9 Feb 2010 20:05:51 +0000 (15:05 -0500)
committerJason Merrill <jason@gcc.gnu.org>
Tue, 9 Feb 2010 20:05:51 +0000 (15:05 -0500)
commit643d4cd6a10f6d202011eb3005c65994219932f3
tree26a08d06bcdc1e2c8c582ce22c772d0c2726683d
parentb16be5f2c5a0f9aaf398c55c2a3802d878433731
re PR c++/42370 ([C++0x][lambda] in a void function: "Warning: control reaches end of non-void function")

PR c++/42370
* decl2.c (change_return_type): New fn.
* semantics.c (apply_lambda_return_type): Use it.
* cp-tree.h: Declare it.

From-SVN: r156634
gcc/cp/ChangeLog
gcc/cp/cp-tree.h
gcc/cp/decl2.c
gcc/cp/semantics.c
gcc/testsuite/ChangeLog
gcc/testsuite/g++.dg/cpp0x/lambda/lambda-warn2.C [new file with mode: 0644]