On Oct 28, 10:07 pm, Mick Krippendorf <mad.m...@gmx.de> wrote: > You could just overwrite set and frozenset: > > class eqmixin(object): > def __eq__(self, other): > print "called %s.__eq__()" % self.__class__ > if isinstance(other, (set, frozenset)): > return True > return super(eqmixin, self).__eq__(other) > > class frozenset(eqmixin, frozenset): > pass
That's nice, but it means that everyone who imports my class will have to import the monkeypatch of frozenset, as well. I'm not sure I want that. More ruby than python, ne? thanks, Jess -- http://mail.python.org/mailman/listinfo/python-list