None assigment

D-Man dsh8290 at rit.edu
Thu Feb 8 14:05:48 EST 2001


On Thu, Feb 08, 2001 at 10:55:40AM -0800, Neil Schemenauer wrote:
| On Thu, Feb 08, 2001 at 01:15:23PM -0500, D-Man wrote:
| > Interesting.  So normally "None" is a special keyword (that is a
| > reference to an object) ,  but that doesn't prevent one from creating
| > a local variable named "None" that shadows the keyword.
| 
| Sounds like something another P language would do.  Things are
| simpler.  None is a builtin.  It exists in the __builtin__
| module.  The buildin module is searched for names after the
| global namespace is searched.

So why can't I 'del' it then?  It is the response from del that made
me think it was a special keyword.

-D





More information about the Python-list mailing list