diff options
author | Guido van Rossum <guido@python.org> | 2001-09-25 03:43:42 (GMT) |
---|---|---|
committer | Guido van Rossum <guido@python.org> | 2001-09-25 03:43:42 (GMT) |
commit | 5c294fb0e634afc4807ca83032ace356512c97dc (patch) | |
tree | 71a9bb4e810bbb936dca64369f49098a4a225196 /Lib/mhlib.py | |
parent | 2306d246e8c5bb928a432726178047b8d50776f5 (diff) | |
download | cpython-5c294fb0e634afc4807ca83032ace356512c97dc.zip cpython-5c294fb0e634afc4807ca83032ace356512c97dc.tar.gz cpython-5c294fb0e634afc4807ca83032ace356512c97dc.tar.bz2 |
Make __class__ assignment possible, when the object structures are the
same. I hope the test for structural equivalence is stringent enough.
It only allows the assignment if the old and new types:
- have the same basic size
- have the same item size
- have the same dict offset
- have the same weaklist offset
- have the same GC flag bit
- have a common base that is the same except for maybe the dict and
weaklist (which may have been added separately at the same offsets
in both types)
Diffstat (limited to 'Lib/mhlib.py')
0 files changed, 0 insertions, 0 deletions