[Tutor] Re: Type Checking
Michael P. Reilly
arcege@shore.net
Sun, 4 Mar 2001 07:57:15 -0500 (EST)
> >From message> 10. Re: Type Checking: (Danny Yoo)
> ...
> > (Does anyone find it humorous that there's even a types.TypeType object
>
> Have you ever repeated a word until it doesn't feel like a word anymore,
> or at least must be spelled wrong?
>
> >>> type(types.TypeType)
> <type 'type'>
Similarly,
>>> types.TypeType
<type 'type'>
>>> x = None
>>> for i in range(5):
... x = type(x)
... print x
...
<type 'None'>
<type 'type'>
<type 'type'>
<type 'type'>
<type 'type'>
>>> x is types.TypeType
1
>>>
I don't find it humorous at all that there should be a name binding in
the types module for the "type" data type; I find it complete.
-Arcege
--
------------------------------------------------------------------------
| Michael P. Reilly, Release Manager | Email: arcege@shore.net |
| Salem, Mass. USA 01970 | |
------------------------------------------------------------------------