Mailing List Archive

clobbering
is there any way to get python to warn you when you clobber
a function refrence with a variable?

I was writing this and it vexed me for some time:

for dir in sys.path:
dir(...)
...

it is silly user error but a flag to say warn if clobbering functions
with variables (or at lease builtin functions).

cheers, Angus.
clobbering [ In reply to ]
From: Angus MacKay <amackay@starvision.com>

is there any way to get python to warn you when you clobber
a function refrence with a variable?

I was writing this and it vexed me for some time:

for dir in sys.path:
dir(...)
...

it is silly user error but a flag to say warn if clobbering functions
with variables (or at lease builtin functions).

cheers, Angus.