* eval.c (rb_yield_0): should enable trace for non-cfunc nodes.
[ruby-dev:18645] * eval.c (blk_orphan): a block created in a different thread is orphan. [ruby-dev:17471] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3029 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
3a86596df1
commit
2b82367a47
@ -1,3 +1,11 @@
|
|||||||
|
Thu Nov 7 09:51:37 2002 Nobuyoshi Nakada <nobu.nokada@softhome.net>
|
||||||
|
|
||||||
|
* eval.c (rb_yield_0): should enable trace for non-cfunc nodes.
|
||||||
|
[ruby-dev:18645]
|
||||||
|
|
||||||
|
* eval.c (blk_orphan): a block created in a different thread is
|
||||||
|
orphan. [ruby-dev:17471]
|
||||||
|
|
||||||
Tue Nov 5 00:46:04 2002 Akinori MUSHA <knu@iDaemons.org>
|
Tue Nov 5 00:46:04 2002 Akinori MUSHA <knu@iDaemons.org>
|
||||||
|
|
||||||
* ext/extmk.rb: Properly pass the given target to
|
* ext/extmk.rb: Properly pass the given target to
|
||||||
|
9
eval.c
9
eval.c
@ -3794,6 +3794,7 @@ rb_yield_0(val, self, klass, pcall)
|
|||||||
int pcall;
|
int pcall;
|
||||||
{
|
{
|
||||||
NODE *node;
|
NODE *node;
|
||||||
|
volatile int old_tracing = tracing;
|
||||||
volatile VALUE result = Qnil;
|
volatile VALUE result = Qnil;
|
||||||
volatile VALUE old_cref;
|
volatile VALUE old_cref;
|
||||||
volatile VALUE old_wrapper;
|
volatile VALUE old_wrapper;
|
||||||
@ -3876,6 +3877,7 @@ rb_yield_0(val, self, klass, pcall)
|
|||||||
result = (*node->nd_cfnc)(val, node->nd_tval, self);
|
result = (*node->nd_cfnc)(val, node->nd_tval, self);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
ENABLE_TRACE();
|
||||||
result = rb_eval(self, node);
|
result = rb_eval(self, node);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -3901,6 +3903,7 @@ rb_yield_0(val, self, klass, pcall)
|
|||||||
}
|
}
|
||||||
POP_TAG();
|
POP_TAG();
|
||||||
POP_ITER();
|
POP_ITER();
|
||||||
|
tracing = old_tracing;
|
||||||
pop_state:
|
pop_state:
|
||||||
POP_CLASS();
|
POP_CLASS();
|
||||||
if (ruby_dyna_vars && (block->flags & BLOCK_D_SCOPE) &&
|
if (ruby_dyna_vars && (block->flags & BLOCK_D_SCOPE) &&
|
||||||
@ -6544,10 +6547,8 @@ static int
|
|||||||
blk_orphan(data)
|
blk_orphan(data)
|
||||||
struct BLOCK *data;
|
struct BLOCK *data;
|
||||||
{
|
{
|
||||||
if (!(data->scope->flags & SCOPE_NOSTACK)) {
|
if ((data->tag->flags & BLOCK_ORPHAN) &&
|
||||||
return 0;
|
(data->scope->flags & SCOPE_NOSTACK)) {
|
||||||
}
|
|
||||||
if ((data->tag->flags & BLOCK_ORPHAN)) {
|
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
if (data->orig_thread != rb_thread_current()) {
|
if (data->orig_thread != rb_thread_current()) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user