diff options
author | shugo <shugo@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2008-08-21 14:57:35 +0000 |
---|---|---|
committer | shugo <shugo@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2008-08-21 14:57:35 +0000 |
commit | a0cc5b19b7fa4207496a74d2ef8f39480eac44b5 (patch) | |
tree | 9e51d949df4dc0aca0f94cd465478998cc598ed7 /time.c | |
parent | 60bc53a1615222d2ad0b111ca84975093cf6efc1 (diff) |
* strftime.c (rb_strftime): supported %F and %<precision>N.
reverted config.h to ruby.h for Windows.
* test/ruby/test_time.rb (TestTime::test_strftime): added tests
for %F and %N.
* time.c: documented %F and %N.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18755 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'time.c')
-rw-r--r-- | time.c | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -2056,13 +2056,17 @@ rb_strftime_alloc(char **buf, const char *format, * %B - The full month name (``January'') * %c - The preferred local date and time representation * %d - Day of the month (01..31) + * %F - Equivalent to %Y-%m-%d (the ISO 8601 date format) * %H - Hour of the day, 24-hour clock (00..23) * %I - Hour of the day, 12-hour clock (01..12) * %j - Day of the year (001..366) * %L - Millisecond of the second (000..999) * %m - Month of the year (01..12) * %M - Minute of the hour (00..59) - * %N - Nanosecond of the second (000000000..999999999) + * %N - Fractional seconds digits, default is 9 digits (nanosecond) + * %3N millisecond (3 digits) + * %6N microsecond (6 digits) + * %9N nanosecond (9 digits) * %p - Meridian indicator (``AM'' or ``PM'') * %S - Second of the minute (00..60) * %U - Week number of the current year, |