summaryrefslogtreecommitdiff
path: root/benchmark/hash_ident_sym.yml
blob: e49bdba7f420eced02e6b4b56bafe89f58b1c353 (plain)
1
2
3
4
5
6
7
benchmark:
  hash_ident_sym: |
    h = {}.compare_by_identity
    syms = ('a'..'z').to_a.map(&:to_sym)
    syms.each { |s| h[s] = s }
    200_000.times { syms.each { |s| h[s] } }
loop_count: 1