aboutsummaryrefslogtreecommitdiff
path: root/tests/basics/gen_yield_from_throw3.py
AgeCommit message (Collapse)Author
2018-03-30py/runtime: Be sure that non-intercepted thrown object is an exception.Damien George
The VM expects that, if mp_resume() returns MP_VM_RETURN_EXCEPTION, then the returned value is an exception instance (eg to add a traceback to it). It's possible that a value passed to a generator's throw() is not an exception so must be explicitly checked for if the thrown value is not intercepted by the generator. Thanks to @jepler for finding the bug.
2017-01-17tests: Update tests, and add new ones, for recent generator tweaks.Damien George