mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
vm.c: simplify
* vm.c (env_mark): remove redundant conditions and mark block.iseq simply unless null. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52130 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
c2e8fb0f34
commit
7c4b03e775
1 changed files with 1 additions and 9 deletions
10
vm.c
10
vm.c
|
@ -414,15 +414,7 @@ env_mark(void * const ptr)
|
|||
RUBY_MARK_UNLESS_NULL(rb_vm_env_prev_envval(env));
|
||||
RUBY_MARK_UNLESS_NULL(env->block.self);
|
||||
RUBY_MARK_UNLESS_NULL(env->block.proc);
|
||||
|
||||
if (env->block.iseq) {
|
||||
if (RUBY_VM_IFUNC_P(env->block.iseq)) {
|
||||
rb_gc_mark((VALUE)env->block.iseq);
|
||||
}
|
||||
else {
|
||||
RUBY_MARK_UNLESS_NULL((VALUE)env->block.iseq);
|
||||
}
|
||||
}
|
||||
RUBY_MARK_UNLESS_NULL((VALUE)env->block.iseq);
|
||||
RUBY_MARK_LEAVE("env");
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue