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

ruby-changes:63487

From: wanabe <ko1@a...>
Date: Sat, 31 Oct 2020 09:18:58 +0900 (JST)
Subject: [ruby-changes:63487] 3685ed7303 (master): Use adjusted sp on `iseq_set_sequence()`

https://git.ruby-lang.org/ruby.git/commit/?id=3685ed7303

From 3685ed7303fc08bf68cd3cc8d11e22a8ce63a067 Mon Sep 17 00:00:00 2001
From: wanabe <s.wanabe@g...>
Date: Fri, 7 Aug 2020 07:59:50 +0900
Subject: Use adjusted sp on `iseq_set_sequence()`


diff --git a/compile.c b/compile.c
index 88f1c42..58cd2cd 100644
--- a/compile.c
+++ b/compile.c
@@ -2270,16 +2270,14 @@ iseq_set_sequence(rb_iseq_t *iseq, LINK_ANCHOR *const anchor) https://github.com/ruby/ruby/blob/trunk/compile.c#L2270
 	    }
 	  case ISEQ_ELEMENT_ADJUST:
 	    {
-		ADJUST *adjust = (ADJUST *)list;
-		if (adjust->line_no != -1) {
-		    int orig_sp = sp;
-		    sp = adjust->label ? adjust->label->sp : 0;
-		    if (orig_sp - sp > 0) {
-			if (orig_sp - sp > 1) code_index++; /* 1 operand */
-			code_index++; /* insn */
-			insn_num++;
-		    }
-		}
+                ADJUST *adjust = (ADJUST *)list;
+                int orig_sp = sp;
+                sp = adjust->label ? adjust->label->sp : 0;
+                if (adjust->line_no != -1 && orig_sp - sp > 0) {
+                    if (orig_sp - sp > 1) code_index++; /* 1 operand */
+                    code_index++; /* insn */
+                    insn_num++;
+                }
 		break;
 	    }
 	  default: break;
-- 
cgit v0.10.2


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

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