summaryrefslogtreecommitdiff
path: root/object.c
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2002-10-02 06:02:17 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2002-10-02 06:02:17 +0000
commitab6b4786152b663215f05841f7d131d1a7f43db7 (patch)
tree5e0a40d402ee6e82cefc7a5e564f306569b645a0 /object.c
parent8c0cbb735000465ca0e07526efb4489e4fe5e414 (diff)
* commit miss; and tcltklib fix too.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2920 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'object.c')
-rw-r--r--object.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/object.c b/object.c
index 71f5e99..455d353 100644
--- a/object.c
+++ b/object.c
@@ -84,6 +84,14 @@ rb_class_real(cl)
}
VALUE
+rb_obj_type(obj)
+ VALUE obj;
+{
+ rb_warn("`type' is deprecated; use `class'");
+ return rb_class_real(CLASS_OF(obj));
+}
+
+VALUE
rb_obj_class(obj)
VALUE obj;
{
@@ -1292,7 +1300,7 @@ Init_Object()
rb_define_method(rb_mKernel, "hash", rb_obj_id, 0);
rb_define_method(rb_mKernel, "id", rb_obj_id, 0);
rb_define_method(rb_mKernel, "__id__", rb_obj_id, 0);
- rb_define_method(rb_mKernel, "type", rb_obj_class, 0);
+ rb_define_method(rb_mKernel, "type", rb_obj_type, 0);
rb_define_method(rb_mKernel, "class", rb_obj_class, 0);
rb_define_method(rb_mKernel, "clone", rb_obj_clone, 0);