Descriptor puzzlement

Jacek Generowicz jacek.generowicz at cern.ch
Thu Jan 8 07:46:27 EST 2004


"John Roth" <newsgroups at jhrothjr.com> writes:

> It doesn't look like the descriptor protocol is getting
> invoked at all.
> 
> What's happening here?

Try changing the following

> class AnotherObject(object):
>     def __init__(self):
>         self.prop = AnObject("snafu")

to 

  class AnotherObject(object):
      prop = AnObject("snafu")




More information about the Python-list mailing list