aboutsummaryrefslogtreecommitdiffstats
path: root/test/yaml
diff options
context:
space:
mode:
authorakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-04-21 14:56:59 +0000
committerakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-04-21 14:56:59 +0000
commit3bc16f62c1fb6225b3f6cb96b62f78e44636aae4 (patch)
tree7861dbce5046671694894b080ca6d0e0d15c6175 /test/yaml
parent143846ad369eba2324e13743ff03bcf50d56c942 (diff)
downloadruby-3bc16f62c1fb6225b3f6cb96b62f78e44636aae4.tar.gz
* time.c: remove time_t restriction from Time class.
* timev.h: new file to define struct vtm. * strftime.c: format struct vtm instead of struct tm. * ext/syck/rubyext.c (mktime_do): don't use time_t; [ruby-dev:38191] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@23242 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/yaml')
-rw-r--r--test/yaml/test_yaml.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/yaml/test_yaml.rb b/test/yaml/test_yaml.rb
index 4f612ebaef..8c7aef3dcd 100644
--- a/test/yaml/test_yaml.rb
+++ b/test/yaml/test_yaml.rb
@@ -48,7 +48,7 @@ class YAML_Unit_Tests < Test::Unit::TestCase
# Make a time with the time zone
#
def mktime( year, mon, day, hour, min, sec, usec, zone = "Z" )
- usec = usec.to_s.to_f * 1000000
+ usec = Rational(usec.to_s) * 1000000
val = Time::utc( year.to_i, mon.to_i, day.to_i, hour.to_i, min.to_i, sec.to_i, usec )
if zone != "Z"
hour = zone[0,3].to_i * 3600