This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c/63498] New: spurious warning about unrecognized command line option "-Wno-typedef-redefinition"


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63498

            Bug ID: 63498
           Summary: spurious warning about unrecognized command line
                    option "-Wno-typedef-redefinition"
           Product: gcc
           Version: 4.9.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c
          Assignee: unassigned at gcc dot gnu.org
          Reporter: zbyszek at in dot waw.pl

With the following program:

# test.c
int main(){}

when compiled with 'gcc -Wall -Wno-typedef-redefinition test.c' I get two
warnings, the second one is wrong, because -Wno-typedef-redefinition is a
documented option:

$ gcc -Wall -Wno-typedef-redefinition test.c
test.c: In function âmainâ:
test.c:1:1: warning: control reaches end of non-void function [-Wreturn-type]
 int main(){}
 ^
test.c: At top level:
cc1: warning: unrecognized command line option "-Wno-typedef-redefinition"

This warning is emitted only when at least one other warning is emitted.

$ rpm -q gcc
gcc-4.9.1-11.fc21.x86_64
(But older versions exhibit this behaviour too.)

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]