summaryrefslogtreecommitdiff
path: root/vm.c
diff options
context:
space:
mode:
authorko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2012-12-25 09:57:07 +0000
committerko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2012-12-25 09:57:07 +0000
commit270fbd9c058fc2a36dc7c44243f4a20c91143481 (patch)
tree2b4e01d852c06c74929382349356d0f902eae70d /vm.c
parentfebab308c87f721d9b7491d37e345d0130a4bca2 (diff)
* vm_core.h, eval_intern.h (CHECK_STACK_OVERFLOW): move
CHECK_STACK_OVERFLOW() to vm_core.h and rename to CHECK_VM_STACK_OVERFLOW(). This change is only move and rename. * tool/instruction.rb: catch up above changes. * vm.c, vm_insnhelper.c: ditto. * vm_insnhelper.c (vm_stackoverflow): add a function to unify raising vm stackoverflow exception. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38594 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'vm.c')
-rw-r--r--vm.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/vm.c b/vm.c
index 55c8508..9ed5d08 100644
--- a/vm.c
+++ b/vm.c
@@ -143,7 +143,7 @@ vm_set_top_stack(rb_thread_t * th, VALUE iseqval)
}
/* for return */
- CHECK_STACK_OVERFLOW(th->cfp, iseq->local_size + iseq->stack_max);
+ CHECK_VM_STACK_OVERFLOW(th->cfp, iseq->local_size + iseq->stack_max);
vm_push_frame(th, iseq, VM_FRAME_MAGIC_TOP | VM_FRAME_FLAG_FINISH,
th->top_self, rb_cObject, VM_ENVVAL_BLOCK_PTR(0),
iseq->iseq_encoded, th->cfp->sp, iseq->local_size, 0);
@@ -155,7 +155,7 @@ vm_set_eval_stack(rb_thread_t * th, VALUE iseqval, const NODE *cref, rb_block_t
rb_iseq_t *iseq;
GetISeqPtr(iseqval, iseq);
- CHECK_STACK_OVERFLOW(th->cfp, iseq->local_size + iseq->stack_max);
+ CHECK_VM_STACK_OVERFLOW(th->cfp, iseq->local_size + iseq->stack_max);
vm_push_frame(th, iseq, VM_FRAME_MAGIC_EVAL | VM_FRAME_FLAG_FINISH,
base_block->self, base_block->klass,
VM_ENVVAL_PREV_EP_PTR(base_block->ep), iseq->iseq_encoded,
@@ -612,7 +612,7 @@ invoke_block_from_c(rb_thread_t *th, const rb_block_t *block,
VM_FRAME_MAGIC_LAMBDA : VM_FRAME_MAGIC_BLOCK;
cfp = th->cfp;
- CHECK_STACK_OVERFLOW(cfp, argc + iseq->stack_max);
+ CHECK_VM_STACK_OVERFLOW(cfp, argc + iseq->stack_max);
for (i=0; i<argc; i++) {
cfp->sp[i] = argv[i];