On Mon, Apr 25, 2011 at 8:04 AM, haael <haael at interia.pl> wrote: > Sorry if I am asking the obvious, but why are the aliases of set types not > included in the 'types' module? I thought for a moment that they are just > classes, but no, they introduce themselves as built-in types, just like any > other standard Python type. The types module pre-dates the time when classes were actually types in their own right, and many of the built-in constructors, like "float", "int", and "list", were simply functions. When that was the case: >>> import types >>> types.IntType == int False For types that have always been types, there's no corresponding entry in the types module, nor is there any need for any, since the type itself is already accessible. -Fred -- Fred L. Drake, Jr. <fdrake at acm.org> "Give me the luxuries of life and I will willingly do without the necessities." --Frank Lloyd Wright
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4