This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: c/10143: Post increment doesn work more than once per statement
- From: Falk Hueffner <falk dot hueffner at student dot uni-tuebingen dot de>
- To: "Nick Macdonald" <macdonn at nortelnetworks dot com>
- Cc: gcc-gnats at gcc dot gnu dot org, gcc-bugs at gcc dot gnu dot org
- Date: 19 Mar 2003 15:24:26 +0100
- Subject: Re: c/10143: Post increment doesn work more than once per statement
- References: <3E787869.CC18EAAA@americasm01.nt.com>
"Nick Macdonald" <macdonn at nortelnetworks dot com> writes:
> http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=10143
>
> If this is not a bug then can someone please point me at an
> indication in the standard that indicates how this is correct
> behaviour?
6.5: Between the previous and next sequence point an object shall have
its stored value modified at most once by the evaluation of an
expression. Furthermore, the prior value shall be read only to
determine the value to be stored.
> (Is there a FAQ entry somewhere that deals with this issue?)
See the documentation of -Wsequence-point. (We should probably add
this to the list of C non-bugs...)
--
Falk