eval.c: use rb_ident_hash_new
* eval.c (hidden_identity_hash_new): use rb_ident_hash_new instead of funcall Hash#compare_by_id. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51514 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
f23a72a656
commit
1d2d307c5c
3
eval.c
3
eval.c
@ -1088,9 +1088,8 @@ rb_mod_prepend(int argc, VALUE *argv, VALUE module)
|
||||
static VALUE
|
||||
hidden_identity_hash_new(void)
|
||||
{
|
||||
VALUE hash = rb_hash_new();
|
||||
VALUE hash = rb_ident_hash_new();
|
||||
|
||||
rb_funcall(hash, rb_intern("compare_by_identity"), 0);
|
||||
RBASIC_CLEAR_CLASS(hash); /* hide from ObjectSpace */
|
||||
return hash;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user