mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
test_jit.rb: test newhashfromarray
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@65355 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
f84c318420
commit
593b58534f
1 changed files with 4 additions and 0 deletions
|
@ -239,6 +239,10 @@ class TestJIT < Test::Unit::TestCase
|
|||
assert_compile_once('a = 1; { a: a }', result_inspect: '{:a=>1}', insns: %i[newhash])
|
||||
end
|
||||
|
||||
def test_compile_insn_newhashfromarray
|
||||
assert_compile_once('{ a: 1 }', result_inspect: '{:a=>1}', insns: %i[newhashfromarray])
|
||||
end
|
||||
|
||||
def test_compile_insn_newrange
|
||||
assert_compile_once('a = 1; 0..a', result_inspect: '0..1', insns: %i[newrange])
|
||||
end
|
||||
|
|
Loading…
Add table
Reference in a new issue