(cls)
| 633 | |
| 634 | @classmethod |
| 635 | def _select_for_exit(cls): |
| 636 | # Return live finalizers marked for exit, oldest first |
| 637 | L = [(f,i) for (f,i) in cls._registry.items() if i.atexit] |
| 638 | L.sort(key=lambda item:item[1].index) |
| 639 | return [f for (f,i) in L] |
| 640 | |
| 641 | @classmethod |
| 642 | def _exitfunc(cls): |