On Wed, 04 Feb 2009 05:18:29 +0000, Steven D'Aprano wrote: > ... I'd recommend: > > def __repr__(self): > return '%s(%s, %s)' % ( > self.__class__.__name__, self.ptr, self.name) > def __str__(self): > return "<dim=%g>" % self.size > > > except of course your class doesn't store ptr.
Ah crap, sorry, I meant setp not ptr. Sorry for the confusion. -- Steven -- http://mail.python.org/mailman/listinfo/python-list