MCPcopy Index your code
hub / github.com/RustPython/RustPython / MyIndexable

Class MyIndexable

Lib/test/test_math.py:234–239  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

232
233# Class providing an __index__ method.
234class MyIndexable(object):
235 def __init__(self, value):
236 self.value = value
237
238 def __index__(self):
239 return self.value
240
241class BadDescr:
242 def __get__(self, obj, objtype=None):

Callers 4

testGcdMethod · 0.70
test_lcmMethod · 0.70
testPermMethod · 0.70
testCombMethod · 0.70

Calls

no outgoing calls

Tested by 4

testGcdMethod · 0.56
test_lcmMethod · 0.56
testPermMethod · 0.56
testCombMethod · 0.56