diff --git a/benchmark/bm_hash_to_proc.rb b/benchmark/bm_hash_to_proc.rb new file mode 100644 index 0000000000..2b675bf509 --- /dev/null +++ b/benchmark/bm_hash_to_proc.rb @@ -0,0 +1,9 @@ +h = {} + +10000.times do |i| + h[i] = nil +end + +5000.times do |i| + [i].map(&h) +end