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

Method __getitem__

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

Source from the content-addressed store, hash-verified

121 self.format = format
122
123 def __getitem__(self, i):
124 funcs = self._days[i]
125 if isinstance(i, slice):
126 return [f(self.format) for f in funcs]
127 else:
128 return funcs(self.format)
129
130 def __len__(self):
131 return 7

Callers

nothing calls this directly

Calls 2

isinstanceFunction · 0.85
fFunction · 0.70

Tested by

no test coverage detected