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

ruby-changes:39201

From: nobu <ko1@a...>
Date: Fri, 17 Jul 2015 22:15:53 +0900 (JST)
Subject: [ruby-changes:39201] nobu:r51282 (trunk): compile.c: remove unused big

nobu	2015-07-17 22:15:29 +0900 (Fri, 17 Jul 2015)

  New Revision: 51282

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

  Log:
    compile.c: remove unused big
    
    * compile.c (iseq_compile_each): remove unused big flag, `while`
      loop always leaves a result on the stack.

  Modified files:
    trunk/compile.c
Index: compile.c
===================================================================
--- compile.c	(revision 51281)
+++ compile.c	(revision 51282)
@@ -3726,10 +3726,6 @@ iseq_compile_each(rb_iseq_t *iseq, LINK_ https://github.com/ruby/ruby/blob/trunk/compile.c#L3726
 		level++;
 		if (ip->compile_data->redo_label != 0) {
 		    level = 0x8000;
-		    if (ip->compile_data->loopval_popped == 0) {
-			/* need value */
-			level |= 0x4000;
-		    }
 		    goto break_by_insn;
 		}
 		else if (ip->type == ISEQ_TYPE_BLOCK) {
@@ -3789,7 +3785,7 @@ iseq_compile_each(rb_iseq_t *iseq, LINK_ https://github.com/ruby/ruby/blob/trunk/compile.c#L3785
 		    break;
 		}
 
-		level = 0x8000 | 0x4000;
+		level = 0x8000;
 		if (ip->compile_data->redo_label != 0) {
 		    /* while loop */
 		    break;
@@ -3850,8 +3846,7 @@ iseq_compile_each(rb_iseq_t *iseq, LINK_ https://github.com/ruby/ruby/blob/trunk/compile.c#L3846
 	}
 	else {
 	    const rb_iseq_t *ip = iseq;
-	    unsigned long level;
-	    level = 0x8000 | 0x4000;
+	    unsigned long level = 0x8000;
 
 	    while (ip) {
 		if (!ip->compile_data) {

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

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