def METHOD_NAME(cls):
    # Return live finalizers marked for exit, oldest first
    L = [(f, i) for (f, i) in cls._registry.items() if i.atexit]
    L.sort(key=lambda item: item[1].index)
    return [f for (f, i) in L]