Message293390
Jim doesn't propose to remove fast test, it proposes to add a test for fast path for avoiding invoking __subclasscheck__ (this is slow). This can change semantic, but isinstance() already contains such fast path.
This is similar to testing "elem is seq[i]" before "elem == seq[i]" when search in sequences. This optimization changes semantic for NaNs. Does a "Not-A-Class" class which is not a subclass of itself (issubclass(C, C) returns False) makes any sense? |
|
Date |
User |
Action |
Args |
2017-05-10 08:31:18 | serhiy.storchaka | set | recipients:
+ serhiy.storchaka, georg.brandl, rhettinger, pitrou, Jim Fasarakis-Hilliard |
2017-05-10 08:31:18 | serhiy.storchaka | set | messageid: <1494405078.14.0.497970690961.issue30230@psf.upfronthosting.co.za> |
2017-05-10 08:31:18 | serhiy.storchaka | link | issue30230 messages |
2017-05-10 08:31:18 | serhiy.storchaka | create | |
|