File tree Expand file tree Collapse file tree 1 file changed +7
-4
lines changed
Expand file tree Collapse file tree 1 file changed +7
-4
lines changed Original file line number Diff line number Diff line change @@ -4554,10 +4554,13 @@ mod hir_opt_tests {
45544554
45554555 #[ test]
45564556 fn test_optimize_getivar_extended ( ) {
4557- eval ( "
4557+ eval ( r# "
45584558 class C
45594559 attr_reader :foo
45604560 def initialize
4561+ 1000.times do |i|
4562+ instance_variable_set("@v#{i}", i)
4563+ end
45614564 @foo = 42
45624565 end
45634566 end
@@ -4566,9 +4569,9 @@ mod hir_opt_tests {
45664569 def test(o) = o.foo
45674570 test O
45684571 test O
4569- " ) ;
4572+ "# ) ;
45704573 assert_snapshot ! ( hir_string( "test" ) , @r"
4571- fn test@<compiled>:10 :
4574+ fn test@<compiled>:13 :
45724575 bb0():
45734576 EntryPoint interpreter
45744577 v1:BasicObject = LoadSelf
@@ -4582,7 +4585,7 @@ mod hir_opt_tests {
45824585 PatchPoint NoSingletonClass(C@0x1000)
45834586 v22:HeapObject[class_exact:C] = GuardType v9, HeapObject[class_exact:C]
45844587 v25:HeapObject[class_exact:C] = GuardShape v22, 0x1038
4585- v26:BasicObject = LoadIvarEmbedded v25, :@foo@0x1039
4588+ v26:BasicObject = LoadIvarExtended v25, :@foo@0x1039
45864589 CheckInterrupts
45874590 Return v26
45884591 " ) ;
You can’t perform that action at this time.
0 commit comments