[Python-Dev] Getting rid of unbound methods: patch available
Bob Ippolito
bob at redivi.com
Tue Jan 18 02:07:13 CET 2005
On Jan 17, 2005, at 18:33, Glyph Lefkowitz wrote:
> It's not the strongest use-case in the world, but is the impetus to
> remove unbound method objects from Python that much stronger? I like
> the fact that it's simpler, but it's a small amount of extra
> simplicity,
> it doesn't seem to enable any new use-cases, and it breaks the
> potential
> for serialization.
Well, it lets you meaningfully do:
class Foo:
def someMethod(self):
pass
class Bar:
someMethod = Foo.someMethod
Where now you have to do:
class Bar:
someMethod = Foo.someMethod.im_func
I'm not sure how useful this actually is, though.
-bob
More information about the Python-Dev
mailing list