Mercurial > cpython-lru_cache-weakref
comparison Python/errors.c @ 19670:78cfb993f274 legacy-trunk
builtin_dir(): Treat classic classes like types. Use PyDict_Keys instead
of PyMapping_Keys because we know we have a real dict. Tolerate that
objects may have an attr named "__dict__" that's not a dict (Py_None
popped up during testing).
test_descr.py, test_dir(): Test the new classic-class behavior; beef up
the new-style class test similarly.
test_pyclbr.py, checkModule(): dir(C) is no longer a synonym for
C.__dict__.keys() when C is a classic class (looks like the same thing
that burned distutils! -- should it be *made* a synoym again? Then it
would be inconsistent with new-style class behavior.).
| author | Tim Peters <tim.peters@gmail.com> |
|---|---|
| date | Tue, 04 Sep 2001 01:20:04 +0000 |
| parents | e1c91ac55cca |
| children | 55874d8e0dfb |
comparison
equal
deleted
inserted
replaced
| 19669:87e8fc0a9862 | 19670:78cfb993f274 |
|---|
