A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2006-September/069040.html below:

[Python-Dev] weakref enhancements

[Python-Dev] weakref enhancementsRaymond Hettinger raymond.hettinger at verizon.net
Fri Sep 29 03:03:43 CEST 2006
> There are *definitely* use cases for keeping bound methods around.
>
> Contrived example:
>
>    one_of = set([1,2,3,4]).__contains__
>    filter(one_of, [2,4,6,8,10])

ISTM, the example shows the (undisputed) utility of regular bound methods.

How does it show the need for methods bound weakly to the underlying object,
where the underlying can be deleted while the bound method persists, alive but 
unusable?


Raymond 

More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4