summaryrefslogtreecommitdiff
path: root/vm_insnhelper.c
diff options
context:
space:
mode:
Diffstat (limited to 'vm_insnhelper.c')
-rw-r--r--vm_insnhelper.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/vm_insnhelper.c b/vm_insnhelper.c
index 3666aed53e..00a21e3669 100644
--- a/vm_insnhelper.c
+++ b/vm_insnhelper.c
@@ -1177,6 +1177,7 @@ vm_get_ev_const(rb_thread_t *th, const rb_iseq_t *iseq,
if (val == Qundef) {
if (am == klass) break;
am = klass;
+ if (is_defined) return 1;
rb_autoload_load(klass, id);
goto search_continue;
}