callable() builtin-function

Gerrit Holl gerrit at nl.linux.org
Wed Feb 19 15:53:25 CET 2003


Hi,

In the Python regrets list, at http://www.python.org/doc/essays/ppt/,
Although I can understand most of the regrets put there, I do not
understand why Guido has put the callable() function there, with the
comment "just call it".  AFAIK, callable(x) equals hasattr(x,
'__call__'), but what is wrong with callable()? Why could it be
something to regret? Can it be heavily abused? Is it ugly? Is it bad
style?

regards,
Gerrit.

-- 
Asperger Syndroom - een persoonlijke benadering:
	http://people.nl.linux.org/~gerrit/
Het zijn tijden om je zelf met politiek te bemoeien:
	http://www.sp.nl/





More information about the Python-list mailing list