From cb9879b948a19c9434316f8ab6aba9c4601a8173 Mon Sep 17 00:00:00 2001 From: Mark Shannon Date: Fri, 17 Jul 2020 11:44:23 +0100 Subject: bpo-40941: Unify implicit and explicit state in the frame and generator objects into a single value. (GH-20803) * Merge gen and frame state variables into one. * Replace stack pointer with depth in PyFrameObject. Makes code easier to read and saves a word of memory. --- Lib/test/test_yield_from.py | 3 +++ 1 file changed, 3 insertions(+) (limited to 'Lib/test/test_yield_from.py') diff --git a/Lib/test/test_yield_from.py b/Lib/test/test_yield_from.py index 4735ef4bee..d105d8c6eb 100644 --- a/Lib/test/test_yield_from.py +++ b/Lib/test/test_yield_from.py @@ -938,6 +938,9 @@ class TestPEP380Operation(unittest.TestCase): res.append(g1.throw(MyErr)) except StopIteration: pass + except: + self.assertEqual(res, [0, 1, 2, 3]) + raise # Check with close class MyIt(object): def __iter__(self): -- cgit v1.2.1