public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/18050] New: -Wsequence-point reports false positives
@ 2004-10-18 21:57 mitr at volny dot cz
  2004-10-18 22:01 ` [Bug c/18050] " pinskia at gcc dot gnu dot org
                   ` (4 more replies)
  0 siblings, 5 replies; 15+ messages in thread
From: mitr at volny dot cz @ 2004-10-18 21:57 UTC (permalink / raw)
  To: gcc-bugs

void f(int a, int *b) { *b = a; } void g(void) { int a = 5; f(++a, &a); }

with -Wall reports
t.c:1: warning: operation on `a' may be undefined.

This is with the following gcc versions:
[I realize they are all Red Hat versions, not official releases, but
I think that this happening on three different release branches
provides sufficient argument that this is very likely an upstream bug.]

Reading specs from /usr/lib/gcc-lib/i386-redhat-linux/3.3.3/specs
Configured with: ../configure --prefix=/usr --mandir=/usr/share/man
--infodir=/usr/share/info --enable-shared --enable-threads=posix
--disable-checking --disable-libunwind-exceptions --with-system-zlib
--enable-__cxa_atexit --host=i386-redhat-linux
Thread model: posix
gcc version 3.3.3 20040412 (Red Hat Linux 3.3.3-7)

and

Reading specs from /usr/lib/gcc/i386-redhat-linux/3.4.1/specs
Configured with: ../configure --prefix=/usr --mandir=/usr/share/man
--infodir=/usr/share/info --enable-shared --enable-threads=posix
--disable-checking --with-system-zlib --enable-__cxa_atexit
--disable-libunwind-exceptions --enable-java-awt=gtk --host=i386-redhat-linux
Thread model: posix
gcc version 3.4.1 20040831 (Red Hat 3.4.1-10)

and

Reading specs from /usr/lib/gcc/i386-redhat-linux/3.5.0/specs
Configured with: ../configure --prefix=/usr --mandir=/usr/share/man
--infodir=/usr/share/info --enable-shared --enable-threads=posix
--disable-checking --with-system-zlib --enable-__cxa_atexit
--disable-libunwind-exceptions --with-gxx-include-dir=/usr/include/c++/3.4.1
--enable-languages=c,c++,f99 --disable-libgcj --host=i386-redhat-linux
Thread model: posix
gcc version 3.5.0 20040818 (Red Hat 3.5.0-0.9)

-- 
           Summary: -Wsequence-point reports false positives
           Product: gcc
           Version: 3.3.3
            Status: UNCONFIRMED
          Severity: minor
          Priority: P2
         Component: c
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: mitr at volny dot cz
                CC: gcc-bugs at gcc dot gnu dot org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18050


^ permalink raw reply	[flat|nested] 15+ messages in thread

end of thread, other threads:[~2008-08-29  0:10 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <bug-18050-4370@http.gcc.gnu.org/bugzilla/>
2006-03-22 12:19 ` [Bug c/18050] -Wsequence-point reports false positives rguenth at gcc dot gnu dot org
2006-03-22 12:26 ` joseph at codesourcery dot com
2006-03-22 12:53 ` rguenth at gcc dot gnu dot org
2006-03-22 13:08 ` schwab at suse dot de
2008-08-27 19:46 ` pinskia at gcc dot gnu dot org
2008-08-28  1:20 ` manu at gcc dot gnu dot org
2008-08-28  1:23 ` pinskia at gcc dot gnu dot org
2008-08-28  1:31 ` manu at gcc dot gnu dot org
2008-08-29  0:09 ` manu at gcc dot gnu dot org
2008-08-29  0:10 ` manu at gcc dot gnu dot org
2004-10-18 21:57 [Bug c/18050] New: " mitr at volny dot cz
2004-10-18 22:01 ` [Bug c/18050] " pinskia at gcc dot gnu dot org
2004-10-18 22:15 ` giovannibajo at libero dot it
2004-10-18 22:25 ` pinskia at gcc dot gnu dot org
2004-10-18 22:35 ` pinskia at gcc dot gnu dot org
2004-10-18 22:45 ` pinskia at gcc dot gnu dot org

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).