diff options
Diffstat (limited to 'lisp/files.el')
| -rw-r--r-- | lisp/files.el | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/lisp/files.el b/lisp/files.el index 9b56dfa9693..ff4ccec2279 100644 --- a/lisp/files.el +++ b/lisp/files.el @@ -316,6 +316,7 @@ A value of nil means don't add newlines. Certain major modes set this locally to the value obtained from `mode-require-final-newline'." + :safe #'symbolp :type '(choice (const :tag "When visiting" visit) (const :tag "When saving" t) (const :tag "When visiting or saving" visit-save) @@ -4916,6 +4917,11 @@ change the additional actions you can take on files." (length autosaved-buffers) (mapconcat 'identity autosaved-buffers ", ")))))))) +(defun clear-visited-file-modtime () + "Clear out records of last mod time of visited file. +Next attempt to save will certainly not complain of a discrepancy." + (set-visited-file-modtime 0)) + (defun not-modified (&optional arg) "Mark current buffer as unmodified, not needing to be saved. With prefix ARG, mark buffer as modified, so \\[save-buffer] will save. |
