[Python-3000] Bound and unbound methods

Steven Bethard steven.bethard at gmail.com
Sun Aug 13 19:29:20 CEST 2006

On 8/13/06, Talin <talin at acm.org> wrote:
> One of the items in PEP 3100 is getting rid of unbound methods. I want
> to explore a heretical notion, which is getting rid of bound methods as
> well.

I believe you're suggesting that the code that I just wrote moments
ago would stop working::

    get_features = self._get_document_features
    return [get_features(i, document_graph, comparable_graphs)
            for i, document_graph in enumerate(document_graphs)]

The line ``get_features = ...`` expects the function stored to be
bound to ``self``.  I write code like this *all the time*,
particularly when I have a long method name that needs to be used in a
complex expression and I want to keep my lines within the suggested 79

If I understand the proposal right and my code above would be
invalidated, I'm a strong -1 to this. It would break an enormous
amount of my code.

I'm not *in*-sane. Indeed, I am so far *out* of sane that you appear a
tiny blip on the distant coast of sanity.
        --- Bucky Katt, Get Fuzzy

More information about the Python-3000 mailing list