Overloading assignment operator

Kay Schluehr kay.schluehr at gmx.net
Tue Jan 23 16:43:27 EST 2007


Achim Domma schrieb:

> Hi,
>
> I want to use Python to script some formulas in my application. The user
> should be able to write something like
>
> A = B * C
>
> where A,B,C are instances of some wrapper classes. Overloading * is no
> problem but I cannot overload the assignment of A. I understand that
> this is due to the nature of Python, but is there a trick to work around
> this?

Not that I know about it but what shall be the behaviour of assignment
when being overloaded? 

Kay




More information about the Python-list mailing list