Message284155
Ah, I tested only with non-debug build in which asserts were ignored! In 2.7 Element doesn't support garbage collection, and the trashcan mechanism Py_TRASHCAN_SAFE_BEGIN/Py_TRASHCAN_SAFE_END can't be applied.
I see three alternatives:
1. Just revert the changes. Let deep ElementTree crashing.
2. Add the support of garbage collection. This will increase the size of empty Element by 1.5 times. This looks less appropriate that the first option since this harms working code.
3. Try to implement different mechanism. By using external list object as a stack or using other field for creating a linked list.
I'll revert the patch (except tests fix) and will try to implement different mechanism. |
|
Date |
User |
Action |
Args |
2016-12-28 07:13:14 | serhiy.storchaka | set | recipients:
+ serhiy.storchaka, scoder, vstinner, eli.bendersky, python-dev |
2016-12-28 07:13:14 | serhiy.storchaka | set | messageid: <1482909194.16.0.445585773319.issue28871@psf.upfronthosting.co.za> |
2016-12-28 07:13:14 | serhiy.storchaka | link | issue28871 messages |
2016-12-28 07:13:13 | serhiy.storchaka | create | |
|