mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
yyyy/mm is not an acceptable format.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4464 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
84c506745a
commit
782b6ceac3
3 changed files with 8 additions and 4 deletions
|
@ -1,3 +1,9 @@
|
|||
Sun Aug 31 10:17:02 2003 Tadayoshi Funaba <tadf@dotrb.org>
|
||||
|
||||
* lib/date/format.rb: yyyy/mm is not an acceptable format.
|
||||
|
||||
* lib/time.rb: follow above.
|
||||
|
||||
Sat Aug 30 14:25:43 2003 Yukihiro Matsumoto <matz@ruby-lang.org>
|
||||
|
||||
* eval.c (rb_iter_break): should not call TAG_JUMP directly.
|
||||
|
|
|
@ -356,7 +356,7 @@ class Date
|
|||
end
|
||||
end
|
||||
|
||||
if $1.size > 2
|
||||
if $3 && $1.size > 2
|
||||
comp = false
|
||||
year, mon, mday = mon, mday, year
|
||||
end
|
||||
|
|
|
@ -99,7 +99,7 @@ class Time
|
|||
# # your timezone is GMT:
|
||||
# Time.parse("16:30") #=> Thu Nov 29 16:30:00 GMT 2001
|
||||
# Time.parse("7/23") #=> Mon Jul 23 00:00:00 GMT 2001
|
||||
# Time.parse("2002/1") #=> Tue Jan 01 00:00:00 GMT 2002
|
||||
# Time.parse("Aug 31") #=> Fri Aug 31 00:00:00 GMT 2001
|
||||
#
|
||||
# Since there are numerous conflicts among locally defined timezone
|
||||
# abbreviations all over the world, this method is not made to
|
||||
|
@ -525,8 +525,6 @@ if __FILE__ == $0
|
|||
Time.parse("2001/11/29 21:12", now))
|
||||
assert_equal(Time.local( 2001,11,29),
|
||||
Time.parse("2001/11/29", now))
|
||||
assert_equal(Time.local( 2001,11),
|
||||
Time.parse("2001/11", now))
|
||||
assert_equal(Time.local( 2001,11,29),
|
||||
Time.parse( "11/29", now))
|
||||
#assert_equal(Time.local(2001,11,1), Time.parse("Nov", now))
|
||||
|
|
Loading…
Reference in a new issue