This is the mail archive of the gcc@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]

Re: Question for ISO C standards gurus



On Mar 25, 2004, at 10:12 AM, Paul Jarc wrote:


law@redhat.com wrote:
if (!(names = ecgetlist(state, *state->pc++, 2, &htok))) {
...
Of particular interest is whether or not the increment occurs before
the call or after the call.

n869, 6.5.2.2p10: # The order of evaluation of the function designator, the actual # arguments, and subexpressions within the actual arguments is # unspecified, but there is a sequence point before the actual call.

So the side effect would take place before the sequence point, and
thus before the call.  n869 was the latest public draft of C99; I
don't have a copy of the final standard.  It's possible that this
might have changed.

The final standard says the same, as does C89.



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