summaryrefslogtreecommitdiff
path: root/time.c
diff options
context:
space:
mode:
authorkosaki <kosaki@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2011-07-15 16:06:53 +0000
committerkosaki <kosaki@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2011-07-15 16:06:53 +0000
commit6270ce85ed36d2844166facb937c2a9f63fb022f (patch)
tree5469169d82e80ccca1698acbeca2b95910e8f519 /time.c
parent4b29cccf57c44f112c4ee06f30962060a16ae0aa (diff)
* time.c (time_dup): used rb_obj_class() instead of CLASS_OF().
The patch is made by Kazuki Tsujimoto. [Bug #5012] [ruby-dev:44071] * test/ruby/test_time.rb (TestTime#test_getlocal_dont_share_eigenclass): added a new test for eigenclass of time object. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32554 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'time.c')
-rw-r--r--time.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/time.c b/time.c
index 95bdb1f..b2e3448 100644
--- a/time.c
+++ b/time.c
@@ -3430,7 +3430,7 @@ time_init_copy(VALUE copy, VALUE time)
static VALUE
time_dup(VALUE time)
{
- VALUE dup = time_s_alloc(CLASS_OF(time));
+ VALUE dup = time_s_alloc(rb_obj_class(time));
time_init_copy(dup, time);
return dup;
}