[Python-Dev] Comparison speed

Barry A. Warsaw barry@digicool.com
Tue, 15 May 2001 17:51:00 -0400


>>>>> "GvR" == Guido van Rossum <guido@digicool.com> writes:

    GvR> I'm curious where the frequent comparisons of types come
    GvR> from.

    GvR> Is there lots of code that does frequent

    GvR>     assert type(x) == T

    GvR> typechecking?

    GvR> Does isinstance(x, T) perhaps use EQ?

Not to mention the several hundred comparisons to None.