diff options
| author | Eli Zaretskii | 2019-08-17 12:25:32 +0300 |
|---|---|---|
| committer | Eli Zaretskii | 2019-08-17 12:25:32 +0300 |
| commit | abd3fdf7b8ce09b67012534c72fe0751c2f23f1e (patch) | |
| tree | 8650047ff1d4a9cbe2cffc2a027cae8751ce2093 /etc | |
| parent | 6715e6af10421b8bf5cc26e42e7c8e11f08769c8 (diff) | |
| parent | 743cc86a053d536a4bfe8d519840c0b4cc2ce02e (diff) | |
| download | emacs-abd3fdf7b8ce09b67012534c72fe0751c2f23f1e.tar.gz emacs-abd3fdf7b8ce09b67012534c72fe0751c2f23f1e.zip | |
Merge branch 'master' of git.savannah.gnu.org:/srv/git/emacs
Diffstat (limited to 'etc')
| -rw-r--r-- | etc/NEWS | 22 |
1 files changed, 16 insertions, 6 deletions
| @@ -2116,10 +2116,20 @@ probing the innards of a timestamp directly, or creating a timestamp | |||
| 2116 | by hand. | 2116 | by hand. |
| 2117 | 2117 | ||
| 2118 | +++ | 2118 | +++ |
| 2119 | *** Decoded (calendrical) timestamps now have a new subsecond member. | 2119 | *** Decoded (calendrical) timestamps now have subsecond resolution. |
| 2120 | This affects functions like decode-time and parse-time-string that | 2120 | This affects decode-time, which generates these timestamps, as well as |
| 2121 | generate these timestamps, and functions like encode-time that accept | 2121 | functions like encode-time that accept them. The subsecond info is |
| 2122 | them. | 2122 | present as a (TICKS . HZ) value in the seconds element of a decoded |
| 2123 | timestamp, and decode-time has a new optional FORM argument specifying | ||
| 2124 | the form of the seconds member. For example, if X is the timestamp | ||
| 2125 | (1566009571321878186 . 1000000000), which represents 2019-08-17 | ||
| 2126 | 02:39:31.321878186 UTC, (decode-time X t t) returns ((31321878186 | ||
| 2127 | . 1000000000) 39 2 17 8 2019 6 nil 0) instead of the traditional (31 | ||
| 2128 | 39 2 17 8 2019 6 nil 0) returned by plain (decode-time X t). Although | ||
| 2129 | the default FORM is currently 'integer', which truncates the seconds | ||
| 2130 | to an integer and is the traditional behavior, this default may change | ||
| 2131 | in future Emacs versions, so callers requiring an integer should | ||
| 2132 | specify FORM explicitly. | ||
| 2123 | 2133 | ||
| 2124 | +++ | 2134 | +++ |
| 2125 | *** 'encode-time' supports a new API '(encode-time TIME)'. | 2135 | *** 'encode-time' supports a new API '(encode-time TIME)'. |
| @@ -2152,8 +2162,8 @@ with POSIX.1-2017. | |||
| 2152 | *** To access (or alter) the elements a decoded time value, the | 2162 | *** To access (or alter) the elements a decoded time value, the |
| 2153 | 'decoded-time-second', 'decoded-time-minute', 'decoded-time-hour', | 2163 | 'decoded-time-second', 'decoded-time-minute', 'decoded-time-hour', |
| 2154 | 'decoded-time-day', 'decoded-time-month', 'decoded-time-year', | 2164 | 'decoded-time-day', 'decoded-time-month', 'decoded-time-year', |
| 2155 | 'decoded-time-weekday', 'decoded-time-dst', 'decoded-time-zone', | 2165 | 'decoded-time-weekday', 'decoded-time-dst' and 'decoded-time-zone' |
| 2156 | and 'decoded-time-subsec' accessors can be used. | 2166 | accessors can be used. |
| 2157 | 2167 | ||
| 2158 | *** The new functions 'date-days-in-month' (which will say how many | 2168 | *** The new functions 'date-days-in-month' (which will say how many |
| 2159 | days there are in a month in a specific year), 'date-ordinal-to-time' | 2169 | days there are in a month in a specific year), 'date-ordinal-to-time' |