This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c/67730] [5/6 Regression] No warning when returning NULL in void function
- From: "mpolacek at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Wed, 30 Sep 2015 12:21:35 +0000
- Subject: [Bug c/67730] [5/6 Regression] No warning when returning NULL in void function
- Auto-submitted: auto-generated
- References: <bug-67730-4 at http dot gcc dot gnu dot org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67730
--- Comment #6 from Marek Polacek <mpolacek at gcc dot gnu.org> ---
Author: mpolacek
Date: Wed Sep 30 12:21:03 2015
New Revision: 228288
URL: https://gcc.gnu.org/viewcvs?rev=228288&root=gcc&view=rev
Log:
PR c/67730
* c-typeck.c (c_finish_return): Use the expansion point location for
certain "return with value" warnings.
* gcc.dg/pr67730.c: New test.
Added:
branches/gcc-5-branch/gcc/testsuite/gcc.dg/pr67730.c
Modified:
branches/gcc-5-branch/gcc/c/ChangeLog
branches/gcc-5-branch/gcc/c/c-typeck.c
branches/gcc-5-branch/gcc/testsuite/ChangeLog