diff options
author | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-08-29 23:12:21 +0000 |
---|---|---|
committer | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-08-29 23:12:21 +0000 |
commit | 6601b076e29e6ea41f72068dee03298e2a860caa (patch) | |
tree | a25d27ffdd53b0b5912e6746131b97a245a3732d /ext/syck | |
parent | be2c0fb02832b2bf907ef4405851eec29b521648 (diff) | |
download | ruby-6601b076e29e6ea41f72068dee03298e2a860caa.tar.gz ruby-6601b076e29e6ea41f72068dee03298e2a860caa.tar.xz ruby-6601b076e29e6ea41f72068dee03298e2a860caa.zip |
* include/ruby/intern.h: declare rb_hash_tbl.
* include/ruby/ruby.h (RHash): delay st_table allocation.
rename tbl field to ntbl to detect direct reference to the st_table
as a compile error.
(RHASH_TBL): abstract accessor defined.
(RHASH_ITER_LEV): ditto.
(RHASH_IFNONE): ditto.
(RHASH_SIZE): ditto.
(RHASH_EMPTY_P): ditto.
* hash.c: delay st_table allocation.
* gc.c: replace tbl by ntbl.
* array.c: replace direct field accessor by abstract field accessor
such as RHASH(hash)->tbl to RHASH_TBL(hash).
* marshal.c: ditto.
* insns.def: ditto.
* ext/iconv/iconv.c: ditto.
* ext/json/ext/generator/generator.c: ditto.
* ext/json/ext/parser/parser.c: ditto.
* ext/syck/rubyext.c: ditto.
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@13309 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/syck')
-rw-r--r-- | ext/syck/rubyext.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/syck/rubyext.c b/ext/syck/rubyext.c index 9a41c18e8..53625c91d 100644 --- a/ext/syck/rubyext.c +++ b/ext/syck/rubyext.c @@ -621,7 +621,7 @@ rb_syck_load_handler(SyckParser *p, SyckNode *n) if ( bonus->taint) OBJ_TAINT( obj ); if ( bonus->proc != 0 ) rb_funcall(bonus->proc, s_call, 1, obj); - rb_hash_aset(bonus->data, INT2FIX(RHASH(bonus->data)->tbl->num_entries), obj); + rb_hash_aset(bonus->data, INT2FIX(RHASH_SIZE(bonus->data)), obj); return obj; } |