while (a=b()) ...

Tony J Ibbs (Tibs) tony at lsl.co.uk
Wed May 12 09:51:38 EDT 1999


Paul Boddie <paulb at infercor.no> wrote:
> Of course, the "while 1" is a bit "ugly", but then it merely causes the
> reader to go looking for the exit points. We could change that to a
> single keyword acting as a synonym if it really bothered a significant
> number of people, but I don't see too much of a need for that.

...not that he started the discussion this time round, or necessarily 
espouses any of the views I'm reacting to...

I wonder what actually *starts* people on this worry - are they finding 
the extra "1" in "while 1:" to be worrisome (and only then getting all 
purist about whether "break" is really some sort of "goto" - oh dear),
or would they be equally worried if it were instead just a simple
"while:" with no expression in there at all?

Hmm. Personally, I'm still much more worried about 0 introducing octal
numbers than by having to type an extra "1" to get infinite loops, 
which shows how much importance I place on *that*, I hope.

Tibs
-- 
Tony J Ibbs (Tibs)      http://www.tibsnjoan.demon.co.uk/
My views! Mine! Mine! (Unless Laser-Scan ask nicely to borrow them.)





More information about the Python-list mailing list