MCPcopy Index your code
hub / github.com/python/cpython / HugeNegativeLen

Class HugeNegativeLen

Lib/test/test_builtin.py:1341–1343  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1339 return sys.maxsize + 1
1340 self.assertRaises(OverflowError, len, HugeLen())
1341 class HugeNegativeLen:
1342 def __len__(self):
1343 return -sys.maxsize-10
1344 self.assertRaises(ValueError, len, HugeNegativeLen())
1345 class NoLenMethod(object): pass
1346 self.assertRaises(TypeError, len, NoLenMethod())

Callers 1

test_lenMethod · 0.85

Calls

no outgoing calls

Tested by 1

test_lenMethod · 0.68

Used in the wild real call sites across dependent graphs

searching dependent graphs…