isNumberType? a bug or a feature?
Mark McEahern
marklists at mceahern.com
Tue Feb 12 09:33:19 EST 2002
[Xunning Yue]
> Here is my situation with Python2.2 in Linux:
> >>> from operator import *
> >>> class dummy:
> pass
>
> >>> t = dummy()
> >>> type(t)
> <type 'instance'>
> >>> isNumberType(t)
> 1
>
> Is this a bug or a feature of Python? Can anyone answer this?
This post would be more readable if your sample code were:
>>> from operator import isNumberType
>>> class dummy:
pass
>>> t = dummy()
>>> type(t)
<type 'instance'>
>>> isNumberType(t)
1
Cheers,
// mark
More information about the Python-list
mailing list