diff options
| author | Paul Eggert | 2016-05-31 08:07:41 -0700 |
|---|---|---|
| committer | Paul Eggert | 2016-05-31 08:07:41 -0700 |
| commit | 25cc0f2aada3e321e5f1c6d1e492a93d16da45b2 (patch) | |
| tree | 05309a9d1d74813cf25073015ef7aaf36d7a36bf /lisp | |
| parent | 4efef3db2fb1c3a20b83a67948e614d9b0c258dd (diff) | |
| parent | 788c9b69e1801dd883dbe603281571ef3c78a724 (diff) | |
| download | emacs-25cc0f2aada3e321e5f1c6d1e492a93d16da45b2.tar.gz emacs-25cc0f2aada3e321e5f1c6d1e492a93d16da45b2.zip | |
Merge from origin/emacs-25
788c9b6 ; Spelling fix
25c4a30 * lisp/recentf.el (recentf-dialog-mode-map): Remove follow-li...
0992ec3 Correct cl-flet usage (Bug#22317)
50caae3 Release MH-E manual version 8.6
602bb40 Update MH-E's documentation about HTML renderers
89018f0 Fx the we->the typo
845ee57 Restore frames into the current display by default
ee28b4c * lisp/recentf.el (recentf-open-files-item): Quick fix for (b...
01c3cd1 etc/TODO: Remove out-of-place issue
5e18486 Clarify doc string of 'file-name-sans-extension'
bffda22 Fix the MSDOS build
f907f98 * lisp/progmodes/elisp-mode.el (elisp-function-argstring): Ca...
1a2ffd0 * src/dired.c (Ffile_name_all_completions): Doc fix. (Bug#23...
f7ffc4b Fix infloop in 'number-sequence'
4ab2673 ; Spelling and punctuation fixes in comments
71c152e * lisp/emacs-lisp/find-func.el (find-function-library):
Diffstat (limited to 'lisp')
| -rw-r--r-- | lisp/ChangeLog.17 | 2 | ||||
| -rw-r--r-- | lisp/desktop.el | 2 | ||||
| -rw-r--r-- | lisp/emacs-lisp/find-func.el | 6 | ||||
| -rw-r--r-- | lisp/files.el | 17 | ||||
| -rw-r--r-- | lisp/mh-e/mh-compat.el | 23 | ||||
| -rw-r--r-- | lisp/mh-e/mh-mime.el | 10 | ||||
| -rw-r--r-- | lisp/mh-e/mh-show.el | 2 | ||||
| -rw-r--r-- | lisp/mh-e/mh-thread.el | 2 | ||||
| -rw-r--r-- | lisp/progmodes/elisp-mode.el | 3 | ||||
| -rw-r--r-- | lisp/recentf.el | 3 | ||||
| -rw-r--r-- | lisp/subr.el | 9 |
11 files changed, 51 insertions, 28 deletions
diff --git a/lisp/ChangeLog.17 b/lisp/ChangeLog.17 index 2f1957ad0ca..f0b2651f870 100644 --- a/lisp/ChangeLog.17 +++ b/lisp/ChangeLog.17 | |||
| @@ -3737,7 +3737,7 @@ | |||
| 3737 | * net/tramp.el (tramp-read-passwd): Ignore errors from `auth-source-*'. | 3737 | * net/tramp.el (tramp-read-passwd): Ignore errors from `auth-source-*'. |
| 3738 | 3738 | ||
| 3739 | * net/tramp-sh.el (tramp-do-copy-or-rename-file-out-of-band): Use "\n" | 3739 | * net/tramp-sh.el (tramp-do-copy-or-rename-file-out-of-band): Use "\n" |
| 3740 | as end-of-line delimeter for passwords, when running on MS Windows. | 3740 | as end-of-line delimiter for passwords, when running on MS Windows. |
| 3741 | 3741 | ||
| 3742 | 2014-12-27 Stefan Monnier <monnier@iro.umontreal.ca> | 3742 | 2014-12-27 Stefan Monnier <monnier@iro.umontreal.ca> |
| 3743 | 3743 | ||
diff --git a/lisp/desktop.el b/lisp/desktop.el index dba3277c091..1f460b7a3ed 100644 --- a/lisp/desktop.el +++ b/lisp/desktop.el | |||
| @@ -408,7 +408,7 @@ See related options `desktop-restore-reuses-frames', | |||
| 408 | :group 'desktop | 408 | :group 'desktop |
| 409 | :version "24.4") | 409 | :version "24.4") |
| 410 | 410 | ||
| 411 | (defcustom desktop-restore-in-current-display nil | 411 | (defcustom desktop-restore-in-current-display t |
| 412 | "Controls how restoring of frames treats displays. | 412 | "Controls how restoring of frames treats displays. |
| 413 | If t, restores frames into the current display. | 413 | If t, restores frames into the current display. |
| 414 | If nil, restores frames into their original displays (if possible). | 414 | If nil, restores frames into their original displays (if possible). |
diff --git a/lisp/emacs-lisp/find-func.el b/lisp/emacs-lisp/find-func.el index 71437ce89bd..4a7b7109106 100644 --- a/lisp/emacs-lisp/find-func.el +++ b/lisp/emacs-lisp/find-func.el | |||
| @@ -404,8 +404,10 @@ signal an error. | |||
| 404 | 404 | ||
| 405 | If VERBOSE is non-nil, and FUNCTION is an alias, display a | 405 | If VERBOSE is non-nil, and FUNCTION is an alias, display a |
| 406 | message about the whole chain of aliases." | 406 | message about the whole chain of aliases." |
| 407 | (let ((def (if (symbolp function) | 407 | (let ((def (when (symbolp function) |
| 408 | (find-function-advised-original function))) | 408 | (or (fboundp function) |
| 409 | (signal 'void-function (list function))) | ||
| 410 | (find-function-advised-original function))) | ||
| 409 | aliases) | 411 | aliases) |
| 410 | ;; FIXME for completeness, it might be nice to print something like: | 412 | ;; FIXME for completeness, it might be nice to print something like: |
| 411 | ;; foo (which is advised), which is an alias for bar (which is advised). | 413 | ;; foo (which is advised), which is an alias for bar (which is advised). |
diff --git a/lisp/files.el b/lisp/files.el index b737c101588..db274e2782d 100644 --- a/lisp/files.el +++ b/lisp/files.el | |||
| @@ -4320,8 +4320,8 @@ the group would be preserved too." | |||
| 4320 | 4320 | ||
| 4321 | (defun file-name-sans-extension (filename) | 4321 | (defun file-name-sans-extension (filename) |
| 4322 | "Return FILENAME sans final \"extension\". | 4322 | "Return FILENAME sans final \"extension\". |
| 4323 | The extension, in a file name, is the part that follows the last `.', | 4323 | The extension, in a file name, is the part that begins with the last `.', |
| 4324 | except that a leading `.', if any, doesn't count." | 4324 | except that a leading `.' of the file name, if there is one, doesn't count." |
| 4325 | (save-match-data | 4325 | (save-match-data |
| 4326 | (let ((file (file-name-sans-versions (file-name-nondirectory filename))) | 4326 | (let ((file (file-name-sans-versions (file-name-nondirectory filename))) |
| 4327 | directory) | 4327 | directory) |
| @@ -4336,15 +4336,16 @@ except that a leading `.', if any, doesn't count." | |||
| 4336 | 4336 | ||
| 4337 | (defun file-name-extension (filename &optional period) | 4337 | (defun file-name-extension (filename &optional period) |
| 4338 | "Return FILENAME's final \"extension\". | 4338 | "Return FILENAME's final \"extension\". |
| 4339 | The extension, in a file name, is the part that follows the last `.', | 4339 | The extension, in a file name, is the part that begins with the last `.', |
| 4340 | excluding version numbers and backup suffixes, | 4340 | excluding version numbers and backup suffixes, except that a leading `.' |
| 4341 | except that a leading `.', if any, doesn't count. | 4341 | of the file name, if there is one, doesn't count. |
| 4342 | Return nil for extensionless file names such as `foo'. | 4342 | Return nil for extensionless file names such as `foo'. |
| 4343 | Return the empty string for file names such as `foo.'. | 4343 | Return the empty string for file names such as `foo.'. |
| 4344 | 4344 | ||
| 4345 | If PERIOD is non-nil, then the returned value includes the period | 4345 | By default, the returned value excludes the period that starts the |
| 4346 | that delimits the extension, and if FILENAME has no extension, | 4346 | extension, but if the optional argument PERIOD is non-nil, the period |
| 4347 | the value is \"\"." | 4347 | is included in the value, and in that case, if FILENAME has no |
| 4348 | extension, the value is \"\"." | ||
| 4348 | (save-match-data | 4349 | (save-match-data |
| 4349 | (let ((file (file-name-sans-versions (file-name-nondirectory filename)))) | 4350 | (let ((file (file-name-sans-versions (file-name-nondirectory filename)))) |
| 4350 | (if (and (string-match "\\.[^.]*\\'" file) | 4351 | (if (and (string-match "\\.[^.]*\\'" file) |
diff --git a/lisp/mh-e/mh-compat.el b/lisp/mh-e/mh-compat.el index 10a8b6e219c..21ff5cb2cb8 100644 --- a/lisp/mh-e/mh-compat.el +++ b/lisp/mh-e/mh-compat.el | |||
| @@ -75,11 +75,24 @@ introduced in Emacs 22." | |||
| 75 | 'cancel-timer | 75 | 'cancel-timer |
| 76 | 'delete-itimer)) | 76 | 'delete-itimer)) |
| 77 | 77 | ||
| 78 | ;; Emacs 24 renamed flet to cl-flet. | 78 | ;; Emacs 24 made flet obsolete and suggested either cl-flet or |
| 79 | (defalias 'mh-cl-flet | 79 | ;; cl-letf. This macro is based upon gmm-flet from Gnus. |
| 80 | (if (fboundp 'cl-flet) | 80 | (defmacro mh-flet (bindings &rest body) |
| 81 | 'cl-flet | 81 | "Make temporary overriding function definitions. |
| 82 | 'flet)) | 82 | This is an analogue of a dynamically scoped `let' that operates on |
| 83 | the function cell of FUNCs rather than their value cell. | ||
| 84 | |||
| 85 | \(fn ((FUNC ARGLIST BODY...) ...) FORM...)" | ||
| 86 | (if (fboundp 'cl-letf) | ||
| 87 | `(cl-letf ,(mapcar (lambda (binding) | ||
| 88 | `((symbol-function ',(car binding)) | ||
| 89 | (lambda ,@(cdr binding)))) | ||
| 90 | bindings) | ||
| 91 | ,@body) | ||
| 92 | `(flet ,bindings ,@body))) | ||
| 93 | (put 'mh-flet 'lisp-indent-function 1) | ||
| 94 | (put 'mh-flet 'edebug-form-spec | ||
| 95 | '((&rest (sexp sexp &rest form)) &rest form)) | ||
| 83 | 96 | ||
| 84 | (defun mh-display-color-cells (&optional display) | 97 | (defun mh-display-color-cells (&optional display) |
| 85 | "Return the number of color cells supported by DISPLAY. | 98 | "Return the number of color cells supported by DISPLAY. |
diff --git a/lisp/mh-e/mh-mime.el b/lisp/mh-e/mh-mime.el index df3a42ec0f7..b8d700ddf5f 100644 --- a/lisp/mh-e/mh-mime.el +++ b/lisp/mh-e/mh-mime.el | |||
| @@ -268,7 +268,7 @@ usually reads the file \"/etc/mailcap\"." | |||
| 268 | (buffer-read-only nil)) | 268 | (buffer-read-only nil)) |
| 269 | (when (string-match "^[^% \t]+$" method) | 269 | (when (string-match "^[^% \t]+$" method) |
| 270 | (setq method (concat method " %s"))) | 270 | (setq method (concat method " %s"))) |
| 271 | (mh-cl-flet | 271 | (mh-flet |
| 272 | ((mm-handle-set-external-undisplayer | 272 | ((mm-handle-set-external-undisplayer |
| 273 | (handle function) | 273 | (handle function) |
| 274 | (mh-handle-set-external-undisplayer folder handle function))) | 274 | (mh-handle-set-external-undisplayer folder handle function))) |
| @@ -525,7 +525,7 @@ parsed and then displayed." | |||
| 525 | (let ((handles ()) | 525 | (let ((handles ()) |
| 526 | (folder mh-show-folder-buffer) | 526 | (folder mh-show-folder-buffer) |
| 527 | (raw-message-data (buffer-string))) | 527 | (raw-message-data (buffer-string))) |
| 528 | (mh-cl-flet | 528 | (mh-flet |
| 529 | ((mm-handle-set-external-undisplayer | 529 | ((mm-handle-set-external-undisplayer |
| 530 | (handle function) | 530 | (handle function) |
| 531 | (mh-handle-set-external-undisplayer folder handle function))) | 531 | (mh-handle-set-external-undisplayer folder handle function))) |
| @@ -1049,7 +1049,7 @@ attachment, the attachment is hidden." | |||
| 1049 | (function (get-text-property (point) 'mh-callback)) | 1049 | (function (get-text-property (point) 'mh-callback)) |
| 1050 | (buffer-read-only nil) | 1050 | (buffer-read-only nil) |
| 1051 | (folder mh-show-folder-buffer)) | 1051 | (folder mh-show-folder-buffer)) |
| 1052 | (mh-cl-flet | 1052 | (mh-flet |
| 1053 | ((mm-handle-set-external-undisplayer | 1053 | ((mm-handle-set-external-undisplayer |
| 1054 | (handle function) | 1054 | (handle function) |
| 1055 | (mh-handle-set-external-undisplayer folder handle function))) | 1055 | (mh-handle-set-external-undisplayer folder handle function))) |
| @@ -1070,7 +1070,7 @@ to click the MIME button." | |||
| 1070 | (mm-inline-media-tests mh-mm-inline-media-tests) | 1070 | (mm-inline-media-tests mh-mm-inline-media-tests) |
| 1071 | (data (get-text-property (point) 'mh-data)) | 1071 | (data (get-text-property (point) 'mh-data)) |
| 1072 | (function (get-text-property (point) 'mh-callback))) | 1072 | (function (get-text-property (point) 'mh-callback))) |
| 1073 | (mh-cl-flet | 1073 | (mh-flet |
| 1074 | ((mm-handle-set-external-undisplayer | 1074 | ((mm-handle-set-external-undisplayer |
| 1075 | (handle func) | 1075 | (handle func) |
| 1076 | (mh-handle-set-external-undisplayer folder handle func))) | 1076 | (mh-handle-set-external-undisplayer folder handle func))) |
| @@ -1166,7 +1166,7 @@ this ;-)" | |||
| 1166 | (defun mh-display-emphasis () | 1166 | (defun mh-display-emphasis () |
| 1167 | "Display graphical emphasis." | 1167 | "Display graphical emphasis." |
| 1168 | (when (and mh-graphical-emphasis-flag (mh-small-show-buffer-p)) | 1168 | (when (and mh-graphical-emphasis-flag (mh-small-show-buffer-p)) |
| 1169 | (mh-cl-flet | 1169 | (mh-flet |
| 1170 | ((article-goto-body ())) ; shadow this function to do nothing | 1170 | ((article-goto-body ())) ; shadow this function to do nothing |
| 1171 | (save-excursion | 1171 | (save-excursion |
| 1172 | (goto-char (point-min)) | 1172 | (goto-char (point-min)) |
diff --git a/lisp/mh-e/mh-show.el b/lisp/mh-e/mh-show.el index afe9812eea8..26e821696a8 100644 --- a/lisp/mh-e/mh-show.el +++ b/lisp/mh-e/mh-show.el | |||
| @@ -900,7 +900,7 @@ See also `mh-folder-mode'. | |||
| 900 | (interactive) | 900 | (interactive) |
| 901 | ;; Don't allow Gnus to create buttons while highlighting, maybe this is bad | 901 | ;; Don't allow Gnus to create buttons while highlighting, maybe this is bad |
| 902 | ;; style? | 902 | ;; style? |
| 903 | (mh-cl-flet | 903 | (mh-flet |
| 904 | ((gnus-article-add-button (&rest args) nil)) | 904 | ((gnus-article-add-button (&rest args) nil)) |
| 905 | (let* ((modified (buffer-modified-p)) | 905 | (let* ((modified (buffer-modified-p)) |
| 906 | (gnus-article-buffer (buffer-name)) | 906 | (gnus-article-buffer (buffer-name)) |
diff --git a/lisp/mh-e/mh-thread.el b/lisp/mh-e/mh-thread.el index 5135e7e88fa..e6acdba8b30 100644 --- a/lisp/mh-e/mh-thread.el +++ b/lisp/mh-e/mh-thread.el | |||
| @@ -647,7 +647,7 @@ Only information about messages in MSG-LIST are added to the tree." | |||
| 647 | 647 | ||
| 648 | (defun mh-thread-set-tables (folder) | 648 | (defun mh-thread-set-tables (folder) |
| 649 | "Use the tables of FOLDER in current buffer." | 649 | "Use the tables of FOLDER in current buffer." |
| 650 | (mh-cl-flet | 650 | (mh-flet |
| 651 | ((mh-get-table (symbol) | 651 | ((mh-get-table (symbol) |
| 652 | (with-current-buffer folder | 652 | (with-current-buffer folder |
| 653 | (symbol-value symbol)))) | 653 | (symbol-value symbol)))) |
diff --git a/lisp/progmodes/elisp-mode.el b/lisp/progmodes/elisp-mode.el index 2ad22ddd0ff..f3607911aa1 100644 --- a/lisp/progmodes/elisp-mode.el +++ b/lisp/progmodes/elisp-mode.el | |||
| @@ -1566,7 +1566,8 @@ In the absence of INDEX, just call `eldoc-docstring-format-sym-doc'." | |||
| 1566 | ARGLIST is either a string, or a list of strings or symbols." | 1566 | ARGLIST is either a string, or a list of strings or symbols." |
| 1567 | (let ((str (cond ((stringp arglist) arglist) | 1567 | (let ((str (cond ((stringp arglist) arglist) |
| 1568 | ((not (listp arglist)) nil) | 1568 | ((not (listp arglist)) nil) |
| 1569 | (t (help--make-usage-docstring 'toto arglist))))) | 1569 | (t (substitute-command-keys |
| 1570 | (help--make-usage-docstring 'toto arglist)))))) | ||
| 1570 | (if (and str (string-match "\\`([^ )]+ ?" str)) | 1571 | (if (and str (string-match "\\`([^ )]+ ?" str)) |
| 1571 | (replace-match "(" t t str) | 1572 | (replace-match "(" t t str) |
| 1572 | str))) | 1573 | str))) |
diff --git a/lisp/recentf.el b/lisp/recentf.el index 3321f2fe101..dc9489752fb 100644 --- a/lisp/recentf.el +++ b/lisp/recentf.el | |||
| @@ -1186,6 +1186,9 @@ IGNORE other arguments." | |||
| 1186 | :format "%[%t\n%]" | 1186 | :format "%[%t\n%]" |
| 1187 | :help-echo ,(concat "Open " (cdr menu-element)) | 1187 | :help-echo ,(concat "Open " (cdr menu-element)) |
| 1188 | :action recentf-open-files-action | 1188 | :action recentf-open-files-action |
| 1189 | ;; Override the (problematic) follow-link property of the | ||
| 1190 | ;; `link' widget (bug#22434). | ||
| 1191 | :follow-link nil | ||
| 1189 | ,(cdr menu-element)))) | 1192 | ,(cdr menu-element)))) |
| 1190 | 1193 | ||
| 1191 | (defun recentf-open-files-items (files) | 1194 | (defun recentf-open-files-items (files) |
diff --git a/lisp/subr.el b/lisp/subr.el index 6e679e70f7e..b66ff288b7a 100644 --- a/lisp/subr.el +++ b/lisp/subr.el | |||
| @@ -486,13 +486,16 @@ of course, also replace TO with a slightly larger value | |||
| 486 | (list from) | 486 | (list from) |
| 487 | (or inc (setq inc 1)) | 487 | (or inc (setq inc 1)) |
| 488 | (when (zerop inc) (error "The increment can not be zero")) | 488 | (when (zerop inc) (error "The increment can not be zero")) |
| 489 | (let (seq (n 0) (next from)) | 489 | (let (seq (n 0) (next from) (last from)) |
| 490 | (if (> inc 0) | 490 | (if (> inc 0) |
| 491 | (while (<= next to) | 491 | ;; The (>= next last) condition protects against integer |
| 492 | ;; overflow in computing NEXT. | ||
| 493 | (while (and (>= next last) (<= next to)) | ||
| 492 | (setq seq (cons next seq) | 494 | (setq seq (cons next seq) |
| 493 | n (1+ n) | 495 | n (1+ n) |
| 496 | last next | ||
| 494 | next (+ from (* n inc)))) | 497 | next (+ from (* n inc)))) |
| 495 | (while (>= next to) | 498 | (while (and (<= next last) (>= next to)) |
| 496 | (setq seq (cons next seq) | 499 | (setq seq (cons next seq) |
| 497 | n (1+ n) | 500 | n (1+ n) |
| 498 | next (+ from (* n inc))))) | 501 | next (+ from (* n inc))))) |