summaryrefslogtreecommitdiffhomepage
path: root/src
diff options
context:
space:
mode:
authorYukihiro "Matz" Matsumoto <[email protected]>2013-04-09 10:52:15 +0900
committerYukihiro "Matz" Matsumoto <[email protected]>2013-04-09 10:52:15 +0900
commit03367c19edaa906a27ee27ba0362ff6e09a0965c (patch)
treea73afe4fc650d93d268f1b105d5cce34cebeacd6 /src
parent9fbd66cb9a45177a4f985fe27b3790d7fc29af0e (diff)
downloadmruby-03367c19edaa906a27ee27ba0362ff6e09a0965c.tar.gz
mruby-03367c19edaa906a27ee27ba0362ff6e09a0965c.zip
target_class should not be TT_ICLASS; close #1152
Diffstat (limited to 'src')
-rw-r--r--src/vm.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/vm.c b/src/vm.c
index 7eae322f7..468396a51 100644
--- a/src/vm.c
+++ b/src/vm.c
@@ -873,7 +873,13 @@ mrb_run(mrb_state *mrb, struct RProc *proc, mrb_value self)
else {
ci->argc = n;
}
- ci->target_class = c;
+ if (c->tt == MRB_TT_ICLASS) {
+ ci->target_class = c->c;
+ }
+ else {
+ ci->target_class = c;
+ }
+
ci->pc = pc + 1;
ci->acc = a;