MCPcopy Create free account
hub / github.com/python/cpython / Evil

Class Evil

Lib/test/_test_atexit.py:140–143  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

138 def test_eq_unregister_clear(self):
139 # Issue #112127: callback's __eq__ may call unregister or _clear
140 class Evil:
141 def __eq__(self, other):
142 action(other)
143 return NotImplemented
144
145 for action in atexit.unregister, lambda o: atexit._clear():
146 with self.subTest(action=action):

Callers 1

Calls

no outgoing calls

Tested by 1

Used in the wild real call sites across dependent graphs

searching dependent graphs…