Is it possible to overload an operator on a python property? Something like:
class Foo( object ):
@property
def bar( self ): return unfoobar( self._bar )
@bar.setter
def bar( self, baz ): self._bar = foobar( baz )
@bar.__eq__
def bar( self, baz ): return self._bar == foobar( baz )
without defining a special class for _bar (although in this example, that's probably the best solution...).