> Your "very strong feeling" is wrong in this case. Evaluation order > for function arguments in C is not specified. However, '&&' and '||' > are not functions. In C/C++, and several other languages, '&&' and > '||' are short-circuit operators, NOT logical operators. Millions of > lines of C (or C++, Java, Perl, JavaScript, etc.) would crash or > otherwise fail if constructs like > > if (ptr && *ptr) { /* do something */ } > > did not work as expected. See > > http://en.wikipedia.org/wiki/Short-circuit_evaluation > > for a more complete description of this common computer language > feature.
Fascinating. Being self-taught in C, it's always interesting to learn something new - even if it does go against intuition :) ATB, Mark. -- Mark Cave-Ayland Sirius Corporation - The Open Source Experts http://www.siriusit.co.uk T: +44 870 608 0063 _______________________________________________ postgis-users mailing list postgis-users@postgis.refractions.net http://postgis.refractions.net/mailman/listinfo/postgis-users