dynamically modify help text

Christian Heimes lists at cheimes.de
Mon Jun 28 16:53:08 EDT 2010


>  >>> i.__add__ = __add__
>  >>> i+1
> 6
>  >>>
> 
> Was this in reference to a specific python version?

This doesn't work with new style classes and thus not in Python 3.x.
Subclass from object and you'll see the difference.

Christian




More information about the Python-list mailing list