[Python-checkins] r75235 - peps/trunk/pep-3100.txt
benjamin.peterson
python-checkins at python.org
Sun Oct 4 17:59:17 CEST 2009
Author: benjamin.peterson
Date: Sun Oct 4 17:59:16 2009
New Revision: 75235
Log:
better callable replacement
Modified:
peps/trunk/pep-3100.txt
Modified: peps/trunk/pep-3100.txt
==============================================================================
--- peps/trunk/pep-3100.txt (original)
+++ peps/trunk/pep-3100.txt Sun Oct 4 17:59:16 2009
@@ -183,7 +183,7 @@
* ``apply()``: use ``f(*args, **kw)`` instead [2]_ [done]
* ``buffer()``: must die (use a bytes() type instead) (?) [2]_ [done]
-* ``callable()``: just use hasattr(x, '__call__') (?) [2]_ [done]
+* ``callable()``: just use isinstance(x, collections.Callable) (?) [2]_ [done]
* ``compile()``: put in ``sys`` (or perhaps in a module of its own) [2]_
* ``coerce()``: no longer needed [2]_ [done]
* ``execfile()``, ``reload()``: use ``exec()`` [2]_ [done]
More information about the Python-checkins
mailing list