mirror of
https://github.com/python/cpython.git
synced 2025-08-04 08:59:19 +00:00
PEP 479: Use the return-keyword instead of raising StopIteration inside a generators.
This commit is contained in:
parent
828d932a2c
commit
bb6c0aaebf
6 changed files with 4 additions and 7 deletions
|
@ -1803,8 +1803,6 @@ class RegressionTests(unittest.TestCase):
|
|||
hist.append(3)
|
||||
yield 2
|
||||
hist.append(4)
|
||||
if x:
|
||||
raise StopIteration
|
||||
|
||||
hist = []
|
||||
self.assertRaises(AssertionError, list, chain(gen1(), gen2(False)))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue