diff options
| author | Michael Albinus | 2018-09-29 15:33:48 +0200 |
|---|---|---|
| committer | Michael Albinus | 2018-09-29 15:33:48 +0200 |
| commit | ce0da8a427467a2a5e5636f4d69eb56b56b0925e (patch) | |
| tree | 5de46dcce14f9a61af05f7ac7b658e877eab7d30 /doc/misc | |
| parent | 9284e22676a80789a95c3df3b74ac938a0f5eeaa (diff) | |
| download | emacs-ce0da8a427467a2a5e5636f4d69eb56b56b0925e.tar.gz emacs-ce0da8a427467a2a5e5636f4d69eb56b56b0925e.zip | |
Rework time-* functions in Tramp
* doc/misc/emacs-mime.texi (time-date): Add time-equal-p.
* lisp/net/tramp-compat.el (tramp-compat-time-equal-p): New defsubst.
* lisp/net/tramp.el (tramp-file-name-handler): Remove `debug'
error handler.
(tramp-half-a-year): Remove.
(tramp-time-dont-know, tramp-time-doesnt-exist): New defconst.
(tramp-time-diff): Remove compat code.
(tramp-handle-set-visited-file-modtime)
(tramp-handle-verify-visited-file-modtime):
* lisp/net/tramp-adb.el (tramp-do-parse-file-attributes-with-ls)
(tramp-adb-handle-set-file-times):
* lisp/net/tramp-sh.el (tramp-do-file-attributes-with-ls)
(tramp-sh-handle-set-visited-file-modtime)
(tramp-sh-handle-verify-visited-file-modtime)
(tramp-sh-handle-set-file-times)
(tramp-sh-handle-file-newer-than-file-p):
Use `tramp-time-dont-know', `tramp-time-doesnt-exist' and
`tramp-compat-time-equal-p'.
(tramp-sh-handle-verify-visited-file-modtime): Simplify check.
* lisp/net/tramp-smb.el (tramp-smb-handle-file-attributes)
(tramp-smb-read-file-entry): Use `tramp-time-dont-know'.
(tramp-smb-handle-insert-directory): Adapt half-a-year check.
* src/editfns.c (Ftime_equal_p): Adapt docstring.
* test/lisp/net/tramp-tests.el
(tramp-test19-directory-files-and-attributes)
(tramp-test22-file-times): Use `tramp-compat-time-equal-p' and
`tramp-time-dont-know'.
(tramp-test23-visited-file-modtime): Extend test.
Diffstat (limited to 'doc/misc')
| -rw-r--r-- | doc/misc/emacs-mime.texi | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/doc/misc/emacs-mime.texi b/doc/misc/emacs-mime.texi index 45f37fb8557..9280311b5c9 100644 --- a/doc/misc/emacs-mime.texi +++ b/doc/misc/emacs-mime.texi | |||
| @@ -1561,6 +1561,9 @@ Here's a bunch of time/date/second/day examples: | |||
| 1561 | (time-less-p '(13818 19266) '(13818 19145)) | 1561 | (time-less-p '(13818 19266) '(13818 19145)) |
| 1562 | @result{} nil | 1562 | @result{} nil |
| 1563 | 1563 | ||
| 1564 | (time-equal-p '(13818 19266) '(13818 19145)) | ||
| 1565 | @result{} nil | ||
| 1566 | |||
| 1564 | (time-subtract '(13818 19266) '(13818 19145)) | 1567 | (time-subtract '(13818 19266) '(13818 19145)) |
| 1565 | @result{} (0 121) | 1568 | @result{} (0 121) |
| 1566 | 1569 | ||
| @@ -1641,6 +1644,10 @@ return a ``zero'' time. | |||
| 1641 | Take two times and say whether the first time is less (i.e., earlier) | 1644 | Take two times and say whether the first time is less (i.e., earlier) |
| 1642 | than the second time. (This is a built-in function.) | 1645 | than the second time. (This is a built-in function.) |
| 1643 | 1646 | ||
| 1647 | @item time-equal-p | ||
| 1648 | Check, whether two time values are equal. The time values must not be | ||
| 1649 | in the same format. (This is a built-in function.) | ||
| 1650 | |||
| 1644 | @item time-since | 1651 | @item time-since |
| 1645 | Take a time and return a time saying how long it was since that time. | 1652 | Take a time and return a time saying how long it was since that time. |
| 1646 | 1653 | ||