On Jun 25, 2:30 pm, Carl Banks wrote:
Thank you for the very good reply. In fact delegating is the approach
that works. The main thing to notice is that for an uninstantiated
class the first arg to __get__ is None:
class desc(object):
__slots__ = ('x')
def __init__(self, desc):
On Jun 25, 8:10 am, Michael Sliczniak wrote:
> Suppose I have this:
>
> Python 2.5.1 (r251:54863, Feb 6 2009, 19:02:12)
> [GCC 4.0.1 (Apple Inc. build 5465)] on darwin
> Type "help", "copyright", "credits" or "license" for more information.>>>
> class A(object):
>
> ... __slots__ = ('x', 'y'
Michael Sliczniak wrote:
> Suppose I have this:
>
> Python 2.5.1 (r251:54863, Feb 6 2009, 19:02:12)
> [GCC 4.0.1 (Apple Inc. build 5465)] on darwin
> Type "help", "copyright", "credits" or "license" for more information.
class A(object):
> ... __slots__ = ('x', 'y')
> ...
a = A()
>