Skip to content

Commit

Permalink
Revert "env referred from top-level callinfo should not be unshared;
Browse files Browse the repository at this point in the history
…fix #4019"

This reverts commit 7258169.

The #4012 that may have been the trigger for issue #4019 was later reverted by #4039 due to issue #4021.
  • Loading branch information
dearblue committed Apr 5, 2024
1 parent 47642f7 commit 21f714e
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion src/vm.c
Original file line number Diff line number Diff line change
Expand Up @@ -375,7 +375,6 @@ mrb_env_unshare(mrb_state *mrb, struct REnv *e, mrb_bool noraise)
if (e == NULL) return TRUE;
if (!MRB_ENV_ONSTACK_P(e)) return TRUE;
if (e->cxt != mrb->c) return TRUE;
if (e == CI_ENV(mrb->c->cibase)) return TRUE; /* for mirb */

e->cxt = NULL; /* make possible to GC the fiber that generated the env */

Expand Down

0 comments on commit 21f714e

Please sign in to comment.