Are routine objects guaranteed mutable & with dictionary?

Marco Mariani marco at sferacarta.com
Fri Dec 4 05:47:00 EST 2009


Alf P. Steinbach wrote:


> Is this guaranteed to work in Python 3.x?
> 
> 
>  >>> def foo(): pass
> ....
>  >>> foo.blah = 222
>  >>> foo.blah
> 222
>  >>> _

I don't see why it shouldn't work.

BTW, it's a function, not a "routine"




More information about the Python-list mailing list