[前][次][番号順一覧][スレッド一覧]

ruby-changes:40049

From: nobu <ko1@a...>
Date: Thu, 15 Oct 2015 13:45:16 +0900 (JST)
Subject: [ruby-changes:40049] nobu:r52130 (trunk): vm.c: simplify

nobu	2015-10-15 13:44:58 +0900 (Thu, 15 Oct 2015)

  New Revision: 52130

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=52130

  Log:
    vm.c: simplify
    
    * vm.c (env_mark): remove redundant conditions and mark block.iseq
      simply unless null.

  Modified files:
    trunk/vm.c
Index: vm.c
===================================================================
--- vm.c	(revision 52129)
+++ vm.c	(revision 52130)
@@ -414,15 +414,7 @@ env_mark(void * const ptr) https://github.com/ruby/ruby/blob/trunk/vm.c#L414
     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");
 }
 

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]