-
-
Notifications
You must be signed in to change notification settings - Fork 942
Closed
Milestone
Description
Time.strftime has some combinated formats, such as %F equal to %Y-%m-%d, and %r equal to %I:%M:%S %p.
Users can apply options even for those combinated formats, for example %20F. But the behavior is different between CRuby and JRuby.
Environment Information
- Confirmed with JRuby 9.1.15.0 and 9.2.10.0.
- Mac OS X 10.13. (The OS does not sound related, though.)
Expected Behavior
This is CRuby's behavior. (2.4, 2.5, 2.6, 2.7)
irb(main):001:0> require 'time'
=> true
irb(main):002:0> Time.now.strftime("%20F")
=> " 2020-04-06"
Actual Behavior
JRuby is working like :
irb(main):001:0> require 'time'
=> true
irb(main):002:0> Time.now.strftime("%20F")
=> "00000000000000002020-04-06"
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels