diff options
author | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2003-05-19 05:41:08 +0000 |
---|---|---|
committer | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2003-05-19 05:41:08 +0000 |
commit | 7c202937fa47f2b65a060f66e83042e151d97aeb (patch) | |
tree | 317cda44160a93678e8b530700ce4a2e17e682ed /numeric.c | |
parent | b1b809d7211b9b34c4e824f63202419b36096f9f (diff) | |
download | ruby-7c202937fa47f2b65a060f66e83042e151d97aeb.tar.gz ruby-7c202937fa47f2b65a060f66e83042e151d97aeb.tar.xz ruby-7c202937fa47f2b65a060f66e83042e151d97aeb.zip |
* object.c (init_copy): rename copy_object as initialize_copy,
since it works as copy constructor.
* eval.c (rb_add_method): initialize_copy should always be
private, like initialize.
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@3820 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'numeric.c')
-rw-r--r-- | numeric.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -158,7 +158,7 @@ num_coerce_relop(x, y) } static VALUE -num_copy_object(x, y) +num_init_copy(x, y) VALUE x, y; { /* Numerics are immutable values, which should not be copied */ @@ -1767,7 +1767,7 @@ Init_Numeric() rb_cNumeric = rb_define_class("Numeric", rb_cObject); rb_include_module(rb_cNumeric, rb_mComparable); - rb_define_method(rb_cNumeric, "copy_object", num_copy_object, 1); + rb_define_method(rb_cNumeric, "initialize_copy", num_init_copy, 1); rb_define_method(rb_cNumeric, "coerce", num_coerce, 1); rb_define_method(rb_cNumeric, "+@", num_uplus, 0); |