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

Method __getitem__

Lib/calendar.py:104–109  ·  view source on GitHub ↗
(self, i)

Source from the content-addressed store, hash-verified

102 self.format = format
103
104 def __getitem__(self, i):
105 funcs = self._months[i]
106 if isinstance(i, slice):
107 return [f(self.format) for f in funcs]
108 else:
109 return funcs(self.format)
110
111 def __len__(self):
112 return 13

Callers

nothing calls this directly

Calls 2

isinstanceFunction · 0.85
fFunction · 0.70

Tested by

no test coverage detected