From 00456175be88098b4612d66a828ab130e15ef97b Mon Sep 17 00:00:00 2001 From: tadf Date: Sun, 6 Feb 2005 05:16:02 +0000 Subject: synchronized with date2 3.6.3 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@7896 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- lib/date.rb | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'lib/date.rb') diff --git a/lib/date.rb b/lib/date.rb index 79a2df1135..0ae368fb98 100644 --- a/lib/date.rb +++ b/lib/date.rb @@ -1,12 +1,12 @@ # # date.rb - date and time library # -# Author: Tadayoshi Funaba 1998-2004 +# Author: Tadayoshi Funaba 1998-2005 # # Documentation: William Webber # #-- -# $Id: date.rb,v 2.12 2004-03-20 08:05:13+09 tadf Exp $ +# $Id: date.rb,v 2.15 2005-02-06 11:09:53+09 tadf Exp $ #++ # # == Overview @@ -647,7 +647,7 @@ class Date elem ||= {} y, m, d = elem.values_at(:year, :mon, :mday) if [y, m, d].include? nil - raise ArgumentError, 'invalid date' + raise ArgumentError, '3 elements of civil date are necessary' else civil(y, m, d, sg) end @@ -1211,7 +1211,7 @@ class DateTime < Date fr ||= 0 of ||= 0 if [y, m, d].include? nil - raise ArgumentError, 'invalid date' + raise ArgumentError, '3 elements of civil date are necessary' else civil(y, m, d, h, min, s, of.to_r/86400, sg) + (fr/86400) end -- cgit v1.2.3