Function Argument Evaluation

Christopher R Volpe volpe at camelback.crd.ge.com
Tue Mar 26 07:22:14 AEST 1991


In article <15552 at smoke.brl.mil>, gwyn at smoke.brl.mil (Doug Gwyn) writes:
|>In article <17809 at crdgw1.crd.ge.com> volpe at camelback.crd.ge.com
(Christopher R Volpe) writes:
|>>Ok, but I believe that is true only because the behavior is undefined
|>
|>No; the order of evaluation in this example is explicitly UNSPECIFIED,

Oh, by the way, Doug, I didn't say the order of evaluation was undefined.
I said the behavior of the program itself was undefined (as Colin
pointed out). And I'm not saying it's because of any unspecified order
of evaluation. It's because the object referenced by p has its value 
modified more than once between sequence points. (Is this right?)

Is it true that the behavior of the program is undefined (for the above
reason)? If so, then of course any output is a possible output. If not,
then could you explain why the value of p at any given time during
execution of that program has any significance whatsoever?

Thanks for your patience and help in clarifying this.

-Chris        
==================
Chris Volpe
G.E. Corporate R&D
volpecr at crd.ge.com



More information about the Comp.std.c mailing list