variable declaration

Michael Tobis mt at 3planes.com
Tue Feb 1 15:43:50 EST 2005


> All in all, I fail to see what gains would be expected by making
Python
> into a single-assignment or single-binding language, even on a module
by
> module basis, to repay this kind of awkwardness.

Just to be clear, if anyone was suggesting that, it wasn't me.

It would be helpful on occasion in a numarray development context to
have *specific* refererences be bound only once, and I wouldn't be
surprised if the compiler couldn't use that information to good
advantage too.

However, this subthread is about whether rebinding is completely
avoidable. Others including you have come up with better reasons than I
did that it's not.

If rebinding is normal, I think the 'epselon' bug can't be dismissed as
completely avoidable. This is something that I gather you disagree with
on the presumption that everyone who writes Python is sufficently
talented that they can use their skills to avoid getting too far into
this trap.

Since I'm very much a believer in Python as a beginner's language, that
doesn't satisfy me. "Declarations are impractical" would satisfy me,
but so far I'm not completely convinced of that.

mt




More information about the Python-list mailing list