summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSatoshi Tagomori <s-tagomori@sakura.ad.jp>2025-06-24 23:11:01 +0900
committerSatoshi Tagomori <tagomoris@gmail.com>2025-09-29 01:15:38 +0900
commitc755f35f0ef755274ba409e3c6e21b759f248b29 (patch)
treec2c545f509254356922f083feecace249efaaaff
parent2100826243ae23e159ccdf9c9805a84074261808 (diff)
Stop using ns->top_self here because it's set to th->top_self beforehand if needed
-rw-r--r--vm.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/vm.c b/vm.c
index 83119c32d2..76f356342b 100644
--- a/vm.c
+++ b/vm.c
@@ -794,7 +794,7 @@ vm_set_top_stack(rb_execution_context_t *ec, const rb_iseq_t *iseq, const rb_nam
/* for return */
vm_push_frame(ec, iseq, VM_FRAME_MAGIC_TOP | VM_ENV_FLAG_LOCAL | VM_FRAME_FLAG_FINISH,
- ns ? ns->top_self : rb_ec_thread_ptr(ec)->top_self,
+ rb_ec_thread_ptr(ec)->top_self,
GC_GUARDED_PTR(ns),
(VALUE)vm_cref_new_toplevel(ec), /* cref or me */
ISEQ_BODY(iseq)->iseq_encoded, ec->cfp->sp,