Issue #16602: When a weakref's target was part of a long deallocation chain, the object could remain reachable through its weakref even though its refcount had dropped to zero.
Thanks to Eugene Toder for diagnosing and reporting the issue.
A
Antoine Pitrou committed
62a0d6ea402d18f528629c6e84ed6f46e7c0912a
Parent: 09974b4