assignment to __class__ (was Re: Copy constructors)

Roman Suzi rnd at onego.ru
Mon Aug 13 22:17:34 CEST 2001


One more question.

Python programmers use the following idiom:

class A:
  # ...
  def __mul__(self, other):
    ...
  __rmul__ = __mul__


If I understood correctly, __rmul__ will be of different
category from __mul__? This causes asymmetry...

Sincerely yours, Roman Suzi
-- 
_/ Russia _/ Karelia _/ Petrozavodsk _/ rnd at onego.ru _/
_/ Monday, August 13, 2001 _/ Powered by Linux RedHat 6.2 _/
_/ "I distinctly remember forgetting that." _/





More information about the Python-list mailing list