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

Class IterClass

Lib/test/test_iter.py:326–328  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

324 # Test a new_style class with __iter__ but no next() method
325 def test_new_style_iter_class(self):
326 class IterClass(object):
327 def __iter__(self):
328 return self
329 self.assertRaises(TypeError, iter, IterClass())
330
331 # Test two-argument iter() with callable instance

Callers 1

Calls

no outgoing calls

Tested by 1

Used in the wild real call sites across dependent graphs

searching dependent graphs…