public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Florian Weimer <fweimer@redhat.com>
To: Marek Polacek <polacek@redhat.com>
Cc: gcc-patches@gcc.gnu.org,  jason@redhat.com,
	 jeffreyalaw@gmail.com, joseph@codesourcery.com,  sam@gentoo.org
Subject: Re: [PATCH v2 8/8] c: Add new -Wdeclaration-missing-parameter-type permerror
Date: Tue, 14 Nov 2023 23:27:08 +0100	[thread overview]
Message-ID: <877cmkug1v.fsf@oldenburg.str.redhat.com> (raw)
In-Reply-To: <ZVPYA9fbgdP2hOaE@redhat.com> (Marek Polacek's message of "Tue, 14 Nov 2023 15:26:43 -0500")

* Marek Polacek:

> On Tue, Nov 14, 2023 at 06:50:58PM +0100, Florian Weimer wrote:
>> --- a/gcc/c-family/c.opt
>> +++ b/gcc/c-family/c.opt
>> @@ -591,6 +591,10 @@ Wdeclaration-after-statement
>>  C ObjC Var(warn_declaration_after_statement) Init(-1) Warning
>>  Warn when a declaration is found after a statement.
>>  
>> +Wdeclaration-missing-parameter-type
>> +C ObjC Warning
>> +Warn for missing parameter types in function declarations.
>> +
>
> This doesn't have Var(warn_declaration_missing_parameter), so
> -fpermissive -Wno-declaration-missing-parameter-type still warns
> for
>
>   void foo (i);
>
> where I think the warning should be suppressed.  Is that expected?
> It would be nice to have a test for that combination.

Okay, I'll send a v3 tomorrow with this change and a test.  I had no
idea that this was necessary. 8-/

Thanks,
Florian


  reply	other threads:[~2023-11-14 22:27 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-11-14 17:50 [PATCH v2 0/8] Turn some C warnings into errors by default Florian Weimer
2023-11-14 17:50 ` [PATCH v2 1/8] Add tests for validating future C permerrors Florian Weimer
2023-11-14 17:50 ` [PATCH v2 2/8] c: Turn int-conversion warnings into permerrors Florian Weimer
2023-11-14 17:50 ` [PATCH v2 3/8] c: Turn -Wimplicit-function-declaration into a permerror Florian Weimer
2023-11-14 17:50 ` [PATCH v2 4/8] c: Turn -Wimplicit-int " Florian Weimer
2023-11-14 17:50 ` [PATCH v2 5/8] c: Do not ignore some forms of -Wimplicit-int in system headers Florian Weimer
2023-11-15  5:03   ` Sam James
2023-11-15  5:12     ` Florian Weimer
2023-11-15  5:13       ` Sam James
2023-11-21 21:18         ` Jason Merrill
2023-11-14 17:50 ` [PATCH v2 6/8] c: Turn -Wreturn-mismatch into a permerror Florian Weimer
2023-11-14 17:50 ` [PATCH v2 7/8] c: Turn -Wincompatible-pointer-types " Florian Weimer
2023-11-14 17:50 ` [PATCH v2 8/8] c: Add new -Wdeclaration-missing-parameter-type permerror Florian Weimer
2023-11-14 20:26   ` Marek Polacek
2023-11-14 22:27     ` Florian Weimer [this message]
2023-11-15  5:16 ` [PATCH v2 0/8] Turn some C warnings into errors by default Sam James
2023-11-15  6:37   ` Florian Weimer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=877cmkug1v.fsf@oldenburg.str.redhat.com \
    --to=fweimer@redhat.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=jason@redhat.com \
    --cc=jeffreyalaw@gmail.com \
    --cc=joseph@codesourcery.com \
    --cc=polacek@redhat.com \
    --cc=sam@gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).