| 356 | # The following test is also by ppperry. It ensures that |
| 357 | # unsafe_object_compare handles Py_NotImplemented appropriately. |
| 358 | class PointlessComparator: |
| 359 | def __lt__(self, other): |
| 360 | return NotImplemented |
| 361 | L = [PointlessComparator(), PointlessComparator()] |
| 362 | self.assertRaises(TypeError, L.sort) |
| 363 | self.assertRaises(TypeError, [(x,) for x in L].sort) |
no outgoing calls
searching dependent graphs…