MCPcopy Create free account
hub / github.com/numpy/numpy / __len__

Method __len__

numpy/core/tests/test_array_coercion.py:630–632  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

628 obj = []
629 class baditem:
630 def __len__(self):
631 obj[0][0] = 2 # replace with a different list.
632 raise ValueError("not actually a sequence!")
633
634 def __getitem__(self):
635 pass

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected