summaryrefslogtreecommitdiff
path: root/vm_eval.c
diff options
context:
space:
mode:
Diffstat (limited to 'vm_eval.c')
-rw-r--r--vm_eval.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/vm_eval.c b/vm_eval.c
index 24bac12bbf..6c248e4eb8 100644
--- a/vm_eval.c
+++ b/vm_eval.c
@@ -1239,6 +1239,11 @@ eval_string_with_cref(VALUE self, VALUE src, VALUE scope, NODE *const cref_arg,
fname = rb_usascii_str_new_cstr("(eval)");
}
+ if (RTEST(fname))
+ fname = rb_fstring(fname);
+ if (RTEST(absolute_path))
+ absolute_path = rb_fstring(absolute_path);
+
/* make eval iseq */
th->parse_in_eval++;
th->mild_compile_error++;