Re: Inexplicable behaviour of

2006-04-23 Thread Leif K-Brooks
Fabiano Sidler wrote: > Have a look to the following lines of code: > --- snip --- > class Foo: pass > def bar(): pass > Foo.bar = bar > --- snap --- > > Why does 'bar.__get__(Foo) is Foo.bar' evaluate to False here? Did I > misunderstand the descriptor protocol? bar.__get__(None, Bar) is what yo

Inexplicable behaviour of

2006-04-23 Thread Fabiano Sidler
Have a look to the following lines of code: --- snip --- class Foo: pass def bar(): pass Foo.bar = bar --- snap --- Why does 'bar.__get__(Foo) is Foo.bar' evaluate to False here? Did I misunderstand the descriptor protocol? Thank you for answering, F. Sidler -- http://mail.python.org/mailman/lis