restore a generator's caller's exception state both on yield and (last) return
authorBenjamin Peterson <benjamin@python.org>
Sun, 3 Jul 2011 18:44:00 +0000 (13:44 -0500)
committerBenjamin Peterson <benjamin@python.org>
Sun, 3 Jul 2011 18:44:00 +0000 (13:44 -0500)
commit83195c3f0cffc571e265ca7e42cbbe1f27c792e1
tree715fce3d966235a79e37a059c7060a2814e62e6b
parentc77eccd608a8a7d74980b2257a2d2721435f7415
restore a generator's caller's exception state both on yield and (last) return

This prevents generator exception state from leaking into the caller.

Closes #12475.
Lib/test/test_exceptions.py
Misc/NEWS
Python/ceval.c