From 9cd678b72f86ed312321cf04fc83f5a10978485b Mon Sep 17 00:00:00 2001 From: matz Date: Mon, 16 Apr 2007 07:28:16 +0000 Subject: [PATCH] * time.c (time_arg): should allow to specify 24:00. [ruby-core:10915] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12176 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 5 +++++ time.c | 3 ++- version.h | 6 +++--- 3 files changed, 10 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index 50337cc683..2097b29397 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Mon Apr 16 10:43:10 2007 Yukihiro Matsumoto + + * time.c (time_arg): should allow to specify 24:00. + [ruby-core:10915] + Sun Apr 15 09:12:54 2007 Tadayoshi Funaba * lib/date/format.rb: added some zone names. diff --git a/time.c b/time.c index 9fa37d7985..5a806ecab4 100644 --- a/time.c +++ b/time.c @@ -368,7 +368,8 @@ time_arg(int argc, VALUE *argv, struct tm *tm, time_t *usec) #endif tm->tm_mon < 0 || tm->tm_mon > 11 || tm->tm_mday < 1 || tm->tm_mday > 31 - || tm->tm_hour < 0 || tm->tm_hour > 23 + || tm->tm_hour < 0 || tm->tm_hour > 24 + || (tm->tm_hour == 24 && (tm->tm_min > 0 || tm->tm_sec > 0)) || tm->tm_min < 0 || tm->tm_min > 59 || tm->tm_sec < 0 || tm->tm_sec > 60) rb_raise(rb_eArgError, "argument out of range"); diff --git a/version.h b/version.h index 255654782c..58390acfc6 100644 --- a/version.h +++ b/version.h @@ -1,7 +1,7 @@ #define RUBY_VERSION "1.9.0" -#define RUBY_RELEASE_DATE "2007-04-12" +#define RUBY_RELEASE_DATE "2007-04-16" #define RUBY_VERSION_CODE 190 -#define RUBY_RELEASE_CODE 20070412 +#define RUBY_RELEASE_CODE 20070416 #define RUBY_PATCHLEVEL 0 #define RUBY_VERSION_MAJOR 1 @@ -9,7 +9,7 @@ #define RUBY_VERSION_TEENY 0 #define RUBY_RELEASE_YEAR 2007 #define RUBY_RELEASE_MONTH 4 -#define RUBY_RELEASE_DAY 12 +#define RUBY_RELEASE_DAY 16 RUBY_EXTERN const char ruby_version[]; RUBY_EXTERN const char ruby_release_date[];