diff options
author | Jeremy Evans <code@jeremyevans.net> | 2022-03-22 16:36:16 -0700 |
---|---|---|
committer | Jeremy Evans <code@jeremyevans.net> | 2022-04-21 20:48:27 -0700 |
commit | 4b14b2902abaa0e8f0d1e8282d2322f47431fa3f (patch) | |
tree | 086716257ae8dc7b4f0e5b928348648be3c9a57e /vm.c | |
parent | 3fa768c5c308b61677342fe2caa9c54fe3a2c3c9 (diff) | |
download | ruby-4b14b2902abaa0e8f0d1e8282d2322f47431fa3f.tar.gz |
Uncomment code to raise LocalJumpError for yield across thread through enum
Not sure if this is the correct fix. It does raise LocalJumpError in
the yielding thread as you would expect, but the value yielded to the calling
thread is still yielded without an exception.
Fixes [Bug #18649]
Diffstat (limited to 'vm.c')
-rw-r--r-- | vm.c | 2 |
1 files changed, 0 insertions, 2 deletions
@@ -1806,11 +1806,9 @@ vm_iter_break(rb_execution_context_t *ec, VALUE val) const VALUE *ep = VM_CF_PREV_EP(cfp); const rb_control_frame_t *target_cfp = rb_vm_search_cf_from_ep(ec, cfp, ep); -#if 0 /* raise LocalJumpError */ if (!target_cfp) { rb_vm_localjump_error("unexpected break", val, TAG_BREAK); } -#endif ec->errinfo = (VALUE)THROW_DATA_NEW(val, target_cfp, TAG_BREAK); EC_JUMP_TAG(ec, TAG_BREAK); |