[PING][PATCH] c/55976 -Werror=return-type should error on returning a value from a void function

2018-05-23 Thread dave . pagan
Ping for the following C patch sent on 4/22/2018 https://gcc.gnu.org/ml/gcc-patches/2018-04/msg01034.html Thanks, --Dave == On 04/22/2018 12:17 PM, dave.pa...@oracle.com wrote: This patch fixes handling of -Werror=return-type as well as -Wno-return-type. Currently,

Re: [PATCH] c/55976 -Werror=return-type should error on returning a value from a void function

2018-06-01 Thread dave . pagan
Thanks for pointing this out. I'll check out what's going on and fix the issue --Dave On 05/31/2018 05:53 AM, H.J. Lu wrote: On Wed, May 30, 2018 at 3:56 PM, Jeff Law wrote: On 04/22/2018 01:17 PM, dave.pa...@oracle.com wrote: This patch fixes handling of -Werror=return-type as well as

[PATCH] c/55976 -Werror=return-type should error on returning a value from a void function

2018-06-19 Thread dave . pagan
This patch fixes spurious failure for C test added with original patch for bug 55976. https://gcc.gnu.org/bugzilla/show_bug.cgi?id=55976 Added dg-prune-output for extraneous message causing unexpected test failure for test gcc.dg/noncompile/pr55976-1.c Bootstrap tests run successfully

[PATCH] PR c/30552 gcc crashes when compiling examples with GNU statement expressions in VLAs

2018-03-13 Thread dave . pagan
This patch fixes ICE when statement expression used in old-style function declaration parameter list. See https://gcc.gnu.org/bugzilla/show_bug.cgi?id=30552 In c_parser_postfix_expression (), after seeing a left paren followed by a left curly brace, in addition to checking for existing

Re: [PATCH] c/55976 -Werror=return-type should error on returning a value from a void function

2018-04-04 Thread dave . pagan
On 04/04/2018 10:58 AM, Martin Sebor wrote: On 04/04/2018 11:15 AM, Jakub Jelinek wrote: On Tue, Apr 03, 2018 at 01:36:13PM -0600, Martin Sebor wrote: On 04/03/2018 10:26 AM, dave.pa...@oracle.com wrote: This patch fixes handlng of -Werror=return-type. Currently, even with the flag specified,

Re: [PATCH] c/55976 -Werror=return-type should error on returning a value from a void function

2018-04-05 Thread dave . pagan
On 04/04/2018 07:44 PM, Martin Sebor wrote: On 04/04/2018 05:50 PM, dave.pa...@oracle.com wrote: On 04/04/2018 10:58 AM, Martin Sebor wrote: On 04/04/2018 11:15 AM, Jakub Jelinek wrote: On Tue, Apr 03, 2018 at 01:36:13PM -0600, Martin Sebor wrote: On 04/03/2018 10:26 AM,

Re: [PATCH] c/55976 -Werror=return-type should error on returning a value from a void function

2018-04-04 Thread dave . pagan
Hi Martin, Hadn't thought about, but you're right ... it should be consistent. Currently, -Wno-return-type has no effect on this warning, but it should. Since this patch does fix the original problem, what do you recommend? Scrap this patch? Or let it proceed and submit a new bug noting the

[PATCH] c/55976 -Werror=return-type should error on returning a value from a void function

2018-04-22 Thread dave . pagan
This patch fixes handling of -Werror=return-type as well as -Wno-return-type. Currently, -Werror=return-type does not turn the warnings into errors and -Wno-return-type does not turn off warning/error. Now they both work as expected. https://gcc.gnu.org/bugzilla/show_bug.cgi?id=55976

[PATCH] c/55976 -Werror=return-type should error on returning a value from a void function

2018-04-03 Thread dave . pagan
This patch fixes handlng of -Werror=return-type. Currently, even with the flag specified, return type errors remain warnings. https://gcc.gnu.org/bugzilla/show_bug.cgi?id=55976 Function c_finish_return (), when calling pedwarn, should specifiy OPT_Wreturn_type as the diagnostic index if

[PATCH] PR c/46921 Lost side effect when struct initializer expression uses comma operator

2018-02-26 Thread dave . pagan
This patch fixes improper handling of comma operator expression in a struct field initializer as described in: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=46921 Currently, function output_init_element () does not evaluate the left hand expression in a comma operator that's used for a struct