diff options
| author | yugui <yugui@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2009-02-22 09:48:50 +0000 |
|---|---|---|
| committer | yugui <yugui@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2009-02-22 09:48:50 +0000 |
| commit | 0db129f6a638e32f7885aa53253d20aff465e7a3 (patch) | |
| tree | 4f3c857feb4d8a7010207c0f15f7ffcd8e45a4df /include | |
| parent | a8f300aa9bea2809e2d6af45a7900f5154f9986f (diff) | |
merges r22132 from trunk into ruby_1_9_1.
* include/ruby/st.h, st.c: order entries by a linked list instead of
a loop to fix iteration miss when hash is modified during iteration.
[ruby-dev:37910]
git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_9_1@22522 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'include')
| -rw-r--r-- | include/ruby/st.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/ruby/st.h b/include/ruby/st.h index 09a7c5822..73216ba45 100644 --- a/include/ruby/st.h +++ b/include/ruby/st.h @@ -75,7 +75,7 @@ struct st_table { #endif st_index_t num_entries : ST_INDEX_BITS - 1; struct st_table_entry **bins; - struct st_table_entry *head; + struct st_table_entry *head, *tail; }; #define st_is_member(table,key) st_lookup(table,key,(st_data_t *)0) |
