reassign to builtin possible !?

Bernhard Merkle bernhard.merkle at googlemail.com
Thu Jan 3 08:04:22 EST 2008


Hi there,

I am reading Learning Python 3e from Mark Lutz and just found out that
reassigning to builtins is possible.
What is the reason, why Python allows this ? IMO this is very risky
and can lead to hard to find errors.
(see also Learning Python 3e, Chapter 16, Page 315)

>>> True
True
>>> False
False
>>> True = 1
>>> True
1
>>> True = 0
>>> True
0

TIA,
Berni



More information about the Python-list mailing list