@JesusCastello/CalmTidyDecompiler
Ruby

No description

Files
  • main.rb
main.rb
a = []
b = {}

GC.start

puts GC.stat(b)[:heap_live_slots]

puts "==== Before loop ===="

5.times {
  sleep(1)

  10_000.times { a << "abc" }

  puts GC.stat(b)[:heap_live_slots]
}

puts "==== After clearing array ===="

a = []
b = {}

GC.start

puts GC.stat(b)[:heap_live_slots]
ruby 2.5.0p0 (2017-12-25 revision 61468) [x86_64-linux]