verify whether "str" is still callable in Python 2.5.1

Lawrence Oluyede raims at dot.com
Mon Aug 13 05:21:05 EDT 2007


Ge Chunyuan <hhygcy at gmail.com> wrote:
> Once use ActivePython latest version for Python 2.5.1.
> I happened to find function "str" is not callable, but it is available
> for Python 2.5.
> Can anybody give some comments about it?

I don't really understand what your asking. str is a callable, it has
always been AFAIK, since it's a type constructor, like int()

In [1]: callable(str)
Out[1]: True

In [2]: str()
Out[2]: ''


-- 
Lawrence, oluyede.org - neropercaso.it
"It is difficult to get a man to understand 
something when his salary depends on not
understanding it" - Upton Sinclair



More information about the Python-list mailing list