Steven Bethard wrote: > I'd like to be able to have an instance variable that can > sometimes be > accessed as a property, and sometimes as a regular value, > e.g. something > like: ... > py> c.x is c.x # I'd like this to be False
You'd like 'c.x is c.x' to be FALSE? You can't be serious. Must be a typo. If you want C._x to return something other than the property descriptor, you can. Grab the sample code for Property from http://users.rcn.com/python/download/Descriptor.htm#properties and modify the __get__ method: def __get__(self, obj, objtype=None): if obj is None: return self # Return whatever you like here if self.fget is None: raise AttributeError, "unreadable attribute" return self.fget(obj) That might be one way to get what you want. Robert Brewer MIS Amor Ministries [EMAIL PROTECTED] -- http://mail.python.org/mailman/listinfo/python-list