This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author ezio.melotti
Recipients SilentGhost, benjamin.peterson, eric.araujo, ezio.melotti, georg.brandl, pitrou
Date 2010-11-24.20:35:11
SpamBayes Score 3.2010172e-11
Marked as misclassified No
Message-id <1290630913.87.0.807686460466.issue10518@psf.upfronthosting.co.za>
In-reply-to
Content
I'm not sure it's worth bringing callable() back at this point.
It would have made more sense for 3.1, but now we already have 2  callable()-less versions of Python if we do it for 3.2 (what about the moratorium though?) or 3 if we do it for 3.3.  Also if isinstance(obj, collections.Callable) is correct in what it does, it's trivial to do something like:

def callable(obj):
  return isinstance(obj, collections.Callable)


If it goes in the `iscallable` name suggested on python-dev might be better (IMHO).  At least people will realize that it's something "new" and don't assume that the old callable() has been there all the time (it also clear that it returns a boolean and reads better in e.g. `if iscallable(obj): ...`).
(The patch should also include an entry in the table at the top of functions.rst now that I committed #10299 in r86732.)
History
Date User Action Args
2010-11-24 20:35:13ezio.melottisetrecipients: + ezio.melotti, georg.brandl, pitrou, benjamin.peterson, eric.araujo, SilentGhost
2010-11-24 20:35:13ezio.melottisetmessageid: <1290630913.87.0.807686460466.issue10518@psf.upfronthosting.co.za>
2010-11-24 20:35:11ezio.melottilinkissue10518 messages
2010-11-24 20:35:11ezio.melotticreate