diff options
author | glass <glass@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2013-12-01 05:39:38 +0000 |
---|---|---|
committer | glass <glass@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2013-12-01 05:39:38 +0000 |
commit | 8efbe962317bfa81dd850695a32f01613e23c79a (patch) | |
tree | a6d5f32d78fb6cf9e6346c22b881d0723a6a2c8f /hash.c | |
parent | bfbe1b9b31aaf678c4cfe2be09e78acb42629c7f (diff) | |
download | ruby-8efbe962317bfa81dd850695a32f01613e23c79a.tar.gz |
* hash.c (rb_hash_to_a): specify array capa.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@43943 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'hash.c')
-rw-r--r-- | hash.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -1606,7 +1606,7 @@ rb_hash_to_a(VALUE hash) { VALUE ary; - ary = rb_ary_new(); + ary = rb_ary_new_capa(RHASH_SIZE(hash)); rb_hash_foreach(hash, to_a_i, ary); OBJ_INFECT(ary, hash); |