Expression sequencing query
Leonard Vanek
len at geac.UUCP
Wed Oct 8 00:37:05 AEST 1986
The one thing that is clear from all of the discussion on
the problem of expression sequencing is that one can never
be sure of the order in which an expression in C will be
evaluated.
Although that I agree that it is asking for trouble to mix
side effects in with complicated expressions, I still
believe that it is a pity that C (even Ansi C) does not even
let the programmer tell it what order is desired by the use
of parentheses! To ignore parentheses in determining the
evaluation order (i.e. (a+b)+c does not guarantee that a and
b are added first) causes problems with round off errors,
not just side effects -- and is totally counter-intuitive.
---------------------------------------------------------------------
Leonard Vanek phone (416) 475-0525
Geac Computers International
350 Steelcase Rd. West USENET ... !utzoo!yetti!geac!len
Markham Ontario L3R 1B3
Canada
Note: My Usenet path is subject to change on short notice!
More information about the Comp.lang.c
mailing list