if <assignment>:
Greg Ewing
see_reply_address at something.invalid
Wed Nov 27 22:01:55 EST 2002
Erik Max Francis wrote:
>
> I think the severity of the =/== confusion problem in C has been
> severely overrepresented in this thread. In my opinon, in the real
> world, among competent software eengineers, it is a tiny issue.
I think it's too simplistic to regard the =/== confusion problem
as the only reason to be wary of assignments in expressions.
It also hurts readability to have expressions with assignments
buried in them.
This is a special case of the general principle that it's
usually clearer if expressions don't have side effects.
--
Greg Ewing, Computer Science Dept,
University of Canterbury,
Christchurch, New Zealand
http://www.cosc.canterbury.ac.nz/~greg
More information about the Python-list
mailing list