A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2003-December/040721.html below:

[Python-Dev] Re: Int FutureWarnings and other 2.4 TODOs

[Python-Dev] Re: Int FutureWarnings and other 2.4 TODOs [Python-Dev] Re: Int FutureWarnings and other 2.4 TODOsJohn J Lee jjl at pobox.com
Thu Dec 4 18:36:05 EST 2003
On Thu, 4 Dec 2003, Andrew Koenig wrote:

> > (It has been pointed out that subclassing int isn't very useful, so
> > maybe this is a moot point.  Does anybody have a real use case?)
>
> isinstance(x, int)

If that's really the only use case, is the following not sufficient?

isinstance(x, types.IntegralTypes)


(where IntegralTypes == (int, long), analogously to types.StringTypes)


John

More information about the Python-Dev mailing list

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