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

Class MyIndexable

Lib/test/test_slice.py:65–70  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

63# Class providing an __index__ method. Used for testing slice.indices.
64
65class MyIndexable(object):
66 def __init__(self, value):
67 self.value = value
68
69 def __index__(self):
70 return self.value
71
72
73class SliceTest(unittest.TestCase):

Callers 1

test_indicesMethod · 0.70

Calls

no outgoing calls

Tested by 1

test_indicesMethod · 0.56

Used in the wild real call sites across dependent graphs

searching dependent graphs…