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

ruby-changes:58652

From: Yusuke <ko1@a...>
Date: Fri, 8 Nov 2019 23:30:32 +0900 (JST)
Subject: [ruby-changes:58652] 882179a0ec (master): tool/mk_builtin_loader.rb: check if op is an array or not

https://git.ruby-lang.org/ruby.git/commit/?id=882179a0ec

From 882179a0ecc0dfb1f212334f3c92f90ffc817167 Mon Sep 17 00:00:00 2001
From: Yusuke Endoh <mame@r...>
Date: Fri, 8 Nov 2019 12:58:17 +0900
Subject: tool/mk_builtin_loader.rb: check if op is an array or not

The insn array includes not only an array but also some literal objects.

diff --git a/tool/mk_builtin_loader.rb b/tool/mk_builtin_loader.rb
index cea4d1f..87b5e2a 100644
--- a/tool/mk_builtin_loader.rb
+++ b/tool/mk_builtin_loader.rb
@@ -18,7 +18,7 @@ def collect_builtin iseq_ary, bs https://github.com/ruby/ruby/blob/trunk/tool/mk_builtin_loader.rb#L18
       end
     else
       insn[1..-1].each{|op|
-        if op[0] == "YARVInstructionSequence/SimpleDataFormat"
+        if op.is_a?(Array) && op[0] == "YARVInstructionSequence/SimpleDataFormat"
           collect_builtin op, bs
         end
       }
-- 
cgit v0.10.2


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

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