From 8bcf7fc40266faa09cf8b6cebb2d96c1bb8d51ee Mon Sep 17 00:00:00 2001 From: ko1 Date: Tue, 22 May 2012 08:31:38 +0000 Subject: * vm_core.h: add a data type rb_location_t to store iseq location information. rb_location_t#filename, filepath, name and line_no was moved from rb_iseq_t. rb_location_t#basename is a new field which is similar to `name' field without any decoration. `name' field contains some decoration such as `block in foo'. `basename' only contains `foo'. rb_iseq_t contains memory object of rb_location_t. * iseq.c: setup rb_location_t for each rb_iseq_t memory objects. * compile.c, proc.c, vm.c, vm_dump.c, vm_eval.c, vm_insnhelper.c, vm_method.c: support about it. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35756 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- vm_eval.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'vm_eval.c') diff --git a/vm_eval.c b/vm_eval.c index 6c26b97f92..8d6c91a158 100644 --- a/vm_eval.c +++ b/vm_eval.c @@ -1776,7 +1776,7 @@ rb_current_realfilepath(void) rb_thread_t *th = GET_THREAD(); rb_control_frame_t *cfp = th->cfp; cfp = vm_get_ruby_level_caller_cfp(th, RUBY_VM_PREVIOUS_CONTROL_FRAME(cfp)); - if (cfp != 0) return cfp->iseq->filepath; + if (cfp != 0) return cfp->iseq->location.filepath; return Qnil; } -- cgit v1.2.3