This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c/37192] --combine problems with one source defining _GNU_SOURCE and the other one doesn't
- From: "pinskia at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 21 Aug 2008 17:56:33 -0000
- Subject: [Bug c/37192] --combine problems with one source defining _GNU_SOURCE and the other one doesn't
- References: <bug-37192-15165@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #4 from pinskia at gcc dot gnu dot org 2008-08-21 17:56 -------
>Compiling the sources separately works, and they are valid C separately.
Well they are valid if compiled separately but once you link them, they become
invalid C :). This is one place where the C standard says the code is invalid
but no diagnostic is required. GCC is producing the diagnostic in --combine
case as it is able to see both prototypes so it complains.
--
pinskia at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Resolution| |INVALID
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37192