summaryrefslogtreecommitdiff
path: root/hash.c
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2002-12-10 06:23:44 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2002-12-10 06:23:44 +0000
commit60b2446bea0297c47f56deb308c29a5c1af64cc9 (patch)
tree2bcb6184518b5e93ec49a03b275258a817511abd /hash.c
parent4dcd8a95c7acf13a87283c11f72f7a8a7ad15019 (diff)
downloadruby-60b2446bea0297c47f56deb308c29a5c1af64cc9.tar.gz
* sprintf.c (rb_f_sprintf): preceding ".." for negative numbers
still left; removed. * sprintf.c (rb_f_sprintf): should not prepend '0' if width > prec for example "%5.3d". * process.c (Init_process): add Process.exit and Process.abort * pack.c (utf8_to_uv): raise ArgumentError for malformed/redundant UTF-8 sequences. * process.c (last_status_set): add pid attribute to Process::Status. * pack.c (uv_to_utf8): limit maximum length of the encoded string to 6 bytes, even when the platform supports 8 bytes long integers. * pack.c (utf8_to_uv): do not decode sequences longer than 6 bytes. * object.c (copy_object): use "copy_object" method, not "become". git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3123 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'hash.c')
-rw-r--r--hash.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/hash.c b/hash.c
index 8a9f8f2fe7..89d7b16019 100644
--- a/hash.c
+++ b/hash.c
@@ -576,7 +576,7 @@ replace_i(key, val, hash)
}
static VALUE
-rb_hash_become(hash, hash2)
+rb_hash_replace(hash, hash2)
VALUE hash, hash2;
{
hash2 = to_hash(hash2);
@@ -1599,7 +1599,7 @@ Init_Hash()
rb_define_singleton_method(rb_cHash, "[]", rb_hash_s_create, -1);
rb_define_method(rb_cHash,"initialize", rb_hash_initialize, -1);
- rb_define_method(rb_cHash,"become", rb_hash_become, 1);
+ rb_define_method(rb_cHash,"copy_object", rb_hash_replace, 1);
rb_define_method(rb_cHash,"rehash", rb_hash_rehash, 0);
rb_define_method(rb_cHash,"to_hash", rb_hash_to_hash, 0);
@@ -1640,7 +1640,7 @@ Init_Hash()
rb_define_method(rb_cHash,"clear", rb_hash_clear, 0);
rb_define_method(rb_cHash,"invert", rb_hash_invert, 0);
rb_define_method(rb_cHash,"update", rb_hash_update, 1);
- rb_define_method(rb_cHash,"replace", rb_hash_become, 1);
+ rb_define_method(rb_cHash,"replace", rb_hash_replace, 1);
rb_define_method(rb_cHash,"include?", rb_hash_has_key, 1);
rb_define_method(rb_cHash,"member?", rb_hash_has_key, 1);