commit 2bd26ed69770b2995c3f3d90b017048429bd1ffe (HEAD, refs/remotes/origin/master) Author: Lars Ingebrigtsen Date: Wed Sep 8 10:28:15 2021 +0200 Further tweak describe-variable look * lisp/help-fns.el (describe-variable): Tweak how long variable values are shown. diff --git a/lisp/help-fns.el b/lisp/help-fns.el index 3f1b56c888..a7219ede94 100644 --- a/lisp/help-fns.el +++ b/lisp/help-fns.el @@ -1222,7 +1222,14 @@ it is displayed along with the global value." ;; Output the indented administrative bits. (with-current-buffer buffer (help-fns--run-describe-functions - help-fns-describe-variable-functions variable))) + help-fns-describe-variable-functions variable)) + + (with-current-buffer standard-output + ;; If we have the long value of the variable at the + ;; end, remove superfluous empty lines before it. + (unless (eobp) + (while (looking-at-p "\n") + (delete-char 1))))) (with-current-buffer standard-output ;; Return the text we displayed. commit 24f370df136fd4a14303d2a9c5aedb20a7879139 Merge: f9aa6c74e4 188f4e6d2b Author: Eli Zaretskii Date: Wed Sep 8 11:27:09 2021 +0300 Merge branch 'master' of git.savannah.gnu.org:/srv/git/emacs commit f9aa6c74e4165e2b7f1ebc40bbde1646cae2c9ef Author: Eli Zaretskii Date: Wed Sep 8 11:26:17 2021 +0300 ; * admin/README: Add descriptions of more subdirectories. diff --git a/admin/README b/admin/README index ac3f81ce68..b0336f91ff 100644 --- a/admin/README +++ b/admin/README @@ -61,13 +61,19 @@ Brief description of sub-directories: charsets scripts for generating charset map files in ../etc/charsets -coccinelle patches to make coccinelle work with - the latest Emacs version. Since they - apply a few minor changes in Emacs internals - in multiple places, they are trivial for - copyright purposes. +coccinelle patches to make coccinelle work with + the latest Emacs version. Since they + apply a few minor changes in Emacs internals + in multiple places, they are trivial for + copyright purposes. +grammars wisent and bovine grammars, used to produce + files in lisp/cedet/. +notes miscellaneous notes related to administrative + tasks. +nt support files for administrative tasks related + to building MS-Windows distributions. unidata scripts for generating character property files - in ../lisp/international + in ../lisp/international/. This file is part of GNU Emacs. commit 6c2823dff36fd290e1b1012258be949f70e63235 Author: Richard Stallman Date: Tue Sep 7 23:25:17 2021 -0400 ; * admin/README: Mention 'coccinelle'. diff --git a/admin/README b/admin/README index 312f09839e..ac3f81ce68 100644 --- a/admin/README +++ b/admin/README @@ -61,6 +61,11 @@ Brief description of sub-directories: charsets scripts for generating charset map files in ../etc/charsets +coccinelle patches to make coccinelle work with + the latest Emacs version. Since they + apply a few minor changes in Emacs internals + in multiple places, they are trivial for + copyright purposes. unidata scripts for generating character property files in ../lisp/international commit 188f4e6d2bfa12bb9936503142a9e969eebc5b26 Author: Mattias Engdegård Date: Wed Sep 8 10:17:23 2021 +0200 * etc/NEWS: macOS alternative context menu mouse binding. diff --git a/etc/NEWS b/etc/NEWS index f43fa74156..fb99827bcc 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -178,7 +178,8 @@ When this mode is enabled, clicking 'down-mouse-3' anywhere in the buffer pops up a menu whose contents depends on surrounding context near the mouse click. You can change the order of the default sub-menus in the context menu by customizing the user option 'context-menu-functions'. -You can also invoke the context menu by pressing 'S-'. +You can also invoke the context menu by pressing 'S-' or, +on macOS, by clicking 'C-down-mouse-1'. +++ ** A new keymap for buffer actions has been added. commit e297c4fbeeb6815d7596792400fb4754b33c0672 Author: Lars Ingebrigtsen Date: Wed Sep 8 10:13:47 2021 +0200 Fix previous help-fns change * lisp/help-fns.el (help-fns--run-describe-functions): Fix the test for whether the function inserted anything. diff --git a/lisp/help-fns.el b/lisp/help-fns.el index 756eb83b50..3f1b56c888 100644 --- a/lisp/help-fns.el +++ b/lisp/help-fns.el @@ -1238,7 +1238,7 @@ it is displayed along with the global value." (let ((size (buffer-size standard-output))) (apply func args) ;; This function inserted something, so register it. - (when (> (buffer-size) size) + (when (> (buffer-size standard-output) size) (push func help-fns--activated-functions))))) (with-current-buffer standard-output (help-fns--ensure-empty-line))) commit 30aaea188888e0d96877a7f40d56801d0e126d3e Author: Lars Ingebrigtsen Date: Wed Sep 8 09:45:45 2021 +0200 Adjust test to describe-function changes The doc now always ends with an empty line diff --git a/test/src/emacs-module-tests.el b/test/src/emacs-module-tests.el index a4d858113e..646c7bb270 100644 --- a/test/src/emacs-module-tests.el +++ b/test/src/emacs-module-tests.el @@ -324,7 +324,9 @@ local reference." (mod-test-sum a b) -Return A + B" +Return A + B + +" module-file-suffix)))))) (ert-deftest module/load-history () commit d80552df71e2ffe9123689ce5c4a268098a34d88 Author: Miha Rihtaršič Date: Wed Sep 8 09:40:28 2021 +0200 Allow kmacros to end with C-g in minibuffer * src/keyboard.c (cmd_error): If a command causes a minibuffer-quit condition, record its key in a keyboard macro (bug#48603). diff --git a/src/keyboard.c b/src/keyboard.c index f6139b30e7..4b0e4a1f77 100644 --- a/src/keyboard.c +++ b/src/keyboard.c @@ -951,6 +951,10 @@ cmd_error (Lisp_Object data) Vexecuting_kbd_macro = Qnil; executing_kbd_macro = Qnil; } + else if (!NILP (KVAR (current_kboard, defining_kbd_macro))) + /* An `M-x' command that signals a `minibuffer-quit' condition + that's part of a kbd macro. */ + finalize_kbd_macro_chars (); specbind (Qstandard_output, Qt); specbind (Qstandard_input, Qt); commit f12df3b5a03dcb9b33bb1e3796b8402e8c125435 Author: Lars Ingebrigtsen Date: Wed Sep 8 09:24:11 2021 +0200 Add support for keypad `=' key in xterm.el * lisp/term/xterm.el (xterm-function-map): Add support for keypad = key (bug#16645). diff --git a/lisp/term/xterm.el b/lisp/term/xterm.el index de5f000089..95187d5d11 100644 --- a/lisp/term/xterm.el +++ b/lisp/term/xterm.el @@ -394,6 +394,9 @@ Return the pasted text as a string." (define-key map "\eOx" [kp-8]) (define-key map "\eOy" [kp-9]) + ;; Some keypads have an equal key (for instance, most Apple keypads). + (define-key map "\eOX" [kp-equal]) + (define-key map "\eO2j" [S-kp-multiply]) (define-key map "\eO2k" [S-kp-add]) (define-key map "\eO2l" [S-kp-separator]) commit afddd5529d8e23a0a4b612fed9792f6beda07965 Author: Lars Ingebrigtsen Date: Wed Sep 8 08:59:29 2021 +0200 Don't disable ipython as a native interpreter * lisp/progmodes/python.el (python-shell-completion-native-disabled-interpreters): Remove ipython from list, because it apparently works fine these days (bug#50458). diff --git a/lisp/progmodes/python.el b/lisp/progmodes/python.el index d8ec032402..db7008df24 100644 --- a/lisp/progmodes/python.el +++ b/lisp/progmodes/python.el @@ -3537,13 +3537,12 @@ the full statement in the case of imports." (defcustom python-shell-completion-native-disabled-interpreters ;; PyPy's readline cannot handle some escape sequences yet. Native - ;; completion was found to be non-functional for IPython (see - ;; Bug#25067). Native completion doesn't work on w32 (Bug#28580). + ;; completion doesn't work on w32 (Bug#28580). (if (eq system-type 'windows-nt) '("") - '("pypy" "ipython")) + '("pypy")) "List of disabled interpreters. When a match is found, native completion is disabled." - :version "25.1" + :version "28.1" :type '(repeat string)) (defcustom python-shell-completion-native-enable t commit 663f7e3fcc1928859e5a5d18633dd92c97f1f505 Author: Lars Ingebrigtsen Date: Wed Sep 8 08:56:07 2021 +0200 Fix mail-user-agent defcustom type * lisp/simple.el (mail-user-agent): Any symbol can be used as the value (bug#50460). diff --git a/lisp/simple.el b/lisp/simple.el index 800a927903..9e29241cc7 100644 --- a/lisp/simple.el +++ b/lisp/simple.el @@ -8730,7 +8730,7 @@ See also `read-mail-command' concerning reading mail." (function-item :tag "Message with full Gnus features" :format "%t\n" gnus-user-agent) - (function :tag "Other")) + (symbol :tag "Other")) :version "23.2" ; sendmail->message :group 'mail) commit 53edc2ba8ec9bf13706cd99ae00107d38bec00cc Author: Lars Ingebrigtsen Date: Wed Sep 8 08:50:27 2021 +0200 Move the indented *Help* block to after the doc string * lisp/help-fns.el (describe-function-1): Move indented admin block to the end (bug#50463). (describe-variable): Ditto (bug#50463). diff --git a/etc/NEWS b/etc/NEWS index 2275fa43a6..f43fa74156 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -513,6 +513,12 @@ built without SVG support, the old icons will be used instead. ** Help +--- +*** The order things are displayed in the *Help* buffer has been changed. +The indented "administrative" block (containing the "probably +introduced" and "other relevant functions" (and similar things) has +been moved to after the doc string. + +++ *** New command 'describe-command' shows help for a command. This can be used instead of 'describe-function' for interactive diff --git a/lisp/help-fns.el b/lisp/help-fns.el index 3eefdd13d2..756eb83b50 100644 --- a/lisp/help-fns.el +++ b/lisp/help-fns.el @@ -960,10 +960,9 @@ Returns a list of the form (REAL-FUNCTION DEF ALIASED REAL-DEF)." ;; E.g. an alias for a not yet defined function. ((invalid-function void-function) doc-raw)))) (help-fns--ensure-empty-line) + (insert (or doc "Not documented.")) (help-fns--run-describe-functions - help-fns-describe-function-functions function) - (help-fns--ensure-empty-line) - (insert (or doc "Not documented."))) + help-fns-describe-function-functions function)) ;; Avoid asking the user annoying questions if she decides ;; to save the help buffer, when her locale's codeset ;; isn't UTF-8. @@ -1197,10 +1196,6 @@ it is displayed along with the global value." ;; of a symbol. (set-syntax-table emacs-lisp-mode-syntax-table) (goto-char val-start-pos) - ;; The line below previously read as - ;; (delete-region (point) (progn (end-of-line) (point))) - ;; which suppressed display of the buffer local value for - ;; large values. (when (looking-at "value is") (replace-match "")) (save-excursion (insert "\n\nValue:") @@ -1221,27 +1216,32 @@ it is displayed along with the global value." (documentation-property alias 'variable-documentation)))) + (with-current-buffer standard-output + (insert (or doc "Not documented as a variable."))) + + ;; Output the indented administrative bits. (with-current-buffer buffer (help-fns--run-describe-functions - help-fns-describe-variable-functions variable)) - - (with-current-buffer standard-output - (help-fns--ensure-empty-line)) - (with-current-buffer standard-output - (insert (or doc "Not documented as a variable.")))) + help-fns-describe-variable-functions variable))) (with-current-buffer standard-output ;; Return the text we displayed. (buffer-string)))))))) (defun help-fns--run-describe-functions (functions &rest args) + (with-current-buffer standard-output + (unless (bolp) + (insert "\n")) + (help-fns--ensure-empty-line)) (let ((help-fns--activated-functions nil)) (dolist (func functions) (let ((size (buffer-size standard-output))) (apply func args) ;; This function inserted something, so register it. (when (> (buffer-size) size) - (push func help-fns--activated-functions)))))) + (push func help-fns--activated-functions))))) + (with-current-buffer standard-output + (help-fns--ensure-empty-line))) (add-hook 'help-fns-describe-variable-functions #'help-fns--customize-variable) (defun help-fns--customize-variable (variable &optional text) commit 79c5e0fca135c12261ff9b9d3a2fb6c26b0eabac Author: Lars Ingebrigtsen Date: Wed Sep 8 08:37:11 2021 +0200 Don't output "probably introduced" if we know the answer for sure * lisp/help-fns.el (help-fns--customize-variable-version): Factored out from `help-fns--customize-variable' to be able to see whether it outputs anything. (help-fns--run-describe-functions): New function. (help-fns--activated-functions): New internal variable. (describe-variable): Use new function. (describe-face, describe-function-1): Ditto (bug#50463). diff --git a/lisp/help-fns.el b/lisp/help-fns.el index 2c7956d968..3eefdd13d2 100644 --- a/lisp/help-fns.el +++ b/lisp/help-fns.el @@ -64,6 +64,12 @@ described in `help-fns-describe-variable-functions', except that the functions are called with two parameters: The face and the frame.") +(defvar help-fns--activated-functions nil + "Internal variable let-bound to help functions that have triggered. +Help functions can check the contents of this list to see whether +a specific previous help function has inserted something in the +current help buffer.") + ;; Functions (defvar help-definition-prefixes nil @@ -723,8 +729,12 @@ FILE is the file where FUNCTION was probably defined." (add-hook 'help-fns-describe-variable-functions #'help-fns--mention-first-release) (defun help-fns--mention-first-release (object) - (let ((first (if (symbolp object) (help-fns--first-release object)))) - (when first + ;; Don't output anything if we've already output the :version from + ;; the `defcustom'. + (unless (memq 'help-fns--customize-variable-version + help-fns--activated-functions) + (when-let ((first (and (symbolp object) + (help-fns--first-release object)))) (with-current-buffer standard-output (insert (format " Probably introduced at or before Emacs version %s.\n" first)))))) @@ -950,7 +960,8 @@ Returns a list of the form (REAL-FUNCTION DEF ALIASED REAL-DEF)." ;; E.g. an alias for a not yet defined function. ((invalid-function void-function) doc-raw)))) (help-fns--ensure-empty-line) - (run-hook-with-args 'help-fns-describe-function-functions function) + (help-fns--run-describe-functions + help-fns-describe-function-functions function) (help-fns--ensure-empty-line) (insert (or doc "Not documented."))) ;; Avoid asking the user annoying questions if she decides @@ -1211,8 +1222,8 @@ it is displayed along with the global value." alias 'variable-documentation)))) (with-current-buffer buffer - (run-hook-with-args 'help-fns-describe-variable-functions - variable)) + (help-fns--run-describe-functions + help-fns-describe-variable-functions variable)) (with-current-buffer standard-output (help-fns--ensure-empty-line)) @@ -1223,6 +1234,15 @@ it is displayed along with the global value." ;; Return the text we displayed. (buffer-string)))))))) +(defun help-fns--run-describe-functions (functions &rest args) + (let ((help-fns--activated-functions nil)) + (dolist (func functions) + (let ((size (buffer-size standard-output))) + (apply func args) + ;; This function inserted something, so register it. + (when (> (buffer-size) size) + (push func help-fns--activated-functions)))))) + (add-hook 'help-fns-describe-variable-functions #'help-fns--customize-variable) (defun help-fns--customize-variable (variable &optional text) ;; Make a link to customize if this variable can be customized. @@ -1234,13 +1254,15 @@ it is displayed along with the global value." (re-search-backward (concat "\\(" customize-label "\\)") nil t) (help-xref-button 1 'help-customize-variable variable))) - (terpri)) + (terpri)))) + +(add-hook 'help-fns-describe-variable-functions + #'help-fns--customize-variable-version) +(defun help-fns--customize-variable-version (variable) + (when (custom-variable-p variable) ;; Note variable's version or package version. - (let ((output (describe-variable-custom-version-info variable))) - (when output - ;; (terpri) - ;; (terpri) - (princ output))))) + (when-let ((output (describe-variable-custom-version-info variable))) + (princ output)))) (add-hook 'help-fns-describe-variable-functions #'help-fns--var-safe-local) (defun help-fns--var-safe-local (variable) @@ -1479,7 +1501,8 @@ If FRAME is omitted or nil, use the selected frame." (terpri) (terpri)))) (terpri) - (run-hook-with-args 'help-fns-describe-face-functions f frame)))))) + (help-fns--run-describe-functions + help-fns-describe-face-functions f frame)))))) (add-hook 'help-fns-describe-face-functions #'help-fns--face-custom-version-info) commit 26d5b510e18e5a7729441e078459d0a9df0cbbcf Author: Stefan Kangas Date: Wed Sep 8 03:57:11 2021 +0200 Center Emacs logo above text on the splash screen * lisp/startup.el (fancy-splash-head): Center Emacs logo above text on the splash and about screen. diff --git a/lisp/startup.el b/lisp/startup.el index 58030ca06a..505d7b83f4 100644 --- a/lisp/startup.el +++ b/lisp/startup.el @@ -1788,9 +1788,19 @@ a face or button specification." (window-width (window-width))) (when img (when (> window-width image-width) - ;; Center the image in the window. - (insert (propertize " " 'display - `(space :align-to (+ center (-0.5 . ,img))))) + ;; Center the image above text. + ;; NB. The logo used to be centered in the window, which made + ;; it align poorly with the non-centered text on large + ;; displays. Arguably it would be better to center both + ;; text and image, but this will do for now. -- SK + (let ((text-width 80) + ;; The below value chosen to avoid splash screen being + ;; visually unbalanced. This needs to be eye-balled. + (adjust-left 3)) + (insert (propertize " " 'display + `(space :align-to (+ ,(- (/ text-width 2) + adjust-left) + (-0.5 . ,img)))))) ;; Change the color of the XPM version of the splash image ;; so that it is visible with a dark frame background. commit ff2c4a8353b93fe02501e3c51d18963ec75e3b7b Author: Dmitry Gutov Date: Wed Sep 8 02:33:24 2021 +0300 Have Git backend actions accept nil filenames again * lisp/vc/vc-git.el (vc-git--literal-pathspec): Move the nil check to the beginning (bug#50422). diff --git a/lisp/vc/vc-git.el b/lisp/vc/vc-git.el index 037fbcbc48..5835b5b92b 100644 --- a/lisp/vc/vc-git.el +++ b/lisp/vc/vc-git.el @@ -245,11 +245,12 @@ included in the completions." (defun vc-git--literal-pathspec (file) "Prepend :(literal) path magic to FILE." ;; Good example of file name that needs this: "test[56].xx". - (let ((lname (file-local-name file))) - ;; Expand abbreviated file names. - (when (file-name-absolute-p lname) - (setq lname (expand-file-name lname))) - (and file (concat ":(literal)" lname)))) + (when file + (let ((lname (file-local-name file))) + ;; Expand abbreviated file names. + (when (file-name-absolute-p lname) + (setq lname (expand-file-name lname))) + (concat ":(literal)" lname)))) (defun vc-git--literal-pathspecs (files) "Prepend :(literal) path magic to FILES." commit 81677cb6990a8afdea6d852a1e995139828dc8c8 Author: Harald Jörg Date: Tue Sep 7 22:11:41 2021 +0200 cperl-mode.el: Use rx sequences for Perl grammar Following advice by Mattias Engdegård, most uses of rx-to-string were eliminated, and rx sequences used instead to define Perl grammar components. * lisp/progmodes/cperl-mode.el: (cperl-block-declaration-p): New function, replaces regexp literals. (cperl-imenu--function-name-regexp-perl): Deleted, use rx sequences to find imenu entries instead. (cperl-indent-line): Use rx components instead of regexp literals. (cperl-sniff-for-indent): use `cperl-block-declaration-p' to increase accuracy, use rx sequence for labels to replace inaccurate regexp literals. (cperl-block-p): Replace inline comment by docstring. Use `cperl-block-declaration-p'. (cperl-after-block-p): Use `cperl-block-declaration-p'. (cperl-after-block-and-statement-beg): Replace inline comment by docstring. (cperl-imenu-package-keywords), (cperl-imenu-sub-keywords), (cperl-imenu-pod-keywords) : New variables to sort imenu entries into categories. (cperl-imenu--create-perl-index): Use rx sequences to collect imenu entries. (cperl-init-faces): Use rx components instead of regexp literals for labels. * test/lisp/progmodes/cperl-mode-tests.el: Test rx sequences instead of regexp strings diff --git a/lisp/progmodes/cperl-mode.el b/lisp/progmodes/cperl-mode.el index f518501c67..4f3ca924dd 100644 --- a/lisp/progmodes/cperl-mode.el +++ b/lisp/progmodes/cperl-mode.el @@ -1203,153 +1203,198 @@ The expansion is entirely correct because it uses the C preprocessor." ;; minimalistic Perl grammar, to be used instead of individual (and ;; not always consistent) literal regular expressions. -(defconst cperl--basic-identifier-regexp - (rx (sequence (or alpha "_") (* (or word "_")))) - "A regular expression for the name of a \"basic\" Perl variable. +;; This is necessary to compile this file under Emacs 26.1 +;; (there's no rx-define which would help) +(eval-and-compile + + (defconst cperl--basic-identifier-rx + '(sequence (or alpha "_") (* (or word "_"))) + "A regular expression for the name of a \"basic\" Perl variable. Neither namespace separators nor sigils are included. As is, this regular expression applies to labels,subroutine calls where the ampersand sigil is not required, and names of subroutine attributes.") -(defconst cperl--label-regexp - (rx-to-string - `(sequence - symbol-start - (regexp ,cperl--basic-identifier-regexp) - (0+ space) - ":")) - "A regular expression for a Perl label. + (defconst cperl--label-rx + `(sequence symbol-start + ,cperl--basic-identifier-rx + (0+ space) + ":") + "A regular expression for a Perl label. By convention, labels are uppercase alphabetics, but this isn't enforced.") -(defconst cperl--normal-identifier-regexp - (rx-to-string - `(or - (sequence - (1+ (sequence - (opt (regexp ,cperl--basic-identifier-regexp)) - "::")) - (opt (regexp ,cperl--basic-identifier-regexp))) - (regexp ,cperl--basic-identifier-regexp))) - "A regular expression for a Perl variable name with optional namespace. + (defconst cperl--false-label-rx + '(sequence (or (in "sym") "tr") (0+ space) ":") + "A regular expression which is similar to a label, but might as +well be a quote-like operator with a colon as delimiter.") + + (defconst cperl--normal-identifier-rx + `(or (sequence (1+ (sequence + (opt ,cperl--basic-identifier-rx) + "::")) + (opt ,cperl--basic-identifier-rx)) + ,cperl--basic-identifier-rx) + "A regular expression for a Perl variable name with optional namespace. Examples are `foo`, `Some::Module::VERSION`, and `::` (yes, that is a legal variable name).") -(defconst cperl--special-identifier-regexp - (rx-to-string - `(or - (1+ digit) ; $0, $1, $2, ... - (sequence "^" (any "A-Z" "]^_?\\")) ; $^V - (sequence "{" (0+ space) ; ${^MATCH} - "^" (any "A-Z" "]^_?\\") - (0+ (any "A-Z" "_" digit)) - (0+ space) "}") - (in "!\"$%&'()+,-./:;<=>?@\\]^_`|~"))) ; $., $|, $", ... but not $^ or ${ - "The list of Perl \"punctuation\" variables, as listed in perlvar.") - -(defconst cperl--ws-regexp - (rx-to-string - '(or space "\n")) - "Regular expression for a single whitespace in Perl.") - -(defconst cperl--eol-comment-regexp - (rx-to-string - '(sequence "#" (0+ (not (in "\n"))) "\n")) - "Regular expression for a single end-of-line comment in Perl") - -(defconst cperl--ws-or-comment-regexp - (rx-to-string - `(1+ - (or - (regexp ,cperl--ws-regexp) - (regexp ,cperl--eol-comment-regexp)))) - "Regular expression for a sequence of whitespace and comments in Perl.") - -(defconst cperl--ows-regexp - (rx-to-string - `(opt (regexp ,cperl--ws-or-comment-regexp))) - "Regular expression for optional whitespaces or comments in Perl") - -(defconst cperl--version-regexp - (rx-to-string - `(or - (sequence (opt "v") - (>= 2 (sequence (1+ digit) ".")) - (1+ digit) - (opt (sequence "_" (1+ word)))) - (sequence (1+ digit) - (opt (sequence "." (1+ digit))) - (opt (sequence "_" (1+ word)))))) - "A sequence for recommended version number schemes in Perl.") - -(defconst cperl--package-regexp - (rx-to-string - `(sequence - "package" ; FIXME: the "class" and "role" keywords need to be - ; recognized soon...ish. - (regexp ,cperl--ws-or-comment-regexp) - (group (regexp ,cperl--normal-identifier-regexp)) - (opt - (sequence - (regexp ,cperl--ws-or-comment-regexp) - (group (regexp ,cperl--version-regexp)))))) - "A regular expression for package NAME VERSION in Perl. -Contains two groups for the package name and version.") - -(defconst cperl--package-for-imenu-regexp - (rx-to-string - `(sequence - (regexp ,cperl--package-regexp) - (regexp ,cperl--ows-regexp) - (group (or ";" "{")))) - "A regular expression to collect package names for `imenu`. + (defconst cperl--special-identifier-rx + '(or + (1+ digit) ; $0, $1, $2, ... + (sequence "^" (any "A-Z" "]^_?\\")) ; $^V + (sequence "{" (0+ space) ; ${^MATCH} + "^" (any "A-Z" "]^_?\\") + (0+ (any "A-Z" "_" digit)) + (0+ space) "}") + (in "!\"$%&'()+,-./:;<=>?@\\]^_`|~")) ; $., $|, $", ... but not $^ or ${ + "The list of Perl \"punctuation\" variables, as listed in perlvar.") + + (defconst cperl--ws-rx + '(sequence (or space "\n")) + "Regular expression for a single whitespace in Perl.") + + (defconst cperl--eol-comment-rx + '(sequence "#" (0+ (not (in "\n"))) "\n") + "Regular expression for a single end-of-line comment in Perl") + + (defconst cperl--ws-or-comment-rx + `(or ,cperl--ws-rx + ,cperl--eol-comment-rx) + "A regular expression for either whitespace or comment") + + (defconst cperl--ws*-rx + `(0+ ,cperl--ws-or-comment-rx) + "Regular expression for optional whitespaces or comments in Perl") + + (defconst cperl--ws+-rx + `(1+ ,cperl--ws-or-comment-rx) + "Regular expression for a sequence of whitespace and comments in Perl.") + + ;; This is left as a string regexp. There are many version schemes in + ;; the wild, so people might want to fiddle with this variable. + (defconst cperl--version-regexp + (rx-to-string + `(or + (sequence (optional "v") + (>= 2 (sequence (1+ digit) ".")) + (1+ digit) + (optional (sequence "_" (1+ word)))) + (sequence (1+ digit) + (optional (sequence "." (1+ digit))) + (optional (sequence "_" (1+ word)))))) + "A sequence for recommended version number schemes in Perl.") + + (defconst cperl--package-rx + `(sequence (group "package") + ,cperl--ws+-rx + (group ,cperl--normal-identifier-rx) + (optional (sequence ,cperl--ws+-rx + (group (regexp ,cperl--version-regexp))))) + "A regular expression for package NAME VERSION in Perl. +Contains three groups for the keyword \"package\", for the +package name and for the version.") + + (defconst cperl--package-for-imenu-rx + `(sequence symbol-start + (group-n 1 "package") + ,cperl--ws*-rx + (group-n 2 ,cperl--normal-identifier-rx) + (optional (sequence ,cperl--ws+-rx + (regexp ,cperl--version-regexp))) + ,cperl--ws*-rx + (group-n 3 (or ";" "{"))) + "A regular expression to collect package names for `imenu`. Catches \"package NAME;\", \"package NAME VERSION;\", \"package NAME BLOCK\" and \"package NAME VERSION BLOCK.\" Contains three -groups: Two from `cperl--package-regexp` for the package name and -version, and a third to detect \"package BLOCK\" syntax.") - -(defconst cperl--sub-name-regexp - (rx-to-string - `(sequence - (optional (sequence (group (or "my" "state" "our")) - (regexp ,cperl--ws-or-comment-regexp))) - "sub" ; FIXME: the "method" and maybe "fun" keywords need to be - ; recognized soon...ish. - (regexp ,cperl--ws-or-comment-regexp) - (group (regexp ,cperl--normal-identifier-regexp)))) - "A regular expression to detect a subroutine start. -Contains two groups: One for to distinguish lexical from -\"normal\" subroutines and one for the subroutine name.") - -(defconst cperl--pod-heading-regexp - (rx-to-string - `(sequence - line-start "=head" - (group (in "1-4")) - (1+ (in " \t")) - (group (1+ (not (in "\n")))) - line-end)) ; that line-end seems to be redundant? +groups: One for the keyword \"package\", one for the package +name, and one for the discovery of a following BLOCK.") + + (defconst cperl--sub-name-for-imenu-rx + `(sequence symbol-start + (optional (sequence (group-n 3 (or "my" "state" "our")) + ,cperl--ws+-rx)) + (group-n 1 "sub") + ,cperl--ws+-rx + (group-n 2 ,cperl--normal-identifier-rx)) + "A regular expression to detect a subroutine start. +Contains three groups: One one to distinguish lexical from +\"normal\" subroutines, for the keyword \"sub\", and one for the +subroutine name.") + +(defconst cperl--block-declaration-rx + `(sequence + (or "package" "sub") ; "class" and "method" coming soon + (1+ ,cperl--ws-or-comment-rx) + ,cperl--normal-identifier-rx) + "A regular expression to find a declaration for a named block. +Used for indentation. These declarations introduce a block which +does not need a semicolon to terminate the statement.") + +(defconst cperl--pod-heading-rx + `(sequence line-start + (group-n 1 "=head") + (group-n 3 (in "1-4")) + (1+ (in " \t")) + (group-n 2 (1+ (not (in "\n"))))) "A regular expression to detect a POD heading. Contains two groups: One for the heading level, and one for the heading text.") -(defconst cperl--imenu-entries-regexp - (rx-to-string - `(or - (regexp ,cperl--package-for-imenu-regexp) ; 1..3 - (regexp ,cperl--sub-name-regexp) ; 4..5 - (regexp ,cperl--pod-heading-regexp))) ; 6..7 +(defconst cperl--imenu-entries-rx + `(or ,cperl--package-for-imenu-rx + ,cperl--sub-name-for-imenu-rx + ,cperl--pod-heading-rx) "A regular expression to collect stuff that goes into the `imenu` index. Covers packages, subroutines, and POD headings.") +;; end of eval-and-compiled stuff +) + + +(defun cperl-block-declaration-p () + "Test whether the following ?\\{ opens a declaration block. +Returns the column where the declarating keyword is found, or nil +if this isn't a declaration block. Declaration blocks are named +subroutines, packages and the like. They start with a keyword +and a name, to be followed by various descriptive items which are +just skipped over for our purpose. Declaration blocks end a +statement, so there's no semicolon." + ;; A scan error means that none of the declarators has been found + (condition-case nil + (let ((is-block-declaration nil) + (continue-searching t)) + (while (and continue-searching (not (bobp))) + (forward-sexp -1) + (cond + ((looking-at (rx (eval cperl--block-declaration-rx))) + (setq is-block-declaration (current-column) + continue-searching nil)) + ;; Another brace means this is no block declaration + ((looking-at "{") + (setq continue-searching nil)) + (t + (cperl-backward-to-noncomment (point-min)) + ;; A semicolon or an opening brace prevent this block from + ;; being a block declaration + (when (or (eq (preceding-char) ?\;) + (eq (preceding-char) ?{)) + (setq continue-searching nil))))) + is-block-declaration) + (error nil))) + ;; These two must be unwound, otherwise take exponential time -(defconst cperl-maybe-white-and-comment-rex "[ \t\n]*\\(#[^\n]*\n[ \t\n]*\\)*" +(defconst cperl-maybe-white-and-comment-rex + (rx (group (eval cperl--ws*-rx))) + ;; was: "[ \t\n]*\\(#[^\n]*\n[ \t\n]*\\)*" "Regular expression to match optional whitespace with interspersed comments. Should contain exactly one group.") ;; This one is tricky to unwind; still very inefficient... -(defconst cperl-white-and-comment-rex "\\([ \t\n]\\|#[^\n]*\n\\)+" +(defconst cperl-white-and-comment-rex + (rx (group (eval cperl--ws+-rx))) + ;; was: "\\([ \t\n]\\|#[^\n]*\n\\)+" "Regular expression to match whitespace with interspersed comments. Should contain exactly one group.") @@ -1405,28 +1450,9 @@ the last)." when (eq char (aref keyword (1- (length keyword)))) return t)) -;; Details of groups in this are used in `cperl-imenu--create-perl-index' -;; and `cperl-outline-level'. -;; Was: 2=sub|package; now 2=package-group, 5=package-name 8=sub-name (+3) -(defvar cperl-imenu--function-name-regexp-perl - (concat - "^\\(" ; 1 = all - "\\([ \t]*package" ; 2 = package-group - "\\(" ; 3 = package-name-group - cperl-white-and-comment-rex ; 4 = pre-package-name - "\\([a-zA-Z_0-9:']+\\)\\)?\\)" ; 5 = package-name - "\\|" - "[ \t]*" - cperl-sub-regexp - (cperl-after-sub-regexp 'named nil) ; 8=name 11=proto 14=attr-start - cperl-maybe-white-and-comment-rex ; 15=pre-block - "\\|" - "=head\\([1-4]\\)[ \t]+" ; 16=level - "\\([^\n]+\\)$" ; 17=text - "\\)")) - (defvar cperl-outline-regexp - (concat cperl-imenu--function-name-regexp-perl "\\|" "\\`")) + (rx (sequence line-start (0+ blank) (eval cperl--imenu-entries-rx))) + "The regular expression used for outline-minor-mode") (defvar cperl-mode-syntax-table nil "Syntax table in use in CPerl mode buffers.") @@ -2516,8 +2542,9 @@ Return the amount the indentation changed by." (t (skip-chars-forward " \t") (if (listp indent) (setq indent (car indent))) - (cond ((and (looking-at "[A-Za-z_][A-Za-z_0-9]*:[^:]") - (not (looking-at "[smy]:\\|tr:"))) + (cond ((and (looking-at (rx (sequence (eval cperl--label-rx) + (not (in ":"))))) + (not (looking-at (rx (eval cperl--false-label-rx))))) (and (> indent 0) (setq indent (max cperl-min-label-indent (+ indent cperl-label-offset))))) @@ -2709,6 +2736,8 @@ Will not look before LIM." (and (eq (preceding-char) ?\}) (cperl-after-block-and-statement-beg (point-min))) ; Was start - too close + (and char-after (char-equal char-after ?{) + (save-excursion (cperl-block-declaration-p))) (memq char-after (append ")]}" nil)) (and (eq (preceding-char) ?\:) ; label (progn @@ -2752,12 +2781,10 @@ Will not look before LIM." ;; Back up over label lines, since they don't ;; affect whether our line is a continuation. ;; (Had \, too) - (while;;(or (eq (preceding-char) ?\,) - (and (eq (preceding-char) ?:) - (or;;(eq (char-after (- (point) 2)) ?\') ; ???? - (memq (char-syntax (char-after (- (point) 2))) - '(?w ?_)))) - ;;) + (while (and (eq (preceding-char) ?:) + (re-search-backward + (rx (sequence (eval cperl--label-rx) point)) + nil t)) ;; This is always FALSE? (if (eq (preceding-char) ?\,) ;; Will go to beginning of line, essentially. @@ -2769,6 +2796,7 @@ Will not look before LIM." (if (not (or (eq (1- (point)) containing-sexp) (and cperl-indent-parens-as-block (not is-block)) + (save-excursion (cperl-block-declaration-p)) (memq (preceding-char) (append (if is-block " ;{" " ,;{") '(nil))) (and (eq (preceding-char) ?\}) @@ -2797,10 +2825,17 @@ Will not look before LIM." (forward-char 1) (let ((colon-line-end 0)) (while - (progn (skip-chars-forward " \t\n") - ;; s: foo : bar :x is NOT label - (and (looking-at "#\\|\\([a-zA-Z0-9_$]+\\):[^:]\\|=[a-zA-Z]") - (not (looking-at "[sym]:\\|tr:")))) + (progn + (skip-chars-forward " \t\n") + ;; s: foo : bar :x is NOT label + (and (looking-at + (rx + (or "#" + (sequence (eval cperl--label-rx) + (not (in ":"))) + (sequence "=" (in "a-zA-Z"))))) + (not (looking-at + (rx (eval cperl--false-label-rx)))))) ;; Skip over comments and labels following openbrace. (cond ((= (following-char) ?\#) (forward-line 1)) @@ -3059,7 +3094,10 @@ and closing parentheses and brackets." ;; If line starts with label, calculate label indentation (if (save-excursion (beginning-of-line) - (looking-at "[ \t]*[a-zA-Z_][a-zA-Z_0-9]*:[^:]")) + (looking-at (rx + (sequence (0+ space) + (eval cperl--label-rx) + (not (in ":")))))) (if (> (current-indentation) cperl-min-label-indent) (- (current-indentation) cperl-label-offset) ;; Do not move `parse-data', this should @@ -4768,15 +4806,19 @@ recursive calls in starting lines of here-documents." (if (< p (point)) (goto-char p)) (setq stop t)))))) -;; Used only in `cperl-calculate-indent'... +;; Used only in `cperl-sniff-for-indent'... (defun cperl-block-p () - "Point is before ?\\{. Checks whether it starts a block." + "Point is before ?\\{. Return true if it starts a block." ;; No save-excursion! This is more a distinguisher of a block/hash ref... (cperl-backward-to-noncomment (point-min)) (or (memq (preceding-char) (append ";){}$@&%\C-@" nil)) ; Or label! \C-@ at bobp ; Label may be mixed up with `$blah :' (save-excursion (cperl-after-label)) + ;; text with the 'attrib-group property is also covered by the + ;; next clause. We keep it because it is faster (for + ;; subroutines with attributes). (get-text-property (cperl-1- (point)) 'attrib-group) + (save-excursion (cperl-block-declaration-p)) (and (memq (char-syntax (preceding-char)) '(?w ?_)) (progn (backward-sexp) @@ -4814,6 +4856,7 @@ statement would start; thus the block in ${func()} does not count." (save-excursion (cperl-after-label)) ;; sub :attr {} (get-text-property (cperl-1- (point)) 'attrib-group) + (save-excursion (cperl-block-declaration-p)) (if (memq (char-syntax (preceding-char)) '(?w ?_)) ; else {} (save-excursion (forward-sexp -1) @@ -4929,7 +4972,8 @@ CHARS is a string that contains good characters to have before us (however, (skip-chars-forward " \t")) (defun cperl-after-block-and-statement-beg (lim) - ;; We assume that we are after ?\} + "Return true if the preceding ?} ends the statement." + ;; We assume that we are after ?\} (and (cperl-after-block-p lim) (save-excursion @@ -5405,6 +5449,10 @@ indentation and initial hashes. Behaves usually outside of comment." ;; Previous space could have gone: (or (memq (preceding-char) '(?\s ?\t)) (insert " ")))))) +(defvar cperl-imenu-package-keywords '("package" "class" "role")) +(defvar cperl-imenu-sub-keywords '("sub" "method" "function" "fun")) +(defvar cperl-imenu-pod-keywords '("=head")) + (defun cperl-imenu--create-perl-index () "Implement `imenu-create-index-function` for CPerl mode. This function relies on syntaxification to exclude lines which @@ -5423,20 +5471,21 @@ comment, or POD." (current-package "(main)") (current-package-end (point-max))) ; end of package scope ;; collect index entries - (while (re-search-forward cperl--imenu-entries-regexp nil t) + (while (re-search-forward (rx (eval cperl--imenu-entries-rx)) nil t) ;; First, check whether we have left the scope of previously ;; recorded packages, and if so, eliminate them from the stack. (while (< current-package-end (point)) (setq current-package (pop package-stack)) (setq current-package-end (pop package-stack))) (let ((state (syntax-ppss)) + (entry-type (match-string 1)) name marker) ; for the "current" entry (cond ((nth 3 state) nil) ; matched in a string, so skip - ((match-string 1) ; found a package name! + ((member entry-type cperl-imenu-package-keywords) ; package or class (unless (nth 4 state) ; skip if in a comment - (setq name (match-string-no-properties 1) - marker (copy-marker (match-end 1))) + (setq name (match-string-no-properties 2) + marker (copy-marker (match-end 2))) (if (string= (match-string 3) ";") (setq current-package name) ; package NAME; ;; No semicolon, therefore we have: package NAME BLOCK. @@ -5449,32 +5498,33 @@ comment, or POD." (setq current-package-end (save-excursion (goto-char (match-beginning 3)) (forward-sexp) - (point))) + (point)))) (push (cons name marker) index-package-alist) - (push (cons (concat "package " name) marker) index-unsorted-alist)))) - ((match-string 5) ; found a sub name! + (push (cons (concat entry-type " " name) marker) index-unsorted-alist))) + ((or (member entry-type cperl-imenu-sub-keywords) ; sub or method + (string-equal entry-type "")) ; named blocks (unless (nth 4 state) ; skip if in a comment - (setq name (match-string-no-properties 5) - marker (copy-marker (match-end 5))) + (setq name (match-string-no-properties 2) + marker (copy-marker (match-end 2))) ;; Qualify the sub name with the package if it doesn't ;; already have one, and if it isn't lexically scoped. ;; "my" and "state" subs are lexically scoped, but "our" ;; are just lexical aliases to package subs. (if (and (null (string-match "::" name)) - (or (null (match-string 4)) - (string-equal (match-string 4) "our"))) + (or (null (match-string 3)) + (string-equal (match-string 3) "our"))) (setq name (concat current-package "::" name))) (let ((index (cons name marker))) (push index index-alist) (push index index-sub-alist) (push index index-unsorted-alist)))) - ((match-string 6) ; found a POD heading! - (when (get-text-property (match-beginning 6) 'in-pod) + ((member entry-type cperl-imenu-pod-keywords) ; POD heading + (when (get-text-property (match-beginning 2) 'in-pod) (setq name (concat (make-string - (* 3 (- (char-after (match-beginning 6)) ?1)) + (* 3 (- (char-after (match-beginning 3)) ?1)) ?\ ) - (match-string-no-properties 7)) - marker (copy-marker (match-beginning 7))) + (match-string-no-properties 2)) + marker (copy-marker (match-beginning 2))) (push (cons name marker) index-pod-alist) (push (cons (concat "=" name) marker) index-unsorted-alist))) (t (error "Unidentified match: %s" (match-string 0)))))) @@ -5727,10 +5777,25 @@ function." 2 font-lock-string-face t))) '("[[ \t{,(]\\(-?[a-zA-Z0-9_:]+\\)[ \t]*=>" 1 font-lock-string-face t) - '("^[ \t]*\\([a-zA-Z0-9_]+[ \t]*:\\)[ \t]*\\($\\|{\\|\\<\\(until\\|while\\|for\\(each\\)?\\|do\\)\\>\\)" 1 - font-lock-constant-face) ; labels - '("\\<\\(continue\\|next\\|last\\|redo\\|break\\|goto\\)\\>[ \t]+\\([a-zA-Z0-9_:]+\\)" ; labels as targets - 2 font-lock-constant-face) + ;; labels + `(,(rx + (sequence + (0+ space) + (group (eval cperl--label-rx)) + (0+ space) + (or line-end "#" "{" + (sequence word-start + (or "until" "while" "for" "foreach" "do") + word-end)))) + 1 font-lock-constant-face) + ;; labels as targets (no trailing colon!) + `(,(rx + (sequence + symbol-start + (or "continue" "next" "last" "redo" "break" "goto") + (1+ space) + (group (eval cperl--basic-identifier-rx)))) + 1 font-lock-constant-face) ;; Uncomment to get perl-mode-like vars ;;; '("[$*]{?\\(\\sw+\\)" 1 font-lock-variable-name-face) ;;; '("\\([@%]\\|\\$#\\)\\(\\sw+\\)" diff --git a/test/lisp/progmodes/cperl-mode-tests.el b/test/lisp/progmodes/cperl-mode-tests.el index 5f3ba4d016..54012c3918 100644 --- a/test/lisp/progmodes/cperl-mode-tests.el +++ b/test/lisp/progmodes/cperl-mode-tests.el @@ -295,23 +295,23 @@ the whole string." (and (string-match regexp string) (string= (match-string 0 string) string)))))) -(ert-deftest cperl-test-ws-regexp () +(ert-deftest cperl-test-ws-rx () "Tests capture of very simple regular expressions (yawn)." (let ((valid '(" " "\t" "\n")) (invalid '("a" " " ""))) - (cperl-test--validate-regexp cperl--ws-regexp + (cperl-test--validate-regexp (rx (eval cperl--ws-rx)) valid invalid))) -(ert-deftest cperl-test-ws-or-comment-regexp () +(ert-deftest cperl-test-ws+-rx () "Tests sequences of whitespace and comment lines." (let ((valid `(" " "\t#\n" "\n# \n" ,(concat "# comment\n" "# comment\n" "\n" "#comment\n"))) (invalid '("=head1 NAME\n" ))) - (cperl-test--validate-regexp cperl--ws-or-comment-regexp + (cperl-test--validate-regexp (rx (eval cperl--ws+-rx)) valid invalid))) (ert-deftest cperl-test-version-regexp () @@ -343,7 +343,7 @@ Also includes valid cases with whitespace in strange places." "packageFoo" ; not a package declaration "package Foo1.1" ; invalid package name "class O3D::Sphere"))) ; class not yet supported - (cperl-test--validate-regexp cperl--package-regexp + (cperl-test--validate-regexp (rx (eval cperl--package-rx)) valid invalid))) ;;; Function test: Building an index for imenu commit 6cca705aa6b2ae93da8e0cd0da71f87fe583058c Author: Eric Abrahamsen Date: Tue Sep 7 11:51:39 2021 -0700 Don't let nndiary.el alter variables when loading file * lisp/gnus/nndiary.el (nndiary-open-server): Move the manipulation of `gnus-extra-headers' and `nnmail-extra-headers' into this function: it should only happen if we're actually firing up an nndiary server. Previously, simply attempting to complete a gnus-* prefixed symbol could end up loading this file, and changing the variable values. diff --git a/lisp/gnus/nndiary.el b/lisp/gnus/nndiary.el index adf4427523..133e0307a5 100644 --- a/lisp/gnus/nndiary.el +++ b/lisp/gnus/nndiary.el @@ -416,6 +416,11 @@ all. This may very well take some time.") (deffoo nndiary-open-server (server &optional defs) (nnoo-change-server 'nndiary server defs) + (dolist (header nndiary-headers) + (setq header (intern (format "X-Diary-%s" (car header)))) + ;; Required for building NOV databases and some other stuff. + (add-to-list 'gnus-extra-headers header) + (add-to-list 'nnmail-extra-headers header)) (when (not (file-exists-p nndiary-directory)) (ignore-errors (make-directory nndiary-directory t))) (cond @@ -1557,12 +1562,6 @@ all. This may very well take some time.") ;; The end... =============================================================== -(dolist (header nndiary-headers) - (setq header (intern (format "X-Diary-%s" (car header)))) - ;; Required for building NOV databases and some other stuff. - (add-to-list 'gnus-extra-headers header) - (add-to-list 'nnmail-extra-headers header)) - (unless (assoc "nndiary" gnus-valid-select-methods) (gnus-declare-backend "nndiary" 'post-mail 'respool 'address)) commit 0cd410fb82d780f3c3d3e870103344ca6ef83234 Author: Glenn Morris Date: Tue Sep 7 09:41:38 2021 -0700 ; Improve resolution of previous merge conflict diff --git a/doc/misc/efaq.texi b/doc/misc/efaq.texi index 5c26f8f756..9b8fc86508 100644 --- a/doc/misc/efaq.texi +++ b/doc/misc/efaq.texi @@ -364,19 +364,21 @@ The main ones are: @code{help-gnu-emacs}, @code{bug-gnu-emacs}, and @code{emacs-devel}. Messages advocating ``non-free'' software are considered unacceptable on -any of the @code{gnu.*} mailing lists (except for @url{https://lists.gnu.org/mailman/listinfo/gnu-misc-discuss, the gnu-misc-discuss mailing list}). +any of the GNU mailing lists, except for +@url{https://lists.gnu.org/mailman/listinfo/gnu-misc-discuss, +the gnu-misc-discuss mailing list}. ``Non-free'' software includes any software for which the end user can't freely modify the source code and exchange enhancements. Please remove GNU mailing lists from the recipients when posting a reply that recommends such software. @cindex newsgroups -Some of the GNU mailing lists are gatewayed to newsgroups. -The newsgroup @uref{news:comp.emacs} is for discussion of Emacs programs -in general. The newsgroup @uref{news:gnu.emacs.help} (i.e., the -@code{help-gnu-emacs} mailing list) is specifically -for GNU Emacs. It therefore makes no sense to cross-post to both -groups, since only one can be appropriate to any question. +Some of the GNU mailing lists are gatewayed to newsgroups (although +the connection is occasionally unreliable). +For example, sending an email to +@url{https://lists.gnu.org/mailman/listinfo/bug-gnu-emacs, The +bug-gnu-emacs list} has the effect of posting on the newsgroup +@uref{news:gnu.emacs.help}). Finally, we recommend reading the @url{https://www.gnu.org/philosophy/kind-communication.html, GNU Kind @@ -409,10 +411,6 @@ newsgroups. Please see the Emacs manual for information on how to report bugs. @xref{Checklist, , Checklist for Bug Reports, emacs, The GNU Emacs Manual}. -It is better to report bugs as described there than to ask on the help -mailing list. RMS says: - -@quotation Sending bug reports to @url{https://lists.gnu.org/mailman/listinfo/help-gnu-emacs, the help-gnu-emacs mailing list} is undesirable because it takes the time @@ -422,15 +420,10 @@ problem. @url{https://lists.gnu.org/mailman/listinfo/bug-gnu-emacs, The bug-gnu-emacs list} reaches a much smaller group of people who are more likely to know what to do and have expressed a wish to receive more messages about Emacs than the others. -@end quotation -RMS says it is sometimes fine to post to the help list: - -@quotation If you have reported a bug and you don't hear about a possible fix, then after a suitable delay (such as a week) it is okay to post on the help list asking if anyone can help you. -@end quotation If you are unsure whether you have found a bug, consider the following non-exhaustive list, courtesy of RMS: commit 400b3c9376a5de033f98476263b7fe65988289a8 Author: Alan Mackenzie Date: Tue Sep 7 16:31:16 2021 +0000 Increase jit-lock-chunk-size from 500 to 1500 for performance reasons * lisp/jit-lock.el (jit-lock-chunk-size): Increase to 1500. See also https://lists.gnu.org/archive/html/emacs-devel/2021-09/msg00540.html. diff --git a/lisp/jit-lock.el b/lisp/jit-lock.el index a905936b6b..c1a5bbe947 100644 --- a/lisp/jit-lock.el +++ b/lisp/jit-lock.el @@ -44,10 +44,13 @@ Preserves the `buffer-modified-p' state of the current buffer." :version "21.1" :group 'font-lock) -(defcustom jit-lock-chunk-size 500 +(defcustom jit-lock-chunk-size 1500 "Jit-lock fontifies chunks of at most this many characters at a time. -This variable controls both display-time and stealth fontification." +This variable controls both display-time and stealth fontification. + +The optimum value is a little over the typical number of buffer +characters which fit in a typical window." :type 'integer) commit 91afb9363de7f0c793f0b10414162ca82a5db821 Author: Eli Zaretskii Date: Tue Sep 7 19:22:48 2021 +0300 ; * doc/emacs/maintaining.texi (Project File Commands): Fix wording. diff --git a/doc/emacs/maintaining.texi b/doc/emacs/maintaining.texi index 578ef0c716..64221f19da 100644 --- a/doc/emacs/maintaining.texi +++ b/doc/emacs/maintaining.texi @@ -1752,7 +1752,7 @@ by the value of @code{xref-auto-jump-to-first-xref} (@pxref{Identifier Search}). @findex project-search - @kbd{M-x project-search} is an incremental variant of + @kbd{M-x project-search} is a sequential variant of @code{project-find-regexp}. It prompts for a regular expression to search in the current project's files, but instead of finding all the matches and displaying them, it stops when it finds a match and visits commit 743a53343c38fab5d1ff7f384b080def1ad2a2ef Author: Lars Ingebrigtsen Date: Tue Sep 7 17:46:52 2021 +0200 Encode urls more before using in browse-url * lisp/net/browse-url.el (browse-url-default-windows-browser) (browse-url-default-macosx-browser): Encode the URL before using (in case it contains spaces) (bug#50435). diff --git a/lisp/net/browse-url.el b/lisp/net/browse-url.el index b8e1f1bf12..bf77ecc7af 100644 --- a/lisp/net/browse-url.el +++ b/lisp/net/browse-url.el @@ -966,6 +966,7 @@ click but point is not changed." "Invoke the MS-Windows system's default Web browser. The optional NEW-WINDOW argument is not used." (interactive (browse-url-interactive-arg "URL: ")) + (setq url (browse-url-encode-url url)) (cond ((eq system-type 'ms-dos) (if dos-windows-version (shell-command (concat "start " (shell-quote-argument url))) @@ -995,6 +996,7 @@ The optional NEW-WINDOW argument is not used." "Invoke the macOS system's default Web browser. The optional NEW-WINDOW argument is not used." (interactive (browse-url-interactive-arg "URL: ")) + (setq url (browse-url-encode-url url)) (start-process (concat "open " url) nil "open" url)) (function-put 'browse-url-default-macosx-browser 'browse-url-browser-kind commit 8448782b40d0e186eb1cb094e0eea86370330d7e Author: Lars Ingebrigtsen Date: Tue Sep 7 17:41:31 2021 +0200 Fix encoding in browse-url-encode-url * lisp/net/browse-url.el (browse-url-url-encode-chars): Document what the argument really is, and simplify the implementation (bug#50435). (browse-url-encode-url): Encode spaces. diff --git a/lisp/net/browse-url.el b/lisp/net/browse-url.el index 73b8c439f2..b8e1f1bf12 100644 --- a/lisp/net/browse-url.el +++ b/lisp/net/browse-url.el @@ -692,16 +692,11 @@ alist is deprecated. Use `browse-url-handlers' instead.") (defun browse-url-url-encode-chars (text chars) "URL-encode the chars in TEXT that match CHARS. -CHARS is a regexp-like character alternative (e.g., \"[)$]\")." - (let ((encoded-text (copy-sequence text)) - (s 0)) - (while (setq s (string-match chars encoded-text s)) - (setq encoded-text - (replace-match (format "%%%X" - (string-to-char (match-string 0 encoded-text))) - t t encoded-text) - s (1+ s))) - encoded-text)) +CHARS is a regexp that matches a character." + (replace-regexp-in-string chars + (lambda (s) + (format "%%%X" (string-to-char s))) + text)) (defun browse-url-encode-url (url) "Escape annoying characters in URL. @@ -710,7 +705,7 @@ regarding its parameter treatment." ;; FIXME: Is there an actual example of a web browser getting ;; confused? (This used to encode commas, but at least Firefox ;; handles commas correctly and doesn't accept encoded commas.) - (browse-url-url-encode-chars url "[\")$] ")) + (browse-url-url-encode-chars url "[\"()$ ]")) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; URL input diff --git a/test/lisp/net/browse-url-tests.el b/test/lisp/net/browse-url-tests.el index 898bef8513..4264e03d91 100644 --- a/test/lisp/net/browse-url-tests.el +++ b/test/lisp/net/browse-url-tests.el @@ -68,11 +68,11 @@ (ert-deftest browse-url-tests-encode-url () (should (equal (browse-url-encode-url "") "")) - (should (equal (browse-url-encode-url "a b c") "a b c")) + (should (equal (browse-url-encode-url "a b c") "a%20b%20c")) (should (equal (browse-url-encode-url "\"a\" \"b\"") - "\"a%22\"b\"")) - (should (equal (browse-url-encode-url "(a) (b)") "(a%29(b)")) - (should (equal (browse-url-encode-url "a$ b$") "a%24b$"))) + "%22a%22%20%22b%22")) + (should (equal (browse-url-encode-url "(a) (b)") "%28a%29%20%28b%29")) + (should (equal (browse-url-encode-url "a$ b$") "a%24%20b%24"))) (ert-deftest browse-url-tests-url-at-point () (with-temp-buffer commit 6b2d5ad615fdcf14270a11af5a32b7fc3a964706 Author: Alex Bochannek Date: Tue Sep 7 17:12:39 2021 +0200 Add a new Gnus command to toggle whether to use fonts in shr * doc/misc/gnus.texi (Article Washing): Document it. * lisp/gnus/gnus-art.el (gnus-article-toggle-fonts): New command and key binding (bug#50383). diff --git a/doc/misc/gnus.texi b/doc/misc/gnus.texi index 5f3fba00df..b384764740 100644 --- a/doc/misc/gnus.texi +++ b/doc/misc/gnus.texi @@ -9374,6 +9374,12 @@ Use html2text---a simple @acronym{HTML} converter included with Gnus. @end table +@item W D F +@kindex W D F @r{(Summary)} +@findex gnus-article-toggle-fonts +Toggle proportional fonts for @acronym{HTML} articles. This temporarily +changes the @code{shr-use-fonts} variable in the current article buffer. + @item W b @kindex W b @r{(Summary)} @findex gnus-article-add-buttons diff --git a/lisp/gnus/gnus-art.el b/lisp/gnus/gnus-art.el index 3c1403e155..c4fa1e960b 100644 --- a/lisp/gnus/gnus-art.el +++ b/lisp/gnus/gnus-art.el @@ -2243,6 +2243,14 @@ This only works if the article in question is HTML." (funcall function (get-text-property start 'image-url) start end))))))) +(defun gnus-article-toggle-fonts () + "Toggle the use of proportional fonts for HTML articles." + (interactive nil gnus-article-mode gnus-summary-mode) + (gnus-with-article-buffer + (when (eq mm-text-html-renderer 'shr) + (setq-local shr-use-fonts (not shr-use-fonts)) + (gnus-summary-show-article)))) + (defun gnus-article-treat-fold-newsgroups () "Fold the Newsgroups and Followup-To message headers." (interactive nil gnus-article-mode gnus-summary-mode) diff --git a/lisp/gnus/gnus-sum.el b/lisp/gnus/gnus-sum.el index 856e95c0ba..c28e38e315 100644 --- a/lisp/gnus/gnus-sum.el +++ b/lisp/gnus/gnus-sum.el @@ -2252,6 +2252,7 @@ increase the score of each group you read." "s" gnus-treat-smiley "D" gnus-article-remove-images "W" gnus-article-show-images + "F" gnus-article-toggle-fonts "f" gnus-treat-from-picon "m" gnus-treat-mail-picon "n" gnus-treat-newsgroups-picon @@ -2561,6 +2562,7 @@ gnus-summary-show-article-from-menu-as-charset-%s" cs)))) ["Unfold headers" gnus-article-treat-unfold-headers t] ["Fold newsgroups" gnus-article-treat-fold-newsgroups t] ["Html" gnus-article-wash-html t] + ["Toggle HTML fonts" gnus-article-toggle-fonts t] ["Unsplit URLs" gnus-article-unsplit-urls t] ["Verify X-PGP-Sig" gnus-article-verify-x-pgp-sig t] ["Decode HZ" gnus-article-decode-HZ t] commit f10a4aad338255e9eed37b9ce3f2a82eb6d6553b Author: Lars Ingebrigtsen Date: Tue Sep 7 16:59:52 2021 +0200 Improve the Info mode line further * lisp/info.el (Info-set-mode-line): Improve the Info mode line further (bug#13776). diff --git a/lisp/info.el b/lisp/info.el index 5589321856..62202d342c 100644 --- a/lisp/info.el +++ b/lisp/info.el @@ -1735,10 +1735,12 @@ escaped (\\\",\\\\)." (if (stringp Info-current-file) (string-replace "%" "%%" - (file-name-sans-extension - (file-name-nondirectory Info-current-file))) + ;; Remove trailing ".info" and ".info.gz", etc. + (replace-regexp-in-string + "\\..*\\'" "" + (file-name-nondirectory Info-current-file))) (format "*%S*" Info-current-file)) - 'help-echo "Info file name") + 'help-echo "Manual name") ") ") (if Info-current-node (propertize (string-replace commit 4128186cc94891f486c98592eb11b0f4b634a7a9 Merge: 11b56fa0b4 f7c26e7b31 Author: Eli Zaretskii Date: Tue Sep 7 18:45:35 2021 +0300 Merge branch 'master' of git.savannah.gnu.org:/srv/git/emacs commit 11b56fa0b4d6245ee8312abe946266969a65fce8 Author: Eli Zaretskii Date: Tue Sep 7 18:44:26 2021 +0300 Fix a recent documentation change * lisp/progmodes/xref.el (xref-auto-jump-to-first-definition) (xref-auto-jump-to-first-xref): * etc/NEWS: Fix wording and typos. diff --git a/etc/NEWS b/etc/NEWS index 52a1443c16..2275fa43a6 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -2309,16 +2309,16 @@ before navigating to the selected location. +++ *** New user options to automatically show the first Xref match. The new user option 'xref-auto-jump-to-first-definition' controls the -behavior of 'xref-find-definitions' and related commands, like -'xref-find-definitions-other-windo': if it's t or 'show', the first +behavior of 'xref-find-definitions' and its variants, like +'xref-find-definitions-other-window': if it's t or 'show', the first match is automatically displayed; if it's 'move', point in the "*xref*" buffer is automatically moved to the first match without displaying it. The new user option 'xref-auto-jump-to-first-xref' changes the behavior of Xref commands such as 'xref-find-references', 'xref-find-apropos', and 'project-find-regexp', which are expected to -display many match that the user would like to -visit. 'xref-auto-jump-to-first-xref' changes their behavior muuch in +display many matches that the user would like to +visit. 'xref-auto-jump-to-first-xref' changes their behavior much in the same way as 'xref-auto-jump-to-first-definition' affects the "find-definitions" commands. diff --git a/lisp/progmodes/xref.el b/lisp/progmodes/xref.el index f6d88e13cc..082da1e1b7 100644 --- a/lisp/progmodes/xref.el +++ b/lisp/progmodes/xref.el @@ -421,7 +421,7 @@ elements is negated: these commands will NOT prompt." `show' means to show the first result's location, but keep the focus on the Xref buffer's window. `move' means to only move point to the first result. -This variable also affects commands similar to `xref-find-definitions', +This variable also affects the variants of `xref-find-definitions', such as `xref-find-definitions-other-window'." :type '(choice (const :tag "Jump" t) (const :tag "Show" show) @@ -435,7 +435,7 @@ such as `xref-find-definitions-other-window'." `show' means to show the first result's location, but keep the focus on the Xref buffer's window. `move' means to only move point to the first result. -This variable also affects commands similar to `xref-find-definitions', +This variable also affects commands similar to `xref-find-references', such as `xref-find-references-at-mouse', `xref-find-apropos', and `project-find-regexp'. commit f7c26e7b31047a20001eeac4c8973675c5620c58 Merge: 31db28b1bb 97aa8240d2 Author: Glenn Morris Date: Tue Sep 7 08:31:22 2021 -0700 Merge from origin/emacs-27 97aa8240d2 (origin/emacs-27) * doc/misc/efaq.texi: Misc copyedits. e1050492d1 * doc/misc/efaq.texi (Reporting bugs): Refer to the Emacs ... # Conflicts: # doc/misc/efaq.texi commit 31db28b1bb93980cf7a39458453b24b661894a92 Author: Michael Albinus Date: Tue Sep 7 16:28:41 2021 +0200 Adapt tramp-test26-file-name-completion * test/lisp/net/tramp-tests.el (tramp-test26-file-name-completion): Do not check for default method. diff --git a/test/lisp/net/tramp-tests.el b/test/lisp/net/tramp-tests.el index 27b37d4f19..54a585c88c 100644 --- a/test/lisp/net/tramp-tests.el +++ b/test/lisp/net/tramp-tests.el @@ -4281,12 +4281,8 @@ This tests also `make-symbolic-link', `file-truename' and `add-name-to-file'." ;; for completion. We must refill the cache. (tramp-set-connection-property tramp-test-vec "property" nil) - (let ;; This is needed for the `simplified' syntax. - ((method-marker - (if (zerop (length tramp-method-regexp)) - "" tramp-default-method-marker)) - ;; This is needed for the `separate' syntax. - (prefix-format (substring tramp-prefix-format 1)) + (let ;; This is needed for the `separate' syntax. + ((prefix-format (substring tramp-prefix-format 1)) ;; This is needed for the IPv6 host name syntax. (ipv6-prefix (and (string-match-p tramp-ipv6-regexp host) @@ -4302,22 +4298,6 @@ This tests also `make-symbolic-link', `file-truename' and `add-name-to-file'." (concat prefix-format method tramp-postfix-method-format) (file-name-all-completions (concat prefix-format (substring method 0 1)) "/")))) - ;; Complete host name for default method. With gvfs - ;; based methods, host name will be determined as - ;; host.local, so we omit the test. - (let ((tramp-default-method (or method tramp-default-method))) - (unless (or (zerop (length host)) - (tramp--test-gvfs-p tramp-default-method)) - (should - (member - (concat - prefix-format method-marker tramp-postfix-method-format - ipv6-prefix host ipv6-postfix tramp-postfix-host-format) - (file-name-all-completions - (concat - prefix-format method-marker tramp-postfix-method-format - ipv6-prefix (substring host 0 1)) - "/"))))) ;; Complete host name. (unless (or (zerop (length method)) (zerop (length tramp-method-regexp)) commit b02c9bccebb47ae83bfcca03d3f97db397861568 Author: Eli Zaretskii Date: Tue Sep 7 16:03:27 2021 +0300 Improve documentation of new Xref options * lisp/progmodes/xref.el (xref-auto-jump-to-first-definition) (xref-auto-jump-to-first-xref): More accurate description in the doc strings. * doc/emacs/maintaining.texi (Looking Up Identifiers) (Identifier Search, List Identifiers, Project File Commands): Fix the documentation of 'xref-auto-jump-to-first-definition' and 'xref-auto-jump-to-first-xref' to be more accurate. * etc/NEWS: More accurate wording of the entry about 'xref-auto-jump-to-first-definition' and 'xref-auto-jump-to-first-xref'. diff --git a/doc/emacs/maintaining.texi b/doc/emacs/maintaining.texi index 5b33c9bd3e..578ef0c716 100644 --- a/doc/emacs/maintaining.texi +++ b/doc/emacs/maintaining.texi @@ -1747,10 +1747,12 @@ commands (@pxref{Xref Commands}). When invoked with a prefix argument, this command additionally prompts for the base directory from which to start the search; this allows, for example, to limit the search only to project files under a certain subdirectory of the -project root. +project root. The way this command displays the matches is affected +by the value of @code{xref-auto-jump-to-first-xref} (@pxref{Identifier +Search}). @findex project-search - @kbd{M-x project-search} is an interactive variant of + @kbd{M-x project-search} is an incremental variant of @code{project-find-regexp}. It prompts for a regular expression to search in the current project's files, but instead of finding all the matches and displaying them, it stops when it finds a match and visits @@ -2155,20 +2157,11 @@ which these definitions are found. Selecting one of these candidates by typing @kbd{@key{RET}} or clicking @kbd{mouse-2} will pop a buffer showing the corresponding definition. If the value of the variable @code{xref-auto-jump-to-first-definition} is @code{move}, the first -candidate is automatically selected, and if it's @code{t} or -@code{show}, the first candidate is automatically shown. The default -value is @code{nil}, which just shows the candidates in the -@file{*xref*} buffer, but doesn't select any of them. - -@vindex xref-auto-jump-to-first-xref - If the value of the variable @code{xref-auto-jump-to-first-xref} is -@code{t}, @emph{all} Xref commands automatically jump to the first -result. If the value is @code{show}, the first result is shown, but -the window showing the @file{*xref*} buffer is left selected. If the -value is @code{move}, the first result is selected in the -@file{*xref*} buffer, but is not shown. The default value is -@code{nil}, which just shows the results in the @file{*xref*} buffer, -but doesn't select any of them. +of these candidates is automatically selected, and if it's @code{t} or +@code{show}, the first candidate is automatically shown; @code{t} also +selects the window showing the first candidate. The default value is +@code{nil}, which just shows the candidates in the @file{*xref*} +buffer, but doesn't select any of them. When entering the identifier argument to @kbd{M-.}, the usual minibuffer completion commands can be used (@pxref{Completion}), with @@ -2337,6 +2330,16 @@ identifier, showing the file name and the line where the identifier is referenced. The XREF mode commands are available in this buffer, see @ref{Xref Commands}. +@vindex xref-auto-jump-to-first-xref + If the value of the variable @code{xref-auto-jump-to-first-xref} is +@code{t}, @code{xref-find-references} automatically jumps to the first +result and selects the window where it is displayed. If the value is +@code{show}, the first result is shown, but the window showing the +@file{*xref*} buffer is left selected. If the value is @code{move}, +the first result is selected in the @file{*xref*} buffer, but is not +shown. The default value is @code{nil}, which just shows the results +in the @file{*xref*} buffer, but doesn't select any of them. + @findex xref-query-replace-in-results @kbd{M-x xref-query-replace-in-results} reads a regexp to match identifier names and a replacement string, just like ordinary @kbd{M-x @@ -2409,6 +2412,8 @@ selected tags table if one is loaded (@code{completion-at-point}). @item M-x xref-find-apropos @key{RET} @var{regexp} @key{RET} Display a list of all known identifiers matching @var{regexp}. +The way this command displays the matches is affected by the value of +@code{xref-auto-jump-to-first-xref} (@pxref{Identifier Search}). @item M-x list-tags @key{RET} @var{file} @key{RET} Display a list of the identifiers defined in the program file @@ -2435,10 +2440,9 @@ for the project to be available. @xref{Tags Tables}. If used interactively, the default tag is file name of the current buffer if used interactively. -@c Sadly, the new-and-improved Xref feature doesn't provide anything -@c close to the described below features of the now-obsoleted -@c tags-apropos. I'm leaving this here to encourage enhancements to -@c xref.el. +@c Sadly, the new-and-improved Xref feature doesn't provide some +@c of the features of the now-obsoleted tags-apropos. I'm leaving +@c this here to encourage enhancements to xref.el. @ignore @findex tags-apropos @vindex tags-apropos-verbose diff --git a/etc/NEWS b/etc/NEWS index 38a5749ec2..52a1443c16 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -2309,13 +2309,18 @@ before navigating to the selected location. +++ *** New user options to automatically show the first Xref match. The new user option 'xref-auto-jump-to-first-definition' controls the -behavior of 'xref-find-definitions' and related commands: if it's t or -'show', the first match is automatically displayed; if it's 'move', -point in the "*xref*" buffer is automatically moved to the first match -without displaying it. -The new user option 'xref-auto-jump-to-first-xref' changes the behavior of -all Xref commands in the same way as 'xref-auto-jump-to-first-definition' -affects the "find-definitions" commands. +behavior of 'xref-find-definitions' and related commands, like +'xref-find-definitions-other-windo': if it's t or 'show', the first +match is automatically displayed; if it's 'move', point in the +"*xref*" buffer is automatically moved to the first match without +displaying it. +The new user option 'xref-auto-jump-to-first-xref' changes the +behavior of Xref commands such as 'xref-find-references', +'xref-find-apropos', and 'project-find-regexp', which are expected to +display many match that the user would like to +visit. 'xref-auto-jump-to-first-xref' changes their behavior muuch in +the same way as 'xref-auto-jump-to-first-definition' affects the +"find-definitions" commands. *** New user options 'xref-search-program' and 'xref-search-program-alist'. So far 'grep' and 'ripgrep' are supported. 'ripgrep' seems to offer better diff --git a/lisp/progmodes/xref.el b/lisp/progmodes/xref.el index d022baaf04..f6d88e13cc 100644 --- a/lisp/progmodes/xref.el +++ b/lisp/progmodes/xref.el @@ -420,7 +420,9 @@ elements is negated: these commands will NOT prompt." "If t, `xref-find-definitions' always jumps to the first result. `show' means to show the first result's location, but keep the focus on the Xref buffer's window. -`move' means to only move point to the first result." +`move' means to only move point to the first result. +This variable also affects commands similar to `xref-find-definitions', +such as `xref-find-definitions-other-window'." :type '(choice (const :tag "Jump" t) (const :tag "Show" show) (const :tag "Move point only" move) @@ -429,13 +431,16 @@ focus on the Xref buffer's window. :package-version '(xref . "1.2.0")) (defcustom xref-auto-jump-to-first-xref nil - "If t, xref commands always jump to the first result. + "If t, `xref-find-references' always jumps to the first result. `show' means to show the first result's location, but keep the focus on the Xref buffer's window. `move' means to only move point to the first result. +This variable also affects commands similar to `xref-find-definitions', +such as `xref-find-references-at-mouse', `xref-find-apropos', +and `project-find-regexp'. -Please be careful changing this value if you are using Emacs 27 -or earlier: it can break dired-do-find-regexp-and-replace." +Please be careful when changing the value if you are using Emacs 27 +or earlier: it can break `dired-do-find-regexp-and-replace'." :type '(choice (const :tag "Jump" t) (const :tag "Show" show) (const :tag "Move point only" move) commit d5c6bf96256568e4654860a15ef37c03293ad71f Author: Michael Albinus Date: Tue Sep 7 14:36:06 2021 +0200 Do not expand default method, user, host in remote file name completion * lisp/net/tramp.el (tramp-completion-handle-file-name-all-completions): Do not expand default method, user, host. (Bug#50387) (tramp-get-completion-methods): `partial-method' can be nil. diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el index 9ed9da9243..0182248dfa 100644 --- a/lisp/net/tramp.el +++ b/lisp/net/tramp.el @@ -2821,6 +2821,15 @@ not in completion mode." "Like `file-name-all-completions' for partial Tramp files." (let ((fullname (tramp-drop-volume-letter (expand-file-name filename directory))) + ;; When `tramp-syntax' is `simplified', we need a default method. + (tramp-default-method + (and (zerop (length tramp-postfix-method-format)) + tramp-default-method)) + (tramp-default-method-alist + (and (zerop (length tramp-postfix-method-format)) + tramp-default-method-alist)) + tramp-default-user tramp-default-user-alist + tramp-default-host tramp-default-host-alist hop result result1) ;; Suppress hop from completion. @@ -3006,7 +3015,7 @@ remote host and localname (filename on remote host)." "Return all method completions for PARTIAL-METHOD." (mapcar (lambda (method) - (and method (string-prefix-p partial-method method) + (and method (string-prefix-p (or partial-method "") method) (tramp-completion-make-tramp-file-name method nil nil nil))) (mapcar #'car tramp-methods))) commit db74a93659d8a94b6f3db88ba1402ccf5edb32d3 Author: Eli Zaretskii Date: Tue Sep 7 13:24:01 2021 +0300 Fix display of tab-bar buttons * src/xterm.c (x_draw_image_relief): * src/w32term.c (w32_draw_image_relief): Fix calculation of relief thickness for tab-bar buttons. * lisp/tab-bar.el (tab-bar--load-buttons) (tab-bar-history-mode): Fix the :margin specification for tab-bar buttons. (Bug#50424) diff --git a/lisp/tab-bar.el b/lisp/tab-bar.el index 7f6afd7d53..cde9a32076 100644 --- a/lisp/tab-bar.el +++ b/lisp/tab-bar.el @@ -161,7 +161,7 @@ Possible modifier keys are `control', `meta', `shift', `hyper', `super' and (add-text-properties 0 (length tab-bar-new-button) `(display (image :type xpm :file "tabs/new.xpm" - :margin (2 . 0) + :margin ,tab-bar-button-margin :ascent center)) tab-bar-new-button)) @@ -171,7 +171,7 @@ Possible modifier keys are `control', `meta', `shift', `hyper', `super' and (add-text-properties 0 (length tab-bar-close-button) `(display (image :type xpm :file "tabs/close.xpm" - :margin (2 . 0) + :margin ,tab-bar-button-margin :ascent center)) tab-bar-close-button))) @@ -1597,7 +1597,7 @@ and can restore them." (add-text-properties 0 (length tab-bar-back-button) `(display (image :type xpm :file "tabs/left-arrow.xpm" - :margin (2 . 0) + :margin ,tab-bar-button-margin :ascent center)) tab-bar-back-button)) (when (and tab-bar-mode (not (get-text-property 0 'display tab-bar-forward-button))) @@ -1605,7 +1605,7 @@ and can restore them." (add-text-properties 0 (length tab-bar-forward-button) `(display (image :type xpm :file "tabs/right-arrow.xpm" - :margin (2 . 0) + :margin ,tab-bar-button-margin :ascent center)) tab-bar-forward-button)) diff --git a/src/w32term.c b/src/w32term.c index ad4d1a3282..ebd672361b 100644 --- a/src/w32term.c +++ b/src/w32term.c @@ -2031,11 +2031,14 @@ w32_draw_image_relief (struct glyph_string *s) if (s->hl == DRAW_IMAGE_SUNKEN || s->hl == DRAW_IMAGE_RAISED) { - thick = (tab_bar_button_relief < 0 - ? DEFAULT_TAB_BAR_BUTTON_RELIEF - : (tool_bar_button_relief < 0 - ? DEFAULT_TOOL_BAR_BUTTON_RELIEF - : min (tool_bar_button_relief, 1000000))); + if (s->face->id == TAB_BAR_FACE_ID) + thick = (tab_bar_button_relief < 0 + ? DEFAULT_TAB_BAR_BUTTON_RELIEF + : min (tab_bar_button_relief, 1000000)); + else + thick = (tool_bar_button_relief < 0 + ? DEFAULT_TOOL_BAR_BUTTON_RELIEF + : min (tool_bar_button_relief, 1000000)); raised_p = s->hl == DRAW_IMAGE_RAISED; } else diff --git a/src/xterm.c b/src/xterm.c index 1887c3255d..b478eff290 100644 --- a/src/xterm.c +++ b/src/xterm.c @@ -3209,11 +3209,14 @@ x_draw_image_relief (struct glyph_string *s) if (s->hl == DRAW_IMAGE_SUNKEN || s->hl == DRAW_IMAGE_RAISED) { - thick = (tab_bar_button_relief < 0 - ? DEFAULT_TAB_BAR_BUTTON_RELIEF - : (tool_bar_button_relief < 0 - ? DEFAULT_TOOL_BAR_BUTTON_RELIEF - : min (tool_bar_button_relief, 1000000))); + if (s->face->id == TAB_BAR_FACE_ID) + thick = (tab_bar_button_relief < 0 + ? DEFAULT_TAB_BAR_BUTTON_RELIEF + : min (tab_bar_button_relief, 1000000)); + else + thick = (tool_bar_button_relief < 0 + ? DEFAULT_TOOL_BAR_BUTTON_RELIEF + : min (tool_bar_button_relief, 1000000)); raised_p = s->hl == DRAW_IMAGE_RAISED; } else commit 55540a3d89862689340aa75d1370c3e8151ee934 Author: A Date: Mon Sep 6 19:12:00 2021 -0700 * test/lisp/vc/vc-tests.el (vc-test--version-diff): Git env tweak. diff --git a/test/lisp/vc/vc-tests.el b/test/lisp/vc/vc-tests.el index 4169a96670..aa401a2391 100644 --- a/test/lisp/vc/vc-tests.el +++ b/test/lisp/vc/vc-tests.el @@ -616,9 +616,17 @@ This checks also `vc-backend' and `vc-responsible-backend'." (setq tempdir (make-temp-file "vc-test--version-diff" t) process-environment (cons (format "BZR_HOME=%s" tempdir) process-environment))) + ;; git tries various approaches to guess a user name and email, + ;; which can fail depending on how the system is configured. + ;; Eg if the user account has no GECOS, git commit can fail with + ;; status 128 "fatal: empty ident name". (when (memq backend '(Bzr Git)) (setq process-environment (cons "EMAIL=john@doe.ee" process-environment))) + (if (eq backend 'Git) + (setq process-environment (append '("GIT_AUTHOR_NAME=A" + "GIT_COMMITTER_NAME=C") + process-environment))) (unwind-protect (progn ;; Cleanup. commit b52cafe49650f7b3398059e1655c77438b9cb125 Author: Dmitry Gutov Date: Tue Sep 7 04:44:38 2021 +0300 Support specifying just one command in project-switch-commands * lisp/progmodes/project.el (project-switch-commands): Describe the new possible type of value. (project--switch-project-command): New function, extract from project-switch-project. (project-switch-project): If project-switch-commands's value is a symbol, invoke that command without showing a menu. Co-authored-by: Jiacai Liu diff --git a/lisp/progmodes/project.el b/lisp/progmodes/project.el index b6eea7e27e..ba95ed094e 100644 --- a/lisp/progmodes/project.el +++ b/lisp/progmodes/project.el @@ -1344,17 +1344,22 @@ Each element is of the form (COMMAND LABEL &optional KEY) where COMMAND is the command to run when KEY is pressed. LABEL is used to distinguish the menu entries in the dispatch menu. If KEY is absent, COMMAND must be bound in `project-prefix-map', and the -key is looked up in that map." +key is looked up in that map. + +The value can also be a symbol, the name of the command to be +invoked immediately without any dispatch menu." :version "28.1" :group 'project :package-version '(project . "0.6.0") - :type '(repeat - (list - (symbol :tag "Command") - (string :tag "Label") - (choice :tag "Key to press" - (const :tag "Infer from the keymap" nil) - (character :tag "Explicit key"))))) + :type '(choice + (repeat :tag "Commands menu" + (list + (symbol :tag "Command") + (string :tag "Label") + (choice :tag "Key to press" + (const :tag "Infer from the keymap" nil) + (character :tag "Explicit key")))) + (symbol :tag "Single command"))) (defcustom project-switch-use-entire-map nil "Make `project-switch-project' use entire `project-prefix-map'. @@ -1384,15 +1389,7 @@ are legal even if they aren't listed in the dispatch menu." project-switch-commands " ")) -;;;###autoload -(defun project-switch-project (dir) - "\"Switch\" to another project by running an Emacs command. -The available commands are presented as a dispatch menu -made from `project-switch-commands'. - -When called in a program, it will use the project corresponding -to directory DIR." - (interactive (list (project-prompt-project-dir))) +(defun project--switch-project-command () (let* ((commands-menu (mapcar (lambda (row) @@ -1423,6 +1420,20 @@ to directory DIR." (when (memq global-command '(keyboard-quit keyboard-escape-quit)) (call-interactively global-command))))) + command)) + +;;;###autoload +(defun project-switch-project (dir) + "\"Switch\" to another project by running an Emacs command. +The available commands are presented as a dispatch menu +made from `project-switch-commands'. + +When called in a program, it will use the project corresponding +to directory DIR." + (interactive (list (project-prompt-project-dir))) + (let ((command (if (symbolp project-switch-commands) + project-switch-commands + (project--switch-project-command)))) (let ((default-directory dir) (project-current-inhibit-prompt t)) (call-interactively command)))) commit e09e8271458cee4de517cfc11ebe5eb4918e156d Author: Stefan Kangas Date: Tue Sep 7 03:17:27 2021 +0200 Small FAQ fixes * doc/misc/efaq.texi (Colors on a TTY): Remove reference to ancient Emacs version 22. (Finding Emacs on the Internet): Use more current terminology. diff --git a/doc/misc/efaq.texi b/doc/misc/efaq.texi index 1514dbe265..66f47cad43 100644 --- a/doc/misc/efaq.texi +++ b/doc/misc/efaq.texi @@ -1594,7 +1594,7 @@ capabilities. The command @kbd{M-x list-colors-display} pops up a window which exhibits all the colors Emacs knows about on the current display. -Syntax highlighting is on by default since version 22.1. +Syntax highlighting is on by default. @cindex direct color in terminals Emacs 26.1 and later support direct color mode in terminals. If Emacs @@ -3495,7 +3495,7 @@ problem (@pxref{Reporting bugs}). @cindex Downloading Emacs Information on downloading Emacs is available at -@uref{https://www.gnu.org/software/emacs/, the Emacs home-page}. +@uref{https://www.gnu.org/software/emacs/, the Emacs website}. @xref{Installing Emacs}, for information on how to obtain and build the latest version of Emacs, and see @ref{Current GNU distributions}, for a list of commit 4c54a6cd5da8f52d1d8e111c6b4b84a25d549d4d Author: Stefan Kangas Date: Tue Sep 7 02:55:16 2021 +0200 Remove Emacs FAQ maintainer * doc/misc/efaq.texi: Remove maintainer Romain Francoise after private communication. diff --git a/doc/misc/efaq.texi b/doc/misc/efaq.texi index d66c12f9fc..1514dbe265 100644 --- a/doc/misc/efaq.texi +++ b/doc/misc/efaq.texi @@ -7,10 +7,6 @@ @include emacsver.texi -@c This file is maintained by Romain Francoise . -@c Feel free to install changes without prior permission (but I'd -@c appreciate a notice if you do). - @copying Copyright @copyright{} 2001--2021 Free Software Foundation, Inc.@* Copyright @copyright{} 1994, 1995, 1996, 1997, 1998, 1999, 2000 commit 3a2c6417ccda56c80e5eb00e35a7860251648a3f Author: Stefan Kangas Date: Tue Sep 7 02:00:22 2021 +0200 * etc/NEWS: Some further re-organization. diff --git a/etc/NEWS b/etc/NEWS index 537480ce55..38a5749ec2 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -1536,11 +1536,6 @@ will now choose the completion under point instead. Also when this option is nil, completions are not shown when the minibuffer reads a file name with initial input as the default directory. -** mspool.el - ---- -*** Autoload the main entry point 'mspool-show'. - ** Windmove +++ @@ -1576,10 +1571,6 @@ This is a fully compatible change to the internal occur-mode implementation, and code creating their own occur-mode buffers will work as before. -** New minor mode 'cl-font-lock-built-in-mode' for 'lisp-mode'. -The mode provides refined highlighting of built-in functions, types, -and variables. - ** Emacs Lisp mode *** The mode-line now indicates whether we're using lexical or dynamic scoping. @@ -1589,6 +1580,17 @@ The presence of a space between an open paren and a symbol now is taken as a statement by the programmer that this should be indented as a data list rather than as a piece of code. +** Lisp Mode + +*** New minor mode 'cl-font-lock-built-in-mode' for 'lisp-mode'. +The mode provides refined highlighting of built-in functions, types, +and variables. + +--- +*** Lisp mode now uses 'common-lisp-indent-function'. +To revert to the previous behavior, +'(setq lisp-indent-function 'lisp-indent-function)' from 'lisp-mode-hook'. + ** Change Logs and VC +++ @@ -1858,11 +1860,6 @@ messages, and will then be used when sending with A server entry retrieved by auth-source can request a desired smtp authentication mechanism by setting a value for the key 'smtp-auth'. ---- -** Lisp mode now uses 'common-lisp-indent-function'. -To revert to the previous behavior, -'(setq lisp-indent-function 'lisp-indent-function)' from 'lisp-mode-hook'. - ** ElDoc +++ @@ -1956,13 +1953,6 @@ Writing auto-save, backup or lock files to the local temporary directory must be confirmed. In order to suppress this confirmation, set user option 'tramp-allow-unsafe-temporary-files' to t. -** Tempo - ---- -*** 'tempo-define-template' can now re-assign templates to tags. -Previously, assigning a new template to an already defined tag had no -effect. - ** gdb-mi *** New user option 'gdb-registers-enable-filter'. @@ -2118,30 +2108,6 @@ To enable, add it to appropriate entries in 'c-offsets-alist', e.g.: c-lineup-arglist)) (c-set-offset 'statement-cont '(c-lineup-ternary-bodies +)) -** SHR - ---- -*** The command 'shr-browse-url' now supports custom mailto handlers. -Clicking on or otherwise following a 'mailto:' link in a HTML buffer -rendered by SHR previously invoked the command 'browse-url-mailto'. -This is still the case by default, but if you customize -'browse-url-mailto-function' or 'browse-url-handlers' to call some -other function, it will now be called instead of the default. - -+++ -*** New user option 'shr-max-width'. -If this user option is non-nil, and 'shr-width' is nil, then SHR will -use the value of 'shr-max-width' to limit the width of the rendered -HTML. The default is 120 characters, so even if you have very wide -frames, HTML text will be rendered more narrowly, which usually leads -to a more readable text. Set this user option to nil to get the -previous behavior of rendering as wide as the 'window-width' allows. -If 'shr-width' is non-nil, it overrides this variable. - ---- -*** New faces for heading elements. -Those are 'shr-h1', 'shr-h2', 'shr-h3', 'shr-h4', 'shr-h5', 'shr-h6'. - ** Images --- @@ -2260,6 +2226,30 @@ The function that is invoked when clicking on or otherwise following a 'mailto:' link in an EWW buffer can now be customized. For more information, see the related entry about 'shr-browse-url' above. +** SHR + +--- +*** The command 'shr-browse-url' now supports custom mailto handlers. +Clicking on or otherwise following a 'mailto:' link in a HTML buffer +rendered by SHR previously invoked the command 'browse-url-mailto'. +This is still the case by default, but if you customize +'browse-url-mailto-function' or 'browse-url-handlers' to call some +other function, it will now be called instead of the default. + ++++ +*** New user option 'shr-max-width'. +If this user option is non-nil, and 'shr-width' is nil, then SHR will +use the value of 'shr-max-width' to limit the width of the rendered +HTML. The default is 120 characters, so even if you have very wide +frames, HTML text will be rendered more narrowly, which usually leads +to a more readable text. Set this user option to nil to get the +previous behavior of rendering as wide as the 'window-width' allows. +If 'shr-width' is non-nil, it overrides this variable. + +--- +*** New faces for heading elements. +Those are 'shr-h1', 'shr-h2', 'shr-h3', 'shr-h4', 'shr-h5', 'shr-h6'. + ** Project *** New user option 'project-vc-merge-submodules'. @@ -2438,20 +2428,6 @@ This face is used for error messages from 'diff'. *** New command 'diff-refresh-hunk'. This new command (bound to 'C-c C-l') regenerates the current hunk. -** Buttons - -+++ -*** New minor mode 'button-mode'. -This minor mode does nothing else than install 'button-buffer-map' as -a minor mode map (which binds the 'TAB' / 'S-TAB' key bindings to navigate -to buttons), and can be used in any view-mode-like buffer that has -buttons in it. - -+++ -*** New utility function 'button-buttonize'. -This function takes a string and returns a string propertized in a way -that makes it a valid button. - ** thing-at-point +++ @@ -2577,7 +2553,7 @@ sequences. *** 'comint-delete-output' can now save deleted text in the kill-ring. Interactively, 'C-u C-c C-o' triggers this new optional behavior. -** erc +** ERC --- *** erc-services.el now supports NickServ passwords from auth-source. @@ -2761,6 +2737,11 @@ The new commands 'doc-view-center-page-horizontally' (bound to 'c h') and 'doc-view-center-page-vertically' (bound to 'c v') center the page horizontally and vertically, respectively. +--- +*** 'tempo-define-template' can now re-assign templates to tags. +Previously, assigning a new template to an already defined tag had no +effect. + --- *** The width of the buffer-name column in 'list-buffers' is now dynamic. The width now depends of the width of the window, but will never be @@ -2778,6 +2759,9 @@ different timezone causing a difference in the date. --- *** The old non-SMIE indentation of 'sh-mode' has been removed. +--- +*** 'mspools-show' is now autoloaded. + *** Loading dunnet.el in batch mode doesn't start the game any more. Instead you need to do "emacs -f dun-batch" to start the game in batch mode. @@ -3955,6 +3939,20 @@ They carry now the destination and the error-name of an event. They also keep the type information of their arguments. Use the 'dbus-event-*' accessor functions. +** Buttons + ++++ +*** New minor mode 'button-mode'. +This minor mode does nothing else than install 'button-buffer-map' as +a minor mode map (which binds the 'TAB' / 'S-TAB' key bindings to navigate +to buttons), and can be used in any view-mode-like buffer that has +buttons in it. + ++++ +*** New utility function 'button-buttonize'. +This function takes a string and returns a string propertized in a way +that makes it a valid button. + --- ** 'text-scale-mode' can now adjust font size of the header line. When the new buffer local variable 'text-scale-remap-header-line' commit 4bd3a40ee3afdafe846362425fd4528c31848134 Author: Stefan Kangas Date: Tue Sep 7 01:48:40 2021 +0200 * etc/NEWS: Clarify entry about the "*Completions*" buffer. diff --git a/etc/NEWS b/etc/NEWS index 773e1e387f..537480ce55 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -1463,6 +1463,8 @@ passed to the browser. This support has been obsolete since 25.1. ** Completion List Mode + +*** Improved navigation in the "*Completions*" buffer. New key bindings have been added to 'completion-list-mode': 'n' and 'p' now navigate completions, and 'M-g M-c' switches to the minibuffer and back to the completion list buffer. commit 163e3052c8ffd840c41b638dc15a9b1a5922642f Author: Tassilo Horn Date: Mon Sep 6 21:47:38 2021 +0200 Add possibility to override the default highlighting * lisp/progmodes/bug-reference.el (bug-reference-fontify): Highlight 99th group if it exists. (bug-reference-bug-regexp): Document that regexp group 99 can be used to override the default behavior of highlighting the complete match. (bug-reference--run-auto-setup): Use run-hook-with-args-until-success instead of throw/catch. diff --git a/lisp/progmodes/bug-reference.el b/lisp/progmodes/bug-reference.el index c0c9d5e659..33548344f3 100644 --- a/lisp/progmodes/bug-reference.el +++ b/lisp/progmodes/bug-reference.el @@ -74,7 +74,20 @@ so that it is considered safe, see `enable-local-variables'.") (defcustom bug-reference-bug-regexp "\\([Bb]ug ?#?\\|[Pp]atch ?#\\|RFE ?#\\|PR [a-z+-]+/\\)\\([0-9]+\\(?:#[0-9]+\\)?\\)" "Regular expression matching bug references. -The second subexpression should match the bug reference (usually a number)." +The second subexpression should match the bug reference (usually +a number). + +The complete expression's matches will be highlighted unless +there is a 99th subexpression. In that case, only the matches of +that will be highlighted. For example, this can be used to +define that bug references at the beginning of a line must not be +matched by using a regexp like + + \"[^\\n]\\\\(?99:\\\\([Bb]ug ?\\\\)\\\\(#[0-9]+\\\\)\\\\)\" + +If there wasn't this explicitly numbered group 99, the +non-newline character before the actual bug reference would be +highlighted, too." :type 'regexp :version "24.3") ; previously defconst @@ -113,7 +126,13 @@ The second subexpression should match the bug reference (usually a number)." (when (or (not bug-reference-prog-mode) ;; This tests for both comment and string syntax. (nth 8 (syntax-ppss))) - (let ((overlay (make-overlay (match-beginning 0) (match-end 0) + ;; We highlight the 99th subexpression if that exists, + ;; otherwise the complete match. See the docstring of + ;; `bug-reference-bug-regexp'. + (let ((overlay (make-overlay (or (match-beginning 99) + (match-beginning 0)) + (or (match-end 99) + (match-end 0)) nil t nil))) (overlay-put overlay 'category 'bug-reference) ;; Don't put a link if format is undefined @@ -564,10 +583,8 @@ guesswork is based on these variables: bug-reference-url-format) (with-demoted-errors "Error during bug-reference auto-setup: %S" - (catch 'setup - (dolist (f bug-reference-auto-setup-functions) - (when (funcall f) - (throw 'setup t)))))))) + (run-hook-with-args-until-success + 'bug-reference-auto-setup-functions))))) ;;;###autoload (define-minor-mode bug-reference-mode commit 96e50693fc1c4f34ccc227d90f4bdc87feace637 Author: Mattias Engdegård Date: Mon Sep 6 19:24:53 2021 +0200 ; * etc/NEWS: revert a change that changed the meaning slightly diff --git a/etc/NEWS b/etc/NEWS index f033176e9f..773e1e387f 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -2263,7 +2263,7 @@ information, see the related entry about 'shr-browse-url' above. *** New user option 'project-vc-merge-submodules'. *** Project commands now have their own history. -Previously, used project directories are now suggested by all commands +Previously used project directories are now suggested by all commands that prompt for a project directory. +++ commit c4724add006e62b81f847937db56335a81bdcc74 Author: Mattias Engdegård Date: Mon Sep 6 14:41:26 2021 +0200 Normalise nested `progn` forms in byte-code optimiser * lisp/emacs-lisp/byte-opt.el (byte-optimize-body): Flatten body. This simplifies the source tree and reduces the number of different cases that other optimisations need to take into account. diff --git a/lisp/emacs-lisp/byte-opt.el b/lisp/emacs-lisp/byte-opt.el index 23c5a566ce..ff512cca36 100644 --- a/lisp/emacs-lisp/byte-opt.el +++ b/lisp/emacs-lisp/byte-opt.el @@ -727,8 +727,12 @@ Same format as `byte-optimize--lexvars', with shared structure and contents.") (while rest (setq fe (or all-for-effect (cdr rest))) (setq new (and (car rest) (byte-optimize-form (car rest) fe))) - (if (or new (not fe)) - (setq result (cons new result))) + (when (and (consp new) (eq (car new) 'progn)) + ;; Flatten `progn' form into the body. + (setq result (append (reverse (cdr new)) result)) + (setq new (pop result))) + (when (or new (not fe)) + (setq result (cons new result))) (setq rest (cdr rest))) (nreverse result))) commit bba48d6ee5d90f326c70cbe8af19dfe6b00651ba Author: Mattias Engdegård Date: Thu Jun 10 21:27:16 2021 +0200 More robust optimisation of `ignore` Treat `ignore` as any other function during source-level optimisation, to avoid having its warning-suppression effects cancelled by repeated passes. Instead, define a custom code generation function. * lisp/emacs-lisp/byte-opt.el (byte-optimize-form-code-walker): Don't treat `ignore' specially here. (side-effect-free-fns): Don't mark `ignore` as side-effect-free or error-free (although it is), since that would allow the optimiser to elide calls. * lisp/emacs-lisp/bytecomp.el (ignore, byte-compile-ignore): Define and register a code-gen function. diff --git a/lisp/emacs-lisp/byte-opt.el b/lisp/emacs-lisp/byte-opt.el index 0c30d83f06..23c5a566ce 100644 --- a/lisp/emacs-lisp/byte-opt.el +++ b/lisp/emacs-lisp/byte-opt.el @@ -562,13 +562,6 @@ Same format as `byte-optimize--lexvars', with shared structure and contents.") `(catch ,(byte-optimize-form tag nil) . ,(byte-optimize-body exps for-effect)))) - (`(ignore . ,exps) - ;; Don't treat the args to `ignore' as being - ;; computed for effect. We want to avoid the warnings - ;; that might occur if they were treated that way. - ;; However, don't actually bother calling `ignore'. - `(progn ,@(mapcar #'byte-optimize-form exps) nil)) - ;; Needed as long as we run byte-optimize-form after cconv. (`(internal-make-closure . ,_) ;; Look up free vars and mark them to be kept, so that they @@ -1419,7 +1412,9 @@ See Info node `(elisp) Integer Basics'." fixnump floatp following-char framep get-largest-window get-lru-window hash-table-p - identity ignore integerp integer-or-marker-p interactive-p + ;; `ignore' isn't here because we don't want calls to it elided; + ;; see `byte-compile-ignore'. + identity integerp integer-or-marker-p interactive-p invocation-directory invocation-name keymapp keywordp list listp diff --git a/lisp/emacs-lisp/bytecomp.el b/lisp/emacs-lisp/bytecomp.el index 145cdbaa6e..8ea591b5d0 100644 --- a/lisp/emacs-lisp/bytecomp.el +++ b/lisp/emacs-lisp/bytecomp.el @@ -4207,6 +4207,7 @@ discarding." (byte-defop-compiler-1 funcall) (byte-defop-compiler-1 let) (byte-defop-compiler-1 let* byte-compile-let) +(byte-defop-compiler-1 ignore) (defun byte-compile-progn (form) (byte-compile-body-do-effect (cdr form))) @@ -4222,6 +4223,11 @@ discarding." (if ,discard 'byte-goto-if-nil 'byte-goto-if-nil-else-pop)) ,tag)) +(defun byte-compile-ignore (form) + (dolist (arg (cdr form)) + (byte-compile-form arg t)) + (byte-compile-form nil)) + ;; Return the list of items in CONDITION-PARAM that match PRED-LIST. ;; Only return items that are not in ONLY-IF-NOT-PRESENT. (defun byte-compile-find-bound-condition (condition-param commit fab1e220dbe38ab7a2f46b673dfc03964e496798 Author: Mattias Engdegård Date: Wed Jul 28 21:07:58 2021 +0200 Optimise `member` and `assoc` (etc) with constant empty list * lisp/emacs-lisp/byte-opt.el (byte-optimize-assq): New. (byte-optimize-member, byte-optimize-assoc, byte-optimize-memq): When the list argument is constant nil, the result is always nil. * test/lisp/emacs-lisp/bytecomp-tests.el (bytecomp-tests--test-cases): Add test cases. diff --git a/lisp/emacs-lisp/byte-opt.el b/lisp/emacs-lisp/byte-opt.el index 6475f69ede..0c30d83f06 100644 --- a/lisp/emacs-lisp/byte-opt.el +++ b/lisp/emacs-lisp/byte-opt.el @@ -967,24 +967,25 @@ See Info node `(elisp) Integer Basics'." (_ (byte-optimize-binary-predicate form)))) (defun byte-optimize-member (form) - ;; Replace `member' or `memql' with `memq' if the first arg is a symbol, - ;; or the second arg is a list of symbols. Same with fixnums. - (if (= (length (cdr form)) 2) - (if (or (byte-optimize--constant-symbol-p (nth 1 form)) - (byte-optimize--fixnump (nth 1 form)) - (let ((arg2 (nth 2 form))) - (and (macroexp-const-p arg2) - (let ((listval (eval arg2))) - (and (listp listval) - (not (memq nil (mapcar - (lambda (o) - (or (symbolp o) - (byte-optimize--fixnump o))) - listval)))))))) - (cons 'memq (cdr form)) - form) - ;; Arity errors reported elsewhere. - form)) + (cond + ((/= (length (cdr form)) 2) form) ; arity error + ((null (nth 2 form)) ; empty list + `(progn ,(nth 1 form) nil)) + ;; Replace `member' or `memql' with `memq' if the first arg is a symbol + ;; or fixnum, or the second arg is a list of symbols or fixnums. + ((or (byte-optimize--constant-symbol-p (nth 1 form)) + (byte-optimize--fixnump (nth 1 form)) + (let ((arg2 (nth 2 form))) + (and (macroexp-const-p arg2) + (let ((listval (eval arg2))) + (and (listp listval) + (not (memq nil (mapcar + (lambda (o) + (or (symbolp o) + (byte-optimize--fixnump o))) + listval)))))))) + (cons 'memq (cdr form))) + (t form))) (defun byte-optimize-assoc (form) ;; Replace 2-argument `assoc' with `assq', `rassoc' with `rassq', @@ -992,22 +993,35 @@ See Info node `(elisp) Integer Basics'." (cond ((/= (length form) 3) form) + ((null (nth 2 form)) ; empty list + `(progn ,(nth 1 form) nil)) ((or (byte-optimize--constant-symbol-p (nth 1 form)) (byte-optimize--fixnump (nth 1 form))) (cons (if (eq (car form) 'assoc) 'assq 'rassq) (cdr form))) (t (byte-optimize-constant-args form)))) +(defun byte-optimize-assq (form) + (cond + ((/= (length form) 3) + form) + ((null (nth 2 form)) ; empty list + `(progn ,(nth 1 form) nil)) + (t (byte-optimize-constant-args form)))) + (defun byte-optimize-memq (form) - ;; (memq foo '(bar)) => (and (eq foo 'bar) '(bar)) (if (= (length (cdr form)) 2) (let ((list (nth 2 form))) - (if (and (eq (car-safe list) 'quote) - (listp (setq list (cadr list))) - (= (length list) 1)) - `(and (eq ,(nth 1 form) ',(nth 0 list)) - ',list) - form)) + (cond + ((null list) ; empty list + `(progn ,(nth 1 form) nil)) + ;; (memq foo '(bar)) => (and (eq foo 'bar) '(bar)) + ((and (eq (car-safe list) 'quote) + (listp (setq list (cadr list))) + (= (length list) 1)) + `(and (eq ,(nth 1 form) ',(nth 0 list)) + ',list)) + (t form))) ;; Arity errors reported elsewhere. form)) @@ -1044,6 +1058,8 @@ See Info node `(elisp) Integer Basics'." (put 'member 'byte-optimizer #'byte-optimize-member) (put 'assoc 'byte-optimizer #'byte-optimize-assoc) (put 'rassoc 'byte-optimizer #'byte-optimize-assoc) +(put 'assq 'byte-optimizer #'byte-optimize-assq) +(put 'rassq 'byte-optimizer #'byte-optimize-assq) (put '+ 'byte-optimizer #'byte-optimize-plus) (put '* 'byte-optimizer #'byte-optimize-multiply) diff --git a/test/lisp/emacs-lisp/bytecomp-tests.el b/test/lisp/emacs-lisp/bytecomp-tests.el index 80003c264a..ac96494cab 100644 --- a/test/lisp/emacs-lisp/bytecomp-tests.el +++ b/test/lisp/emacs-lisp/bytecomp-tests.el @@ -536,6 +536,21 @@ (let ((_a 1) (_b 2)) 'z) + + ;; Check empty-list optimisations. + (mapcar (lambda (x) (member x nil)) '("a" 2 nil)) + (mapcar (lambda (x) (memql x nil)) '(a 2 nil)) + (mapcar (lambda (x) (memq x nil)) '(a nil)) + (let ((n 0)) + (list (mapcar (lambda (x) (member (setq n (1+ n)) nil)) '(a "nil")) + n)) + (mapcar (lambda (x) (assoc x nil)) '("a" nil)) + (mapcar (lambda (x) (assq x nil)) '(a nil)) + (mapcar (lambda (x) (rassoc x nil)) '("a" nil)) + (mapcar (lambda (x) (rassq x nil)) '(a nil)) + (let ((n 0)) + (list (mapcar (lambda (x) (assoc (setq n (1+ n)) nil)) '(a "nil")) + n)) ) "List of expressions for cross-testing interpreted and compiled code.") commit ba6df554755e1989670e23220d2d14bc8e389274 Author: Dmitry Gutov Date: Mon Sep 6 17:07:25 2021 +0300 Fixup dired-do-find-regexp-and-replace * lisp/dired-aux.el (dired-do-find-regexp-and-replace): Disregard the customized value of xref-auto-jump-to-first-xref (it breaks the xref-query-replace-in-results invocation). * lisp/progmodes/xref.el (xref-auto-jump-to-first-xref): Mention the caveat for users or xref distributed through ELPA. diff --git a/lisp/dired-aux.el b/lisp/dired-aux.el index 8e00af8f96..c728642917 100644 --- a/lisp/dired-aux.el +++ b/lisp/dired-aux.el @@ -3245,10 +3245,13 @@ REGEXP should use constructs supported by your local `grep' command." (list (nth 0 common) (nth 1 common)))) (require 'xref) (defvar xref-show-xrefs-function) + (defvar xref-auto-jump-to-first-xref) (with-current-buffer (let ((xref-show-xrefs-function ;; Some future-proofing (bug#44905). - (custom--standard-value 'xref-show-xrefs-function))) + (custom--standard-value 'xref-show-xrefs-function)) + ;; Disable auto-jumping, it will mess up replacement logic. + xref-auto-jump-to-first-xref) (dired-do-find-regexp from)) (xref-query-replace-in-results from to))) diff --git a/lisp/progmodes/xref.el b/lisp/progmodes/xref.el index ec8b05d294..d022baaf04 100644 --- a/lisp/progmodes/xref.el +++ b/lisp/progmodes/xref.el @@ -432,7 +432,10 @@ focus on the Xref buffer's window. "If t, xref commands always jump to the first result. `show' means to show the first result's location, but keep the focus on the Xref buffer's window. -`move' means to only move point to the first result." +`move' means to only move point to the first result. + +Please be careful changing this value if you are using Emacs 27 +or earlier: it can break dired-do-find-regexp-and-replace." :type '(choice (const :tag "Jump" t) (const :tag "Show" show) (const :tag "Move point only" move) commit 9ff425d16fe956a8e4c9a22379c4444d8c96bc0d Author: Michael Albinus Date: Mon Sep 6 15:16:51 2021 +0200 Revert an accidential change in etc/NEWS diff --git a/etc/NEWS b/etc/NEWS index 6c5eeef64c..f033176e9f 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -3354,7 +3354,7 @@ initial frame used in batch mode. +++ ** Doc strings can now link to customization groups. -Text like "customization group 'whitespace'" will be made into a +Text like "customization group `whitespace'" will be made into a button. When clicked, it'll take the user to a Custom buffer displaying that customization group. commit 5f5623981cf38b798a37f42ed2b752018c7cc255 Author: Michael Albinus Date: Mon Sep 6 15:06:07 2021 +0200 ; Fix typos in etc/NEWS diff --git a/etc/NEWS b/etc/NEWS index b7dc8f4327..6c5eeef64c 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -245,7 +245,7 @@ symbolic links, and 'file-precious-flag' is non-nil. +++ ** New user option 'copy-directory-create-symlink'. -If non-nil, will make `copy-directory' (when used on a symbolic +If non-nil, will make 'copy-directory' (when used on a symbolic link) copy the link instead of following the link. The default is nil, so the default behavior is unchanged. @@ -336,7 +336,7 @@ window after deleting the currently selected one. +++ *** New argument NO-OTHER for some window functions. -'get-lru-window', ‘get-mru-window’ and 'get-largest-window' now accept a +'get-lru-window', 'get-mru-window' and 'get-largest-window' now accept a new optional argument NO-OTHER which, if non-nil, avoids returning a window whose 'no-other-window' parameter is non-nil. @@ -717,7 +717,7 @@ buffers. This can be controlled by customizing the variable +++ *** 'nobreak-char-display' now also affects all non-ASCII space characters. -Previously, this was limited only to NO-BREAK-SPACE and hyphen +Previously, this was limited only to 'NO-BREAK SPACE' and hyphen characters. Now it also covers the rest of the non-ASCII Unicode space characters. @@ -892,12 +892,12 @@ trying to be non-destructive. +++ ** New command 'revert-buffer-quick'. -This is bound to 'C-x x g' and is like `revert-buffer', but prompts +This is bound to 'C-x x g' and is like 'revert-buffer', but prompts less. +++ ** New user option 'revert-buffer-quick-short-answers'. -This controls how the new 'revert-buffer-quick' (`C-x x g') command +This controls how the new 'revert-buffer-quick' ('C-x x g') command prompts. +++ @@ -915,7 +915,7 @@ during command invocation. --- ** New user option 'save-place-abbreviate-file-names'. -This can simplify sharing the ‘save-place-file’ file across +This can simplify sharing the 'save-place-file' file across different hosts. --- @@ -1505,13 +1505,13 @@ This allows controlling the current/total number of matches for the prompt prefix. +++ -*** New minor modes 'icomplete-vertical-mode' and 'fido-vertical-mode' +*** New minor modes 'icomplete-vertical-mode' and 'fido-vertical-mode'. These modes modify Icomplete ('M-x icomplete-mode') and Fido ('M-x -fido-mode'), to display completions candidates vertically instead of +fido-mode'), to display completion candidates vertically instead of horizontally. In Icomplete, completions are rotated and selection kept at the top. In Fido, completions scroll like a typical dropdown -widget. Both these new minor modes will first turn on their -non-vertical counterparts first, if they are not on already. +widget. Both these new minor modes will turn on their non-vertical +counterparts first, if they are not on already. --- *** Default value of 'icomplete-compute-delay' has been changed to 0.15 s. @@ -1591,8 +1591,8 @@ as a data list rather than as a piece of code. +++ *** 'vc-revert-show-diff' now has a third possible value: 'kill'. -If this variable is 'kill', then the diff buffer will be killed after -the 'vc-revert' action instead of buried. +If this user option is 'kill', then the diff buffer will be killed +after the 'vc-revert' action instead of buried. *** More VC commands can be used from non-file buffers. The relevant commands are those that don't change the VC state. @@ -1617,7 +1617,7 @@ Those are: 'vc-dir-header', 'vc-dir-header-value', 'vc-dir-directory', *** The responsible VC backend is now the most specific one. 'vc-responsible-backend' loops over the backends in 'vc-handled-backends' to determine which backend is responsible for a -specific (unregistered) file. Previously the first matching backend +specific (unregistered) file. Previously, the first matching backend was chosen, but now the one with the most specific path is chosen (in case there's a directory handled by one backend inside another). @@ -2263,7 +2263,7 @@ information, see the related entry about 'shr-browse-url' above. *** New user option 'project-vc-merge-submodules'. *** Project commands now have their own history. -Previously used project directories are now suggested by all commands +Previously, used project directories are now suggested by all commands that prompt for a project directory. +++ @@ -2316,12 +2316,12 @@ before navigating to the selected location. +++ *** New user options to automatically show the first Xref match. -The new option 'xref-auto-jump-to-first-definition' controls the +The new user option 'xref-auto-jump-to-first-definition' controls the behavior of 'xref-find-definitions' and related commands: if it's t or 'show', the first match is automatically displayed; if it's 'move', -point in the *xref* buffer is automatically moved to the first match +point in the "*xref*" buffer is automatically moved to the first match without displaying it. -The new option 'xref-auto-jump-to-first-xref' changes the behavior of +The new user option 'xref-auto-jump-to-first-xref' changes the behavior of all Xref commands in the same way as 'xref-auto-jump-to-first-definition' affects the "find-definitions" commands. @@ -2568,7 +2568,7 @@ Adding the new 'comint-osc-process-output' to ("Operating System Command") escape sequences in comint buffers. By default, only OSC 8, for hyperlinks, and OSC 7, for directory tracking, are acted upon. Adding more entries to -`comint-osc-handlers' allows a customized treatment of further escape +'comint-osc-handlers' allows a customized treatment of further escape sequences. +++ @@ -2878,7 +2878,7 @@ Xterm sends this sequence for both 'F16' and 'Menu' keys It used to be mapped to 'print' but we couldn't find a terminal that uses this sequence for any kind of 'Print' key. This makes the Menu key (see https://en.wikipedia.org/wiki/Menu_key) -work for `context-menu-mode` in Xterm. +work for 'context-menu-mode' in Xterm. --- ** New user option 'xterm-store-paste-on-kill-ring'. @@ -2978,7 +2978,7 @@ multiple every time it runs, which means that if the laptop wakes at --- ** 'parse-partial-sexp' now signals an error if TO is smaller than FROM. -Previously this would lead to the function interpreting FROM as TO and +Previously, this would lead to the function interpreting FROM as TO and vice versa, which would be confusing when passing in OLDSTATE, which refers to the old state at FROM. @@ -2993,7 +2993,7 @@ Previously, zero-length overlays at the end of the buffer were included in the result (if the region queried for stopped at that position). The same was not the case if the buffer had been narrowed to exclude the real end of the buffer. This has now been changed, and -zero-length overlays at `point-max' are always included in the results. +zero-length overlays at 'point-max' are always included in the results. --- ** 'replace-match' now runs modification hooks slightly later. @@ -3010,7 +3010,7 @@ replacement text. in the minibuffer instead of being set via a global let-binding. ** XML serialization functions now reject invalid characters. -Previously 'xml-print' would produce invalid XML when given a string +Previously, 'xml-print' would produce invalid XML when given a string with characters that are not valid in XML (see https://www.w3.org/TR/xml/#charsets). Now it rejects such strings. @@ -3354,7 +3354,7 @@ initial frame used in batch mode. +++ ** Doc strings can now link to customization groups. -Text like "customization group `whitespace'" will be made into a +Text like "customization group 'whitespace'" will be made into a button. When clicked, it'll take the user to a Custom buffer displaying that customization group. commit 61e5570863aa236628a87c722912dea86d2903b0 Author: Lars Ingebrigtsen Date: Mon Sep 6 12:56:02 2021 +0200 Make calc-grab-region work with rectangular selects * lisp/calc/calc.el (calc-grab-region): Heed `rectangle-mark-mode' (bug#50403). diff --git a/lisp/calc/calc.el b/lisp/calc/calc.el index 27a6cff627..800ec7a6a3 100644 --- a/lisp/calc/calc.el +++ b/lisp/calc/calc.el @@ -139,6 +139,7 @@ ;;; Code: (require 'calc-macs) +(require 'rect) ;; Declare functions which are defined elsewhere. (declare-function calc-set-language "calc-lang" (lang &optional option no-refresh)) @@ -3388,7 +3389,9 @@ and all digits are kept, regardless of Calc's current precision." "Parse the region as a vector of numbers and push it on the Calculator stack." (interactive "r\nP") (require 'calc-ext) - (calc-do-grab-region top bot arg)) + (if rectangle-mark-mode + (calc-do-grab-rectangle top bot arg) + (calc-do-grab-region top bot arg))) ;;;###autoload (defun calc-grab-rectangle (top bot arg) commit 9680994d3a1a9d08a12927be4aacb8b631f6b046 Author: martin rudalics Date: Mon Sep 6 12:48:07 2021 +0200 Restore the debugging window size more reliably * lisp/emacs-lisp/debug.el (debug): Restore the debugging window size more reliably (bug#12921). diff --git a/lisp/emacs-lisp/debug.el b/lisp/emacs-lisp/debug.el index 2007f79634..f76ae3fe69 100644 --- a/lisp/emacs-lisp/debug.el +++ b/lisp/emacs-lisp/debug.el @@ -266,16 +266,15 @@ the debugger will not be entered." (window-frame debugger-previous-window))) `((previous-window . ,debugger-previous-window)))))) (setq debugger-window (selected-window)) - (if (eq debugger-previous-window debugger-window) - (when debugger-jumping-flag - ;; Try to restore previous height of debugger - ;; window. - (condition-case nil - (window-resize - debugger-window - (- debugger-previous-window-height - (window-total-height debugger-window))) - (error nil))) + (when debugger-jumping-flag + ;; Try to restore previous height of debugger + ;; window. + (condition-case nil + (window-resize + debugger-window + (- debugger-previous-window-height + (window-total-height debugger-window))) + (error nil)) (setq debugger-previous-window debugger-window)) (message "") (let ((standard-output nil) commit 63618ba27aeb41c1b0348ac5ef7104bc02b97dc7 Author: Lars Ingebrigtsen Date: Mon Sep 6 12:36:32 2021 +0200 Add a tooltip to the comint-mode mode line format * lisp/comint.el (comint-mode): Add a tooltip to say what the :run bit means (bug#13776). diff --git a/lisp/comint.el b/lisp/comint.el index 9e3042f597..e058e6b8cf 100644 --- a/lisp/comint.el +++ b/lisp/comint.el @@ -665,7 +665,8 @@ to continue it. \\{comint-mode-map} Entry to this mode runs the hooks on `comint-mode-hook'." - (setq mode-line-process '(":%s")) + (setq mode-line-process + (list (propertize ":%s" 'help-echo "Process status"))) (setq-local window-point-insertion-type t) (setq-local comint-last-input-start (point-min-marker)) (setq-local comint-last-input-end (point-min-marker)) commit 8ed2f2014559f54093e550b0bd693b03e70a2995 Author: Lars Ingebrigtsen Date: Mon Sep 6 12:33:22 2021 +0200 Improve the info-mode mode line * lisp/info.el (Info-set-mode-line): Add a help echo to help explain what the thing in parentheses is (bug#13776). diff --git a/lisp/info.el b/lisp/info.el index e6b5f3e5a7..5589321856 100644 --- a/lisp/info.el +++ b/lisp/info.el @@ -1731,22 +1731,24 @@ escaped (\\\",\\\\)." (list (concat " (" - (if (stringp Info-current-file) - (string-replace - "%" "%%" - (file-name-sans-extension - (file-name-nondirectory Info-current-file))) - (format "*%S*" Info-current-file)) - ") " - (if Info-current-node - (propertize (string-replace - "%" "%%" Info-current-node) - 'face 'mode-line-buffer-id - 'help-echo - "mouse-1: scroll forward, mouse-3: scroll back" - 'mouse-face 'mode-line-highlight - 'local-map Info-mode-line-node-keymap) - "")))))) + (propertize + (if (stringp Info-current-file) + (string-replace + "%" "%%" + (file-name-sans-extension + (file-name-nondirectory Info-current-file))) + (format "*%S*" Info-current-file)) + 'help-echo "Info file name") + ") ") + (if Info-current-node + (propertize (string-replace + "%" "%%" Info-current-node) + 'face 'mode-line-buffer-id + 'help-echo + "mouse-1: scroll forward, mouse-3: scroll back" + 'mouse-face 'mode-line-highlight + 'local-map Info-mode-line-node-keymap) + ""))))) ;; Go to an Info node specified with a filename-and-nodename string ;; of the sort that is found in pointers in nodes. commit 61562c78dd86f7d93e2610e5c826ca8a3b0d40f4 Author: Eli Zaretskii Date: Mon Sep 6 13:13:22 2021 +0300 ; * lisp/tab-bar.el (toggle-frame-tab-bar, tab-bar-new-tab-to): Doc fix. diff --git a/lisp/tab-bar.el b/lisp/tab-bar.el index 4ec1143128..7f6afd7d53 100644 --- a/lisp/tab-bar.el +++ b/lisp/tab-bar.el @@ -260,7 +260,9 @@ See `tab-bar-mode' for more information." (tab-bar-mode arg))) (defun toggle-frame-tab-bar (&optional frame) - "Toggle tab bar of FRAME. + "Toggle tab bar of the selected frame. +When calling from Lisp, use the optional argument FRAME to toggle +the tab bar on that frame. This is useful when you want to enable the tab bar individually on each new frame when the global `tab-bar-mode' is disabled, or when you want to disable the tab bar individually on each @@ -1074,7 +1076,8 @@ to the tab argument will be applied after all functions are called." "Add a new tab at the absolute position TO-INDEX. TO-INDEX counts from 1. If no TO-INDEX is specified, then add a new tab at the position specified by `tab-bar-new-tab-to'. -Negative TO-INDEX counts tabs from the end of the tab bar. +Negative TO-INDEX counts tabs from the end of the tab bar, +and -1 means the new tab will become the last one. Argument addressing is absolute in contrast to `tab-bar-new-tab' where argument addressing is relative. After the tab is created, the hooks in commit 555a1ee4680025f8f68905529c7eebabbd0b7bda Merge: c0a0eb5460 1ff772e28a Author: Eli Zaretskii Date: Mon Sep 6 13:12:54 2021 +0300 Merge branch 'master' of git.savannah.gnu.org:/srv/git/emacs commit c0a0eb5460320c1e297d5246884fa5db28181c0b Merge: fb061cd0ca 9309dc9df9 Author: Eli Zaretskii Date: Mon Sep 6 13:12:30 2021 +0300 Merge branch 'master' of git.savannah.gnu.org:/srv/git/emacs commit 1ff772e28a2282e965c57643a6863fc35c74f293 Author: Lars Ingebrigtsen Date: Mon Sep 6 12:10:37 2021 +0200 Simplify `image-dired-dired-file-marked-p' * lisp/image-dired.el (image-dired-dired-file-marked-p): Use `dired-re-mark' instead of open-coding the opposite regexp (bug#14925). diff --git a/lisp/image-dired.el b/lisp/image-dired.el index cf878ae122..b92a9371ec 100644 --- a/lisp/image-dired.el +++ b/lisp/image-dired.el @@ -1387,7 +1387,7 @@ comment." "Check whether file on current line is marked or not." (save-excursion (beginning-of-line) - (not (looking-at "^ .*$")))) + (looking-at-p dired-re-mark))) (defun image-dired-modify-mark-on-thumb-original-file (command) "Modify mark in dired buffer. commit fb061cd0ca67dca453edce78892adcad57bfe7e5 Author: Eli Zaretskii Date: Mon Sep 6 13:10:16 2021 +0300 ; * etc/NEWS: Rearrange and fix wording of some entries. diff --git a/etc/NEWS b/etc/NEWS index df7bc1efc9..8a6b632e03 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -48,11 +48,6 @@ still be available when HarfBuzz is supported, but will not be used by default. We strongly recommend building with HarBuzz support. 'x' is still a valid backend. ---- -** Building without double buffering support. -'configure --with-xdbe=no' can now be used to disable double buffering -at build time. - --- ** 'configure' now warns about building with libXft support. libXft is unmaintained, and causes a number of problems with modern @@ -66,6 +61,11 @@ We want to encourage people to use the most modern font features available, and this is the Cairo graphics library + HarfBuzz for font shaping, so 'configure' now recommends that combination. +--- +** Building without double buffering support. +'configure --with-xdbe=no' can now be used to disable double buffering +at build time. + --- ** Support for building with Motif has been removed. @@ -97,11 +97,6 @@ This means that Emacs won't steal keyboard focus upon startup (when started via the Desktop) if the user is typing into another application. -** Emacs now prints a backtrace when signaling an error in batch mode. -This makes debugging Emacs Lisp scripts run in batch mode easier. To -get back the old behavior, set the new variable -'backtrace-on-error-noninteractive' to a nil value. - --- ** Errors in 'kill-emacs-hook' no longer prevent Emacs from shutting down. If a function in that hook signals an error in an interactive Emacs, @@ -125,23 +120,14 @@ lacks the terminfo database, you can instruct Emacs to support 24-bit true color by setting 'COLORTERM=truecolor' in the environment. This is useful on systems such as FreeBSD which ships only with "etc/termcap". -** New variable 'redisplay-skip-initial-frame' to enable batch redisplay tests. -Setting it to nil forces the redisplay to do its job even in the -initial frame used in batch mode. - --- -** File names given on the command line will now be pushed onto -'file-name-history'. - -** 'blink-cursor-mode' is now enabled by default regardless of the UI. -It used to be enabled when Emacs is started in GUI mode but not when started -in text mode. The cursor still only actually blinks in GUI frames. +** File names given on the command line are now be pushed onto history. +The file names will be pushed onto 'file-name-history', like the names +of files visited via 'C-x C-f' and other commands. * Changes in Emacs 28.1 -** The new NonGNU ELPA archive is enabled by default alongside GNU ELPA. - +++ ** New command 'execute-extended-command-for-buffer'. This new command, bound to 'M-S-x', works like @@ -159,15 +145,19 @@ buffer's major and minor modes, and respect the command's completion predicate (if any). +++ -** When 'suggest-key-bindings' is non-nil, the completion list of 'M-x' -shows equivalent key bindings for all commands that have them. +** Completion on 'M-x' shows key bindings for commands. +When 'suggest-key-bindings' is non-nil (as it is by default), the +completion list popped up by 'M-x' shows the key bindings for all the +commands shown in the list of candidate completions that have a key +binding. ** New user option 'completions-detailed'. When non-nil, some commands like 'describe-symbol' show more detailed completions with more information in completion prefix and suffix. +The default is nil. --- -** 'C-s' in 'M-x' now searches over completions again. +** 'C-s' in 'M-x' now once again searches over completions. In Emacs 23, typing 'M-x' ('read-extended-command') and then 'C-s' (to do an interactive search) would search over possible completions. This was lost in Emacs 24, but is now back again. @@ -175,14 +165,6 @@ This was lost in Emacs 24, but is now back again. --- ** User option 'completions-format' supports a new value 'one-column'. -+++ -** A new keymap for buffer actions has been added. -The 'C-x x' keymap now holds keystrokes for various buffer-oriented -commands. The new keystrokes are 'C-x x g' ('revert-buffer-quick'), -'C-x x r' ('rename-buffer'), 'C-x x u' ('rename-uniquely'), 'C-x x n' -('clone-buffer'), 'C-x x i' ('insert-buffer'), 'C-x x t' -('toggle-truncate-lines') and 'C-x x f' ('font-lock-update'). - +++ ** New system for displaying documentation for groups of functions. This can either be used by saying 'M-x shortdoc-display-group' and @@ -198,6 +180,14 @@ mouse click. You can change the order of the default sub-menus in the context menu by customizing the user option 'context-menu-functions'. You can also invoke the context menu by pressing 'S-'. ++++ +** A new keymap for buffer actions has been added. +The 'C-x x' keymap now holds keystrokes for various buffer-oriented +commands. The new keystrokes are 'C-x x g' ('revert-buffer-quick'), +'C-x x r' ('rename-buffer'), 'C-x x u' ('rename-uniquely'), 'C-x x n' +('clone-buffer'), 'C-x x i' ('insert-buffer'), 'C-x x t' +('toggle-truncate-lines') and 'C-x x f' ('font-lock-update'). + +++ ** Modifiers now go outside angle brackets in pretty-printed key bindings. For example, 'RET' with Control and Meta modifiers is now shown as @@ -300,7 +290,7 @@ This is like 'C-x 5 2', but uses the frame parameters of the current frame instead of 'default-frame-alist'. --- -*** The default value of 'frame-title-format' and 'icon-title-format' has changed. +*** Default values of 'frame-title-format' and 'icon-title-format' have changed. These variables are used to display the title bar of visible frames and the title bar of an iconified frame. They now show the name of the current buffer and the text "GNU Emacs" instead of the value of @@ -316,11 +306,14 @@ This parameter, similar to 'drag-with-header-line', allows moving frames by dragging the tab lines of their topmost windows with the mouse. +++ -*** A prefix arg now causes 'delete-other-frames' to only iconify frames. +*** New optional behavior of 'delete-other-frames'. +When invoked with a prefix argument, 'delete-other-frames' now +iconifies frames, rather than deleting them. --- -*** Commands 'set-frame-width' and 'set-frame-height' can now get their -input using the minibuffer. +*** Commands 'set-frame-width' and 'set-frame-height' now prompt for values. +These commands now prompt for the value via the minibuffer, instead of +requiring the user to specify the value via the prefix argument. ** Windows @@ -334,12 +327,12 @@ of the next command to be displayed in a new window. +++ *** New command 'recenter-other-window', bound to 'S-M-C-l'. -Like 'recenter-top-bottom' acting in the other window. +Like 'recenter-top-bottom' acting on the other window. +++ *** New user option 'delete-window-choose-selected'. -This allows to choose a frame's selected window after deleting the -previously selected one. +This allows to choose a window that will be the frame's selected +window after deleting the currently selected one. +++ *** New argument NO-OTHER for some window functions. @@ -360,13 +353,8 @@ This updates the use time of a window. *** Minibuffer scrolling is now conservative by default. This is controlled by the new variable 'scroll-minibuffer-conservatively'. - -In addition, there is a new variable -'redisplay-adhoc-scroll-in-resize-mini-windows' to disable the -ad-hoc auto-scrolling when resizing minibuffer windows. It has been -found that its heuristic can be counter productive in some corner -cases, tho the cure may be worse than the disease. This said, the -effect should be negligible in the vast majority of cases anyway. +It is t by default; setting it to nil will cause scrolling in the +minibuffer obey the value of 'scroll-conservatively'. +++ *** Improved handling of minibuffers on switching frames. @@ -387,30 +375,40 @@ When customized to nil, it uses 'minibuffer-restore-windows' in 'minibuffer-exit-hook' to remove only the window showing the "*Completions*" buffer. +--- +*** New variable 'redisplay-adhoc-scroll-in-resize-mini-windows'. +Customizing it to nil will disable the ad-hoc auto-scrolling of +minibuffer text shown in mini-windows when resizing those windows. +The default heuristics of that scrolling can be counter productive in +some corner cases, though the cure might be worse than the disease. +This said, the effect should be negligible in the vast majority of +cases anyway. + ** Mode Line +++ *** New user option 'mode-line-compact'. If non-nil, repeating spaces are compressed into a single space. If 'long', this is only done when the mode line is longer than the -current window width (in characters). +current window width (in columns). +++ -*** New user options to control the line/column numbers in the mode line. +*** New user options to control format of line/column numbers in the mode line. 'mode-line-position-line-format' is the line number format (when 'line-number-mode' is on), 'mode-line-position-column-format' is the column number format (when 'column-number-mode' is on), and 'mode-line-position-column-line-format' is the combined format (when both modes are on). -** Tab Bars +** Tab Bars and Tab Lines -*** The key prefix 'C-x t t' displays next command buffer in a new tab. -It's bound to the command 'other-tab-prefix' that requests the buffer -of the next command to be displayed in a new tab. +*** The prefix key 'C-x t t' can be used to display a buffer in a new tab. +Typing 'C-x t t' before a command will cause the buffer shown by that +command to be displayed in a new tab. 'C-x t t" is bound to the +command 'other-tab-prefix'. +++ -*** New command 'C-x t C-r' to open file read-only in other tab. +*** New command 'C-x t C-r' to open file read-only in the other tab. --- *** The tab bar is frame-local when 'tab-bar-show' is a number. @@ -419,17 +417,17 @@ value of 'tab-bar-show'. --- *** New command 'toggle-frame-tab-bar'. -It can be used to enable/disable the tab bar individually on each frame -independently from the value of 'tab-bar-mode' and 'tab-bar-show'. +It can be used to enable/disable the tab bar on the currently selected +frame regardless of the values of 'tab-bar-mode' and 'tab-bar-show'. --- *** New user option 'tab-bar-format' defines a list of tab bar items. When it contains 'tab-bar-format-global' (possibly appended after 'tab-bar-format-align-right'), then after enabling 'display-time-mode' (or any other mode that uses 'global-mode-string') it displays time -aligned to the right on the tab bar instead of the mode line. +aligned to the right on the tab bar instead of on the mode line. When 'tab-bar-format-tabs' is replaced with 'tab-bar-format-tabs-groups', -then the tab bar displays tab groups. +the tab bar displays tab groups. --- *** 'Mod-9' bound to 'tab-last' now switches to the last tab. @@ -440,19 +438,21 @@ It also supports a negative argument. --- *** 'C-x t N' creates a new tab at the specified absolute position. -It also supports a negative argument. +The position is provided as prefix arg, and specifies an index that +starts at 1. Negative values count from the end of the tab bar. --- *** 'C-x t M' moves the current tab to the specified absolute position. -It also supports a negative argument. +The position is provided as prefix arg, whose interpretation is as in +'C-x t N'. --- -*** 'C-x t G' assigns a group name to the tab. -'tab-close-group' can close all tabs that belong to the selected group. -The user option 'tab-bar-new-tab-group' defines the default group of a -new tab. After customizing 'tab-bar-tab-post-change-group-functions' -to 'tab-bar-move-tab-to-group', changing the tab group will also move it -closer to other tabs in the same group. +*** 'C-x t G' assigns a tab to a named group of tabs. +'tab-close-group' closes all tabs that belong to the selected group. +The user option 'tab-bar-new-tab-group' defines the default group of +new tabs. After customizing 'tab-bar-tab-post-change-group-functions' +to 'tab-bar-move-tab-to-group', changing the group of a tab will also +move it closer to other tabs in the same group. --- *** New user option 'tab-bar-tab-name-format-function'. @@ -468,14 +468,13 @@ the mouse pointer is in the tab line by scrolling left or right. --- *** New tab-line faces and options. The face 'tab-line-tab-special' is used for tabs whose buffers are -special, i.e. not file-backed. The face +special, i.e. buffers that don't visit a file. The face 'tab-line-tab-inactive-alternate' is used to display inactive tabs with an alternating background color, making them easier to -distinguish between, especially if the face 'tab-line-tab' is -configured to not display with a box; this alternate face is only -applied when the option 'tab-line-tab-face-functions' is -so-configured. That option may also be used to customize tab-line -faces in other ways. +distinguish, especially if the face 'tab-line-tab' is configured to +not display with a box; this alternate face is only applied when the +option 'tab-line-tab-face-functions' is so configured. That option +may also be used to customize tab-line faces in other ways. ** Mouse wheel @@ -526,7 +525,7 @@ commands and is globally bound to 'C-h x'. This works like 'C-u M-x apropos-command' but is more discoverable. --- -*** New keybinding 'C-h R' prompts for a manual to display and displays it. +*** New keybinding 'C-h R' prompts for an Info manual and displays it. --- *** Keybindings in 'help-mode' use the new 'help-key-binding' face. @@ -555,8 +554,8 @@ can provide a better overview in a long list of available bindings. +++ *** New command 'lossage-size'. -It allows users to set the maximum number of keystrokes and commands -recorded for the purpose of 'view-lossage'. +It allows users to change the maximum number of keystrokes and +commands recorded for the purpose of 'view-lossage'. *** New commands to describe buttons and widgets. 'widget-describe' (on a widget) will pop up a help buffer and give a @@ -586,6 +585,46 @@ clicking the "X" icon in the tool bar. --- *** 'g' ('revert-buffer') in 'help-mode' no longer requires confirmation. +** File Locks + ++++ +*** New user option 'lock-file-name-transforms'. +This option allows controlling where lock files are written. It uses +the same syntax as 'auto-save-file-name-transforms'. + ++++ +*** New user option 'remote-file-name-inhibit-locks'. +When non-nil, this option suppresses lock files for remote files. + ++++ +*** New minor mode 'lock-file-mode'. +This command, called interactively, toggles the local value of +'create-lockfiles' in the current buffer. + +** Emacs Server + ++++ +*** New user option 'server-client-instructions'. +When emacsclient connects, Emacs will (by default) output a message +about how to exit the client frame. If 'server-client-instructions' +is set to nil, this message is inhibited. + ++++ +*** New command 'server-edit-abort'. +This command (not bound to any key by default) can be used to abort +an edit instead of marking it as "Done" (which the 'C-x #' command +does). The 'emacsclient' program exits with an abnormal status as +result of this command. + ++++ +*** New desktop integration for connecting to the server. +If your operating system’s desktop environment is +freedesktop.org-compatible (which is true of most GNU/Linux and other +recent Unix-like desktops), you may use the new "Emacs (Client)" +desktop menu entry to open files in an existing Emacs instance rather +than starting a new one. The daemon starts if it is not already +running. + ** Miscellaneous +++ @@ -659,8 +698,8 @@ new 'minibuffer-default-prompt-format' user option to format "default" prompts. This means that prompts that look like "Enter a number (default 10)" can be customized to look like, for instance, "Enter a number [10]", or not have the default displayed at all, like "Enter a -number". (This requires that all callers are altered to use -'format-prompt', though.) +number". (This only affects callers that were altered to use +'format-prompt'.) --- *** New help window when Emacs prompts before opening a large file. @@ -742,44 +781,8 @@ Emacs now supports 256 color display on the 'st' terminal emulator. freenode IRC network for years now. Occurrences of "irc.freenode.net" have been replaced with "chat.freenode.net" throughout Emacs. -** File Locks - -+++ -*** New user option 'lock-file-name-transforms'. -This option allows controlling where lock files are written. It uses -the same syntax as 'auto-save-file-name-transforms'. - -+++ -*** New user option 'remote-file-name-inhibit-locks'. -When non-nil, this option suppresses lock files for remote files. - -+++ -*** New minor mode 'lock-file-mode'. -This command, called interactively, toggles the local value of -'create-lockfiles' in the current buffer. - -** Emacs Server - -+++ -*** New user option 'server-client-instructions'. -When emacsclient connects, Emacs will (by default) output a message -about how to exit the client frame. If 'server-client-instructions' -is set to nil, this message is inhibited. - -+++ -*** New command 'server-edit-abort'. -This command (not bound to any key by default) can be used to abort -an edit instead of marking it as "Done" (which the 'C-x #' command -does). The 'emacsclient' program exits with an abnormal status as -result of this command. - -+++ -*** New desktop integration for connecting to the server. -If your operating system’s desktop environment is -freedesktop.org-compatible (which is true of most GNU/Linux and other -recent Unix-like GUIs), you may use the new "Emacs (Client)" desktop -menu entry to open files in an existing Emacs instance rather than -starting a new one. The daemon starts if not already running. + +* Editing Changes in Emacs 28.1 ** Input methods @@ -829,9 +832,6 @@ methods 'lakota-slo-prefix', 'lakota-slo-postfix', and 'lakota-white-hat-postfix' have been added. There is also a Lakota greeting in "etc/HELLO". - -* Editing Changes in Emacs 28.1 - +++ ** Standalone 'M-y' allows interactive selection from previous kills. 'M-y' can now be typed after a command that is not a yank command. @@ -842,6 +842,13 @@ in Isearch can be invoked if you bind 'C-s M-y' to the command 'isearch-yank-pop'. When the user option 'yank-from-kill-ring-rotate' is nil the kill ring is not rotated after 'yank-from-kill-ring'. ++++ +** New user option 'word-wrap-by-category'. +When word-wrap is enabled, and this option is non-nil, that allows +Emacs to break lines after more characters than just whitespace +characters. In particular, this significantly improves word-wrapping +for CJK text mixed with Latin text. + +++ ** New command 'undo-redo'. It undoes previous undo commands, but doesn't record itself as an @@ -896,40 +903,33 @@ This is bound to 'C-x x g' and is like `revert-buffer', but prompts less. +++ -** New user option 'revert-buffer-quick-short-answers'. This -controls how the new 'revert-buffer-quick' (`C-x x g') command +** New user option 'revert-buffer-quick-short-answers'. +This controls how the new 'revert-buffer-quick' (`C-x x g') command prompts. +++ ** New user option 'query-about-changed-file'. -If non-nil (the default), users are prompted as before when -re-visiting a file that has changed externally after it was visited -the first time. If nil, the user is not prompted, but instead the -buffer is opened with its contents before the change, and the user is -given instructions how to revert the buffer. +If non-nil (the default), Emacs prompts as before when re-visiting a +file that has changed externally after it was visited the first time. +If nil, Emacs does not prompt, but instead shows the buffer with its +contents before the change, and provides instructions how to revert +the buffer. ** New value 'save-some-buffers-root' of 'save-some-buffers-default-predicate'. -It allows to ask about saving only files under the project root -or in subdirectories of the directory that was default during -command invocation. +They allow to ask about saving only those files that are under the +project root or in subdirectories of the directory that was default +during command invocation. --- ** New user option 'save-place-abbreviate-file-names'. This can simplify sharing the ‘save-place-file’ file across different hosts. -+++ -** New user option 'word-wrap-by-category'. -When word-wrap is enabled, and this option is non-nil, that allows -Emacs to break lines after more characters than just whitespace -characters. In particular, this significantly improves word-wrapping -for CJK text mixed with Latin text. - --- ** New user options 'copy-region-blink-delay' and 'delete-pair-blink-delay'. 'copy-region-blink-delay' specifies a delay to indicate the region copied by 'kill-ring-save'. 'delete-pair-blink-delay' specifies -a delay to show a paired character to delete. +a delay to show the paired character to delete. --- ** 'zap-up-to-char' now uses 'read-char-from-minibuffer'. @@ -955,15 +955,21 @@ buffer to be able to move point to the inaccessible portion. 'goto-line-relative' is bound to 'C-x n g'. +++ -** When called interactively, 'goto-char' now offers the number at -point as default. +** 'got-char' prompts for the character position. +When called interactively, 'goto-char' now offers the position at +point as the default. -** Autosaving via 'auto-save-visited-mode' can now be inhibited by -setting the variable 'auto-save-visited-mode' buffer-locally to nil. +** Autosaving via 'auto-save-visited-mode' can now be inhibited. +Set the variable 'auto-save-visited-mode' buffer-locally to nil to +achieve that. +++ ** New command 'C-x C-k Q' to force redisplay in keyboard macros. +** 'blink-cursor-mode' is now enabled by default regardless of the UI. +It used to be enabled when Emacs is started in GUI mode but not when started +in text mode. The cursor still only actually blinks in GUI frames. + * Changes in Specialized Modes and Packages in Emacs 28.1 @@ -981,6 +987,11 @@ This is controlled by the 'search-highlight-submatches' user option. This feature is available only on terminals that have enough colors to distinguish between sub-expression highlighting. ++++ +*** Interactive regular expression replace now uses faces for sub-groups. +Like 'search-highlight-submatches', this is controlled by the new user option +'query-replace-highlight-submatches'. + *** New user option 'isearch-wrap-pause' defines how to wrap the search. There are choices to disable wrapping completely and to wrap immediately. When wrapping immediately, it consistently handles the numeric arguments @@ -993,12 +1004,7 @@ When this option is set, direction changes in Isearch move to another search match, if there is one, instead of moving point to the other end of the current match. -+++ -*** Interactive regular expression replace now uses faces for sub-groups. -Like 'search-highlight-submatches', this is controlled by the new user option -'query-replace-highlight-submatches'. - -*** New key 'M-s M-.' starts isearch with the thing found at point. +*** New key 'M-s M-.' starts isearch looking for the thing at point. This key is bound to the new command 'isearch-forward-thing-at-point'. The new user option 'isearch-forward-thing-at-point' defines a list of symbols to try to get the "thing" at point. By default, @@ -1071,14 +1077,16 @@ Non-nil reverts the destination Dired buffer after performing one of these operations: 'dired-do-copy', 'dired-do-rename', 'dired-do-symlink', 'dired-do-hardlink'. -*** New user option 'dired-mark-region' affects all Dired commands -that mark files. When non-nil and the region is active in Transient -Mark mode, then Dired commands operate only on files in the active -region. The values 'file' and 'line' of this user option define the -details of marking the file at the end of the region. +*** New user option 'dired-mark-region'. +This option affects all Dired commands that mark files. When non-nil +and the region is active in Transient Mark mode, then Dired commands +operate only on files in the active region. The values 'file' and +'line' of this user option define the details of marking the file at +the end of the region. -*** State changing VC operations are supported in Dired on files and -directories with the help of new command 'dired-vc-next-action'. +*** State changing VC operations are supported in Dired. +These operations are supported on files and directories via the new +command 'dired-vc-next-action'. +++ *** 'dired-jump' and 'dired-jump-other-window' moved from 'dired-x' to 'dired'. @@ -1126,14 +1134,31 @@ major mode. ** Ispell +++ -*** 'ispell-comments-and-strings' now accepts START and END arguments, -defaulting to active region when used interactively. +*** 'ispell-comments-and-strings' now accepts START and END arguments. +These arguments default to active region when used interactively. + ++++ +*** New command 'ispell-comment-or-string-at-point'. + +** Flyspell mode +++ -*** New command 'ispell-comment-or-string-at-point' is provided. +*** Corrections and actions menu can be optionally bound to 'mouse-3'. +When Flyspell mode highlights a word as misspelled, you can click on +it to display a menu of possible corrections and actions. You can now +easily bind this menu to 'down-mouse-3' (usually the right mouse button) +instead of 'mouse-2' (the default) by enabling 'context-menu-mode'. + +--- +*** The current dictionary is now displayed in the minor mode lighter. +Clicking the dictionary name changes the current dictionary. ** Package +*** The new NonGNU ELPA archive is enabled by default alongside GNU ELPA. +Thus, packages on nonGNU ELPA will appear by default in the list shown +by 'list-packages'. + --- *** '/ s' ('package-menu-filter-by-status') changes parameter handling. The command was documented to take a comma-separated list of statuses @@ -1168,7 +1193,9 @@ native compilation of packages when they are installed. That option is nil by default; if set non-nil, and if your Emacs was built with native-compilation support, each package will be natively compiled when it is installed, by invoking an asynchronous Emacs subprocess to -run the native-compilation of the package files. +run the native-compilation of the package files. (Be sure to leave +Emacs running until these asynchronous subprocesses exit, or else the +native-compilation will be aborted when you exit Emacs.) --- *** Column widths in 'list-packages' display can now be customized. @@ -1182,9 +1209,9 @@ See the new user options 'package-name-column-width', *** New user option 'Info-warn-on-index-alternatives-wrap'. This option affects what happens when using the ',' command after looking up an entry with 'i' in info buffers. If non-nil (the -default), the ',' command will now warn you when proceeding beyond the -final entry, and tapping ',' once more will then take you to the -first entry. +default), the ',' command will now display a warning when proceeding +beyond the final index match, and tapping ',' once more will then take +you to the first match. ** Abbrev mode @@ -1231,7 +1258,7 @@ deleting. *** The recentf files are no longer backed up. --- -*** 'recentf-auto-cleanup' time string now repeats. +*** 'recentf-auto-cleanup' now repeats daily when set to a time string. When 'recentf-auto-cleanup' is set to a time string, it now repeats every day, rather than only running once after the mode is turned on. @@ -1279,43 +1306,32 @@ Previously, killing a virtual ido buffer with 'ido-kill-buffer' didn't do anything. This has now been changed, and killing virtual buffers with that command will remove the buffer from recentf. -** Flyspell mode - -+++ -*** Corrections and actions menu can be optionally bound to 'mouse-3'. -When Flyspell mode highlights a word as misspelled, you can click on -it to display a menu of possible corrections and actions. You can now -easily bind this menu to 'down-mouse-3' (usually the right mouse button) -instead of 'mouse-2' (the default) by enabling 'context-menu-mode'. - ---- -*** The current dictionary is now displayed in the minor mode lighter. -Clicking the dictionary name changes the current dictionary. - ** So Long --- -*** New 'so-long-predicate' function 'so-long-statistics-excessive-p' -efficiently detects the presence of a long line anywhere in the buffer -using 'buffer-line-statistics' (see above). This is now the default -predicate (replacing 'so-long-detected-long-line-p'). +*** New 'so-long-predicate' function 'so-long-statistics-excessive-p'. +It efficiently detects the presence of a long line anywhere in the +buffer using 'buffer-line-statistics' (see above). This is now the +default predicate (replacing 'so-long-detected-long-line-p'). --- -*** 'so-long-threshold' and 'so-long-max-lines' have been raised to -10000 bytes and 500 lines respectively, to reduce the likelihood of -false-positives when 'global-so-long-mode' is enabled. The latter -value is now only used by the old predicate, as the new predicate -knows the longest line in the entire buffer. +*** Default values 'so-long-threshold' and 'so-long-max-lines' increased. +The values of these variables have been raised to 10000 bytes and 500 +lines respectively, to reduce the likelihood of false-positives when +'global-so-long-mode' is enabled. The latter value is now only used +by the old predicate, as the new predicate knows the longest line in +the entire buffer. --- -*** 'so-long-target-modes' now includes 'fundamental-mode' by default, -meaning that 'global-so-long-mode' will also process files which were +*** 'so-long-target-modes' now includes 'fundamental-mode' by default. +This means that 'global-so-long-mode' will also process files which were not recognised. (This only has an effect if 'set-auto-mode' chooses 'fundamental-mode'; buffers which are simply in 'fundamental-mode' by default are unaffected.) --- -*** New user options 'so-long-mode-preserved-minor-modes' and +*** New user options to preserve modes and variables. +The new options 'so-long-mode-preserved-minor-modes' and 'so-long-mode-preserved-variables' allow specified mode and variable states to be maintained if 'so-long-mode' replaces the original major mode. By default, these new options support 'view-mode'. @@ -1400,15 +1416,16 @@ changes. *** Can now modify members of 'ar' archives. -*** Display of summaries unified between backends. +*** Display of summaries is unified between backends. -*** New user option 'archive-hidden-columns' and command -'archive-hideshow-column'. These let you control which columns are -displayed and which are kept hidden. +*** New user option and command to control displayed columns. +New user option 'archive-hidden-columns' and new command +'archive-hideshow-column' let you control which columns are displayed +and which are kept hidden. --- *** New command bound to 'C': 'archive-copy-file'. -This command extracts the file under point and writes the data to a +This command extracts the file at point and writes its data to a file. ** browse-url @@ -1426,7 +1443,7 @@ Formerly, one could do the same by setting 'browse-url-browser-function' to such an alist. This usage is still supported but deprecated. -*** Categorization of browsing commands in internal vs. external. +*** Categorization of browsing commands into internal vs. external. All standard browsing commands such as 'browse-url-firefox', 'browse-url-mail', or 'eww' have been categorized into internal (URL is browsed in Emacs) or external (an external application is spawned @@ -1437,7 +1454,7 @@ either an internal or external browser. --- *** Support for browsing of remote files. -If a remote file is taken, a local temporary copy of that file is +If a remote file is specified, a local temporary copy of that file is passed to the browser. *** Support for the conkeror browser is now obsolete. @@ -1462,7 +1479,7 @@ layout back. --- *** New user option 'python-forward-sexp-function'. -This allows the user to easier customize whether to use block-based +This allows the user easier customization of whether to use block-based navigation or not. --- @@ -1533,11 +1550,13 @@ These options include 'windmove-default-keybindings', ** Occur mode -*** New bindings in occur-mode, 'next-error-no-select' bound to 'n' and -'previous-error-no-select' bound to 'p'. +*** New bindings in occur-mode. +The command 'next-error-no-select' is now bound to 'n' and +'previous-error-no-select' is bound to 'p'. -*** The new command 'recenter-current-error', bound to 'l' in Occur or -compilation buffers, recenters the current displayed occurrence/error. +*** The new command 'recenter-current-error'. +It is bound to 'l' in Occur or compilation buffers, and recenters the +current displayed occurrence/error. *** Matches in target buffers are now highlighted as in 'compilation-mode'. The method of highlighting is specified by the user options @@ -1883,12 +1902,14 @@ it when producing a doc string. ** Tramp +++ -*** New connection method "mtp", which allows accessing media devices -like cell phones, tablets or cameras. +*** New connection method "mtp". +It allows accessing media devices like cell phones, tablets or +cameras. +++ -*** New connection method "sshfs", which allows accessing remote files -via a file system mounted with 'sshfs'. +*** New connection method "sshfs". +It allows accessing remote files via a file system mounted with +'sshfs'. +++ *** Tramp supports SSH authentication via a hardware security key now. @@ -1898,7 +1919,7 @@ security key, like yubikey, solokey, or nitrokey. +++ *** Trashed remote files are moved to the local trash directory. All remote files, which are trashed, are moved to the local trash -directory. Except remote encrypted files, which are always deleted. +directory, except remote encrypted files, which are always deleted. +++ *** New command 'tramp-crypt-add-directory'. @@ -1928,10 +1949,10 @@ In order to deactivate this, set user option 'remote-file-name-inhibit-locks' to t. +++ -*** Writing sensitive auto-save, backup or lock files to the local -temporary directory must be confirmed. In order to suppress this -confirmation, set user option 'tramp-allow-unsafe-temporary-files' to -t. +*** Writing sensitive data locally requires confirmation. +Writing auto-save, backup or lock files to the local temporary +directory must be confirmed. In order to suppress this confirmation, +set user option 'tramp-allow-unsafe-temporary-files' to t. ** Tempo @@ -1947,7 +1968,7 @@ If non-nil, apply a register filter based on 'gdb-registers-filter-pattern-list'. +++ -*** gdb-mi can now store and restore window configurations. +*** gdb-mi can now save and restore window configurations. Use 'gdb-save-window-configuration' to save window configuration to a file and 'gdb-load-window-configuration' to load from a file. These commands can also be accessed through the menu bar under "Gud => @@ -1955,11 +1976,11 @@ GDB-Windows". 'gdb-default-window-configuration-file', when non-nil, is loaded when GDB starts up. +++ -*** gdb-mi can now restore window configuration after quit. +*** gdb-mi can now restore window configuration after quitting. Set 'gdb-restore-window-configuration-after-quit' to non-nil and Emacs will remember the window configuration before GDB started and restore it after GDB quits. A toggle button is also provided under "Gud => -GDB-Windows". +GDB-Windows" menu item. +++ *** gdb-mi now has a better logic for displaying source buffers. @@ -2005,10 +2026,11 @@ be done (and this restores how this previously worked). ** Hi Lock mode --- -*** Matching in 'hi-lock-mode' is case-sensitive when regexp contains -upper case characters and 'search-upper-case' is non-nil. -'highlight-phrase' also uses 'search-whitespace-regexp' -to substitute spaces in regexp search. +*** Matching in 'hi-lock-mode' can be case-sensitive. +The matching is case-sensitive when a regexp contains upper case +characters and 'search-upper-case' is non-nil. 'highlight-phrase' +also uses 'search-whitespace-regexp' to substitute spaces in regexp +search. --- *** The default value of 'hi-lock-highlight-range' was enlarged. @@ -2059,7 +2081,7 @@ t, which preserves the original behavior. --- *** New user option 'rmail-show-message-set-modified'. If set non-nil, showing an unseen message will set the Rmail buffer's -modified flag. +modified flag. The default is nil, to preserve the old behavior. ** CC Mode @@ -2271,6 +2293,7 @@ project's root directory, respectively. +++ *** New user option 'project-list-file'. +This specifies the file in which to save the list of known projects. +++ *** New command 'project-remove-known-project'. @@ -2365,16 +2388,17 @@ truncation, amongst other things. ** bug-reference.el --- -*** Bug reference mode auto-setup. If 'bug-reference-mode' or -'bug-reference-prog-mode' have been activated, their respective hook -has been run and still 'bug-reference-bug-regexp' and -'bug-reference-url-format' aren't both set, it tries to guess -appropriate values for those two variables. There are three guessing -mechanisms so far: based on version control information of the current -buffer's file, based on newsgroup/mail-folder name and several news -and mail message headers in Gnus buffers, and based on IRC channel and -network in rcirc and ERC buffers. All mechanisms are extensible with -custom rules, see the variables 'bug-reference-setup-from-vc-alist', +*** Bug reference mode uses auto-setup. +If 'bug-reference-mode' or 'bug-reference-prog-mode' have been +activated, their respective hook has been run and still +'bug-reference-bug-regexp' and 'bug-reference-url-format' aren't both +set, it tries to guess appropriate values for those two variables. +There are three guessing mechanisms so far: based on version control +information of the current buffer's file, based on +newsgroup/mail-folder name and several news and mail message headers +in Gnus buffers, and based on IRC channel and network in rcirc and ERC +buffers. All the mechanisms are extensible with custom rules, see the +variables 'bug-reference-setup-from-vc-alist', 'bug-reference-setup-from-mail-alist', and 'bug-reference-setup-from-irc-alist'. @@ -2456,101 +2480,6 @@ images are marked. --- *** New command 'image-dired-delete-marked'. -** Miscellaneous - ---- -*** 'shell-script-mode' now supports 'outline-minor-mode'. -The outline headings have lines that start with "###". - ---- -*** fileloop will now skip missing files instead of signalling an error. - ---- -*** 'tabulated-list-mode' can now restore original display order. -Many commands (like 'C-x C-b') are derived from 'tabulated-list-mode', -and that mode allows the user to sort on any column. There was -previously no easy way to get back to the original displayed order -after sorting, but giving a -1 numerical prefix to the sorting command -will now restore the original order. - ---- -*** 'M-left' and 'M-right' now move between columns in 'tabulated-list-mode'. - -+++ -*** rcirc now supports SASL authentication. - ---- -*** New variable 'hl-line-overlay-priority'. -This can be used to change the priority of the hl-line overlays. - -+++ -*** New command 'mailcap-view-file'. -This command will open a viewer based on the file type, as determined -by "~/.mailcap" and related files and variables. - ---- -*** New user option 'remember-diary-regexp'. - ---- -*** New user option 'remember-text-format-function'. - ---- -*** New user option 'authinfo-hide-elements'. -This can be set to nil to inhibit hiding passwords in ".authinfo" files. - ---- -*** 'hexl-mode' scrolling commands now heed 'next-screen-context-lines'. -Previously, 'hexl-scroll-down' and 'hexl-scroll-up' would scroll -up/down an entire window, but they now work more like the standard -scrolling commands. - ---- -*** New user option 'bibtex-unify-case-function'. -This new option allows the user to customize how case is converted -when unifying entries. - ---- -*** The user option 'bibtex-maintain-sorted-entries' now permits -user-defined sorting schemes. - ---- -*** New user option 'reveal-auto-hide'. -If non-nil (the default), revealed text is automatically hidden when -point leaves the text. If nil, the text is not hidden again. Instead -'M-x reveal-hide-revealed' can be used to hide all the revealed text. - ---- -*** New variable 'ffap-file-name-with-spaces'. -If non-nil, 'find-file-at-point' and friends will try to guess more -expansively to identify a file name with spaces. - ---- -*** Two new commands for centering in 'doc-view-mode'. -The new commands 'doc-view-center-page-horizontally' (bound to 'c h') -and 'doc-view-center-page-vertically' (bound to 'c v') center the page -horizontally and vertically, respectively. - ---- -*** The width of the buffer-name column in 'list-buffers' is now dynamic. -The width now depends of the width of the window, but will never be -wider than the length of the longest buffer name, except that it will -never be narrower than 19 characters. - -+++ -*** New diary sexp 'diary-offset'. -It offsets another diary sexp by a number of days. This is useful -when for example your organization has a committee meeting two days -after every monthly meeting which takes place on the third Thursday, -or if you would like to attend a virtual meeting scheduled in a -different timezone causing a difference in the date. - ---- -*** The old non-SMIE indentation of 'sh-mode' has been removed. - -*** Loading dunnet.el in batch mode doesn't start the game any more. -Instead you need to do "emacs -f dun-batch" to start the game in -batch mode. - ** Flymake mode +++ @@ -2756,6 +2685,101 @@ Variable 'mh-whitelist-preserves-sequences-flag' is renamed Face 'mh-folder-blacklisted' is renamed 'mh-folder-blocklisted'. Face 'mh-folder-whitelisted' is renamed 'mh-folder-allowlisted'. +** Miscellaneous + +--- +*** 'shell-script-mode' now supports 'outline-minor-mode'. +The outline headings have lines that start with "###". + +--- +*** fileloop will now skip missing files instead of signalling an error. + +--- +*** 'tabulated-list-mode' can now restore original display order. +Many commands (like 'C-x C-b') are derived from 'tabulated-list-mode', +and that mode allows the user to sort on any column. There was +previously no easy way to get back to the original displayed order +after sorting, but giving a -1 numerical prefix to the sorting command +will now restore the original order. + +--- +*** 'M-left' and 'M-right' now move between columns in 'tabulated-list-mode'. + ++++ +*** rcirc now supports SASL authentication. + +--- +*** New variable 'hl-line-overlay-priority'. +This can be used to change the priority of the hl-line overlays. + ++++ +*** New command 'mailcap-view-file'. +This command will open a viewer based on the file type, as determined +by "~/.mailcap" and related files and variables. + +--- +*** New user option 'remember-diary-regexp'. + +--- +*** New user option 'remember-text-format-function'. + +--- +*** New user option 'authinfo-hide-elements'. +This can be set to nil to inhibit hiding passwords in ".authinfo" files. + +--- +*** 'hexl-mode' scrolling commands now heed 'next-screen-context-lines'. +Previously, 'hexl-scroll-down' and 'hexl-scroll-up' would scroll +up/down an entire window, but they now work more like the standard +scrolling commands. + +--- +*** New user option 'bibtex-unify-case-function'. +This new option allows the user to customize how case is converted +when unifying entries. + +--- +*** The user option 'bibtex-maintain-sorted-entries' now permits +user-defined sorting schemes. + +--- +*** New user option 'reveal-auto-hide'. +If non-nil (the default), revealed text is automatically hidden when +point leaves the text. If nil, the text is not hidden again. Instead +'M-x reveal-hide-revealed' can be used to hide all the revealed text. + +--- +*** New variable 'ffap-file-name-with-spaces'. +If non-nil, 'find-file-at-point' and friends will try to guess more +expansively to identify a file name with spaces. + +--- +*** Two new commands for centering in 'doc-view-mode'. +The new commands 'doc-view-center-page-horizontally' (bound to 'c h') +and 'doc-view-center-page-vertically' (bound to 'c v') center the page +horizontally and vertically, respectively. + +--- +*** The width of the buffer-name column in 'list-buffers' is now dynamic. +The width now depends of the width of the window, but will never be +wider than the length of the longest buffer name, except that it will +never be narrower than 19 characters. + ++++ +*** New diary sexp 'diary-offset'. +It offsets another diary sexp by a number of days. This is useful +when for example your organization has a committee meeting two days +after every monthly meeting which takes place on the third Thursday, +or if you would like to attend a virtual meeting scheduled in a +different timezone causing a difference in the date. + +--- +*** The old non-SMIE indentation of 'sh-mode' has been removed. + +*** Loading dunnet.el in batch mode doesn't start the game any more. +Instead you need to do "emacs -f dun-batch" to start the game in +batch mode. + * New Modes and Packages in Emacs 28.1 @@ -2807,7 +2831,8 @@ complex menus take advantage of infix arguments, which are somewhat similar to prefix arguments, but are more flexible and discoverable. ** hierarchy.el -It's a library to create, query, navigate and display hierarchy structures. +It's a library to create, query, navigate and display hierarchical +structures. * Incompatible Editing Changes in Emacs 28.1 @@ -2891,6 +2916,11 @@ file: * Incompatible Lisp Changes in Emacs 28.1 +** Emacs now prints a backtrace when signaling an error in batch mode. +This makes debugging Emacs Lisp scripts run in batch mode easier. To +get back the old behavior, set the new variable +'backtrace-on-error-noninteractive' to a nil value. + --- ** Some floating-point numbers are now handled differently by the Lisp reader. In previous versions of Emacs, numbers with a trailing dot and an exponent @@ -2984,22 +3014,24 @@ Previously 'xml-print' would produce invalid XML when given a string with characters that are not valid in XML (see https://www.w3.org/TR/xml/#charsets). Now it rejects such strings. - --- -** JSON number parsing is now stricter. +** JSON + +*** JSON number parsing is now stricter. Numbers with a leading plus sign, leading zeros, or a missing integer component are now rejected by 'json-read' and friends. This makes them more compliant with the JSON specification and consistent with the native JSON parsing functions. -** The JSON functions 'json-serialize', 'json-insert', +*** JSON functions support the semantics of RFC 8259. +The JSON functions 'json-serialize', 'json-insert', 'json-parse-string', and 'json-parse-buffer' now implement some of the semantics of RFC 8259 instead of the earlier RFC 4627. In particular, these functions now accept top-level JSON values that are neither arrays nor objects. --- -** Some JSON encoding functions are now obsolete. +*** Some JSON encoding functions are now obsolete. The functions 'json-encode-number', 'json-encode-hash-table', 'json-encode-key', and 'json-encode-list' are now obsolete. @@ -3009,7 +3041,7 @@ one of 'json-encode', 'json-encode-alist', 'json-encode-plist', or 'json-encode-array' instead. +++ -** Native JSON functions now signal an error if libjansson is unavailable. +*** Native JSON functions now signal an error if libjansson is unavailable. This affects 'json-serialize', 'json-insert', 'json-parse-string', and 'json-parse-buffer'. This can happen if Emacs was compiled with libjansson, but the DLL cannot be found and/or loaded by Emacs at run @@ -3027,10 +3059,12 @@ marked as such. This affects the suffix specified by completion 'annotation-function'. +++ -** An active minibuffer now has major mode 'minibuffer-mode', not the -erroneous 'minibuffer-inactive-mode' it formerly had. +** An active minibuffer now has major mode 'minibuffer-mode'. +This is instead of the erroneous 'minibuffer-inactive-mode' it +formerly had. -** When its first argument is a string, 'make-text-button' no longer +** 'make-text-button' no longer text properties of its first argument. +When its first argument is a string, 'make-text-button' no longer modifies the string's text properties; instead, it uses and returns a copy of the string. This helps avoid trouble when strings are shared or constants. @@ -3080,7 +3114,8 @@ These variables describe facts about the SQL standard and product-specific additions. There should be no need for users to customize them. -** The Lisp variables 'previous-system-messages-locale' and +** Some locale-related variables have been removed. +The Lisp variables 'previous-system-messages-locale' and 'previous-system-time-locale' have been removed, as they were created by mistake and were not useful to Lisp code. @@ -3287,8 +3322,9 @@ whenever the protected form terminates without error, with the specified variable bound to the the value of the protected form. +++ -** A function can now be thrown to the 'exit' label in addition to t or nil. -The command loop will call it with zero arguments before returning. +** The value thrown to the 'exit' label can now be a function. +This is in addition to values t or nil. If the value is a function, +the command loop will call it with zero arguments before returning. +++ ** The behavior of 'format-spec' is now closer to that of 'format'. @@ -3308,6 +3344,10 @@ If bound to non-nil, a command with '(interactive "e")' doesn't signal an error when invoked by input event that is not a mouse click (e.g., a key sequence). +** New variable 'redisplay-skip-initial-frame' to enable batch redisplay tests. +Setting it to nil forces the redisplay to do its job even in the +initial frame used in batch mode. + +++ ** Doc strings can now link to customization groups. Text like "customization group `whitespace'" will be made into a @@ -3331,8 +3371,7 @@ the dynamically bound 'generated-autoload-file' variable, the output file is now a explicit parameter. --- -** Dragging a file to Emacs will now also push the name of the file -onto 'file-name-history'. +** Dragging a file into Emacs pushes the file name onto 'file-name-history'. --- ** The 'easymenu' library is now preloaded. @@ -3426,11 +3465,13 @@ The new 'cl-type' pattern compares types using 'cl-typep', which allows comparing simple types like '(cl-type integer)', as well as forms like '(cl-type (integer 0 10))'. -*** New macro 'pcase-setq' +*** New macro 'pcase-setq'. This macro is the 'setq' equivalent of 'pcase-let', which allows for destructuring patterns in a 'setq' form. -** Edebug specification lists can use some new keywords: +** Edebug + +*** Edebug specification lists can use some new keywords: +++ **** '&interpose SPEC FUN ARGS..' lets FUN control parsing after SPEC. @@ -3447,7 +3488,8 @@ use) and HEAD is the code that matched SPEC. ** Dynamic modules changes +++ -*** The module header 'emacs-module.h' now contains type aliases +*** Type aliases for module functions and finalizers. +The module header 'emacs-module.h' now contains type aliases 'emacs_function' and 'emacs_finalizer' for module functions and finalizers, respectively. @@ -3457,18 +3499,19 @@ Use 'make_interactive' to give a module function an interactive specification. +++ -*** Module functions can now install an optional finalizer that is -called when the function object is garbage-collected. Use -'set_function_finalizer' to set the finalizer and +*** Module functions can now install an optional finalizer. +The finalizer is called when the function object is garbage-collected. +Use 'set_function_finalizer' to set the finalizer and 'get_function_finalizer' to retrieve it. +++ -*** Modules can now open a channel to an existing pipe process using -the new module function 'open_channel'. Modules can use this -functionality to asynchronously send data back to Emacs. +*** Modules can now open a channel to an existing pipe process. +Modules can use the new module function 'open_channel' to do that. +On capable systems, modules can use this functionality to +asynchronously send data back to Emacs. +++ -*** A new module API 'make_unibyte_string' is provided. +*** A new module API 'make_unibyte_string'. It can be used to create Lisp strings with arbitrary byte sequences (a.k.a. "raw bytes"). @@ -3480,8 +3523,8 @@ the first instance of the former string in the latter. +++ ** New function 'string-replace'. This function works along the line of 'replace-regexp-in-string', but -matching on strings instead of regexps, and does not change the global -match state. +it matches on fixed strings instead of regexps, and does not change +the global match state. +++ ** New function 'split-string-shell-command'. @@ -3490,8 +3533,9 @@ respecting quoting with single ('like this') and double ("like this") quotes, as well as backslash quoting (like\ this). ** New string manipulation functions added to subr-x.el. -'string-clean-whitespace', 'string-fill', 'string-limit', -'string-lines', 'string-pad' and 'string-chop-newline'. +the functions are 'string-clean-whitespace', 'string-fill', +'string-limit', 'string-lines', 'string-pad' and +'string-chop-newline'. +++ ** New function 'replace-regexp-in-region'. @@ -3516,7 +3560,7 @@ result. +++ ** New function 'file-backup-file-names'. This function returns the list of file names of all the backup files -of its file argument. +for the specified file. +++ ** New function 'directory-empty-p'. @@ -3533,7 +3577,7 @@ This is identical to 'ignore', but returns t instead. +++ ** New function 'sxhash-equal-including-properties'. -This is identical to 'sxhash-equal' but accounting also for string +This is identical to 'sxhash-equal' but also accounts for string properties. ** New function 'buffer-line-statistics'. @@ -3569,8 +3613,8 @@ parameter. --- ** New function 'get-locale-names'. -This utility function returns a list of locale names on the current -system. +This utility function returns a list of names of locales available on +the current system. +++ ** New function 'insert-into-buffer'. @@ -3676,8 +3720,9 @@ commands. --- ** New variables 'read-char-choice-use-read-key' and 'y-or-n-p-use-read-key'. -When non-nil, then functions 'read-char-choice' and 'y-or-n-p' (respectively) -use the function 'read-key' to read a character instead of using the minibuffer. +When non-nil, then functions 'read-char-choice' and 'y-or-n-p' +(respectively) use the function 'read-key' to read a character instead +of using the minibuffer. +++ ** New variable 'global-minor-modes'. @@ -3790,8 +3835,9 @@ boundary it encountered; now it keeps counting all the way to the region's (or buffer's) end. +++ -** 'file-modes', 'set-file-modes', and 'set-file-times' now have an -optional argument specifying whether to follow symbolic links. +** File-related APIs can optionally follow symlinks. +The functions 'file-modes', 'set-file-modes', and 'set-file-times' now +have an optional argument specifying whether to follow symbolic links. +++ ** 'format-seconds' can now be used for sub-second times. @@ -3855,9 +3901,10 @@ applying that 'secure-hash' to the buffer file name. This avoids any risk of excessively long file names. --- -** Functions operating on local file names now check that the file names +** File names checked for null bytes. +Functions operating on local file names now check that the file names don't contain any NUL bytes. This avoids subtle bugs caused by -xsilently using only the part of the file name until the first NUL byte. +silently using only the part of the file name until the first NUL byte. +++ ** New user option 'process-file-return-signal-string'. @@ -3937,7 +3984,7 @@ arbitrary-size integers, recursive types, and more. See the Info node +++ ** On MS-Windows, Emacs can now use the native image API to display images. Emacs can now use the MS-Windows GDI+ library to load and display -images in JPEG, PNG, GIF and TIFF formats. This support is enabled +images in JPEG, PNG, GIF and TIFF formats. This support is available unless Emacs was configured '--without-native-image-api'. This feature is experimental, and needs to be turned on to be used. commit 331be89e7ccb9cd51a0bb03cb7421ddb02e8ce58 Author: Lars Ingebrigtsen Date: Mon Sep 6 11:12:00 2021 +0200 Improve the gnus-group-default-list-level doc string * lisp/gnus/gnus-group.el (gnus-group-default-list-level): Improve doc string. diff --git a/lisp/gnus/gnus-group.el b/lisp/gnus/gnus-group.el index 4eea2df12b..c1b46d6e9e 100644 --- a/lisp/gnus/gnus-group.el +++ b/lisp/gnus/gnus-group.el @@ -118,7 +118,9 @@ If nil, only list groups that have unread articles." (defcustom gnus-group-default-list-level gnus-level-subscribed "Default listing level. -Ignored if `gnus-group-use-permanent-levels' is non-nil." +When `gnus-group-use-permanent-levels' is non-nil, this level is +used as the starting level until the user sets a different level, +and is ignored afterwards." :group 'gnus-group-listing :type '(choice (integer :tag "Level") (function :tag "Function returning level"))) commit 9309dc9df997bbd088391724272ae619622a5307 Author: Lars Ingebrigtsen Date: Mon Sep 6 11:07:55 2021 +0200 Reset gnus-group-use-permanent-levels when Gnus restarts * lisp/gnus/gnus-start.el (gnus-clear-system): Reset `gnus-group-use-permanent-levels' upon Gnus restart (bug#50416). diff --git a/lisp/gnus/gnus-start.el b/lisp/gnus/gnus-start.el index 02bbe19e7f..4bbeb24dc3 100644 --- a/lisp/gnus/gnus-start.el +++ b/lisp/gnus/gnus-start.el @@ -715,6 +715,9 @@ the first newsgroup." (kill-buffer (get-file-buffer gnus-current-startup-file))) ;; Clear the dribble buffer. (gnus-dribble-clear) + ;; Reset the level when Gnus is restarted. + (when (numberp gnus-group-use-permanent-levels) + (setq gnus-group-use-permanent-levels t)) ;; Kill global KILL file buffer. (when (get-file-buffer (gnus-newsgroup-kill-file nil)) (kill-buffer (get-file-buffer (gnus-newsgroup-kill-file nil)))) commit 7f9ca3b2f4f1a9800d7557f64e25bb3ee5059cba Author: Allen Li Date: Mon Sep 6 10:59:54 2021 +0200 Make `gnus-group-use-permanent-levels' work better * lisp/gnus/gnus-group.el (gnus-group-default-level): Removed implicit setting of gnus-group-use-permanent-levels. (gnus-group-list-groups): Set gnus-group-use-permanent-levels explicitly. (gnus-group-get-new-news): Set gnus-group-use-permanent-levels explicitly (bug#50417). (gnus-group-get-new-news): When the user has given a numeric prefix, use that as the list level. diff --git a/lisp/gnus/gnus-group.el b/lisp/gnus/gnus-group.el index b1134397e5..4eea2df12b 100644 --- a/lisp/gnus/gnus-group.el +++ b/lisp/gnus/gnus-group.el @@ -1176,11 +1176,11 @@ The following commands are available: (defun gnus-group-default-level (&optional level number-or-nil) (cond (gnus-group-use-permanent-levels - (or (setq gnus-group-use-permanent-levels - (or level (if (numberp gnus-group-use-permanent-levels) - gnus-group-use-permanent-levels - (or (gnus-group-default-list-level) - gnus-level-subscribed)))) + (or level + (if (numberp gnus-group-use-permanent-levels) + gnus-group-use-permanent-levels + (or (gnus-group-default-list-level) + gnus-level-subscribed)) (gnus-group-default-list-level) gnus-level-subscribed)) (number-or-nil level) @@ -1228,20 +1228,23 @@ The following commands are available: (let ((charset (gnus-group-name-charset nil string))) (gnus-group-name-decode string charset))) -(defun gnus-group-list-groups (&optional level unread lowest) +(defun gnus-group-list-groups (&optional level unread lowest update-level) "List newsgroups with level LEVEL or lower that have unread articles. Default is all subscribed groups. If argument UNREAD is non-nil, groups with no unread articles are also listed. -Also see the `gnus-group-use-permanent-levels' variable." +Also see the `gnus-group-use-permanent-levels' variable. If this +variable is non-nil, and UPDATE-LEVEL is non-nil (which is the +case interactively), the level will be updated by this command." (interactive (list (if current-prefix-arg (prefix-numeric-value current-prefix-arg) (or (gnus-group-default-level nil t) (gnus-group-default-list-level) - gnus-level-subscribed))) + gnus-level-subscribed)) + nil nil t) gnus-group-mode) (unless level (setq level (car gnus-group-list-mode) @@ -1288,7 +1291,9 @@ Also see the `gnus-group-use-permanent-levels' variable." (goto-char (point-max)) (forward-line -1))))))) ;; Adjust cursor point. - (gnus-group-position-point))) + (gnus-group-position-point) + (when (and update-level gnus-group-use-permanent-levels) + (setq gnus-group-use-permanent-levels level)))) (defun gnus-group-list-level (level &optional all) "List groups on LEVEL. @@ -4205,8 +4210,9 @@ otherwise all levels below ARG will be scanned too." (gnus-check-reasonable-setup) (gnus-run-hooks 'gnus-after-getting-new-news-hook) - (gnus-group-list-groups (and (numberp arg) - (max (car gnus-group-list-mode) arg))))) + (gnus-group-list-groups (and (numberp arg) arg)) + (when gnus-group-use-permanent-levels + (setq gnus-group-use-permanent-levels (gnus-group-default-level arg))))) (defun gnus-group-get-new-news-this-group (&optional n dont-scan) "Check for newly arrived news in the current group (and the N-1 next groups). commit bd4a2fc385e33d27831917b8901afcddc4a8b3df Author: Stefan Kangas Date: Mon Sep 6 08:47:10 2021 +0200 ; * etc/NEWS: Restore entry that had been inadvertently deleted. diff --git a/etc/NEWS b/etc/NEWS index 9b7cc8f33b..2d15ada438 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -3286,6 +3286,10 @@ It is written as '(:success BODY...)' where BODY is executed whenever the protected form terminates without error, with the specified variable bound to the the value of the protected form. +** New function 'benchmark-call' to measure the execution time of a function. +Additionally, the number of repetitions can be expressed as a minimal duration +in seconds. + +++ ** A function can now be thrown to the 'exit' label in addition to t or nil. The command loop will call it with zero arguments before returning. commit 4e5af2988fcf39f9d69a6a73c214f1a569ebbdf9 Author: Juri Linkov Date: Mon Sep 6 09:32:39 2021 +0300 * etc/NEWS: Reorder "Isearch and Replace" items diff --git a/etc/NEWS b/etc/NEWS index df7bc1efc9..9b7cc8f33b 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -645,13 +645,6 @@ specify 'cursor-type' to be '(box . SIZE)', the cursor becomes a hollow box if the point is on an image larger than SIZE pixels in any dimension. -+++ -*** New user option 'lazy-highlight-no-delay-length'. -Lazy highlighting of matches in Isearch now starts immediately if the -search string is at least this long. 'lazy-highlight-initial-delay' -still applies for shorter search strings, which avoids flicker in the -search buffer due to too many matches being highlighted. - +++ *** The user can now customize how "default" values are prompted for. The new utility function 'format-prompt' has been added which uses the @@ -967,7 +960,7 @@ setting the variable 'auto-save-visited-mode' buffer-locally to nil. * Changes in Specialized Modes and Packages in Emacs 28.1 -** Isearch +** Isearch and Replace +++ *** Interactive regular expression search now uses faces for sub-groups. @@ -981,6 +974,11 @@ This is controlled by the 'search-highlight-submatches' user option. This feature is available only on terminals that have enough colors to distinguish between sub-expression highlighting. ++++ +*** Interactive regular expression replace now uses faces for sub-groups. +Like 'search-highlight-submatches', this is controlled by the new user option +'query-replace-highlight-submatches'. + *** New user option 'isearch-wrap-pause' defines how to wrap the search. There are choices to disable wrapping completely and to wrap immediately. When wrapping immediately, it consistently handles the numeric arguments @@ -993,11 +991,6 @@ When this option is set, direction changes in Isearch move to another search match, if there is one, instead of moving point to the other end of the current match. -+++ -*** Interactive regular expression replace now uses faces for sub-groups. -Like 'search-highlight-submatches', this is controlled by the new user option -'query-replace-highlight-submatches'. - *** New key 'M-s M-.' starts isearch with the thing found at point. This key is bound to the new command 'isearch-forward-thing-at-point'. The new user option 'isearch-forward-thing-at-point' defines @@ -1005,6 +998,13 @@ a list of symbols to try to get the "thing" at point. By default, the first element of the list is 'region' that tries to yank the currently active region to the search string. ++++ +*** New user option 'lazy-highlight-no-delay-length'. +Lazy highlighting of matches in Isearch now starts immediately if the +search string is at least this long. 'lazy-highlight-initial-delay' +still applies for shorter search strings, which avoids flicker in the +search buffer due to too many matches being highlighted. + ** Dired +++ commit f9cd9d430a7cf89af0699a0e1933b3c7c8051524 Author: Eli Zaretskii Date: Mon Sep 6 07:28:05 2021 +0300 * doc/emacs/maintaining.texi (Xref Commands): Fix indexing. diff --git a/doc/emacs/maintaining.texi b/doc/emacs/maintaining.texi index e6cbb14ece..5b33c9bd3e 100644 --- a/doc/emacs/maintaining.texi +++ b/doc/emacs/maintaining.texi @@ -2243,6 +2243,7 @@ Display the reference on the current line (@code{xref-goto-xref}). With prefix argument, also bury the @file{*xref*} buffer. @item mouse-2 +@findex xref-select-and-show-xref The same as @code{mouse-1}, but make the window displaying the @file{*xref*} buffer the selected window (@code{xref-select-and-show-xref}). @@ -2284,8 +2285,8 @@ the match with @var{replacement}. @xref{Identifier Search}. Refresh the contents of the @file{*xref*} buffer (@code{xref-revert-buffer}. -@findex xref-quit @item q +@findex xref-quit Quit the window showing the @file{*xref*} buffer (@code{xref-quit}). @end table commit c3ca31308fe33102aa624f4665cc9126785c9886 Author: Stefan Kangas Date: Mon Sep 6 04:27:12 2021 +0200 * etc/NEWS: Improve file organization. diff --git a/etc/NEWS b/etc/NEWS index d1a9b7cf15..df7bc1efc9 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -31,9 +31,6 @@ and also requires GCC and Binutils to be available when Lisp code is natively compiled. See the Info node "(elisp) Native Compilation" for more details. ---- -** Support for building with Motif has been removed. - ** The Cairo graphics library is now used by default if present. '--with-cairo' is now the default, if the appropriate development files are found by 'configure'. Note that building with Cairo means using @@ -70,8 +67,7 @@ available, and this is the Cairo graphics library + HarfBuzz for font shaping, so 'configure' now recommends that combination. --- -** The ftx font backend driver has been removed. -It was declared obsolete in Emacs 27.1. +** Support for building with Motif has been removed. --- ** The configure option '--without-makeinfo' has been removed. @@ -83,6 +79,10 @@ This now requires makeinfo, which is part of the texinfo package. GCC has withdrawn the '-fcheck-pointer-bounds' option and support for its implementation has been removed from the Linux kernel. +--- +** The ftx font backend driver has been removed. +It was declared obsolete in Emacs 27.1. + --- ** Emacs no longer supports old OpenBSD systems. OpenBSD 5.3 and older releases are no longer supported, as they lack @@ -91,21 +91,22 @@ proper pty support that Emacs needs. * Startup Changes in Emacs 28.1 ---- -** File names given on the command line will now be pushed onto -'file-name-history'. - --- ** In GTK builds, Emacs now supports startup notification. This means that Emacs won't steal keyboard focus upon startup (when started via the Desktop) if the user is typing into another application. -** Emacs can support 24-bit color TTY without terminfo database. -If your text-mode terminal supports 24-bit true color, but your system -lacks the terminfo database, you can instruct Emacs to support 24-bit -true color by setting 'COLORTERM=truecolor' in the environment. This is -useful on systems such as FreeBSD which ships only with "etc/termcap". +** Emacs now prints a backtrace when signaling an error in batch mode. +This makes debugging Emacs Lisp scripts run in batch mode easier. To +get back the old behavior, set the new variable +'backtrace-on-error-noninteractive' to a nil value. + +--- +** Errors in 'kill-emacs-hook' no longer prevent Emacs from shutting down. +If a function in that hook signals an error in an interactive Emacs, +the user will be prompted on whether to continue. If the user doesn't +answer within five seconds, Emacs will continue shutting down anyway. ** Emacs now supports loading a Secure Computing filter. This is supported only on capable GNU/Linux systems. To activate, @@ -118,89 +119,69 @@ avoid security issues when executing untrusted code. See the manual page for 'seccomp' system call, for details about Secure Computing filters. -** Setting 'fill-column' to nil is obsolete. -This undocumented use of 'fill-column' is now obsolete. To disable -auto filling, turn off 'auto-fill-mode' instead. - -For instance, you could add something like the following to your init -file: +** Emacs can support 24-bit color TTY without terminfo database. +If your text-mode terminal supports 24-bit true color, but your system +lacks the terminfo database, you can instruct Emacs to support 24-bit +true color by setting 'COLORTERM=truecolor' in the environment. This is +useful on systems such as FreeBSD which ships only with "etc/termcap". - (add-hook 'foo-mode-hook (lambda () (auto-fill-mode -1)) +** New variable 'redisplay-skip-initial-frame' to enable batch redisplay tests. +Setting it to nil forces the redisplay to do its job even in the +initial frame used in batch mode. - -* Changes in Emacs 28.1 +--- +** File names given on the command line will now be pushed onto +'file-name-history'. ** 'blink-cursor-mode' is now enabled by default regardless of the UI. It used to be enabled when Emacs is started in GUI mode but not when started in text mode. The cursor still only actually blinks in GUI frames. ---- -** 'auto-composition-mode' can now be selectively disabled on some TTYs. -Some text-mode terminals produce display glitches trying to compose -characters. The 'auto-composition-mode' can now have a string value -that names a terminal type; if the value returned by the 'tty-type' -function compares equal with that string, automatic composition will -be disabled in windows shown on that terminal. The Linux terminal -sets this up by default. - -+++ -** Etags now supports the Mercury programming language. -See https://mercurylang.org. + +* Changes in Emacs 28.1 -+++ -** Etags command line option '--declarations' now has Mercury-specific behavior. -All Mercury declarations are tagged by default. However, for -compatibility with 'etags' support for Prolog, predicates and -functions appearing first in clauses will also be tagged if 'etags' is -invoked with the '--declarations' command-line option. +** The new NonGNU ELPA archive is enabled by default alongside GNU ELPA. +++ -** New command 'font-lock-update', bound to 'C-x x f'. -This command updates the syntax highlighting in this buffer. +** New command 'execute-extended-command-for-buffer'. +This new command, bound to 'M-S-x', works like +'execute-extended-command', but limits the set of commands to the +commands that have been determined to be particularly useful with the +current mode. +++ -** A new standard face 'font-lock-doc-markup-face'. -Intended for documentation mark-up syntax and tags inside text that -uses 'font-lock-doc-face', with which it should harmonise. It would -typically be used in structured documentation comments in program -source code by language-specific modes, for mark-up conventions like -Haddock, Javadoc or Doxygen. By default this face inherits from -'font-lock-constant-face'. - -** The new NonGNU ELPA archive is enabled by default alongside GNU ELPA. +** New user option 'read-extended-command-predicate'. +This user option controls how 'M-x' performs completion of commands when +you type 'TAB'. By default, any command that matches what you have +typed is considered a completion candidate, but you can customize this +option to exclude commands that are not applicable to the current +buffer's major and minor modes, and respect the command's completion +predicate (if any). +++ -** New command 'recenter-other-window', bound to 'S-M-C-l'. -Like 'recenter-top-bottom' acting in the other window. +** When 'suggest-key-bindings' is non-nil, the completion list of 'M-x' +shows equivalent key bindings for all commands that have them. -** Minibuffer scrolling is now conservative by default. -This is controlled by the new variable 'scroll-minibuffer-conservatively'. +** New user option 'completions-detailed'. +When non-nil, some commands like 'describe-symbol' show more detailed +completions with more information in completion prefix and suffix. -In addition, there is a new variable -'redisplay-adhoc-scroll-in-resize-mini-windows' to disable the -ad-hoc auto-scrolling when resizing minibuffer windows. It has been -found that its heuristic can be counter productive in some corner -cases, tho the cure may be worse than the disease. This said, the -effect should be negligible in the vast majority of cases anyway. +--- +** 'C-s' in 'M-x' now searches over completions again. +In Emacs 23, typing 'M-x' ('read-extended-command') and then 'C-s' (to +do an interactive search) would search over possible completions. +This was lost in Emacs 24, but is now back again. -+++ -** Improved handling of minibuffers on switching frames. -By default, when you switch to another frame, an active minibuffer now -moves to the newly selected frame. Nevertheless, the effect of what -you type in the minibuffer happens in the frame where the minibuffer -was first activated. An alternative behavior is available by -customizing 'minibuffer-follows-selected-frame' to nil. Here, the -minibuffer stays in the frame where you first opened it, and you must -switch back to this frame to continue or abort its command. The old -behavior, which mixed these two, can be approximated by customizing -'minibuffer-follows-selected-frame' to a value which is neither nil -nor t. +--- +** User option 'completions-format' supports a new value 'one-column'. +++ -** New user option 'read-minibuffer-restore-windows'. -When customized to nil, it uses 'minibuffer-restore-windows' in -'minibuffer-exit-hook' to remove only the window showing the -"*Completions*" buffer. +** A new keymap for buffer actions has been added. +The 'C-x x' keymap now holds keystrokes for various buffer-oriented +commands. The new keystrokes are 'C-x x g' ('revert-buffer-quick'), +'C-x x r' ('rename-buffer'), 'C-x x u' ('rename-uniquely'), 'C-x x n' +('clone-buffer'), 'C-x x i' ('insert-buffer'), 'C-x x t' +('toggle-truncate-lines') and 'C-x x f' ('font-lock-update'). +++ ** New system for displaying documentation for groups of functions. @@ -209,77 +190,117 @@ choosing a group, or clicking a button in the "*Help*" buffers when looking at the doc string of a function that belongs to one of these groups. ++++ +** New minor mode 'context-menu-mode' for context menus popped by 'mouse-3'. +When this mode is enabled, clicking 'down-mouse-3' anywhere in the buffer +pops up a menu whose contents depends on surrounding context near the +mouse click. You can change the order of the default sub-menus in the +context menu by customizing the user option 'context-menu-functions'. +You can also invoke the context menu by pressing 'S-'. + ++++ +** Modifiers now go outside angle brackets in pretty-printed key bindings. +For example, 'RET' with Control and Meta modifiers is now shown as +'C-M-' instead of ''. Either variant can be used +as input; functions such as 'kbd' and 'read-kbd-macro' accept both +styles as equivalent (they have done so for a long time). + --- -** Improved "find definition" feature of "*Help*" buffers. -Now clicking on the link to find the definition of functions generated -by 'cl-defstruct', or variables generated by 'define-derived-mode', -for example, will go to the exact place where they are defined. +** 'eval-expression' no longer signals an error on incomplete expressions. +Previously, typing 'M-: ( RET' would result in Emacs saying "End of +file during parsing" and dropping out of the minibuffer. The user +would have to type 'M-: M-p' to edit and redo the expression. Now +Emacs will echo the message and allow the user to continue editing. -** New variable 'redisplay-skip-initial-frame' to enable batch redisplay tests. -Setting it to nil forces the redisplay to do its job even in the -initial frame used in batch mode. ++++ +** 'eval-last-sexp' now handles 'defvar'/'defcustom'/'defface' specially. +This command would previously not redefine values defined by these +forms, but this command has now been changed to work more like +'eval-defun', and reset the values as specified. --- -** Support for the 'strike-through' face attribute on TTY frames. -If your terminal's termcap or terminfo database entry has the 'smxx' -capability defined, Emacs will now emit the prescribed escape -sequences necessary to render faces with the 'strike-through' -attribute on TTY frames. +** New user option 'use-short-answers'. +When non-nil, the function 'y-or-n-p' is used instead of +'yes-or-no-p'. This eliminates the need to define an alias that maps +one to another in the init file. The same user option also controls +whether the function 'read-answer' accepts short answers. +++ -** Emacs now defaults to UTF-8 instead of ISO-8859-1. -This is only for the default, where the user has set no 'LANG' (or -similar) variable or environment. This change should lead to no -user-visible changes for normal usage. +** New user option 'kill-buffer-delete-auto-save-files'. +If non-nil, killing a buffer that has an auto-save file will prompt +the user for whether that file should be deleted. (Note that +'delete-auto-save-files', if non-nil, was previously documented to +result in deletion of auto-save files when killing a buffer without +unsaved changes, but this has apparently not worked for several +decades, so the documented semantics of this variable has been changed +to match the behaviour.) +++ -** New variables that hold default buffer names for shell output. -The new constants 'shell-command-buffer-name' and -'shell-command-buffer-name-async' store the default buffer names -for the output of, respectively, synchronous and async shell -commands. +** New user option 'next-error-message-highlight'. +In addition to a fringe arrow, 'next-error' error may now optionally +highlight the current error message in the 'next-error' buffer. +This user option can be also customized to keep highlighting on all +visited errors, so you can have an overview what errors were already visited. -** Support for '(box . SIZE)' 'cursor-type'. -By default, 'box' cursor always has a filled box shape. But if you -specify 'cursor-type' to be '(box . SIZE)', the cursor becomes a hollow -box if the point is on an image larger than SIZE pixels in any -dimension. +--- +** New choice 'next-error-quit-window' for 'next-error-found-function'. +When 'next-error-found-function' is customized to 'next-error-quit-window', +then typing the numeric prefix argument 0 before the command 'next-error' +will quit the source window after visiting the next occurrence. +++ -** New user option 'word-wrap-by-category'. -When word-wrap is enabled, and this option is non-nil, that allows -Emacs to break lines after more characters than just whitespace -characters. In particular, this significantly improves word-wrapping -for CJK text mixed with Latin text. +** New user option 'file-preserve-symlinks-on-save'. +This controls what Emacs does when saving buffers that visit files via +symbolic links, and 'file-precious-flag' is non-nil. + ++++ +** New user option 'copy-directory-create-symlink'. +If non-nil, will make `copy-directory' (when used on a symbolic +link) copy the link instead of following the link. The default is +nil, so the default behavior is unchanged. + ++++ +** New user option 'ignored-local-variable-values'. +This is the opposite of 'safe-local-variable-values' -- it's an alist +of variable-value pairs that are to be ignored when reading a +local-variables section of a file. --- -** Rudimentary support for the 'st' terminal emulator. -Emacs now supports 256 color display on the 'st' terminal emulator. +** Specific warnings can now be disabled from the warning buffer. +When a warning is displayed to the user, the resulting buffer now has +buttons which allow making permanent changes to the treatment of that +warning. Automatic showing of the warning can be disabled (although +it is still logged to the "*Messages*" buffer), or the warning can be +disabled entirely. + ++++ +** ".dir-locals.el" now supports setting 'auto-mode-alist'. +The new 'auto-mode-alist' specification in ".dir-locals.el" files can +now be used to override the global 'auto-mode-alist' in the current +directory tree. --- -** Mouse wheel scrolling now works on more parts of frame's display. -When using 'mwheel-mode', the mouse wheel will now scroll also when -the mouse cursor is on the scroll bars, fringes, margins, header line, -and mode line. ('mwheel-mode' is enabled by default on most graphical -displays.) +** User option 'uniquify-buffer-name-style' can now be a function. +This user option can be one of the predefined styles or a function to +personalize the uniquified buffer name. --- -** Mouse wheel scrolling now defaults to one line at a time. +** 'remove-hook' is now an interactive command. + +** Frames +++ -** Mouse wheel scrolling with Shift modifier now scrolls horizontally. -This works in text buffers and over images. Typing a numeric prefix arg -(e.g. 'M-5') before starting horizontal scrolling changes its step value. -The value is saved in the user option 'mouse-wheel-scroll-amount-horizontal'. +*** The key prefix 'C-x 5 5' displays next command buffer in a new frame. +It's bound to the command 'other-frame-prefix' that requests the buffer +of the next command to be displayed in a new frame. ---- -** New choice 'permanent' for 'shift-select-mode'. -When the mark was activated by shifted motion keys, -non-shifted motion keys don't deactivate the mark -after customizing 'shift-select-mode' to 'permanent'. ++++ +*** New command 'clone-frame' (bound to 'C-x 5 c'). +This is like 'C-x 5 2', but uses the frame parameters of the current +frame instead of 'default-frame-alist'. --- -** The default value of 'frame-title-format' and 'icon-title-format' has changed. +*** The default value of 'frame-title-format' and 'icon-title-format' has changed. These variables are used to display the title bar of visible frames and the title bar of an iconified frame. They now show the name of the current buffer and the text "GNU Emacs" instead of the value of @@ -290,623 +311,699 @@ your init file: ("" invocation-name "@" system-name))) +++ -** 'nobreak-char-display' now also affects all non-ASCII space characters. -Previously, this was limited only to NO-BREAK-SPACE and hyphen -characters. Now it also covers the rest of the non-ASCII Unicode -space characters. +*** New frame parameter 'drag-with-tab-line'. +This parameter, similar to 'drag-with-header-line', allows moving frames +by dragging the tab lines of their topmost windows with the mouse. + ++++ +*** A prefix arg now causes 'delete-other-frames' to only iconify frames. --- -** Prefer "chat.freenode.net" to "irc.freenode.net". -"chat.freenode.net" has been the preferred address for connecting to the -freenode IRC network for years now. Occurrences of "irc.freenode.net" -have been replaced with "chat.freenode.net" throughout Emacs. +*** Commands 'set-frame-width' and 'set-frame-height' can now get their +input using the minibuffer. -+++ -** New functions 'null-device' and 'path-separator'. -These functions return the connection local value of the respective -variables. This can be used for remote hosts. +** Windows -** Emacs now prints a backtrace when signaling an error in batch mode. -This makes debugging Emacs Lisp scripts run in batch mode easier. To -get back the old behavior, set the new variable -'backtrace-on-error-noninteractive' to a nil value. +*** The key prefix 'C-x 4 1' displays next command buffer in the same window. +It's bound to the command 'same-window-prefix' that requests the buffer +of the next command to be displayed in the same window. -** 'redisplay-skip-fontification-on-input' helps Emacs keep up with fast input. -This is another attempt to solve the problem of handling high key repeat rate -and other "slow scrolling" situations. It is hoped it behaves better -than 'fast-but-imprecise-scrolling' and 'jit-lock-defer-time'. -It is not enabled by default. +*** The key prefix 'C-x 4 4' displays next command buffer in a new window. +It's bound to the command 'other-window-prefix' that requests the buffer +of the next command to be displayed in a new window. +++ -** Modifiers now go outside angle brackets in pretty-printed key bindings. -For example, 'RET' with Control and Meta modifiers is now shown as -'C-M-' instead of ''. Either variant can be used -as input; functions such as 'kbd' and 'read-kbd-macro' accept both -styles as equivalent (they have done so for a long time). +*** New command 'recenter-other-window', bound to 'S-M-C-l'. +Like 'recenter-top-bottom' acting in the other window. +++ -** New user option 'lazy-highlight-no-delay-length'. -Lazy highlighting of matches in Isearch now starts immediately if the -search string is at least this long. 'lazy-highlight-initial-delay' -still applies for shorter search strings, which avoids flicker in the -search buffer due to too many matches being highlighted. +*** New user option 'delete-window-choose-selected'. +This allows to choose a frame's selected window after deleting the +previously selected one. +++ -** A new keymap for buffer actions has been added. -The 'C-x x' keymap now holds keystrokes for various buffer-oriented -commands. The new keystrokes are 'C-x x g' ('revert-buffer-quick'), -'C-x x r' ('rename-buffer'), 'C-x x u' ('rename-uniquely'), 'C-x x n' -('clone-buffer'), 'C-x x i' ('insert-buffer'), 'C-x x t' -('toggle-truncate-lines') and 'C-x x f' ('font-lock-update'). - ---- -** Commands 'set-frame-width' and 'set-frame-height' can now get their -input using the minibuffer. +*** New argument NO-OTHER for some window functions. +'get-lru-window', ‘get-mru-window’ and 'get-largest-window' now accept a +new optional argument NO-OTHER which, if non-nil, avoids returning a +window whose 'no-other-window' parameter is non-nil. +++ -** New command 'clone-frame' (bound to 'C-x 5 c'). -This is like 'C-x 5 2', but uses the frame parameters of the current -frame instead of 'default-frame-alist'. +*** New 'display-buffer' function 'display-buffer-use-least-recent-window'. +This is like 'display-buffer-use-some-window', but won't reuse the +current window, and when called repeatedly will try not to reuse a +previously selected window. ---- -** New help window when Emacs prompts before opening a large file. -Commands like 'find-file' or 'visit-tags-table' ask to visit a file -normally or literally when the file is larger than a certain size (by -default, 9.5 MiB). Press '?' or 'C-h' in that prompt to read more -about the different options to visit a file, how you can disable the -prompt, and how you can tweak the file size threshold. +*** New function 'window-bump-use-time'. +This updates the use time of a window. -+++ -** New user option 'query-about-changed-file'. -If non-nil (the default), users are prompted as before when -re-visiting a file that has changed externally after it was visited -the first time. If nil, the user is not prompted, but instead the -buffer is opened with its contents before the change, and the user is -given instructions how to revert the buffer. +** Minibuffer -+++ -** Improved support for terminal emulators that encode the Meta flag. -Some terminal emulators set the 8th bit of Meta characters, and then -encode the resulting character code as if it were non-ASCII character -above codepoint 127. Previously, the only way of using these in Emacs -was to set up the terminal emulator to use the 'ESC' characters to send -Meta characters to Emacs, e.g., send "ESC x" when the user types -'M-x'. You can now avoid the need for this setup of such terminal -emulators by using the new input-meta-mode with the special value -'encoded' with these terminal emulators. +*** Minibuffer scrolling is now conservative by default. +This is controlled by the new variable 'scroll-minibuffer-conservatively'. + +In addition, there is a new variable +'redisplay-adhoc-scroll-in-resize-mini-windows' to disable the +ad-hoc auto-scrolling when resizing minibuffer windows. It has been +found that its heuristic can be counter productive in some corner +cases, tho the cure may be worse than the disease. This said, the +effect should be negligible in the vast majority of cases anyway. +++ -** New frame parameter 'drag-with-tab-line'. -This parameter, similar to 'drag-with-header-line', allows moving frames -by dragging the tab lines of their topmost windows with the mouse. +*** Improved handling of minibuffers on switching frames. +By default, when you switch to another frame, an active minibuffer now +moves to the newly selected frame. Nevertheless, the effect of what +you type in the minibuffer happens in the frame where the minibuffer +was first activated. An alternative behavior is available by +customizing 'minibuffer-follows-selected-frame' to nil. Here, the +minibuffer stays in the frame where you first opened it, and you must +switch back to this frame to continue or abort its command. The old +behavior, which mixed these two, can be approximated by customizing +'minibuffer-follows-selected-frame' to a value which is neither nil +nor t. - -* Editing Changes in Emacs 28.1 ++++ +*** New user option 'read-minibuffer-restore-windows'. +When customized to nil, it uses 'minibuffer-restore-windows' in +'minibuffer-exit-hook' to remove only the window showing the +"*Completions*" buffer. -** New value 'save-some-buffers-root' of 'save-some-buffers-default-predicate'. -It allows to ask about saving only files under the project root -or in subdirectories of the directory that was default during -command invocation. +** Mode Line ---- -** Dragging a file to Emacs will now also push the name of the file -onto 'file-name-history'. ++++ +*** New user option 'mode-line-compact'. +If non-nil, repeating spaces are compressed into a single space. If +'long', this is only done when the mode line is longer than the +current window width (in characters). +++ -** A prefix arg now causes 'delete-other-frames' to only iconify frames. +*** New user options to control the line/column numbers in the mode line. +'mode-line-position-line-format' is the line number format (when +'line-number-mode' is on), 'mode-line-position-column-format' is +the column number format (when 'column-number-mode' is on), and +'mode-line-position-column-line-format' is the combined format (when +both modes are on). -** Menus +** Tab Bars -+++ -*** New minor mode 'context-menu-mode' for context menus popped by 'mouse-3'. -When this mode is enabled, clicking 'down-mouse-3' anywhere in the buffer -pops up a menu whose contents depends on surrounding context near the -mouse click. You can change the order of the default sub-menus in the -context menu by customizing the user option 'context-menu-functions'. -You can also invoke the context menu by pressing 'S-'. +*** The key prefix 'C-x t t' displays next command buffer in a new tab. +It's bound to the command 'other-tab-prefix' that requests the buffer +of the next command to be displayed in a new tab. +++ -*** The "Edit => Clear" menu item now obeys a rectangular region. +*** New command 'C-x t C-r' to open file read-only in other tab. -+++ -** New command 'execute-extended-command-for-buffer'. -This new command, bound to 'M-S-x', works like -'execute-extended-command', but limits the set of commands to the -commands that have been determined to be particularly useful with the -current mode. +--- +*** The tab bar is frame-local when 'tab-bar-show' is a number. +Show/hide the tab bar independently for each frame, according to the +value of 'tab-bar-show'. -+++ -** New user option 'read-extended-command-predicate'. -This user option controls how 'M-x' performs completion of commands when -you type 'TAB'. By default, any command that matches what you have -typed is considered a completion candidate, but you can customize this -option to exclude commands that are not applicable to the current -buffer's major and minor modes, and respect the command's completion -predicate (if any). +--- +*** New command 'toggle-frame-tab-bar'. +It can be used to enable/disable the tab bar individually on each frame +independently from the value of 'tab-bar-mode' and 'tab-bar-show'. --- -** 'eval-expression' now no longer signals an error on incomplete expressions. -Previously, typing 'M-: ( RET' would result in Emacs saying "End of -file during parsing" and dropping out of the minibuffer. The user -would have to type 'M-: M-p' to edit and redo the expression. Now -Emacs will echo the message and allow the user to continue editing. +*** New user option 'tab-bar-format' defines a list of tab bar items. +When it contains 'tab-bar-format-global' (possibly appended after +'tab-bar-format-align-right'), then after enabling 'display-time-mode' +(or any other mode that uses 'global-mode-string') it displays time +aligned to the right on the tab bar instead of the mode line. +When 'tab-bar-format-tabs' is replaced with 'tab-bar-format-tabs-groups', +then the tab bar displays tab groups. -+++ -** 'eval-last-sexp' now handles 'defvar'/'defcustom'/'defface' specially. -This command would previously not redefine values defined by these -forms, but this command has now been changed to work more like -'eval-defun', and reset the values as specified. +--- +*** 'Mod-9' bound to 'tab-last' now switches to the last tab. +It also supports a negative argument. -+++ -** Standalone 'M-y' allows interactive selection from previous kills. -'M-y' can now be typed after a command that is not a yank command. -When invoked like that, it prompts in the minibuffer for one of the -previous kills, offering completion and minibuffer-history navigation -through previous kills recorded in the kill ring. A similar feature -in Isearch can be invoked if you bind 'C-s M-y' to the command -'isearch-yank-pop'. When the user option 'yank-from-kill-ring-rotate' -is nil the kill ring is not rotated after 'yank-from-kill-ring'. +--- +*** New command 'tab-duplicate' bound to 'C-x t n'. --- -** New user options 'copy-region-blink-delay' and 'delete-pair-blink-delay'. -'copy-region-blink-delay' specifies a delay to indicate the region -copied by 'kill-ring-save'. 'delete-pair-blink-delay' specifies -a delay to show a paired character to delete. +*** 'C-x t N' creates a new tab at the specified absolute position. +It also supports a negative argument. -+++ -** New command 'undo-redo'. -It undoes previous undo commands, but doesn't record itself as an -undoable command. +--- +*** 'C-x t M' moves the current tab to the specified absolute position. +It also supports a negative argument. -+++ -** 'read-number' now has its own history variable. -Additionally, the function now accepts a HIST argument which can be -used to specify a custom history variable. +--- +*** 'C-x t G' assigns a group name to the tab. +'tab-close-group' can close all tabs that belong to the selected group. +The user option 'tab-bar-new-tab-group' defines the default group of a +new tab. After customizing 'tab-bar-tab-post-change-group-functions' +to 'tab-bar-move-tab-to-group', changing the tab group will also move it +closer to other tabs in the same group. -+++ -** Input history for 'goto-line' can now be made local to every buffer. -In any event, line numbers used with 'goto-line' are kept in their own -history list. This should help make faster the process of finding -line numbers that were previously jumped to. By default, all buffers -share a single history list. To make every buffer have its own -history list, customize the user option 'goto-line-history-local'. +--- +*** New user option 'tab-bar-tab-name-format-function'. -+++ -** New command 'goto-line-relative' to use in a narrowed buffer. -It moves point to the line relative to the accessible portion of the -narrowed buffer. 'M-g M-g' in Info is rebound to this command. -When 'widen-automatically' is non-nil, 'goto-line' widens the narrowed -buffer to be able to move point to the inaccessible portion. -'goto-line-relative' is bound to 'C-x n g'. +--- +*** New user option 'tab-line-tab-name-format-function'. -+++ -** When called interactively, 'goto-char' now offers the number at -point as default. +--- +*** The tabs in the tab line can now be scrolled using horizontal scroll. +If your mouse or trackpad supports it, you can now scroll tabs when +the mouse pointer is in the tab line by scrolling left or right. -+++ -** When 'suggest-key-bindings' is non-nil, the completion list of 'M-x' -shows equivalent key bindings for all commands that have them. +--- +*** New tab-line faces and options. +The face 'tab-line-tab-special' is used for tabs whose buffers are +special, i.e. not file-backed. The face +'tab-line-tab-inactive-alternate' is used to display inactive tabs +with an alternating background color, making them easier to +distinguish between, especially if the face 'tab-line-tab' is +configured to not display with a box; this alternate face is only +applied when the option 'tab-line-tab-face-functions' is +so-configured. That option may also be used to customize tab-line +faces in other ways. -** Autosaving via 'auto-save-visited-mode' can now be inhibited by -setting the variable 'auto-save-visited-mode' buffer-locally to nil. +** Mouse wheel -** New commands to describe buttons and widgets have been added. -'widget-describe' (on a widget) will pop up a help buffer and give a -description of the properties. Likewise 'button-describe' does the -same for a button. +--- +*** Mouse wheel scrolling now defaults to one line at a time. -** Obsolete aliases are no longer hidden from command completion. -Completion of command names now considers obsolete aliases as -candidates, if they were marked obsolete in the current major version -of Emacs. Invoking a command via an obsolete alias now mentions the -obsolescence fact and shows the new name of the command. +--- +*** Mouse wheel scrolling now works on more parts of frame's display. +When using 'mwheel-mode', the mouse wheel will now scroll also when +the mouse cursor is on the scroll bars, fringes, margins, header line, +and mode line. ('mwheel-mode' is enabled by default on most graphical +displays.) +++ -** New command 'revert-buffer-with-fine-grain'. -Revert a buffer trying to be as non-destructive as possible, -preserving markers, properties and overlays. The new variable -'revert-buffer-with-fine-grain-max-seconds' specifies the maximum -number of seconds that 'revert-buffer-with-fine-grain' should spend -trying to be non-destructive. +*** Mouse wheel scrolling with Shift modifier now scrolls horizontally. +This works in text buffers and over images. Typing a numeric prefix arg +(e.g. 'M-5') before starting horizontal scrolling changes its step value. +The value is saved in the user option 'mouse-wheel-scroll-amount-horizontal'. -+++ -** New command 'memory-report'. -This command opens a new buffer called "*Memory Report*" and gives a -summary of where Emacs is using memory currently. +** Customize -+++ -** New user option 'isearch-repeat-on-direction-change'. -When this option is set, direction changes in Isearch move to another -search match, if there is one, instead of moving point to the other -end of the current match. +--- +*** Customize buffers can now be reverted with 'C-x x g'. -** Outline +*** Most customize commands now hide obsolete user options. +Obsolete user options are no longer shown in the listings produced by +the commands 'customize', 'customize-group', 'customize-apropos' and +'customize-changed'. -+++ -*** New commands to cycle heading visibility. -Typing 'TAB' on a heading line cycles the current section between -"hide all", "subheadings", and "show all" states. Typing 'S-TAB' -anywhere in the buffer cycles the whole buffer between "only top-level -headings", "all headings and subheadings", and "show all" states. +To customize obsolete user options, use 'customize-option' or +'customize-saved'. -+++ -*** New user option 'outline-minor-mode-cycle'. -This user option customizes 'outline-minor-mode', with the difference -that 'TAB' and 'S-TAB' on heading lines cycle heading visibility. -Typing 'TAB' on a heading line cycles the current section between -"hide all", "subheadings", and "show all" states. Typing 'S-TAB' on a -heading line cycles the whole buffer between "only top-level -headings", "all headings and subheadings", and "show all" states. +*** New SVG icons for checkboxes and arrows. +They will be used automatically instead of the old icons. If Emacs is +built without SVG support, the old icons will be used instead. ---- -*** New user option 'outline-minor-mode-highlight'. -This user option customizes 'outline-minor-mode'. It puts -highlighting on heading lines using standard outline faces. This -works well only when there are no conflicts with faces used by the -major mode. +** Help +++ -** New commands 'copy-matching-lines' and 'kill-matching-lines'. -These commands are similar to the command 'flush-lines', -but add the matching lines to the kill ring as a single string, -including the newlines that separate the lines. - - -* Changes in Specialized Modes and Packages in Emacs 28.1 - -** Completion List Mode +*** New command 'describe-command' shows help for a command. +This can be used instead of 'describe-function' for interactive +commands and is globally bound to 'C-h x'. -New key bindings have been added to 'completion-list-mode': 'n' and -'p' now navigate completions, and 'M-g M-c' switches to the -minibuffer and back to the completion list buffer. ++++ +*** New command 'describe-keymap' describes keybindings in a keymap. -** Benchmark -*** New function 'benchmark-call' to measure the execution time of a function. -Additionally, the number of repetitions can be expressed as a minimal duration -in seconds. +*** New command 'apropos-function'. +This works like 'C-u M-x apropos-command' but is more discoverable. -** Macroexp ---- -*** New function 'macroexp-file-name' to know the name of the current file. --- -*** New function 'macroexp-compiling-p' to know if we're compiling. +*** New keybinding 'C-h R' prompts for a manual to display and displays it. + --- -*** New function 'macroexp-warn-and-return' to help emit warnings. -This used to be named 'macroexp--warn-and-return' and has proved useful -and well-behaved enough to lose the "internal" marker. +*** Keybindings in 'help-mode' use the new 'help-key-binding' face. +This face is added by 'substitute-command-keys' to any "\[command]" +substitution. The return value of that function should consequently +be assumed to be a propertized string. + +Note that the new face will also be used in tooltips. When using the +GTK toolkit, this is only true if 'x-gtk-use-system-tooltips' is t. -** Bindat +--- +*** The 'help-for-help' ('C-h C-h') screen has been redesigned. +++ -*** New 'Bindat type expression' description language. -This new system is provided by the new macro 'bindat-type' and -obsoletes the old data layout specifications. It supports -arbitrary-size integers, recursive types, and more. See the Info node -"(elisp) Byte Packing" in the ELisp manual for more details. +*** New convenience commands with short keys in the Help buffer. +New command 'help-view-source' ('s') will view the source file (if +any) of the current help topic. New command 'help-goto-info' ('i') +will look up the current symbol (if any) in Info. New command +'help-customize' ('c') will customize the variable or the face +(if any) whose doc string is being shown in the Help buffer. -** pcase +--- +*** New user option 'describe-bindings-outline'. +It enables outlines in the output buffer of 'describe-bindings' that +can provide a better overview in a long list of available bindings. +++ -*** The 'or' pattern now binds the union of the vars of its sub-patterns. -If a variable is not bound by the subpattern that matched, it gets bound -to nil. This was already sometimes the case, but it is now guaranteed. +*** New command 'lossage-size'. +It allows users to set the maximum number of keystrokes and commands +recorded for the purpose of 'view-lossage'. -+++ -*** The 'pred' pattern can now take the form '(pred (not FUN))'. -This is like '(pred (lambda (x) (not (FUN x))))' but results -in better code. +*** New commands to describe buttons and widgets. +'widget-describe' (on a widget) will pop up a help buffer and give a +description of the properties. Likewise 'button-describe' does the +same for a button. --- -*** New function 'pcase-compile-patterns' to write other macros. +*** Improved "find definition" feature of "*Help*" buffers. +Now clicking on the link to find the definition of functions generated +by 'cl-defstruct', or variables generated by 'define-derived-mode', +for example, will go to the exact place where they are defined. -*** Added 'cl-type' pattern. -The new 'cl-type' pattern compares types using 'cl-typep', which allows -comparing simple types like '(cl-type integer)', as well as forms like -'(cl-type (integer 0 10))'. +*** New commands 'apropos-next-symbol' and 'apropos-previous-symbol'. +These new navigation commands are bound to 'n' and 'p' in +'apropos-mode'. -*** New macro 'pcase-setq' -This macro is the 'setq' equivalent of 'pcase-let', which allows for -destructuring patterns in a 'setq' form. +--- +*** The command 'view-lossage' can now be invoked from the menu bar. +The menu bar "Help" menu now has a "Show Recent Inputs" item under the +"Describe" sub-menu. -+++ -** profiler.el -The results displayed by 'profiler-report' now have the usage figures -at the left hand side followed by the function name. This is intended -to make better use of the horizontal space, in particular eliminating -the truncation of function names. There is no way to get the former -layout back. +--- +*** Closing the "*Help*" buffer from the toolbar now buries the buffer. +In previous Emacs versions, the "*Help*" buffer was killed instead when +clicking the "X" icon in the tool bar. -** Loading dunnet.el in batch mode doesn't start the game any more. -Instead you need to do "emacs -f dun-batch" to start the game in -batch mode. +--- +*** 'g' ('revert-buffer') in 'help-mode' no longer requires confirmation. -** Emacs Server +** Miscellaneous +++ -*** New user option 'server-client-instructions'. -When emacsclient connects, Emacs will (by default) output a message -about how to exit the client frame. If 'server-client-instructions' -is set to nil, this message is inhibited. +*** New command 'font-lock-update', bound to 'C-x x f'. +This command updates the syntax highlighting in this buffer. +++ -*** New command 'server-edit-abort'. -This command (not bound to any key by default) can be used to abort -an edit instead of marking it as "Done" (which the 'C-x #' command -does). The 'emacsclient' program exits with an abnormal status as -result of this command. +*** New command 'memory-report'. +This command opens a new buffer called "*Memory Report*" and gives a +summary of where Emacs is using memory currently. +++ -*** New desktop integration for connecting to the server. -If your operating system’s desktop environment is -freedesktop.org-compatible (which is true of most GNU/Linux and other -recent Unix-like GUIs), you may use the new "Emacs (Client)" desktop -menu entry to open files in an existing Emacs instance rather than -starting a new one. The daemon starts if not already running. - -** Perl mode +*** New command 'submit-emacs-patch'. +This works like 'report-emacs-bug', but is more geared towards sending +patches to the Emacs issue tracker. ---- -*** New face 'perl-non-scalar-variable'. -This is used to fontify non-scalar variables. +*** New face 'apropos-button'. +Applies to buttons that indicate a face. -** Python mode ++++ +*** New face 'font-lock-doc-markup-face'. +Intended for documentation mark-up syntax and tags inside text that +uses 'font-lock-doc-face', with which it should harmonise. It would +typically be used in structured documentation comments in program +source code by language-specific modes, for mark-up conventions like +Haddock, Javadoc or Doxygen. By default this face inherits from +'font-lock-constant-face'. ---- -*** New user option 'python-forward-sexp-function'. -This allows the user to easier customize whether to use block-based -navigation or not. ++++ +*** New face 'flat-button'. +This is a plain 2D button, but uses the background color instead of +the foreground color. --- -*** 'python-shell-interpreter' now defaults to python3 on systems with python3. +*** New face 'shortdoc-heading'. +Applies to headings of shortdoc sections. --- -*** 'C-c C-r' can now be used on arbitrary regions. -The command previously extended the start of the region to the start -of the line, but will now actually send the marked region, as -documented. - -** Ruby mode +*** New face 'separator-line'. +This is used by 'make-separator-line' (see below). ---- -*** 'ruby-use-smie' is declared obsolete. -SMIE is now always enabled and 'ruby-use-smie' only controls whether -indentation is done using SMIE or with the old ad-hoc code. +*** 'redisplay-skip-fontification-on-input' helps Emacs keep up with fast input. +This is another attempt to solve the problem of handling high key repeat rate +and other "slow scrolling" situations. It is hoped it behaves better +than 'fast-but-imprecise-scrolling' and 'jit-lock-defer-time'. +It is not enabled by default. -** Icomplete +*** Obsolete aliases are no longer hidden from command completion. +Completion of command names now considers obsolete aliases as +candidates, if they were marked obsolete in the current major version +of Emacs. Invoking a command via an obsolete alias now mentions the +obsolescence fact and shows the new name of the command. ---- -*** New user option 'icomplete-matches-format'. -This allows controlling the current/total number of matches for the -prompt prefix. +*** Support for '(box . SIZE)' 'cursor-type'. +By default, 'box' cursor always has a filled box shape. But if you +specify 'cursor-type' to be '(box . SIZE)', the cursor becomes a hollow +box if the point is on an image larger than SIZE pixels in any +dimension. +++ -*** New minor modes 'icomplete-vertical-mode' and 'fido-vertical-mode' -These modes modify Icomplete ('M-x icomplete-mode') and Fido ('M-x -fido-mode'), to display completions candidates vertically instead of -horizontally. In Icomplete, completions are rotated and selection -kept at the top. In Fido, completions scroll like a typical dropdown -widget. Both these new minor modes will first turn on their -non-vertical counterparts first, if they are not on already. +*** New user option 'lazy-highlight-no-delay-length'. +Lazy highlighting of matches in Isearch now starts immediately if the +search string is at least this long. 'lazy-highlight-initial-delay' +still applies for shorter search strings, which avoids flicker in the +search buffer due to too many matches being highlighted. ---- -*** Default value of 'icomplete-compute-delay' has been changed to 0.15 s. ++++ +*** The user can now customize how "default" values are prompted for. +The new utility function 'format-prompt' has been added which uses the +new 'minibuffer-default-prompt-format' user option to format "default" +prompts. This means that prompts that look like "Enter a number +(default 10)" can be customized to look like, for instance, "Enter a +number [10]", or not have the default displayed at all, like "Enter a +number". (This requires that all callers are altered to use +'format-prompt', though.) --- -*** Default value of 'icomplete-max-delay-chars' has been changed to 2. +*** New help window when Emacs prompts before opening a large file. +Commands like 'find-file' or 'visit-tags-table' ask to visit a file +normally or literally when the file is larger than a certain size (by +default, 9.5 MiB). Press '?' or 'C-h' in that prompt to read more +about the different options to visit a file, how you can disable the +prompt, and how you can tweak the file size threshold. ---- -*** Reduced blinking while completing the next completions set. -Icomplete doesn't hide the hint with the previously computed -completions anymore when compute delay is in effect, or the previous -computation has been aborted by input. Instead it shows the previous -completions until the new ones are ready. ++++ +*** Emacs now defaults to UTF-8 instead of ISO-8859-1. +This is only for the default, where the user has set no 'LANG' (or +similar) variable or environment. This change should lead to no +user-visible changes for normal usage. --- -** Specific warnings can now be disabled from the warning buffer. -When a warning is displayed to the user, the resulting buffer now has -buttons which allow making permanent changes to the treatment of that -warning. Automatic showing of the warning can be disabled (although -it is still logged to the "*Messages*" buffer), or the warning can be -disabled entirely. +*** 'global-display-fill-column-indicator-mode' skips some buffers. +By default, turning on 'global-display-fill-column-indicator-mode' +doesn't turn on 'display-fill-column-indicator-mode' in special-mode +buffers. This can be controlled by customizing the variable +'global-display-fill-column-indicator-modes'. -** mspool.el ++++ +*** 'nobreak-char-display' now also affects all non-ASCII space characters. +Previously, this was limited only to NO-BREAK-SPACE and hyphen +characters. Now it also covers the rest of the non-ASCII Unicode +space characters. ---- -*** Autoload the main entry point 'mspool-show'. ++++ +*** Improved support for terminal emulators that encode the Meta flag. +Some terminal emulators set the 8th bit of Meta characters, and then +encode the resulting character code as if it were non-ASCII character +above codepoint 127. Previously, the only way of using these in Emacs +was to set up the terminal emulator to use the 'ESC' characters to send +Meta characters to Emacs, e.g., send "ESC x" when the user types +'M-x'. You can now avoid the need for this setup of such terminal +emulators by using the new input-meta-mode with the special value +'encoded' with these terminal emulators. -** Windmove +--- +*** 'auto-composition-mode' can now be selectively disabled on some TTYs. +Some text-mode terminals produce display glitches trying to compose +characters. The 'auto-composition-mode' can now have a string value +that names a terminal type; if the value returned by the 'tty-type' +function compares equal with that string, automatic composition will +be disabled in windows shown on that terminal. The Linux terminal +sets this up by default. -+++ -*** New user options to customize windmove keybindings. -These options include 'windmove-default-keybindings', -'windmove-display-default-keybindings', -'windmove-delete-default-keybindings', -'windmove-swap-states-default-keybindings'. +--- +*** Support for the 'strike-through' face attribute on TTY frames. +If your terminal's termcap or terminfo database entry has the 'smxx' +capability defined, Emacs will now emit the prescribed escape +sequences necessary to render faces with the 'strike-through' +attribute on TTY frames. -** Windows +--- +*** TTY menu navigation is now supported in 'xterm-mouse-mode'. +TTY menus support mouse navigation and selection when 'xterm-mouse-mode' +is active. When run on a terminal, clicking on the menu bar with the +mouse now pops up a TTY menu by default instead of running the command +'tmm-menubar'. To restore the old behavior, set the user option +'tty-menu-open-use-tmm' to non-nil. -+++ -*** New user option 'delete-window-choose-selected'. -This allows to choose a frame's selected window after deleting the -previously selected one. +--- +*** 'M-x report-emacs-bug' will no longer include "Recent messages" section. +These were taken from the "*Messages*" buffer, and may inadvertently +leak information from the reporting user. -+++ -*** New argument NO-OTHER for some window functions. -'get-lru-window', ‘get-mru-window’ and 'get-largest-window' now accept a -new optional argument NO-OTHER which, if non-nil, avoids returning a -window whose 'no-other-window' parameter is non-nil. +--- +*** 'C-u M-x dig' will now prompt for a query type to use. -+++ -*** New 'display-buffer' function 'display-buffer-use-least-recent-window'. -This is like 'display-buffer-use-some-window', but won't reuse the -current window, and when called repeatedly will try not to reuse a -previously selected window. +--- +*** Rudimentary support for the 'st' terminal emulator. +Emacs now supports 256 color display on the 'st' terminal emulator. -*** New function 'window-bump-use-time'. -This updates the use time of a window. +--- +*** Prefer "chat.freenode.net" to "irc.freenode.net". +"chat.freenode.net" has been the preferred address for connecting to the +freenode IRC network for years now. Occurrences of "irc.freenode.net" +have been replaced with "chat.freenode.net" throughout Emacs. -*** The key prefix 'C-x 4 1' displays next command buffer in the same window. -It's bound to the command 'same-window-prefix' that requests the buffer -of the next command to be displayed in the same window. +** File Locks -*** The key prefix 'C-x 4 4' displays next command buffer in a new window. -It's bound to the command 'other-window-prefix' that requests the buffer -of the next command to be displayed in a new window. ++++ +*** New user option 'lock-file-name-transforms'. +This option allows controlling where lock files are written. It uses +the same syntax as 'auto-save-file-name-transforms'. -** Frames ++++ +*** New user option 'remote-file-name-inhibit-locks'. +When non-nil, this option suppresses lock files for remote files. +++ -*** The key prefix 'C-x 5 5' displays next command buffer in a new frame. -It's bound to the command 'other-frame-prefix' that requests the buffer -of the next command to be displayed in a new frame. +*** New minor mode 'lock-file-mode'. +This command, called interactively, toggles the local value of +'create-lockfiles' in the current buffer. -** Tab Bars +** Emacs Server -*** The key prefix 'C-x t t' displays next command buffer in a new tab. -It's bound to the command 'other-tab-prefix' that requests the buffer -of the next command to be displayed in a new tab. ++++ +*** New user option 'server-client-instructions'. +When emacsclient connects, Emacs will (by default) output a message +about how to exit the client frame. If 'server-client-instructions' +is set to nil, this message is inhibited. +++ -*** New command 'C-x t C-r' to open file read-only in other tab. +*** New command 'server-edit-abort'. +This command (not bound to any key by default) can be used to abort +an edit instead of marking it as "Done" (which the 'C-x #' command +does). The 'emacsclient' program exits with an abnormal status as +result of this command. ---- -*** The tab bar is frame-local when 'tab-bar-show' is a number. -Show/hide the tab bar independently for each frame, according to the -value of 'tab-bar-show'. ++++ +*** New desktop integration for connecting to the server. +If your operating system’s desktop environment is +freedesktop.org-compatible (which is true of most GNU/Linux and other +recent Unix-like GUIs), you may use the new "Emacs (Client)" desktop +menu entry to open files in an existing Emacs instance rather than +starting a new one. The daemon starts if not already running. ---- -*** New command 'toggle-frame-tab-bar'. -It can be used to enable/disable the tab bar individually on each frame -independently from the value of 'tab-bar-mode' and 'tab-bar-show'. +** Input methods ---- -*** New user option 'tab-bar-format' defines a list of tab bar items. -When it contains 'tab-bar-format-global' (possibly appended after -'tab-bar-format-align-right'), then after enabling 'display-time-mode' -(or any other mode that uses 'global-mode-string') it displays time -aligned to the right on the tab bar instead of the mode line. -When 'tab-bar-format-tabs' is replaced with 'tab-bar-format-tabs-groups', -then the tab bar displays tab groups. ++++ +*** Emacs now supports "transient" input methods. +A transient input method is enabled for inserting a single character, +and is then automatically disabled. 'C-x \' temporarily enables the +selected transient input method. Use 'C-u C-x \' to select a +transient input method (which can be different from the input method +enabled by 'C-\'). For example, 'C-u C-x \ compose RET' selects the +'compose' input method; then typing 'C-x \ 1 2' will insert the +character '½', and disable the 'compose' input method afterwards. +You can use 'C-x \' in incremental search to insert a single character +to the search string. --- -*** 'Mod-9' bound to 'tab-last' now switches to the last tab. -It also supports a negative argument. +*** New input method 'compose' based on X Multi_key sequences. --- -*** New command 'tab-duplicate' bound to 'C-x t n'. +*** New input method 'iso-transl' with the same keys as 'C-x 8'. +After selecting it as a transient input method with 'C-u C-x \ +iso-transl RET', it supports the same key sequences as 'C-x 8', +so e.g. like 'C-x 8 [' inserts a left single quotation mark, +'C-x \ [' does the same. --- -*** 'C-x t N' creates a new tab at the specified absolute position. -It also supports a negative argument. +*** New user option 'read-char-by-name-sort'. +It defines the sorting order of characters for completion of 'C-x 8 RET TAB' +and can be customized to sort them by codepoints instead of character names. +Additionally, you can group characters by Unicode blocks after customizing +'completions-group' and 'completions-group-sort'. --- -*** 'C-x t M' moves the current tab to the specified absolute position. -It also supports a negative argument. +*** Improved language transliteration in Malayalam input methods. +Added a new Mozhi scheme. The inapplicable ITRANS scheme is now +deprecated. Errors in the Inscript method were corrected. --- -*** 'C-x t G' assigns a group name to the tab. -'tab-close-group' can close all tabs that belong to the selected group. -The user option 'tab-bar-new-tab-group' defines the default group of a -new tab. After customizing 'tab-bar-tab-post-change-group-functions' -to 'tab-bar-move-tab-to-group', changing the tab group will also move it -closer to other tabs in the same group. +*** New input method 'cham'. +There's also a Cham greeting in "etc/HELLO". --- -*** New user option 'tab-bar-tab-name-format-function'. +*** New input methods for Lakota language orthographies. +Two orthographies are represented here, the Suggested Lakota +Orthography and what is known as the White Hat Orthography. Input +methods 'lakota-slo-prefix', 'lakota-slo-postfix', and +'lakota-white-hat-postfix' have been added. There is also a Lakota +greeting in "etc/HELLO". ---- -*** New user option 'tab-line-tab-name-format-function'. + +* Editing Changes in Emacs 28.1 ---- -*** The tabs in the tab line can now be scrolled using horizontal scroll. -If your mouse or trackpad supports it, you can now scroll tabs when -the mouse pointer is in the tab line by scrolling left or right. ++++ +** Standalone 'M-y' allows interactive selection from previous kills. +'M-y' can now be typed after a command that is not a yank command. +When invoked like that, it prompts in the minibuffer for one of the +previous kills, offering completion and minibuffer-history navigation +through previous kills recorded in the kill ring. A similar feature +in Isearch can be invoked if you bind 'C-s M-y' to the command +'isearch-yank-pop'. When the user option 'yank-from-kill-ring-rotate' +is nil the kill ring is not rotated after 'yank-from-kill-ring'. ---- -*** New tab-line faces and options. -The face 'tab-line-tab-special' is used for tabs whose buffers are -special, i.e. not file-backed. The face -'tab-line-tab-inactive-alternate' is used to display inactive tabs -with an alternating background color, making them easier to -distinguish between, especially if the face 'tab-line-tab' is -configured to not display with a box; this alternate face is only -applied when the option 'tab-line-tab-face-functions' is -so-configured. That option may also be used to customize tab-line -faces in other ways. ++++ +** New command 'undo-redo'. +It undoes previous undo commands, but doesn't record itself as an +undoable command. -** Occur mode ++++ +** New commands 'copy-matching-lines' and 'kill-matching-lines'. +These commands are similar to the command 'flush-lines', +but add the matching lines to the kill ring as a single string, +including the newlines that separate the lines. -*** New bindings in occur-mode, 'next-error-no-select' bound to 'n' and -'previous-error-no-select' bound to 'p'. ++++ +** New user option 'kill-transform-function'. +This can be used to transform (and suppress) strings from entering the +kill ring. -*** The new command 'recenter-current-error', bound to 'l' in Occur or -compilation buffers, recenters the current displayed occurrence/error. ++++ +** 'save-interprogram-paste-before-kill' can now be a number. +In that case, it's interpreted as a limit on the size of the clipboard +data that will be saved to the 'kill-ring' prior to killing text: if +the size of the clipboard data is greater than or equal to the limit, +it will not be saved. -*** Matches in target buffers are now highlighted as in 'compilation-mode'. -The method of highlighting is specified by the user options -'next-error-highlight' and 'next-error-highlight-no-select'. ++++ +** New user option 'tab-first-completion'. +If 'tab-always-indent' is 'complete', this new user option can be used to +further tweak whether to complete or indent. --- -*** A fringe arrow in the "*Occur*" buffer indicates the selected match. +** 'indent-tabs-mode' is now a global minor mode instead of just a variable. --- -*** Occur mode may use a different type for 'occur-target' property values. -The value was previously always a marker set to the start of the first -match on the line but can now also be a list of '(BEGIN . END)' pairs -of markers delimiting each match on the line. -This is a fully compatible change to the internal occur-mode -implementation, and code creating their own occur-mode buffers will -work as before. +** New choice 'permanent' for 'shift-select-mode'. +When the mark was activated by shifted motion keys, non-shifted motion +keys don't deactivate the mark after customizing 'shift-select-mode' +to 'permanent'. -** EIEIO ++++ +** The "Edit => Clear" menu item now obeys a rectangular region. +++ -*** The macro 'oref-default' can now be used with 'setf'. -It is now defined as a generalized variable that can be used with -'setf' to modify the value stored in a given class slot. +** New command 'revert-buffer-with-fine-grain'. +Revert a buffer trying to be as non-destructive as possible, +preserving markers, properties and overlays. The new variable +'revert-buffer-with-fine-grain-max-seconds' specifies the maximum +number of seconds that 'revert-buffer-with-fine-grain' should spend +trying to be non-destructive. + ++++ +** New command 'revert-buffer-quick'. +This is bound to 'C-x x g' and is like `revert-buffer', but prompts +less. + ++++ +** New user option 'revert-buffer-quick-short-answers'. This +controls how the new 'revert-buffer-quick' (`C-x x g') command +prompts. + ++++ +** New user option 'query-about-changed-file'. +If non-nil (the default), users are prompted as before when +re-visiting a file that has changed externally after it was visited +the first time. If nil, the user is not prompted, but instead the +buffer is opened with its contents before the change, and the user is +given instructions how to revert the buffer. + +** New value 'save-some-buffers-root' of 'save-some-buffers-default-predicate'. +It allows to ask about saving only files under the project root +or in subdirectories of the directory that was default during +command invocation. --- -*** 'form' in '(eql form)' specializers in 'cl-defmethod' is now evaluated. -This corresponds to the behavior of defmethod in Common Lisp Object System. -For compatibility, '(eql SYMBOL)' does not evaluate SYMBOL, for now. +** New user option 'save-place-abbreviate-file-names'. +This can simplify sharing the ‘save-place-file’ file across +different hosts. -** New minor mode 'cl-font-lock-built-in-mode' for 'lisp-mode'. -The mode provides refined highlighting of built-in functions, types, -and variables. ++++ +** New user option 'word-wrap-by-category'. +When word-wrap is enabled, and this option is non-nil, that allows +Emacs to break lines after more characters than just whitespace +characters. In particular, this significantly improves word-wrapping +for CJK text mixed with Latin text. -** Archive mode +--- +** New user options 'copy-region-blink-delay' and 'delete-pair-blink-delay'. +'copy-region-blink-delay' specifies a delay to indicate the region +copied by 'kill-ring-save'. 'delete-pair-blink-delay' specifies +a delay to show a paired character to delete. --- -*** Archive Mode can now parse ".squashfs" files. +** 'zap-up-to-char' now uses 'read-char-from-minibuffer'. +This allows navigating through the history of characters that have +been input. This is mostly useful for characters that have complex +input methods where inputting the character again may involve many +keystrokes. -*** Can now modify members of 'ar' archives. ++++ +** Input history for 'goto-line' can now be made local to every buffer. +In any event, line numbers used with 'goto-line' are kept in their own +history list. This should help make faster the process of finding +line numbers that were previously jumped to. By default, all buffers +share a single history list. To make every buffer have its own +history list, customize the user option 'goto-line-history-local'. -*** Display of summaries unified between backends. ++++ +** New command 'goto-line-relative' for use in a narrowed buffer. +It moves point to the line relative to the accessible portion of the +narrowed buffer. 'M-g M-g' in Info is rebound to this command. +When 'widen-automatically' is non-nil, 'goto-line' widens the narrowed +buffer to be able to move point to the inaccessible portion. +'goto-line-relative' is bound to 'C-x n g'. -*** New user option 'archive-hidden-columns' and command -'archive-hideshow-column'. These let you control which columns are -displayed and which are kept hidden. ++++ +** When called interactively, 'goto-char' now offers the number at +point as default. ---- -*** New command bound to 'C': 'archive-copy-file'. -This command extracts the file under point and writes the data to a -file. +** Autosaving via 'auto-save-visited-mode' can now be inhibited by +setting the variable 'auto-save-visited-mode' buffer-locally to nil. -** Emacs Lisp mode ++++ +** New command 'C-x C-k Q' to force redisplay in keyboard macros. -*** The mode-line now indicates whether we're using lexical or dynamic scoping. + +* Changes in Specialized Modes and Packages in Emacs 28.1 -*** A space between an open paren and a symbol changes the indentation rule. -The presence of a space between an open paren and a symbol now is -taken as a statement by the programmer that this should be indented -as a data list rather than as a piece of code. +** Isearch -** Calendar ++++ +*** Interactive regular expression search now uses faces for sub-groups. +E.g., 'C-M-s foo-\([0-9]+\)' will now use the 'isearch-group-1' face +on the part of the regexp that matches the sub-expression "[0-9]+". +By default, there are two faces for sub-group highlighting, but you +can define more faces whose names are of the form 'isearch-group-N', +where N are successive numbers above 2. + +This is controlled by the 'search-highlight-submatches' user option. +This feature is available only on terminals that have enough colors to +distinguish between sub-expression highlighting. + +*** New user option 'isearch-wrap-pause' defines how to wrap the search. +There are choices to disable wrapping completely and to wrap immediately. +When wrapping immediately, it consistently handles the numeric arguments +of 'C-s' ('isearch-repeat-forward') and 'C-r' ('isearch-repeat-backward'), +continuing with the remaining count after wrapping. +++ -*** New user option 'calendar-time-zone-style'. -If 'numeric', calendar functions (eg 'calendar-sunrise-sunset') that display -time zones will use a form like "+0100" instead of "CET". +*** New user option 'isearch-repeat-on-direction-change'. +When this option is set, direction changes in Isearch move to another +search match, if there is one, instead of moving point to the other +end of the current match. + ++++ +*** Interactive regular expression replace now uses faces for sub-groups. +Like 'search-highlight-submatches', this is controlled by the new user option +'query-replace-highlight-submatches'. + +*** New key 'M-s M-.' starts isearch with the thing found at point. +This key is bound to the new command 'isearch-forward-thing-at-point'. +The new user option 'isearch-forward-thing-at-point' defines +a list of symbols to try to get the "thing" at point. By default, +the first element of the list is 'region' that tries to yank +the currently active region to the search string. ** Dired @@ -996,299 +1093,242 @@ keys, add the following to your init file: (global-set-key "\C-x\C-j" nil) (global-set-key "\C-x4\C-j" nil) -** Change Logs and VC +--- +*** 'dired-query' now uses 'read-char-from-minibuffer'. +Using it instead of 'read-char-choice' allows using 'C-x o' +to switch to the help window displayed after typing 'C-h'. -+++ -*** 'vc-revert-show-diff' now has a third possible value: 'kill'. -If this variable is 'kill', then the diff buffer will be killed after -the 'vc-revert' action instead of buried. +** Outline -*** More VC commands can be used from non-file buffers. -The relevant commands are those that don't change the VC state. -The non-file buffers which can use VC commands are those that have -their 'default-directory' under VC. ++++ +*** New commands to cycle heading visibility. +Typing 'TAB' on a heading line cycles the current section between +"hide all", "subheadings", and "show all" states. Typing 'S-TAB' +anywhere in the buffer cycles the whole buffer between "only top-level +headings", "all headings and subheadings", and "show all" states. -*** New command 'vc-dir-root' uses the root directory without asking. ++++ +*** New user option 'outline-minor-mode-cycle'. +This user option customizes 'outline-minor-mode', with the difference +that 'TAB' and 'S-TAB' on heading lines cycle heading visibility. +Typing 'TAB' on a heading line cycles the current section between +"hide all", "subheadings", and "show all" states. Typing 'S-TAB' on a +heading line cycles the whole buffer between "only top-level +headings", "all headings and subheadings", and "show all" states. --- -*** New face 'log-view-commit-body'. -This is used when expanding commit messages from 'vc-print-root-log' -and similar commands. +*** New user option 'outline-minor-mode-highlight'. +This user option customizes 'outline-minor-mode'. It puts +highlighting on heading lines using standard outline faces. This +works well only when there are no conflicts with faces used by the +major mode. ---- -*** New faces for 'vc-dir' buffers. -Those are: 'vc-dir-header', 'vc-dir-header-value', 'vc-dir-directory', -'vc-dir-file', 'vc-dir-mark-indicator', 'vc-dir-status-warning', -'vc-dir-status-edited', 'vc-dir-status-up-to-date', -'vc-dir-status-ignored'. +** Ispell ---- -*** The responsible VC backend is now the most specific one. -'vc-responsible-backend' loops over the backends in -'vc-handled-backends' to determine which backend is responsible for a -specific (unregistered) file. Previously the first matching backend -was chosen, but now the one with the most specific path is chosen (in -case there's a directory handled by one backend inside another). ++++ +*** 'ispell-comments-and-strings' now accepts START and END arguments, +defaulting to active region when used interactively. -*** New commands 'vc-dir-mark-registered-files' (bound to '* r') and -'vc-dir-mark-unregistered-files'. ++++ +*** New command 'ispell-comment-or-string-at-point' is provided. -*** Support for bookmark.el. -Bookmark locations can refer to VC directory buffers. +** Package --- -*** New user option 'vc-hg-create-bookmark'. -It controls whether a bookmark or branch will be created when you -invoke 'C-u C-x v s' ('vc-create-tag'). +*** '/ s' ('package-menu-filter-by-status') changes parameter handling. +The command was documented to take a comma-separated list of statuses +to filter by, but instead it used the parameter as a regexp. The +command has been changed so that it now works as documented, and +checks statuses not as a regexp, but instead an exact match from the +comma-separated list. ---- -*** 'vc-hg' now uses 'hg summary' to populate extra 'vc-dir' headers. ++++ +*** New command 'package-browse-url' and keystroke 'w'. + ++++ +*** New commands to filter the package list. +The filter commands are bound to the following keys: + +key binding +--- ------- +/ a package-menu-filter-by-archive +/ d package-menu-filter-by-description +/ k package-menu-filter-by-keyword +/ N package-menu-filter-by-name-or-description +/ n package-menu-filter-by-name +/ s package-menu-filter-by-status +/ v package-menu-filter-by-version +/ m package-menu-filter-marked +/ u package-menu-filter-upgradable +/ / package-menu-filter-clear + +*** Option to automatically native-compile packages upon installation. +Customize the user option 'package-native-compile' to enable automatic +native compilation of packages when they are installed. That option +is nil by default; if set non-nil, and if your Emacs was built with +native-compilation support, each package will be natively compiled +when it is installed, by invoking an asynchronous Emacs subprocess to +run the native-compilation of the package files. --- -*** New user option 'vc-git-revision-complete-only-branches'. -If non-nil, only branches and remotes are considered when doing -completion over Git branch names. The default is nil, which causes -tags to be considered as well. +*** Column widths in 'list-packages' display can now be customized. +See the new user options 'package-name-column-width', +'package-version-column-width', 'package-status-column-width', and +'package-archive-column-width'. + +** Info --- -*** New user option 'vc-git-log-switches'. -String or list of strings specifying switches for Git log under VC. +*** New user option 'Info-warn-on-index-alternatives-wrap'. +This option affects what happens when using the ',' command after +looking up an entry with 'i' in info buffers. If non-nil (the +default), the ',' command will now warn you when proceeding beyond the +final entry, and tapping ',' once more will then take you to the +first entry. -** Gnus +** Abbrev mode +++ -*** New user option 'gnus-topic-display-predicate'. -This can be used to inhibit the display of some topics completely. +*** Emacs can now suggest to use an abbrev based on text you type. +A new user option, 'abbrev-suggest', enables the new abbrev suggestion +feature. When enabled, if a user manually types a piece of text that +could have saved enough typing by using an abbrev, a hint will be +displayed in the echo area, mentioning the abbrev that could have been +used instead. -+++ -*** nnimap now supports the oauth2.el library. +** Bookmarks -+++ -*** New Summary buffer sort options for extra headers. -The extra header sort option ('C-c C-s C-x') prompts for a header -and fails if no sort function has been defined. Sorting by -Newsgroups ('C-c C-s C-u') has been pre-defined. - -+++ -*** The '#' command in the Group and Summary buffer now toggles, -instead of sets, the process mark. +*** Bookmarks can now be targets for new tabs. +When the bookmark.el library is loaded, a customize choice is added +to 'tab-bar-new-tab-choice' for new tabs to show the bookmark list. -+++ -*** New user option 'gnus-process-mark-toggle'. -If non-nil (the default), the '#' command in the Group and Summary -buffers will toggle, instead of set, the process mark. +--- +*** The 'list-bookmarks' menu is now based on 'tabulated-list-mode'. +The interactive bookmark list will now benefit from features in +'tabulated-list-mode' like sorting columns or changing column width. +Support for the optional "inline" header line, allowing for a header +without using 'header-line-format', has been dropped. Consequently, +the variables 'bookmark-bmenu-use-header-line' and +'bookmark-bmenu-inline-header-height' are now declared obsolete. -+++ -*** New user option 'gnus-registry-register-all'. -If non-nil (the default), create registry entries for all messages. -If nil, don't automatically create entries, they must be created -manually. +--- +*** New user option 'bookmark-fontify'. +If non-nil, setting a bookmark will colorize the current line with +'bookmark-face'. -+++ -*** New user options to customise the summary line specs "%[" and "%]". -Four new options introduced in customisation group -'gnus-summary-format'. These are 'gnus-sum-opening-bracket', -'gnus-sum-closing-bracket', 'gnus-sum-opening-bracket-adopted', and -'gnus-sum-closing-bracket-adopted'. Their default values are "[", "]", -"<", ">" respectively. These options control the appearance of "%[" -and "%]" specs in the summary line format. "%[" will normally display -the value of 'gnus-sum-opening-bracket', but can also be -'gnus-sum-opening-bracket-adopted' for the adopted articles. "%]" will -normally display the value of 'gnus-sum-closing-bracket', but can also -be 'gnus-sum-closing-bracket-adopted' for the adopted articles. +--- +*** New user option 'bookmark-menu-confirm-deletion'. +In Bookmark Menu mode, Emacs by default does not prompt for +confirmation when you type 'x' to execute the deletion of bookmarks +that have been marked for deletion. However, if this new option is +non-nil then Emacs will require confirmation with 'yes-or-no-p' before +deleting. -+++ -*** New user option 'gnus-paging-select-next'. -This controls what happens when using commands like 'SPC' and 'DEL' to -page the current article. If non-nil (the default), go to the -next/prev article, but if nil, do nothing at the end/start of the article. +** Recentf -+++ -*** New gnus-search library. -A new unified search syntax which can be used across multiple -supported search engines. Set 'gnus-search-use-parsed-queries' to -non-nil to enable. +--- +*** The recentf files are no longer backed up. -+++ -*** New value for user option 'smiley-style'. -Smileys can now be rendered with emojis instead of small images when -using the new 'emoji' value in 'smiley-style'. +--- +*** 'recentf-auto-cleanup' time string now repeats. +When 'recentf-auto-cleanup' is set to a time string, it now repeats +every day, rather than only running once after the mode is turned on. -+++ -*** New user option 'gnus-agent-eagerly-store-articles'. -If non-nil (which is the default), the Gnus Agent will store all read -articles in the Agent cache. +** Calc -+++ -*** New user option 'gnus-global-groups'. -Gnus handles private groups differently from public (i.e., NNTP-like) -groups. Most importantly, Gnus doesn't download external images from -mail-like groups. This can be overridden by putting group names in -'gnus-global-groups': Any group present in that list will be treated -like a public group. +--- +*** The behavior when doing forward-delete has been changed. +Previously, using the 'C-d' command would delete the final number in +the input field, no matter where point was. This has been changed to +work more traditionally, with 'C-d' deleting the next character. +Likewise, point isn't moved to the end of the string before inserting +digits. +++ -*** New scoring types for the Date header. -You can now score based on the relative age of an article with the new -'<' and '>' date scoring types. +*** Setting the word size to zero disables word clipping. +The word size normally clips the results of certain bit-oriented +operations such as shifts and bitwise XOR. A word size of zero, set +by 'b w', makes the operation have effect on the whole argument values +and the result is not truncated in any way. -+++ -*** User-defined scoring is now possible. -The new type is 'score-fn'. More information in the Gnus manual node -"(gnus) Score File Format". +--- +*** The '/' operator now has higher precedence in (La)TeX input mode. +It no longer has lower precedence than '+' and '-'. -+++ -*** New backend 'nnselect'. -The newly added 'nnselect' backend allows creating groups from an -arbitrary list of articles that may come from multiple groups and -servers. These groups generally behave like any other group: they may -be ephemeral or persistent, and allow article marking, moving, -deletion, etc. 'nnselect' groups may be created like any other group, -but there are three convenience functions for the common case of -obtaining the list of articles as a result of a search: -'gnus-group-make-search-group' ('G g') that will prompt for an 'nnir' -search query and create a persistent group for that search; -'gnus-group-read-ephemeral-search-group' ('G G') that will prompt for -an 'nnir' search query and create an ephemeral group for that search; -and 'gnus-summary-make-group-from-search' ('C-c C-p') that will create -a persistent group with the search parameters of a current ephemeral -search group. +--- +*** Calc now marks its windows dedicated. +The new user option 'calc-make-windows-dedicated' controls this. It +is t by default; set to nil to get back the old behavior. -As part of this addition, the user option 'nnir-summary-line-format' -has been removed; its functionality is now available directly in the -'gnus-summary-line-format' specs '%G' and '%g'. The user option -'gnus-refer-thread-use-nnir' has been renamed to -'gnus-refer-thread-use-search'. +** Calendar +++ -*** New user option 'gnus-dbus-close-on-sleep'. -On systems with D-Bus support, it is now possible to register a signal -to close all Gnus servers before the system sleeps. +*** New user option 'calendar-time-zone-style'. +If 'numeric', calendar functions (eg 'calendar-sunrise-sunset') that display +time zones will use a form like "+0100" instead of "CET". -+++ -*** The key binding of 'gnus-summary-search-article-forward' has changed. -This command was previously on 'M-s' and shadowed the global 'M-s' -search prefix. The command has now been moved to 'M-s M-s'. (For -consistency, the 'M-s M-r' key binding has been added for the -'gnus-summary-search-article-backward' command.) +** ido --- -*** The value of "all" in the 'large-newsgroup-initial' group parameter changes. -It was previously nil, which didn't work, because nil is -indistinguishable from not being present. The new value for "all" is -the symbol 'all'. +*** Switching on 'ido-mode' now also overrides 'ffap-file-finder'. -+++ -*** The name of dependent Gnus sessions has changed from "slave" to "child". -The names of the commands 'gnus-slave', 'gnus-slave-no-server' and -'gnus-slave-unplugged' have changed to 'gnus-child', -'gnus-child-no-server' and 'gnus-child-unplugged' respectively. +--- +*** Killing virtual ido buffers interactively will make them go away. +Previously, killing a virtual ido buffer with 'ido-kill-buffer' didn't +do anything. This has now been changed, and killing virtual buffers +with that command will remove the buffer from recentf. -+++ -*** The 'W Q' summary mode command now takes a numerical prefix to -allow adjusting the fill width. +** Flyspell mode +++ -*** New variable 'mm-inline-font-lock'. -This variable is supposed to be bound by callers to determine whether -inline MIME parts (that support it) are supposed to be font-locked or -not. - -** Message +*** Corrections and actions menu can be optionally bound to 'mouse-3'. +When Flyspell mode highlights a word as misspelled, you can click on +it to display a menu of possible corrections and actions. You can now +easily bind this menu to 'down-mouse-3' (usually the right mouse button) +instead of 'mouse-2' (the default) by enabling 'context-menu-mode'. --- -*** Respect 'message-forward-ignored-headers' more. -Previously, this user option would not be consulted if -'message-forward-show-mml' was nil and forwarding as MIME. - -+++ -*** New user option 'message-forward-included-mime-headers'. -This is used when forwarding messages as MIME, but not using MML. +*** The current dictionary is now displayed in the minor mode lighter. +Clicking the dictionary name changes the current dictionary. -+++ -*** Message now supports the OpenPGP header. -To generate these headers, add the new function -'message-add-openpgp-header' to 'message-send-hook'. The header will -be generated according to the new 'message-openpgp-header' variable. +** So Long --- -*** A change to how "Mail-Copies-To: never" is handled. -If a user has specified "Mail-Copies-To: never", and Message was asked -to do a "wide reply", some other arbitrary recipient would end up in -the resulting "To" header, while the remaining recipients would be put -in the "Cc" header. This is somewhat misleading, as it looks like -you're responding to a specific person in particular. This has been -changed so that all the recipients are put in the "To" header in these -instances. - -+++ -*** New command to start Emacs in Message mode to send an email. -Emacs can be defined as a handler for the "x-scheme-handler/mailto" -MIME type with the following command: "emacs -f message-mailto %u". -An "emacs-mail.desktop" file has been included, suitable for -installing in desktop directories like "/usr/share/applications" or -"~/.local/share/applications". -Clicking on a 'mailto:' link in other applications will then open -Emacs with headers filled out according to the link, e.g. -"mailto:larsi@gnus.org?subject=This+is+a+test". If you prefer -emacsclient, use "emacsclient -e '(message-mailto "%u")'" -or "emacsclient-mail.desktop". +*** New 'so-long-predicate' function 'so-long-statistics-excessive-p' +efficiently detects the presence of a long line anywhere in the buffer +using 'buffer-line-statistics' (see above). This is now the default +predicate (replacing 'so-long-detected-long-line-p'). --- -*** Change to default value of 'message-draft-headers' user option. -The 'Date' symbol has been removed from the default value, meaning that -draft or delayed messages will get a date reflecting when the message -was sent. To restore the original behavior of dating a message -from when it is first saved or delayed, add the symbol 'Date' back to -this user option. +*** 'so-long-threshold' and 'so-long-max-lines' have been raised to +10000 bytes and 500 lines respectively, to reduce the likelihood of +false-positives when 'global-so-long-mode' is enabled. The latter +value is now only used by the old predicate, as the new predicate +knows the longest line in the entire buffer. -+++ -*** New command to take screenshots. -In Message mode buffers, the 'C-c C-p' ('message-insert-screenshot') -command has been added. It depends on using an external program to -take the actual screenshot, and defaults to "ImageMagick import". +--- +*** 'so-long-target-modes' now includes 'fundamental-mode' by default, +meaning that 'global-so-long-mode' will also process files which were +not recognised. (This only has an effect if 'set-auto-mode' chooses +'fundamental-mode'; buffers which are simply in 'fundamental-mode' by +default are unaffected.) -** Smtpmail +--- +*** New user options 'so-long-mode-preserved-minor-modes' and +'so-long-mode-preserved-variables' allow specified mode and variable +states to be maintained if 'so-long-mode' replaces the original major +mode. By default, these new options support 'view-mode'. -+++ -*** smtpmail now supports using the oauth2.el library. +** Grep +++ -*** New user option 'smtpmail-store-queue-variables'. -If non-nil, SMTP variables will be stored together with the queued -messages, and will then be used when sending with -'M-x smtpmail-send-queued-mail'. - -+++ -*** Allow direct selection of smtp authentication mechanism. -A server entry retrieved by auth-source can request a desired smtp -authentication mechanism by setting a value for the key 'smtp-auth'. - -** Search and Replace - -*** New key 'M-s M-.' starts isearch with the thing found at point. -This key is bound to the new command 'isearch-forward-thing-at-point'. -The new user option 'isearch-forward-thing-at-point' defines -a list of symbols to try to get the "thing" at point. By default, -the first element of the list is 'region' that tries to yank -the currently active region to the search string. - -*** New user option 'isearch-wrap-pause' defines how to wrap the search. -There are choices to disable wrapping completely and to wrap immediately. -When wrapping immediately, it consistently handles the numeric arguments -of 'C-s' ('isearch-repeat-forward') and 'C-r' ('isearch-repeat-backward'), -continuing with the remaining count after wrapping. - -** Grep - -+++ -*** New user option 'grep-match-regexp' matches grep markers to highlight. -Grep emits SGR ANSI escape sequences to color its output. The new -user option 'grep-match-regexp' holds the regular expression to match -the appropriate markers in order to provide highlighting in the source -buffer. The user option can be customized to accommodate other -grep-like tools. +*** New user option 'grep-match-regexp' matches grep markers to highlight. +Grep emits SGR ANSI escape sequences to color its output. The new +user option 'grep-match-regexp' holds the regular expression to match +the appropriate markers in order to provide highlighting in the source +buffer. The user option can be customized to accommodate other +grep-like tools. --- *** The 'lgrep' command now ignores directories. @@ -1309,596 +1349,717 @@ This change is for better compatibility with old versions of non-GNU This returns the name of the file at point (if any) in 'grep-mode' buffers. -** Help - -+++ -*** New convenience commands with short keys in the Help buffer. -New command 'help-view-source' ('s') will view the source file (if -any) of the current help topic. New command 'help-goto-info' ('i') -will look up the current symbol (if any) in Info. New command -'help-customize' ('c') will customize the variable or the face -(if any) whose doc string is being shown in the Help buffer. +** Shell --- -*** The 'help-for-help' ('C-h C-h') screen has been redesigned. +*** New command in 'shell-mode': 'narrow-to-prompt'. +This is bound to 'C-x n d' in 'shell-mode' buffers, and narrows to the +command line under point (and any following output). --- -*** Keybindings in 'help-mode' use the new 'help-key-binding' face. -This face is added by 'substitute-command-keys' to any "\[command]" -substitution. The return value of that function should consequently -be assumed to be a propertized string. +*** New user option 'shell-has-auto-cd'. +If non-nil, 'shell-mode' handles implicit "cd" commands, changing the +directory if the command is a directory. Useful for shells like "zsh" +that has this feature. -Note that the new face will also be used in tooltips. When using the -GTK toolkit, this is only true if 'x-gtk-use-system-tooltips' is t. +** term-mode --- -*** 'g' ('revert-buffer') in 'help-mode' no longer requires confirmation. +*** New user option 'term-scroll-snap-to-bottom'. +By default, 'term' and 'ansi-term' will now recenter the buffer so +that the prompt is on the final line in the window. Setting this new +user option to nil inhibits this behavior. -+++ -*** New command 'describe-command' shows help for a command. -This can be used instead of 'describe-function' for interactive -commands and is globally bound to 'C-h x'. +--- +*** New user option 'term-set-terminal-size' +If non-nil, the 'LINES' and 'COLUMNS' environment variables will be set +based on the current window size. In previous versions of Emacs, this +was always done (and that could lead to odd displays when resizing the +window after starting). This variable defaults to nil. -+++ -*** New command 'describe-keymap' describes keybindings in a keymap. +** Eshell --- -*** New user option 'describe-bindings-outline'. -It enables outlines in the output buffer of 'describe-bindings' that -can provide a better overview in a long list of available bindings. +*** 'eshell-hist-ignoredups' can now also be used to mimic "erasedups" in bash. --- -*** New keybinding 'C-h R' prompts for a manual to display and displays it. +*** Environment variable 'INSIDE_EMACS' is now copied to subprocesses. +Its value contains the result of evaluating '(format "%s,eshell" +emacs-version)'. Other package names, like "tramp", could also be included. --- -*** Closing the "*Help*" buffer from the toolbar now buries the buffer. -In previous Emacs versions, the "*Help*" buffer was killed instead when -clicking the "X" icon in the tool bar. +*** Eshell no longer re-initializes its keymap every call. +This allows users to use (define-key eshell-mode-map ...) as usual. +Some modules have their own minor mode now to account for these +changes. -** Info +** Archive mode --- -*** New user option 'Info-warn-on-index-alternatives-wrap'. -This option affects what happens when using the ',' command after -looking up an entry with 'i' in info buffers. If non-nil (the -default), the ',' command will now warn you when proceeding beyond the -final entry, and tapping ',' once more will then take you to the -first entry. - -+++ -** New command 'lossage-size'. -It allows users to set the maximum number of keystrokes and commands -recorded for the purpose of 'view-lossage'. +*** Archive Mode can now parse ".squashfs" files. ---- -*** The command 'view-lossage' can now be invoked from the menu bar. -The menu bar "Help" menu now has a "Show Recent Inputs" item under the -"Describe" sub-menu. +*** Can now modify members of 'ar' archives. -** Input methods +*** Display of summaries unified between backends. -+++ -*** Emacs now supports "transient" input methods. -A transient input method is enabled for inserting a single character, -and is then automatically disabled. 'C-x \' temporarily enables the -selected transient input method. Use 'C-u C-x \' to select a -transient input method (which can be different from the input method -enabled by 'C-\'). For example, 'C-u C-x \ compose RET' selects the -'compose' input method; then typing 'C-x \ 1 2' will insert the -character '½', and disable the 'compose' input method afterwards. -You can use 'C-x \' in incremental search to insert a single character -to the search string. +*** New user option 'archive-hidden-columns' and command +'archive-hideshow-column'. These let you control which columns are +displayed and which are kept hidden. --- -*** New input method 'compose' based on X Multi_key sequences. +*** New command bound to 'C': 'archive-copy-file'. +This command extracts the file under point and writes the data to a +file. ---- -*** New input method 'iso-transl' with the same keys as 'C-x 8'. -After selecting it as a transient input method with 'C-u C-x \ -iso-transl RET', it supports the same key sequences as 'C-x 8', -so e.g. like 'C-x 8 [' inserts a left single quotation mark, -'C-x \ [' does the same. +** browse-url ---- -*** New user option 'read-char-by-name-sort'. -It defines the sorting order of characters for completion of 'C-x 8 RET TAB' -and can be customized to sort them by codepoints instead of character names. -Additionally, you can group characters by Unicode blocks after customizing -'completions-group' and 'completions-group-sort'. +*** Added support for custom URL handlers. +There is a new variable 'browse-url-default-handlers' and a user +option 'browse-url-handlers' being alists with '(REGEXP-OR-PREDICATE +. FUNCTION)' entries allowing to define different browsing FUNCTIONs +depending on the URL to be browsed. The variable is for default +handlers provided by Emacs itself or external packages, the user +option is for the user (and allows for overriding the default +handlers). ---- -*** Improved language transliteration in Malayalam input methods. -Added a new Mozhi scheme. The inapplicable ITRANS scheme is now -deprecated. Errors in the Inscript method were corrected. +Formerly, one could do the same by setting +'browse-url-browser-function' to such an alist. This usage is still +supported but deprecated. ---- -*** New input method 'cham'. -There's also a Cham greeting in "etc/HELLO". +*** Categorization of browsing commands in internal vs. external. +All standard browsing commands such as 'browse-url-firefox', +'browse-url-mail', or 'eww' have been categorized into internal (URL +is browsed in Emacs) or external (an external application is spawned +with the URL). This is done by adding a 'browse-url-browser-kind' +symbol property to the browsing commands. With a new command +'browse-url-with-browser-kind', an URL can explicitly be browsed with +either an internal or external browser. --- -*** New input methods for Lakota language orthographies. -Two orthographies are represented here, the Suggested Lakota -Orthography and what is known as the White Hat Orthography. Input -methods 'lakota-slo-prefix', 'lakota-slo-postfix', and -'lakota-white-hat-postfix' have been added. There is also a Lakota -greeting in "etc/HELLO". +*** Support for browsing of remote files. +If a remote file is taken, a local temporary copy of that file is +passed to the browser. -** Ispell +*** Support for the conkeror browser is now obsolete. -+++ -*** 'ispell-comments-and-strings' now accepts START and END arguments, -defaulting to active region when used interactively. +*** Support for the Mosaic browser has been removed. +This support has been obsolete since 25.1. + +** Completion List Mode +New key bindings have been added to 'completion-list-mode': 'n' and +'p' now navigate completions, and 'M-g M-c' switches to the +minibuffer and back to the completion list buffer. +++ -*** New command 'ispell-comment-or-string-at-point' is provided. +** profiler.el +The results displayed by 'profiler-report' now have the usage figures +at the left hand side followed by the function name. This is intended +to make better use of the horizontal space, in particular eliminating +the truncation of function names. There is no way to get the former +layout back. ---- -** The old non-SMIE indentation of 'sh-mode' has been removed. +** Python mode --- -** The sb-image.el library is now marked obsolete. -This file was a compatibility kludge which is no longer needed. +*** New user option 'python-forward-sexp-function'. +This allows the user to easier customize whether to use block-based +navigation or not. --- -** Lisp mode now uses 'common-lisp-indent-function'. -To revert to the previous behavior, -'(setq lisp-indent-function 'lisp-indent-function)' from 'lisp-mode-hook'. - -** Customize +*** 'python-shell-interpreter' now defaults to python3 on systems with python3. --- -*** Customize buffers can now be reverted with 'C-x x g'. +*** 'C-c C-r' can now be used on arbitrary regions. +The command previously extended the start of the region to the start +of the line, but will now actually send the marked region, as +documented. -*** Most customize commands now hide obsolete user options. -Obsolete user options are no longer shown in the listings produced by -the commands 'customize', 'customize-group', 'customize-apropos' and -'customize-changed'. +** Perl mode -To customize obsolete user options, use 'customize-option' or -'customize-saved'. +--- +*** New face 'perl-non-scalar-variable'. +This is used to fontify non-scalar variables. -*** New SVG icons for checkboxes and arrows. -They will be used automatically instead of the old icons. If Emacs is -built without SVG support, the old icons will be used instead. +** Icomplete -** Bookmarks +--- +*** New user option 'icomplete-matches-format'. +This allows controlling the current/total number of matches for the +prompt prefix. -*** Bookmarks can now be targets for new tabs. -When the bookmark.el library is loaded, a customize choice is added -to 'tab-bar-new-tab-choice' for new tabs to show the bookmark list. ++++ +*** New minor modes 'icomplete-vertical-mode' and 'fido-vertical-mode' +These modes modify Icomplete ('M-x icomplete-mode') and Fido ('M-x +fido-mode'), to display completions candidates vertically instead of +horizontally. In Icomplete, completions are rotated and selection +kept at the top. In Fido, completions scroll like a typical dropdown +widget. Both these new minor modes will first turn on their +non-vertical counterparts first, if they are not on already. --- -*** The 'list-bookmarks' menu is now based on 'tabulated-list-mode'. -The interactive bookmark list will now benefit from features in -'tabulated-list-mode' like sorting columns or changing column width. +*** Default value of 'icomplete-compute-delay' has been changed to 0.15 s. -Support for the optional "inline" header line, allowing for a header -without using 'header-line-format', has been dropped. Consequently, -the variables 'bookmark-bmenu-use-header-line' and -'bookmark-bmenu-inline-header-height' are now declared obsolete. +--- +*** Default value of 'icomplete-max-delay-chars' has been changed to 2. --- -*** New user option 'bookmark-fontify'. -If non-nil, setting a bookmark will colorize the current line with -'bookmark-face'. +*** Reduced blinking while completing the next completions set. +Icomplete doesn't hide the hint with the previously computed +completions anymore when compute delay is in effect, or the previous +computation has been aborted by input. Instead it shows the previous +completions until the new ones are ready. --- -*** New user option 'bookmark-menu-confirm-deletion'. -In Bookmark Menu mode, Emacs by default does not prompt for -confirmation when you type 'x' to execute the deletion of bookmarks -that have been marked for deletion. However, if this new option is -non-nil then Emacs will require confirmation with 'yes-or-no-p' before -deleting. +*** Change in meaning of 'icomplete-show-matches-on-no-input'. +Previously, choosing a different completion with commands like 'C-.' +and then hitting 'RET' would choose the default completion. Doing this +will now choose the completion under point instead. Also when this option +is nil, completions are not shown when the minibuffer reads a file name +with initial input as the default directory. -** Edebug +** mspool.el -*** Obsoletions --- -**** 'get-edebug-spec' is obsolete, replaced by 'edebug-get-spec'. -+++ -**** The spec operator ':name NAME' is obsolete, use '&name' instead. -+++ -**** The spec element 'function-form' is obsolete, use 'form' instead. +*** Autoload the main entry point 'mspool-show'. ---- -*** rfc2368.el is now obsolete. -Use rfc6068.el instead. The main difference is that -'rfc2368-parse-mailto-url' and 'rfc2368-unhexify-string' assumed that -the strings were all-ASCII, while 'rfc6068-parse-mailto-url' and -'rfc6068-unhexify-string' parse UTF-8 strings. +** Windmove +++ -*** New function 'def-edebug-elem-spec' to define Edebug spec elements. -These used to be defined with 'def-edebug-spec' thus conflating the -two name spaces, which lead to name collisions. -The use of 'def-edebug-spec' to define Edebug spec elements is -declared obsolete. +*** New user options to customize windmove keybindings. +These options include 'windmove-default-keybindings', +'windmove-display-default-keybindings', +'windmove-delete-default-keybindings', +'windmove-swap-states-default-keybindings'. -*** Edebug specification lists can use some new keywords: +** Occur mode -+++ -**** '&interpose SPEC FUN ARGS..' lets FUN control parsing after SPEC. -More specifically, FUN is called with 'HEAD PF ARGS..' where -PF is a parsing function that expects a single argument (the specs to -use) and HEAD is the code that matched SPEC. +*** New bindings in occur-mode, 'next-error-no-select' bound to 'n' and +'previous-error-no-select' bound to 'p'. -+++ -**** '&error MSG' unconditionally aborts the current edebug instrumentation. +*** The new command 'recenter-current-error', bound to 'l' in Occur or +compilation buffers, recenters the current displayed occurrence/error. -+++ -**** '&name SPEC FUN' extracts the current name from the code matching SPEC. +*** Matches in target buffers are now highlighted as in 'compilation-mode'. +The method of highlighting is specified by the user options +'next-error-highlight' and 'next-error-highlight-no-select'. -** ElDoc +--- +*** A fringe arrow in the "*Occur*" buffer indicates the selected match. -+++ -*** New user option 'eldoc-echo-area-display-truncation-message'. -If non-nil (the default), eldoc will display a message saying -something like "(Documentation truncated. Use `M-x eldoc-doc-buffer' -to see rest)" when a message has been truncated. If nil, truncated -messages will be marked with just "..." at the end. +--- +*** Occur mode may use a different type for 'occur-target' property values. +The value was previously always a marker set to the start of the first +match on the line but can now also be a list of '(BEGIN . END)' pairs +of markers delimiting each match on the line. +This is a fully compatible change to the internal occur-mode +implementation, and code creating their own occur-mode buffers will +work as before. -+++ -*** New hook 'eldoc-documentation-functions'. -This hook is intended to be used for registering doc string functions. -These functions don't need to produce the doc string right away, they -may arrange for it to be produced asynchronously. The results of all -doc string functions are accessible to the user through the user -option 'eldoc-documentation-strategy'. +** New minor mode 'cl-font-lock-built-in-mode' for 'lisp-mode'. +The mode provides refined highlighting of built-in functions, types, +and variables. -*** New hook 'eldoc-display-functions'. -This hook is intended to be used for displaying doc strings. The -functions receive the doc string composed according to -'eldoc-documentation-strategy' and are tasked with displaying it to -the user. Examples of such functions would use the echo area, a -separate buffer, or a tooltip. +** Emacs Lisp mode + +*** The mode-line now indicates whether we're using lexical or dynamic scoping. + +*** A space between an open paren and a symbol changes the indentation rule. +The presence of a space between an open paren and a symbol now is +taken as a statement by the programmer that this should be indented +as a data list rather than as a piece of code. + +** Change Logs and VC +++ -*** New user option 'eldoc-documentation-strategy'. -The built-in choices available for this user option let users compose -the results of 'eldoc-documentation-functions' in various ways, even -if some of those functions are synchronous and some asynchronous. -The user option replaces 'eldoc-documentation-function', which is now -obsolete. +*** 'vc-revert-show-diff' now has a third possible value: 'kill'. +If this variable is 'kill', then the diff buffer will be killed after +the 'vc-revert' action instead of buried. -*** 'eldoc-echo-area-use-multiline-p' is now handled by ElDoc. -The user option 'eldoc-echo-area-use-multiline-p' is now handled -by the ElDoc library itself. Functions in -'eldoc-documentation-functions' don't need to worry about consulting -it when producing a doc string. +*** More VC commands can be used from non-file buffers. +The relevant commands are those that don't change the VC state. +The non-file buffers which can use VC commands are those that have +their 'default-directory' under VC. -** Shell +*** New command 'vc-dir-root' uses the root directory without asking. --- -*** New command in 'shell-mode': 'narrow-to-prompt'. -This is bound to 'C-x n d' in 'shell-mode' buffers, and narrows to the -command line under point (and any following output). +*** New face 'log-view-commit-body'. +This is used when expanding commit messages from 'vc-print-root-log' +and similar commands. --- -*** New user option 'shell-has-auto-cd'. -If non-nil, 'shell-mode' handles implicit "cd" commands, changing the -directory if the command is a directory. Useful for shells like "zsh" -that has this feature. - -** Eshell +*** New faces for 'vc-dir' buffers. +Those are: 'vc-dir-header', 'vc-dir-header-value', 'vc-dir-directory', +'vc-dir-file', 'vc-dir-mark-indicator', 'vc-dir-status-warning', +'vc-dir-status-edited', 'vc-dir-status-up-to-date', +'vc-dir-status-ignored'. --- -*** 'eshell-hist-ignoredups' can now also be used to mimic "erasedups" in bash. +*** The responsible VC backend is now the most specific one. +'vc-responsible-backend' loops over the backends in +'vc-handled-backends' to determine which backend is responsible for a +specific (unregistered) file. Previously the first matching backend +was chosen, but now the one with the most specific path is chosen (in +case there's a directory handled by one backend inside another). + +*** New commands 'vc-dir-mark-registered-files' (bound to '* r') and +'vc-dir-mark-unregistered-files'. + +*** Support for bookmark.el. +Bookmark locations can refer to VC directory buffers. --- -*** Environment variable 'INSIDE_EMACS' is now copied to subprocesses. -Its value contains the result of evaluating '(format "%s,eshell" -emacs-version)'. Other package names, like "tramp", could also be included. +*** New user option 'vc-hg-create-bookmark'. +It controls whether a bookmark or branch will be created when you +invoke 'C-u C-x v s' ('vc-create-tag'). --- -*** Eshell no longer re-initializes its keymap every call. -This allows users to use (define-key eshell-mode-map ...) as usual. -Some modules have their own minor mode now to account for these -changes. +*** 'vc-hg' now uses 'hg summary' to populate extra 'vc-dir' headers. -** EUDC +--- +*** New user option 'vc-git-revision-complete-only-branches'. +If non-nil, only branches and remotes are considered when doing +completion over Git branch names. The default is nil, which causes +tags to be considered as well. -+++ -*** New macOS Contacts backend. -This backend works on newer versions of macOS and is generally -preferred over the eudcb-mab.el backend. +--- +*** New user option 'vc-git-log-switches'. +String or list of strings specifying switches for Git log under VC. -** Tramp +** Gnus +++ -*** New connection method "mtp", which allows accessing media devices -like cell phones, tablets or cameras. +*** New user option 'gnus-topic-display-predicate'. +This can be used to inhibit the display of some topics completely. +++ -*** New connection method "sshfs", which allows accessing remote files -via a file system mounted with 'sshfs'. +*** nnimap now supports the oauth2.el library. +++ -*** Tramp supports SSH authentication via a hardware security key now. -This requires at least OpenSSH 8.2, and a FIDO U2F compatible -security key, like yubikey, solokey, or nitrokey. +*** New Summary buffer sort options for extra headers. +The extra header sort option ('C-c C-s C-x') prompts for a header +and fails if no sort function has been defined. Sorting by +Newsgroups ('C-c C-s C-u') has been pre-defined. +++ -*** Trashed remote files are moved to the local trash directory. -All remote files, which are trashed, are moved to the local trash -directory. Except remote encrypted files, which are always deleted. +*** The '#' command in the Group and Summary buffer now toggles, +instead of sets, the process mark. +++ -*** New command 'tramp-crypt-add-directory'. -This command marks a remote directory to contain only encrypted files. -See the "(tramp) Keeping files encrypted" node of the Tramp manual for -details. This feature is experimental. +*** New user option 'gnus-process-mark-toggle'. +If non-nil (the default), the '#' command in the Group and Summary +buffers will toggle, instead of set, the process mark. + +++ -*** Support of direct asynchronous process invocation. -When Tramp connection property "direct-async-process" is set to -non-nil for a given connection, 'make-process' and 'start-file-process' -calls are performed directly as in "ssh ... ". This avoids -initialization performance penalties. See the "(tramp) Improving -performance of asynchronous remote processes" node of the Tramp manual -for details, and also for a discussion or restrictions. This feature -is experimental. +*** New user option 'gnus-registry-register-all'. +If non-nil (the default), create registry entries for all messages. +If nil, don't automatically create entries, they must be created +manually. +++ -*** New user option 'tramp-debug-to-file'. -When non-nil, this user option instructs Tramp to mirror the debug -buffer to a file under the "/tmp/" directory. This is useful, if (in -rare cases) Tramp blocks Emacs, and we need further debug information. +*** New user options to customise the summary line specs "%[" and "%]". +Four new options introduced in customisation group +'gnus-summary-format'. These are 'gnus-sum-opening-bracket', +'gnus-sum-closing-bracket', 'gnus-sum-opening-bracket-adopted', and +'gnus-sum-closing-bracket-adopted'. Their default values are "[", "]", +"<", ">" respectively. These options control the appearance of "%[" +and "%]" specs in the summary line format. "%[" will normally display +the value of 'gnus-sum-opening-bracket', but can also be +'gnus-sum-opening-bracket-adopted' for the adopted articles. "%]" will +normally display the value of 'gnus-sum-closing-bracket', but can also +be 'gnus-sum-closing-bracket-adopted' for the adopted articles. +++ -*** Tramp supports lock files now. -In order to deactivate this, set user option -'remote-file-name-inhibit-locks' to t. +*** New user option 'gnus-paging-select-next'. +This controls what happens when using commands like 'SPC' and 'DEL' to +page the current article. If non-nil (the default), go to the +next/prev article, but if nil, do nothing at the end/start of the article. +++ -*** Writing sensitive auto-save, backup or lock files to the local -temporary directory must be confirmed. In order to suppress this -confirmation, set user option 'tramp-allow-unsafe-temporary-files' to -t. +*** New gnus-search library. +A new unified search syntax which can be used across multiple +supported search engines. Set 'gnus-search-use-parsed-queries' to +non-nil to enable. -** Tempo ++++ +*** New value for user option 'smiley-style'. +Smileys can now be rendered with emojis instead of small images when +using the new 'emoji' value in 'smiley-style'. ---- -*** 'tempo-define-template' can now re-assign templates to tags. -Previously, assigning a new template to an already defined tag had no -effect. ++++ +*** New user option 'gnus-agent-eagerly-store-articles'. +If non-nil (which is the default), the Gnus Agent will store all read +articles in the Agent cache. -** map.el ++++ +*** New user option 'gnus-global-groups'. +Gnus handles private groups differently from public (i.e., NNTP-like) +groups. Most importantly, Gnus doesn't download external images from +mail-like groups. This can be overridden by putting group names in +'gnus-global-groups': Any group present in that list will be treated +like a public group. -*** Pcase 'map' pattern added keyword symbols abbreviation. -A pattern like '(map :sym)' binds the map's value for ':sym' to 'sym', -equivalent to '(map (:sym sym))'. - ---- -*** The function 'map-copy' now uses 'copy-alist' on alists. -This is a slightly deeper copy than the previous 'copy-sequence'. - ---- -*** The function 'map-contains-key' now supports plists. ++++ +*** New scoring types for the Date header. +You can now score based on the relative age of an article with the new +'<' and '>' date scoring types. ---- -*** More consistent duplicate key handling in 'map-merge-with'. -Until now, 'map-merge-with' promised to call its function argument -whenever multiple maps contained 'eql' keys. However, this did not -always coincide with the keys that were actually merged, which could -be 'equal' instead. The function argument is now called whenever keys -are merged, for greater consistency with 'map-merge' and 'map-elt'. ++++ +*** User-defined scoring is now possible. +The new type is 'score-fn'. More information in the Gnus manual node +"(gnus) Score File Format". -** Package ++++ +*** New backend 'nnselect'. +The newly added 'nnselect' backend allows creating groups from an +arbitrary list of articles that may come from multiple groups and +servers. These groups generally behave like any other group: they may +be ephemeral or persistent, and allow article marking, moving, +deletion, etc. 'nnselect' groups may be created like any other group, +but there are three convenience functions for the common case of +obtaining the list of articles as a result of a search: +'gnus-group-make-search-group' ('G g') that will prompt for an 'nnir' +search query and create a persistent group for that search; +'gnus-group-read-ephemeral-search-group' ('G G') that will prompt for +an 'nnir' search query and create an ephemeral group for that search; +and 'gnus-summary-make-group-from-search' ('C-c C-p') that will create +a persistent group with the search parameters of a current ephemeral +search group. ---- -*** '/ s' ('package-menu-filter-by-status') changes parameter handling. -The command was documented to take a comma-separated list of statuses -to filter by, but instead it used the parameter as a regexp. The -command has been changed so that it now works as documented, and -checks statuses not as a regexp, but instead an exact match from the -comma-separated list. +As part of this addition, the user option 'nnir-summary-line-format' +has been removed; its functionality is now available directly in the +'gnus-summary-line-format' specs '%G' and '%g'. The user option +'gnus-refer-thread-use-nnir' has been renamed to +'gnus-refer-thread-use-search'. +++ -*** New command 'package-browse-url' and keystroke 'w'. +*** New user option 'gnus-dbus-close-on-sleep'. +On systems with D-Bus support, it is now possible to register a signal +to close all Gnus servers before the system sleeps. +++ -*** New commands to filter the package list. -The filter commands are bound to the following keys: - -key binding ---- ------- -/ a package-menu-filter-by-archive -/ d package-menu-filter-by-description -/ k package-menu-filter-by-keyword -/ N package-menu-filter-by-name-or-description -/ n package-menu-filter-by-name -/ s package-menu-filter-by-status -/ v package-menu-filter-by-version -/ m package-menu-filter-marked -/ u package-menu-filter-upgradable -/ / package-menu-filter-clear - -*** Option to automatically native-compile packages upon installation. -Customize the user option 'package-native-compile' to enable automatic -native compilation of packages when they are installed. That option -is nil by default; if set non-nil, and if your Emacs was built with -native-compilation support, each package will be natively compiled -when it is installed, by invoking an asynchronous Emacs subprocess to -run the native-compilation of the package files. +*** The key binding of 'gnus-summary-search-article-forward' has changed. +This command was previously on 'M-s' and shadowed the global 'M-s' +search prefix. The command has now been moved to 'M-s M-s'. (For +consistency, the 'M-s M-r' key binding has been added for the +'gnus-summary-search-article-backward' command.) --- -*** Column widths in 'list-packages' display can now be customized. -See the new user options 'package-name-column-width', -'package-version-column-width', 'package-status-column-width', and -'package-archive-column-width'. - -** gdb-mi - -*** New user option 'gdb-registers-enable-filter'. -If non-nil, apply a register filter based on -'gdb-registers-filter-pattern-list'. - -+++ -*** gdb-mi can now store and restore window configurations. -Use 'gdb-save-window-configuration' to save window configuration to a -file and 'gdb-load-window-configuration' to load from a file. These -commands can also be accessed through the menu bar under "Gud => -GDB-Windows". 'gdb-default-window-configuration-file', when non-nil, -is loaded when GDB starts up. +*** The value of "all" in the 'large-newsgroup-initial' group parameter changes. +It was previously nil, which didn't work, because nil is +indistinguishable from not being present. The new value for "all" is +the symbol 'all'. +++ -*** gdb-mi can now restore window configuration after quit. -Set 'gdb-restore-window-configuration-after-quit' to non-nil and Emacs -will remember the window configuration before GDB started and restore -it after GDB quits. A toggle button is also provided under "Gud => -GDB-Windows". +*** The name of dependent Gnus sessions has changed from "slave" to "child". +The names of the commands 'gnus-slave', 'gnus-slave-no-server' and +'gnus-slave-unplugged' have changed to 'gnus-child', +'gnus-child-no-server' and 'gnus-child-unplugged' respectively. +++ -*** gdb-mi now has a better logic for displaying source buffers. -Now GDB only uses one source window to display source file by default. -Customize 'gdb-max-source-window-count' to use more than one window. -Control source file display by 'gdb-display-source-buffer-action'. +*** The 'W Q' summary mode command now takes a numerical prefix to +allow adjusting the fill width. +++ -*** The default value of 'gdb-mi-decode-strings' is now t. -This means that the default coding-system is now used to decode strings -and source file names from GDB. - -** Gravatar - ---- -*** New user option 'gravatar-service' for host to query for gravatars. -Defaults to 'libravatar', with 'unicornify' and 'gravatar' as options. +*** New variable 'mm-inline-font-lock'. +This variable is supposed to be bound by callers to determine whether +inline MIME parts (that support it) are supposed to be font-locked or +not. -** Compilation mode +** Message --- -*** New function 'ansi-color-compilation-filter'. -This function is meant to be used in 'compilation-filter-hook'. +*** Respect 'message-forward-ignored-headers' more. +Previously, this user option would not be consulted if +'message-forward-show-mml' was nil and forwarding as MIME. ---- -*** New user option 'ansi-color-for-compilation-mode'. -This controls what 'ansi-color-compilation-filter' does. ++++ +*** New user option 'message-forward-included-mime-headers'. +This is used when forwarding messages as MIME, but not using MML. -*** Regexp matching of messages is now case-sensitive by default. -The variable 'compilation-error-case-fold-search' can be set for -case-insensitive matching of messages when the old behavior is -required, but the recommended solution is to use a correctly matching -regexp instead. ++++ +*** Message now supports the OpenPGP header. +To generate these headers, add the new function +'message-add-openpgp-header' to 'message-send-hook'. The header will +be generated according to the new 'message-openpgp-header' variable. --- -*** New user option 'compilation-search-all-directories'. -When doing parallel builds, directories and compilation errors may -arrive in the "*compilation*" buffer out-of-order. If this variable is -non-nil (the default), Emacs will now search backwards in the buffer -for any directory the file with errors may be in. If nil, this won't -be done (and this restores how this previously worked). +*** A change to how "Mail-Copies-To: never" is handled. +If a user has specified "Mail-Copies-To: never", and Message was asked +to do a "wide reply", some other arbitrary recipient would end up in +the resulting "To" header, while the remaining recipients would be put +in the "Cc" header. This is somewhat misleading, as it looks like +you're responding to a specific person in particular. This has been +changed so that all the recipients are put in the "To" header in these +instances. ---- -*** Messages from ShellCheck are now recognized. ++++ +*** New command to start Emacs in Message mode to send an email. +Emacs can be defined as a handler for the "x-scheme-handler/mailto" +MIME type with the following command: "emacs -f message-mailto %u". +An "emacs-mail.desktop" file has been included, suitable for +installing in desktop directories like "/usr/share/applications" or +"~/.local/share/applications". +Clicking on a 'mailto:' link in other applications will then open +Emacs with headers filled out according to the link, e.g. +"mailto:larsi@gnus.org?subject=This+is+a+test". If you prefer +emacsclient, use "emacsclient -e '(message-mailto "%u")'" +or "emacsclient-mail.desktop". --- -*** Messages from Visual Studio that mention column numbers are now recognized. +*** Change to default value of 'message-draft-headers' user option. +The 'Date' symbol has been removed from the default value, meaning that +draft or delayed messages will get a date reflecting when the message +was sent. To restore the original behavior of dating a message +from when it is first saved or delayed, add the symbol 'Date' back to +this user option. -** Hi Lock mode ++++ +*** New command to take screenshots. +In Message mode buffers, the 'C-c C-p' ('message-insert-screenshot') +command has been added. It depends on using an external program to +take the actual screenshot, and defaults to "ImageMagick import". ---- -*** Matching in 'hi-lock-mode' is case-sensitive when regexp contains -upper case characters and 'search-upper-case' is non-nil. -'highlight-phrase' also uses 'search-whitespace-regexp' -to substitute spaces in regexp search. +** Smtpmail ---- -*** The default value of 'hi-lock-highlight-range' was enlarged. -The new default value is 2000000 (2 megabytes). ++++ +*** smtpmail now supports using the oauth2.el library. -** Whitespace mode ++++ +*** New user option 'smtpmail-store-queue-variables'. +If non-nil, SMTP variables will be stored together with the queued +messages, and will then be used when sending with +'M-x smtpmail-send-queued-mail'. +++ -*** New style 'missing-newline-at-eof'. -If present in 'whitespace-style' (as it is by default), the final -character in the buffer will be highlighted if the buffer doesn't end -with a newline. +*** Allow direct selection of smtp authentication mechanism. +A server entry retrieved by auth-source can request a desired smtp +authentication mechanism by setting a value for the key 'smtp-auth'. --- -*** The default 'whitespace-enable-predicate' predicate has changed. -It used to check elements in the list version of -'whitespace-global-modes' with 'eq', but now uses 'derived-mode-p'. +** Lisp mode now uses 'common-lisp-indent-function'. +To revert to the previous behavior, +'(setq lisp-indent-function 'lisp-indent-function)' from 'lisp-mode-hook'. -** Texinfo +** ElDoc ---- -*** New user option 'texinfo-texi2dvi-options'. -This is used when invoking 'texi2dvi' from 'texinfo-tex-buffer'. ++++ +*** New user option 'eldoc-echo-area-display-truncation-message'. +If non-nil (the default), eldoc will display a message saying +something like "(Documentation truncated. Use `M-x eldoc-doc-buffer' +to see rest)" when a message has been truncated. If nil, truncated +messages will be marked with just "..." at the end. ---- -*** New commands for moving in and between environments. -An "environment" is something that ends with '@end'. The commands are -'C-c C-c C-f' (next end), 'C-c C-c C-b' (previous end), -'C-c C-c C-n' (next start) and 'C-c C-c C-p' (previous start), as well -as 'C-c .', which will alternate between the start and the end of the -current environment. ++++ +*** New hook 'eldoc-documentation-functions'. +This hook is intended to be used for registering doc string functions. +These functions don't need to produce the doc string right away, they +may arrange for it to be produced asynchronously. The results of all +doc string functions are accessible to the user through the user +option 'eldoc-documentation-strategy'. -** Rmail +*** New hook 'eldoc-display-functions'. +This hook is intended to be used for displaying doc strings. The +functions receive the doc string composed according to +'eldoc-documentation-strategy' and are tasked with displaying it to +the user. Examples of such functions would use the echo area, a +separate buffer, or a tooltip. ---- -*** New user option 'rmail-re-abbrevs'. -Its default value matches localized abbreviations of the "reply" -prefix on the Subject line in various languages. ++++ +*** New user option 'eldoc-documentation-strategy'. +The built-in choices available for this user option let users compose +the results of 'eldoc-documentation-functions' in various ways, even +if some of those functions are synchronous and some asynchronous. +The user option replaces 'eldoc-documentation-function', which is now +obsolete. ---- -*** New user option 'shr-offer-extend-specpdl'. -If this is nil, rendering of HTML in the email message body that -requires to enlarge 'max-specpdl-size', the number of Lisp variable -bindings, will be aborted, and Emacs will not ask you whether to -enlarge 'max-specpdl-size' to complete the rendering. The default is -t, which preserves the original behavior. +*** 'eldoc-echo-area-use-multiline-p' is now handled by ElDoc. +The user option 'eldoc-echo-area-use-multiline-p' is now handled +by the ElDoc library itself. Functions in +'eldoc-documentation-functions' don't need to worry about consulting +it when producing a doc string. ---- -*** New user option 'rmail-show-message-set-modified'. -If set non-nil, showing an unseen message will set the Rmail buffer's -modified flag. +** Tramp + ++++ +*** New connection method "mtp", which allows accessing media devices +like cell phones, tablets or cameras. + ++++ +*** New connection method "sshfs", which allows accessing remote files +via a file system mounted with 'sshfs'. + ++++ +*** Tramp supports SSH authentication via a hardware security key now. +This requires at least OpenSSH 8.2, and a FIDO U2F compatible +security key, like yubikey, solokey, or nitrokey. + ++++ +*** Trashed remote files are moved to the local trash directory. +All remote files, which are trashed, are moved to the local trash +directory. Except remote encrypted files, which are always deleted. + ++++ +*** New command 'tramp-crypt-add-directory'. +This command marks a remote directory to contain only encrypted files. +See the "(tramp) Keeping files encrypted" node of the Tramp manual for +details. This feature is experimental. + ++++ +*** Support of direct asynchronous process invocation. +When Tramp connection property "direct-async-process" is set to +non-nil for a given connection, 'make-process' and 'start-file-process' +calls are performed directly as in "ssh ... ". This avoids +initialization performance penalties. See the "(tramp) Improving +performance of asynchronous remote processes" node of the Tramp manual +for details, and also for a discussion or restrictions. This feature +is experimental. + ++++ +*** New user option 'tramp-debug-to-file'. +When non-nil, this user option instructs Tramp to mirror the debug +buffer to a file under the "/tmp/" directory. This is useful, if (in +rare cases) Tramp blocks Emacs, and we need further debug information. + ++++ +*** Tramp supports lock files now. +In order to deactivate this, set user option +'remote-file-name-inhibit-locks' to t. + ++++ +*** Writing sensitive auto-save, backup or lock files to the local +temporary directory must be confirmed. In order to suppress this +confirmation, set user option 'tramp-allow-unsafe-temporary-files' to +t. + +** Tempo --- -*** New faces for heading elements. -Those are 'shr-h1', 'shr-h2', 'shr-h3', 'shr-h4', 'shr-h5', 'shr-h6'. +*** 'tempo-define-template' can now re-assign templates to tags. +Previously, assigning a new template to an already defined tag had no +effect. -** MH-E mail handler for Emacs +** gdb-mi -Functions and variables related to handling junk mail have been -renamed to not associate color with sender quality. +*** New user option 'gdb-registers-enable-filter'. +If non-nil, apply a register filter based on +'gdb-registers-filter-pattern-list'. +++ -*** New names for mh-junk interactive functions. -Function 'mh-junk-whitelist' is renamed 'mh-junk-allowlist'. -Function 'mh-junk-blacklist' is renamed 'mh-junk-blocklist'. +*** gdb-mi can now store and restore window configurations. +Use 'gdb-save-window-configuration' to save window configuration to a +file and 'gdb-load-window-configuration' to load from a file. These +commands can also be accessed through the menu bar under "Gud => +GDB-Windows". 'gdb-default-window-configuration-file', when non-nil, +is loaded when GDB starts up. +++ -*** New binding for 'mh-junk-allowlist'. -The key binding for 'mh-junk-allowlist' is changed from 'J w' to 'J a'. -The old binding is supported but warns that it is obsolete. +*** gdb-mi can now restore window configuration after quit. +Set 'gdb-restore-window-configuration-after-quit' to non-nil and Emacs +will remember the window configuration before GDB started and restore +it after GDB quits. A toggle button is also provided under "Gud => +GDB-Windows". +++ -*** New names for some hooks. -'mh-whitelist-msg-hook' is renamed 'mh-allowlist-msg-hook'. -'mh-blacklist-msg-hook' is renamed 'mh-blocklist-msg-hook'. +*** gdb-mi now has a better logic for displaying source buffers. +Now GDB only uses one source window to display source file by default. +Customize 'gdb-max-source-window-count' to use more than one window. +Control source file display by 'gdb-display-source-buffer-action'. +++ -*** New names for some variables. -Variable 'mh-whitelist-preserves-sequences-flag' is renamed -'mh-allowlist-preserves-sequences-flag'. +*** The default value of 'gdb-mi-decode-strings' is now t. +This means that the default coding-system is now used to decode strings +and source file names from GDB. + +** Compilation mode + +--- +*** New function 'ansi-color-compilation-filter'. +This function is meant to be used in 'compilation-filter-hook'. + +--- +*** New user option 'ansi-color-for-compilation-mode'. +This controls what 'ansi-color-compilation-filter' does. + +*** Regexp matching of messages is now case-sensitive by default. +The variable 'compilation-error-case-fold-search' can be set for +case-insensitive matching of messages when the old behavior is +required, but the recommended solution is to use a correctly matching +regexp instead. + +--- +*** New user option 'compilation-search-all-directories'. +When doing parallel builds, directories and compilation errors may +arrive in the "*compilation*" buffer out-of-order. If this variable is +non-nil (the default), Emacs will now search backwards in the buffer +for any directory the file with errors may be in. If nil, this won't +be done (and this restores how this previously worked). + +--- +*** Messages from ShellCheck are now recognized. + +--- +*** Messages from Visual Studio that mention column numbers are now recognized. + +** Hi Lock mode + +--- +*** Matching in 'hi-lock-mode' is case-sensitive when regexp contains +upper case characters and 'search-upper-case' is non-nil. +'highlight-phrase' also uses 'search-whitespace-regexp' +to substitute spaces in regexp search. + +--- +*** The default value of 'hi-lock-highlight-range' was enlarged. +The new default value is 2000000 (2 megabytes). + +** Whitespace mode +++ -*** New names for some faces. -Face 'mh-folder-blacklisted' is renamed 'mh-folder-blocklisted'. -Face 'mh-folder-whitelisted' is renamed 'mh-folder-allowlisted'. +*** New style 'missing-newline-at-eof'. +If present in 'whitespace-style' (as it is by default), the final +character in the buffer will be highlighted if the buffer doesn't end +with a newline. -** Apropos +--- +*** The default 'whitespace-enable-predicate' predicate has changed. +It used to check elements in the list version of +'whitespace-global-modes' with 'eq', but now uses 'derived-mode-p'. -*** New commands 'apropos-next-symbol' and 'apropos-previous-symbol'. -These new navigation commands are bound to 'n' and 'p' in -'apropos-mode'. +** Texinfo -*** New command 'apropos-function'. -This works like 'C-u M-x apropos-command' but is more discoverable. +--- +*** New user option 'texinfo-texi2dvi-options'. +This is used when invoking 'texi2dvi' from 'texinfo-tex-buffer'. -*** New face 'apropos-button'. -Applies to buttons that indicate a face. +--- +*** New commands for moving in and between environments. +An "environment" is something that ends with '@end'. The commands are +'C-c C-c C-f' (next end), 'C-c C-c C-b' (previous end), +'C-c C-c C-n' (next start) and 'C-c C-c C-p' (previous start), as well +as 'C-c .', which will alternate between the start and the end of the +current environment. + +** Rmail + +--- +*** New user option 'rmail-re-abbrevs'. +Its default value matches localized abbreviations of the "reply" +prefix on the Subject line in various languages. + +--- +*** New user option 'shr-offer-extend-specpdl'. +If this is nil, rendering of HTML in the email message body that +requires to enlarge 'max-specpdl-size', the number of Lisp variable +bindings, will be aborted, and Emacs will not ask you whether to +enlarge 'max-specpdl-size' to complete the rendering. The default is +t, which preserves the original behavior. + +--- +*** New user option 'rmail-show-message-set-modified'. +If set non-nil, showing an unseen message will set the Rmail buffer's +modified flag. ** CC Mode @@ -1933,40 +2094,6 @@ To enable, add it to appropriate entries in 'c-offsets-alist', e.g.: c-lineup-arglist)) (c-set-offset 'statement-cont '(c-lineup-ternary-bodies +)) -** browse-url - -*** Added support for custom URL handlers. -There is a new variable 'browse-url-default-handlers' and a user -option 'browse-url-handlers' being alists with '(REGEXP-OR-PREDICATE -. FUNCTION)' entries allowing to define different browsing FUNCTIONs -depending on the URL to be browsed. The variable is for default -handlers provided by Emacs itself or external packages, the user -option is for the user (and allows for overriding the default -handlers). - -Formerly, one could do the same by setting -'browse-url-browser-function' to such an alist. This usage is still -supported but deprecated. - -*** Categorization of browsing commands in internal vs. external. -All standard browsing commands such as 'browse-url-firefox', -'browse-url-mail', or 'eww' have been categorized into internal (URL -is browsed in Emacs) or external (an external application is spawned -with the URL). This is done by adding a 'browse-url-browser-kind' -symbol property to the browsing commands. With a new command -'browse-url-with-browser-kind', an URL can explicitly be browsed with -either an internal or external browser. - ---- -*** Support for browsing of remote files. -If a remote file is taken, a local temporary copy of that file is -passed to the browser. - -*** Support for the conkeror browser is now obsolete. - -*** Support for the Mosaic browser has been removed. -This support has been obsolete since 25.1. - ** SHR --- @@ -1987,6 +2114,10 @@ to a more readable text. Set this user option to nil to get the previous behavior of rendering as wide as the 'window-width' allows. If 'shr-width' is non-nil, it overrides this variable. +--- +*** New faces for heading elements. +Those are 'shr-h1', 'shr-h2', 'shr-h3', 'shr-h4', 'shr-h5', 'shr-h6'. + ** Images --- @@ -2208,101 +2339,9 @@ binding in 'xref--xref-buffer-mode-map'. --- *** New user option 'etags-xref-prefer-current-file'. -When non-nil, 'M-.' matches for identifiers in the file visited by the +When non-nil, matches for identifiers in the file visited by the current buffer will be shown first in the "*xref*" buffer. -** json.el - ---- -*** JSON number parsing is now stricter. -Numbers with a leading plus sign, leading zeros, or a missing integer -component are now rejected by 'json-read' and friends. This makes -them more compliant with the JSON specification and consistent with -the native JSON parsing functions. - ---- -*** Some JSON encoding functions are now obsolete. -The functions 'json-encode-number', 'json-encode-hash-table', -'json-encode-key', and 'json-encode-list' are now obsolete. - -The first two are kept as aliases of 'json-encode', which should be -used instead. Uses of 'json-encode-list' should be changed to call -one of 'json-encode', 'json-encode-alist', 'json-encode-plist', or -'json-encode-array' instead. - -** json.c - -+++ -*** New function 'json-available-p'. -This predicate returns non-nil if Emacs is built with libjansson -support, and it is available on the current system. - -+++ -*** Native JSON functions now signal an error if libjansson is unavailable. -This affects 'json-serialize', 'json-insert', 'json-parse-string', -and 'json-parse-buffer'. This can happen if Emacs was compiled with -libjansson, but the DLL cannot be found and/or loaded by Emacs at run -time. Previously, Emacs would display a message and return nil in -these cases. - -*** The JSON functions 'json-serialize', 'json-insert', -'json-parse-string', and 'json-parse-buffer' now implement some of the -semantics of RFC 8259 instead of the earlier RFC 4627. In particular, -these functions now accept top-level JSON values that are neither -arrays nor objects. - -** xml.el - -*** XML serialization functions now reject invalid characters. -Previously 'xml-print' would produce invalid XML when given a string -with characters that are not valid in XML (see -https://www.w3.org/TR/xml/#charsets). Now it rejects such strings. - -** erc - ---- -*** erc-services.el now supports NickServ passwords from auth-source. -The 'erc-use-auth-source-for-nickserv-password' user option enables -querying auth-source for NickServ passwords. To enable this, add the -following to your init file: - - (setq erc-prompt-for-nickserv-password nil - erc-use-auth-source-for-nickserv-password t) - ---- -*** The '/ignore' command will now ask for a timeout to stop ignoring the user. -Allowed inputs are seconds or ISO8601-like periods like "1h" or "4h30m". - ---- -*** ERC now recognizes 'C-]' for italic text. -Italic text is displayed in the new 'erc-italic-face'. - ---- -*** The erc-compat.el library is now marked obsolete. -This file contained ERC compatibility code for Emacs 21 and XEmacs -which is no longer needed. - ---- -*** erc-match.el now supports 'message' highlight type (not including the nick). -The 'erc-current-nick-highlight-type', 'erc-pal-highlight-type', -'erc-fool-highlight-type', 'erc-keyword-highlight-type', and -'erc-dangerous-host-highlight-type' variables now support a 'message' -type for highlighting the entire message but not the sender's nick. - -*** erc-status-sidebar.el is now part of ERC. -The 'erc-status-sidebar' package which provides a HexChat-like -activity overview sidebar for joined IRC channels is now part of ERC. - -+++ -*** erc-tls now supports specifying a TLS client certificate. -The 'erc-tls' function has been updated to allow specifying a TLS -client certificate for authentication, as an alternative to NickServ -password-based authentication. This is referred to as "CertFP" (short -for Certificate Fingerprint) by several IRC networks. See the Info -node "(erc) Connecting" in the ERC manual for more details and -examples on how to specify and use TLS client certificates with -'erc-tls'. - ** Battery --- @@ -2346,57 +2385,6 @@ custom rules, see the variables 'bug-reference-setup-from-vc-alist', It's bound to the 'C-c C-c f' keystroke, and prompts for a local file name. -** Recentf - ---- -*** The recentf files are no longer backed up. - ---- -*** 'recentf-auto-cleanup' time string now repeats. -When 'recentf-auto-cleanup' is set to a time string, it now repeats -every day, rather than only running once after the mode is turned on. - -** Calc - ---- -*** The behavior when doing forward-delete has been changed. -Previously, using the 'C-d' command would delete the final number in -the input field, no matter where point was. This has been changed to -work more traditionally, with 'C-d' deleting the next character. -Likewise, point isn't moved to the end of the string before inserting -digits. - -+++ -*** Setting the word size to zero disables word clipping. -The word size normally clips the results of certain bit-oriented -operations such as shifts and bitwise XOR. A word size of zero, set -by 'b w', makes the operation have effect on the whole argument values -and the result is not truncated in any way. - ---- -*** The '/' operator now has higher precedence in (La)TeX input mode. -It no longer has lower precedence than '+' and '-'. - ---- -*** Calc now marks its windows dedicated. -The new user option 'calc-make-windows-dedicated' controls this. It -is t by default; set to nil to get back the old behavior. - -** term-mode - ---- -*** New user option 'term-scroll-snap-to-bottom'. -By default, 'term' and 'ansi-term' will now recenter the buffer so -that the prompt is on the final line in the window. Setting this new -user option to nil inhibits this behavior. - ---- -*** New user option 'term-set-terminal-size' -If non-nil, the 'LINES' and 'COLUMNS' environment variables will be set -based on the current window size. In previous versions of Emacs, this -was always done (and that could lead to odd displays when resizing the -window after starting). This variable defaults to nil. - ** Widget +++ @@ -2438,56 +2426,23 @@ buttons in it. This function takes a string and returns a string propertized in a way that makes it a valid button. -** subr-x -+++ -*** A number of new string manipulation functions have been added. -'string-clean-whitespace', 'string-fill', 'string-limit', -'string-lines', 'string-pad' and 'string-chop-newline'. - -*** New macro 'named-let' that provides Scheme's "named let" looping construct. +** thing-at-point -** thingatpt ++++ +*** New 'thing-at-point' target: 'existing-filename'. +This is like 'filename', but is a full path, and is nil if the file +doesn't exist. +++ *** New variable 'thing-at-point-provider-alist'. This allows mode-specific alterations to how 'thing-at-point' works. --- -*** thingatpt now respects fields. +*** thing-at-point now respects fields. 'thing-at-point' (and all functions that use it, like 'symbol-at-point') will narrow to the current field (if any) before trying to identify the thing at point. -** Enriched mode - ---- -*** 'C-a' is by default no longer bound to 'beginning-of-line-text'. -This is so 'C-a' works as in other modes, and in particular holding -Shift while typing 'C-a', i.e. 'C-S-a', will now highlight the text. - -** ERT - -+++ -*** ERT can now output more verbose test failure reports. -If the 'EMACS_TEST_VERBOSE' environment variable is set, failure -summaries will include the failing condition. - -** File Locks - -+++ -*** New user option 'lock-file-name-transforms'. -This option allows controlling where lock files are written. It uses -the same syntax as 'auto-save-file-name-transforms'. - -+++ -*** New user option 'remote-file-name-inhibit-locks'. -When non-nil, this option suppresses lock files for remote files. - -+++ -*** New minor mode 'lock-file-mode'. -This command, called interactively, toggles the local value of -'create-lockfiles' in the current buffer. - ** image-dired --- @@ -2503,74 +2458,13 @@ images are marked. ** Miscellaneous -+++ -*** New user option 'file-preserve-symlinks-on-save'. -This controls what Emacs does when saving buffers that visit files via -symbolic links, and 'file-precious-flag' is non-nil. - -+++ -*** New user option 'copy-directory-create-symlink'. -If non-nil, will make `copy-directory' (when used on a symbolic -link) copy the link instead of following the link. The default is -nil, so the default behavior is unchanged. - -+++ -*** New function 'replace-regexp-in-region'. - -+++ -*** New function 'replace-string-in-region'. - ---- -*** New function 'mail-header-parse-addresses-lax'. -This takes a comma-separated string and returns a list of mail/name -pairs. - ---- -*** New function 'mail-header-parse-address-lax'. -Parse a string as a mail address-like string. - --- *** 'shell-script-mode' now supports 'outline-minor-mode'. The outline headings have lines that start with "###". -+++ -*** New command 'revert-buffer-quick'. -This is bound to 'C-x x g' and is like `revert-buffer', but prompts -less. - -+++ -*** New user option 'revert-buffer-quick-short-answers'. This -controls how the new 'revert-buffer-quick' (`C-x x g') command -prompts. - --- *** fileloop will now skip missing files instead of signalling an error. -+++ -*** ".dir-locals.el" now supports setting 'auto-mode-alist'. -The new 'auto-mode-alist' specification in ".dir-locals.el" files can -now be used to override the global 'auto-mode-alist' in the current -directory tree. - ---- -*** New utility function 'make-separator-line'. - ---- -*** New face 'separator-line'. -This is used by 'make-separator-line'. - -+++ -*** New user option 'ignored-local-variable-values'. -This is the opposite of 'safe-local-variable-values' -- it's an alist -of variable-value pairs that are to be ignored when reading a -local-variables section of a file. - ---- -*** 'indent-tabs-mode' is now a global minor mode instead of just a variable. - ---- -*** New user option 'save-place-abbreviate-file-names'. - --- *** 'tabulated-list-mode' can now restore original display order. Many commands (like 'C-x C-b') are derived from 'tabulated-list-mode', @@ -2582,29 +2476,9 @@ will now restore the original order. --- *** 'M-left' and 'M-right' now move between columns in 'tabulated-list-mode'. -+++ -*** New utility function 'insert-into-buffer'. -This is like 'insert-buffer-substring', but works in the opposite -direction. - -+++ -*** New user option 'kill-transform-function'. -This can be used to transform (and suppress) strings from entering the -kill ring. - ---- -*** 'C-u M-x dig' will now prompt for a query type to use. - +++ *** rcirc now supports SASL authentication. -+++ -*** 'save-interprogram-paste-before-kill' can now be a number. -In that case, it's interpreted as a limit on the size of the clipboard -data that will be saved to the 'kill-ring' prior to killing text: if -the size of the clipboard data is greater than or equal to the limit, -it will not be saved. - --- *** New variable 'hl-line-overlay-priority'. This can be used to change the priority of the hl-line overlays. @@ -2614,217 +2488,48 @@ This can be used to change the priority of the hl-line overlays. This command will open a viewer based on the file type, as determined by "~/.mailcap" and related files and variables. -+++ -*** New command 'C-x C-k Q' to force redisplay in keyboard macros. - --- *** New user option 'remember-diary-regexp'. --- *** New user option 'remember-text-format-function'. -*** New function 'buffer-line-statistics'. -This function returns some statistics about the line lengths in a buffer. +--- +*** New user option 'authinfo-hide-elements'. +This can be set to nil to inhibit hiding passwords in ".authinfo" files. -+++ -*** New variable 'inhibit-interaction' to make user prompts signal an error. -If this is bound to something non-nil, functions like -'read-from-minibuffer', 'read-char' (and related) will signal an -'inhibited-interaction' error. +--- +*** 'hexl-mode' scrolling commands now heed 'next-screen-context-lines'. +Previously, 'hexl-scroll-down' and 'hexl-scroll-up' would scroll +up/down an entire window, but they now work more like the standard +scrolling commands. --- -*** 'process-attributes' now works under OpenBSD, too. - -+++ -*** New button face 'flat-button'. -This is a plain 2D button, but uses the background color instead of -the foreground color. - ---- -*** New face 'shortdoc-heading'. -Applies to headings of shortdoc sections. - -+++ -*** New predicate functions 'length<', 'length>' and 'length='. -Using these functions may be more efficient than using 'length' (if -the length of a (long) list is being computed just to compare this -length to a number). - ---- -*** 'remove-hook' is now an interactive command. - ---- -*** New user option 'authinfo-hide-elements'. -This can be set to nil to inhibit hiding passwords in ".authinfo" files. - -+++ -*** New variable 'current-minibuffer-command'. -This is like 'this-command', but it is bound recursively when entering -the minibuffer. - -+++ -*** New function 'object-intervals'. -This function returns a copy of the list of intervals (i.e., text -properties) in the object in question (which must either be a string -or a buffer). - ---- -*** 'hexl-mode' scrolling commands now heed 'next-screen-context-lines'. -Previously, 'hexl-scroll-down' and 'hexl-scroll-up' would scroll -up/down an entire window, but they now work more like the standard -scrolling commands. - ---- -*** Errors in 'kill-emacs-hook' no longer prevent Emacs from shutting down. -If a function in that hook signals an error in an interactive Emacs, -the user will be prompted on whether to continue. If the user doesn't -answer within five seconds, Emacs will continue shutting down anyway. - ---- -*** iso-transl is now preloaded. -This means that keystrokes like 'Alt-[' are defined by default, -instead of only becoming available after doing (for instance) -'C-x 8 '. - -*** New user option 'completions-detailed'. -When non-nil, some commands like 'describe-symbol' show more detailed -completions with more information in completion prefix and suffix. - ---- -*** User option 'completions-format' supports a new value 'one-column'. - ---- -*** New user option 'bibtex-unify-case-function'. -This new option allows the user to customize how case is converted -when unifying entries. +*** New user option 'bibtex-unify-case-function'. +This new option allows the user to customize how case is converted +when unifying entries. --- *** The user option 'bibtex-maintain-sorted-entries' now permits user-defined sorting schemes. -+++ -*** 'format-seconds' can now be used for sub-second times. -The new optional "," parameter has been added, and -'(format-seconds "%mm %,1ss" 66.4)' will now result in "1m 6.4s". - ---- -*** 'global-display-fill-column-indicator-mode' skips some buffers. -By default, turning on 'global-display-fill-column-indicator-mode' -doesn't turn on 'display-fill-column-indicator-mode' in special-mode -buffers. This can be controlled by customizing the variable -'global-display-fill-column-indicator-modes'. - -+++ -*** New user option 'next-error-message-highlight'. -In addition to a fringe arrow, 'next-error' error may now optionally -highlight the current error message in the 'next-error' buffer. -This user option can be also customized to keep highlighting on all -visited errors, so you can have an overview what errors were already visited. - ---- -*** New choice 'next-error-quit-window' for 'next-error-found-function'. -When 'next-error-found-function' is customized to 'next-error-quit-window', -then typing the numeric prefix argument 0 before the command 'next-error' -will quit the source window after visiting the next occurrence. - -+++ -*** New user option 'tab-first-completion'. -If 'tab-always-indent' is 'complete', this new user option can be used to -further tweak whether to complete or indent. - ---- -*** 'dired-query' now uses 'read-char-from-minibuffer'. -Using it instead of 'read-char-choice' allows using 'C-x o' -to switch to the help window displayed after typing 'C-h'. - ---- -*** 'zap-up-to-char' now uses 'read-char-from-minibuffer'. -This allows navigating through the history of characters that have -been input. This is mostly useful for characters that have complex -input methods where inputting the character again may involve many -keystrokes. - -+++ -*** Interactive regular expression search now uses faces for sub-groups. -E.g., 'C-M-s foo-\([0-9]+\)' will now use the 'isearch-group-1' face -on the part of the regexp that matches the sub-expression "[0-9]+". -By default, there are two faces for sub-group highlighting, but you -can define more faces whose names are of the form 'isearch-group-N', -where N are successive numbers above 2. - -This is controlled by the 'search-highlight-submatches' user option. -This feature is available only on terminals that have enough colors to -distinguish between sub-expression highlighting. - -+++ -*** Interactive regular expression replace now uses faces for sub-groups. -Like 'search-highlight-submatches', this is controlled by the new user option -'query-replace-highlight-submatches'. - --- *** New user option 'reveal-auto-hide'. If non-nil (the default), revealed text is automatically hidden when point leaves the text. If nil, the text is not hidden again. Instead 'M-x reveal-hide-revealed' can be used to hide all the revealed text. -+++ -*** New command 'submit-emacs-patch'. -This works like 'report-emacs-bug', but is more geared towards sending -patches to the Emacs issue tracker. - -+++ -*** The user can now customize how "default" values are prompted for. -The new utility function 'format-prompt' has been added which uses the -new 'minibuffer-default-prompt-format' user option to format "default" -prompts. This means that prompts that look like "Enter a number -(default 10)" can be customized to look like, for instance, "Enter a -number [10]", or not have the default displayed at all, like "Enter a -number". (This requires that all callers are altered to use -'format-prompt', though.) - -+++ -*** New global mode 'global-goto-address-mode'. -This will enable 'goto-address-mode' in all buffers. - ---- -*** 'C-s' in 'M-x' now searches over completions again. -In Emacs 23, typing 'M-x' ('read-extended-command') and then 'C-s' (to -do an interactive search) would search over possible completions. -This was lost in Emacs 24, but is now back again. - ---- -*** 'M-x report-emacs-bug' will no longer include "Recent messages" section. -These were taken from the "*Messages*" buffer, and may inadvertently -leak information from the reporting user. - ---- -*** 'count-windows' now takes an optional parameter ALL-FRAMES. -The semantics are as with 'walk-windows'. - --- *** New variable 'ffap-file-name-with-spaces'. If non-nil, 'find-file-at-point' and friends will try to guess more expansively to identify a file name with spaces. -+++ -*** New 'thing-at-point' target: 'existing-filename'. -This is like 'filename', but is a full path, and is nil if the file -doesn't exist. - --- *** Two new commands for centering in 'doc-view-mode'. The new commands 'doc-view-center-page-horizontally' (bound to 'c h') and 'doc-view-center-page-vertically' (bound to 'c v') center the page horizontally and vertically, respectively. ---- -*** Change in meaning of 'icomplete-show-matches-on-no-input'. -Previously, choosing a different completion with commands like 'C-.' -and then hitting 'RET' would choose the default completion. Doing this -will now choose the completion under point instead. Also when this option -is nil, completions are not shown when the minibuffer reads a file name -with initial input as the default directory. - --- *** The width of the buffer-name column in 'list-buffers' is now dynamic. The width now depends of the width of the window, but will never be @@ -2839,60 +2544,12 @@ after every monthly meeting which takes place on the third Thursday, or if you would like to attend a virtual meeting scheduled in a different timezone causing a difference in the date. -** xterm-mouse mode - ---- -*** TTY menu navigation is now supported in 'xterm-mouse-mode'. -TTY menus support mouse navigation and selection when 'xterm-mouse-mode' -is active. When run on a terminal, clicking on the menu bar with the -mouse now pops up a TTY menu by default instead of running the command -'tmm-menubar'. To restore the old behavior, set the user option -'tty-menu-open-use-tmm' to non-nil. - -** text-scale-mode - ---- -*** 'text-scale-mode' can now adjust font size of the header line. -When the new buffer local variable 'text-scale-remap-header-line' -is non-nil, 'text-scale-adjust' will also scale the text in the header -line when displaying that buffer. - -This is useful for major modes that arrange their display in a tabular -form below the header line. It is enabled by default in -'tabulated-list-mode' and its derived modes. - -** xwidget-webkit mode - -*** New xwidget commands. -'xwidget-webkit-uri' (return the current URL), 'xwidget-webkit-title' -(return the current title), and 'xwidget-webkit-goto-history' (goto a -point in history). - -*** Pixel-based scrolling. -The 'xwidget-webkit-scroll-up', 'xwidget-webkit-scroll-down' commands -now supports scrolling arbitrary pixel values. It now treats the -optional 2nd argument as the pixel values to scroll. - -*** New commands for scrolling. -The new commands 'xwidget-webkit-scroll-up-line', -'xwidget-webkit-scroll-down-line', 'xwidget-webkit-scroll-forward', -'xwidget-webkit-scroll-backward' can be used to scroll webkit by the -height of lines or width of chars. - -*** New user option 'xwidget-webkit-bookmark-jump-new-session'. -When non-nil, use a new xwidget webkit session after bookmark jump. -Otherwise, it will use 'xwidget-webkit-last-session'. - -** ido - --- -*** Switching on 'ido-mode' now also overrides 'ffap-file-finder'. +*** The old non-SMIE indentation of 'sh-mode' has been removed. ---- -*** Killing virtual ido buffers interactively will make them go away. -Previously, killing a virtual ido buffer with 'ido-kill-buffer' didn't -do anything. This has now been changed, and killing virtual buffers -with that command will remove the buffer from recentf. +*** Loading dunnet.el in batch mode doesn't start the game any more. +Instead you need to do "emacs -f dun-batch" to start the game in +batch mode. ** Flymake mode @@ -2905,19 +2562,6 @@ and 'flymake-mode-line-counters'. The new user option like 'flymake-mode-line-error-counter', 'flymake-mode-line-warning-counter' and 'flymake-mode-line-note-counter'. -** Flyspell mode - -+++ -*** Corrections and actions menu can be optionally bound to 'mouse-3'. -When Flyspell mode highlights a word as misspelled, you can click on -it to display a menu of possible corrections and actions. You can now -easily bind this menu to 'down-mouse-3' (usually the right mouse button) -instead of 'mouse-2' (the default) by enabling 'context-menu-mode'. - ---- -*** The current dictionary is now displayed in the minor mode lighter. -Clicking the dictionary name changes the current dictionary. - ** Time --- @@ -2947,63 +2591,18 @@ The old names are now obsolete. *** 'world-clock-mode' can no longer be turned on interactively. Use 'world-clock' to turn on that mode. -** D-Bus - -+++ -*** Property values can be typed explicitly. -'dbus-register-property' and 'dbus-set-property' accept now optional -type symbols. Both functions propagate D-Bus errors. - -+++ -*** Registered properties can have the new access type ':write'. - -+++ -*** In case of problems, handlers can emit proper D-Bus error messages now. - -+++ -*** D-Bus errors, which have been converted from incoming D-Bus error -messages, contain the error name of that message now. - -+++ -*** D-Bus messages can be monitored with the new command 'dbus-monitor'. - -+++ -*** D-Bus events have changed their internal structure. -They carry now the destination and the error-name of an event. They -also keep the type information of their arguments. Use the -'dbus-event-*' accessor functions. - ** CPerl Mode --- *** New face 'perl-heredoc', used for heredoc elements. -+++ -** A function can now be thrown to the 'exit' label in addition to t or nil. -The command loop will call it with zero arguments before returning. - -+++ -** New error symbol 'minibuffer-quit'. -Signaling it has almost the same effect as 'quit' except that it -doesn't cause keyboard macro termination. - --- *** The command 'cperl-set-style' offers the new value "PBP". This value customizes Emacs to use the style recommended in Damian Conway's book "Perl Best Practices" for indentation and formatting of conditionals. -** Abbrev mode - -+++ -*** Emacs can now suggest to use an abbrev based on text you type. -A new user option, 'abbrev-suggest', enables the new abbrev suggestion -feature. When enabled, if a user manually types a piece of text that -could have saved enough typing by using an abbrev, a hint will be -displayed in the echo area, mentioning the abbrev that could have been -used instead. - -** Octave Mode +** Octave Mode +++ *** Line continuations in double-quoted strings now use a backslash. @@ -3012,57 +2611,24 @@ the behavior introduced in Octave 3.8 of using a backslash as a line continuation marker within double-quoted strings, and an ellipsis everywhere else. -** Repeat - -+++ -*** New transient mode 'repeat-mode' to allow shorter key sequences. -You can type 'C-x u u' instead of 'C-x u C-x u' to undo many changes, -'C-x o o' instead of 'C-x o C-x o' to switch several windows, -'C-x { { } } ^ ^ v v' to resize the selected window interactively, -'M-g n n p p' to navigate next-error matches. Any other key exits -transient mode and then is executed normally. 'repeat-exit-key' -defines an additional key to exit mode like 'isearch-exit' ('RET'). -The user option 'repeat-exit-timeout' specifies the number of -seconds of idle time to break the repetition chain automatically. -With 'repeat-keep-prefix' you can keep the prefix arg of the previous -command. For example, this can help to reverse the window navigation -direction with e.g. 'C-x o M-- o o'. Also it can help to set a new -step with e.g. 'C-x { C-5 { { {', which will set the window resizing -step to 5 columns. - +++ ** EasyPG GPG key servers can now be queried for keys with the 'M-x epa-search-keys' command. Keys can then be added to your personal key ring. -** So Long - ---- -*** New 'so-long-predicate' function 'so-long-statistics-excessive-p' -efficiently detects the presence of a long line anywhere in the buffer -using 'buffer-line-statistics' (see above). This is now the default -predicate (replacing 'so-long-detected-long-line-p'). - ---- -*** 'so-long-threshold' and 'so-long-max-lines' have been raised to -10000 bytes and 500 lines respectively, to reduce the likelihood of -false-positives when 'global-so-long-mode' is enabled. The latter -value is now only used by the old predicate, as the new predicate -knows the longest line in the entire buffer. +** Etags ---- -*** 'so-long-target-modes' now includes 'fundamental-mode' by default, -meaning that 'global-so-long-mode' will also process files which were -not recognised. (This only has an effect if 'set-auto-mode' chooses -'fundamental-mode'; buffers which are simply in 'fundamental-mode' by -default are unaffected.) ++++ +*** Etags now supports the Mercury programming language. +See https://mercurylang.org. ---- -*** New user options 'so-long-mode-preserved-minor-modes' and -'so-long-mode-preserved-variables' allow specified mode and variable -states to be maintained if 'so-long-mode' replaces the original major -mode. By default, these new options support 'view-mode'. ++++ +*** Etags command line option '--declarations' now has Mercury-specific behavior. +All Mercury declarations are tagged by default. However, for +compatibility with 'etags' support for Prolog, predicates and +functions appearing first in clauses will also be tagged if 'etags' is +invoked with the '--declarations' command-line option. ** Comint @@ -3080,17 +2646,134 @@ sequences. *** 'comint-delete-output' can now save deleted text in the kill-ring. Interactively, 'C-u C-c C-o' triggers this new optional behavior. +** erc + +--- +*** erc-services.el now supports NickServ passwords from auth-source. +The 'erc-use-auth-source-for-nickserv-password' user option enables +querying auth-source for NickServ passwords. To enable this, add the +following to your init file: + + (setq erc-prompt-for-nickserv-password nil + erc-use-auth-source-for-nickserv-password t) + +--- +*** The '/ignore' command will now ask for a timeout to stop ignoring the user. +Allowed inputs are seconds or ISO8601-like periods like "1h" or "4h30m". + +--- +*** ERC now recognizes 'C-]' for italic text. +Italic text is displayed in the new 'erc-italic-face'. + +--- +*** The erc-compat.el library is now marked obsolete. +This file contained ERC compatibility code for Emacs 21 and XEmacs +which is no longer needed. + +--- +*** erc-match.el now supports 'message' highlight type (not including the nick). +The 'erc-current-nick-highlight-type', 'erc-pal-highlight-type', +'erc-fool-highlight-type', 'erc-keyword-highlight-type', and +'erc-dangerous-host-highlight-type' variables now support a 'message' +type for highlighting the entire message but not the sender's nick. + +*** erc-status-sidebar.el is now part of ERC. +The 'erc-status-sidebar' package which provides a HexChat-like +activity overview sidebar for joined IRC channels is now part of ERC. + ++++ +*** erc-tls now supports specifying a TLS client certificate. +The 'erc-tls' function has been updated to allow specifying a TLS +client certificate for authentication, as an alternative to NickServ +password-based authentication. This is referred to as "CertFP" (short +for Certificate Fingerprint) by several IRC networks. See the Info +node "(erc) Connecting" in the ERC manual for more details and +examples on how to specify and use TLS client certificates with +'erc-tls'. + +** xwidget-webkit mode + +*** New xwidget commands. +'xwidget-webkit-uri' (return the current URL), 'xwidget-webkit-title' +(return the current title), and 'xwidget-webkit-goto-history' (goto a +point in history). + +*** Pixel-based scrolling. +The 'xwidget-webkit-scroll-up', 'xwidget-webkit-scroll-down' commands +now supports scrolling arbitrary pixel values. It now treats the +optional 2nd argument as the pixel values to scroll. + +*** New commands for scrolling. +The new commands 'xwidget-webkit-scroll-up-line', +'xwidget-webkit-scroll-down-line', 'xwidget-webkit-scroll-forward', +'xwidget-webkit-scroll-backward' can be used to scroll webkit by the +height of lines or width of chars. + +*** New user option 'xwidget-webkit-bookmark-jump-new-session'. +When non-nil, use a new xwidget webkit session after bookmark jump. +Otherwise, it will use 'xwidget-webkit-last-session'. + +** Enriched mode + +--- +*** 'C-a' is by default no longer bound to 'beginning-of-line-text'. +This is so 'C-a' works as in other modes, and in particular holding +Shift while typing 'C-a', i.e. 'C-S-a', will now highlight the text. + +** Gravatar + +--- +*** New user option 'gravatar-service' for host to query for gravatars. +Defaults to 'libravatar', with 'unicornify' and 'gravatar' as options. + +** MH-E mail handler for Emacs + +Functions and variables related to handling junk mail have been +renamed to not associate color with sender quality. + ++++ +*** New names for mh-junk interactive functions. +Function 'mh-junk-whitelist' is renamed 'mh-junk-allowlist'. +Function 'mh-junk-blacklist' is renamed 'mh-junk-blocklist'. + ++++ +*** New binding for 'mh-junk-allowlist'. +The key binding for 'mh-junk-allowlist' is changed from 'J w' to 'J a'. +The old binding is supported but warns that it is obsolete. + ++++ +*** New names for some hooks. +'mh-whitelist-msg-hook' is renamed 'mh-allowlist-msg-hook'. +'mh-blacklist-msg-hook' is renamed 'mh-blocklist-msg-hook'. + ++++ +*** New names for some variables. +Variable 'mh-whitelist-preserves-sequences-flag' is renamed +'mh-allowlist-preserves-sequences-flag'. + ++++ +*** New names for some faces. +Face 'mh-folder-blacklisted' is renamed 'mh-folder-blocklisted'. +Face 'mh-folder-whitelisted' is renamed 'mh-folder-allowlisted'. + * New Modes and Packages in Emacs 28.1 -** Lisp Data mode -The new command 'lisp-data-mode' enables a major mode for buffers -composed of Lisp symbolic expressions that do not form a computer -program. The ".dir-locals.el" file is automatically set to use this -mode, as are other data files produced by Emacs. - -** hierarchy.el -It's a library to create, query, navigate and display hierarchy structures. ++++ +** New transient mode 'repeat-mode' to allow shorter key sequences. +You can type 'C-x u u' instead of 'C-x u C-x u' to undo many changes, +'C-x o o' instead of 'C-x o C-x o' to switch several windows, +'C-x { { } } ^ ^ v v' to resize the selected window interactively, +'M-g n n p p' to navigate next-error matches. Any other key exits +transient mode and then is executed normally. 'repeat-exit-key' +defines an additional key to exit mode like 'isearch-exit' ('RET'). +The user option 'repeat-exit-timeout' specifies the number of +seconds of idle time to break the repetition chain automatically. +With 'repeat-keep-prefix' you can keep the prefix arg of the previous +command. For example, this can help to reverse the window navigation +direction with e.g. 'C-x o M-- o o'. Also it can help to set a new +step with e.g. 'C-x { C-5 { { {', which will set the window resizing +step to 5 columns. ** New themes 'modus-vivendi' and 'modus-operandi'. These themes are designed to conform with the highest standard for @@ -3107,13 +2790,25 @@ This is a mode for searching a RFC 2229 dictionary server. the mouse in 'dictionary-tooltip-dictionary' (which must be customized first). -** transient.el +** Lisp Data mode +The new command 'lisp-data-mode' enables a major mode for buffers +composed of Lisp symbolic expressions that do not form a computer +program. The ".dir-locals.el" file is automatically set to use this +mode, as are other data files produced by Emacs. + ++++ +** New global mode 'global-goto-address-mode'. +This will enable 'goto-address-mode' in all buffers. +** transient.el This library implements support for powerful keyboard-driven menus. Such menus can be used as simple visual command dispatchers. More complex menus take advantage of infix arguments, which are somewhat similar to prefix arguments, but are more flexible and discoverable. +** hierarchy.el +It's a library to create, query, navigate and display hierarchy structures. + * Incompatible Editing Changes in Emacs 28.1 @@ -3149,629 +2844,963 @@ before, you can add the following to your init file: (define-key global-map "\M-o\M-s" 'center-line) (define-key global-map "\M-o\M-S" 'center-paragraph) -** The 'M-o M-o' global binding has been removed. -Use 'M-x font-lock-fontify-block' instead, or the new 'C-x x f' -command, which updates the syntax highlighting in the current buffer. +** The 'M-o M-o' global binding has been removed. +Use 'M-x font-lock-fontify-block' instead, or the new 'C-x x f' +command, which updates the syntax highlighting in the current buffer. + +** The escape sequence '\e[29~' in Xterm is now mapped to 'menu'. +Xterm sends this sequence for both 'F16' and 'Menu' keys +It used to be mapped to 'print' but we couldn't find a terminal +that uses this sequence for any kind of 'Print' key. +This makes the Menu key (see https://en.wikipedia.org/wiki/Menu_key) +work for `context-menu-mode` in Xterm. + +--- +** New user option 'xterm-store-paste-on-kill-ring'. +If non-nil (the default), Emacs pushes pasted text onto the kill ring +(if using an xterm-like terminal that supports bracketed paste). +Setting this to nil inhibits that. + +** 'vc-print-branch-log' shows the change log for BRANCH from its root +directory instead of the default directory. + +--- +** 'project-shell' and 'shell' now use 'pop-to-buffer-same-window'. +This is to keep the same behavior as Eshell. + +** In 'nroff-mode', 'center-line' is now bound to 'M-o M-s'. +The original key binding was 'M-s', which interfered with I-search, +since the latter uses 'M-s' as a prefix key of the search prefix map. + +** In 'f90-mode', the backslash character ('\') no longer escapes. +For about a decade, the backslash character has no longer had a +special escape syntax in Fortran F90. To get the old behavior back, +say something like: + + (modify-syntax-entry ?\\ "\\" f90-mode-syntax-table) + +** Setting 'fill-column' to nil is obsolete. +This undocumented use of 'fill-column' is now obsolete. To disable +auto filling, turn off 'auto-fill-mode' instead. + +For instance, you could add something like the following to your init +file: + + (add-hook 'foo-mode-hook (lambda () (auto-fill-mode -1)) + + +* Incompatible Lisp Changes in Emacs 28.1 + +--- +** Some floating-point numbers are now handled differently by the Lisp reader. +In previous versions of Emacs, numbers with a trailing dot and an exponent +were read as integers and the exponent ignored: 2.e6 was interpreted as the +integer 2. Such numerals are now read as floats with the exponent included: +2.e6 is now read as the floating-point value 2000000.0. +That is, '(read-from-string "1.e3")' => '(1000.0 . 4)' now. + +** 'equal' no longer examines some contents of window configurations. +Instead, it considers window configurations to be equal only if they +are 'eq'. To compare contents, use 'compare-window-configurations' +instead. This change helps fix a bug in 'sxhash-equal', which returned +incorrect hashes for window configurations and some other objects. + ++++ +** The 'lexical-binding' local variable is always enabled. +Previously, if 'enable-local-variables' was nil, a 'lexical-binding' +local variable would not be heeded. This has now changed, and a file +with a 'lexical-binding' cookie is always heeded. To revert to the +old behavior, set 'permanently-enabled-local-variables' to nil. + +--- +** 'kill-all-local-variables' has changed how it handles non-symbol hooks. +The function is documented to eliminate all buffer-local bindings +except variables with a 'permanent-local' property, or hooks that +have elements with a 'permanent-local-hook' property. In addition, it +would also keep lambda expressions in hooks sometimes. The latter has +now been changed: The function will now also remove these. + ++++ +** Temporary buffers no longer run certain buffer hooks. +The macros 'with-temp-buffer' and 'with-temp-file' no longer run the +hooks 'kill-buffer-hook', 'kill-buffer-query-functions', and +'buffer-list-update-hook' for the temporary buffers they create. This +avoids slowing them down when a lot of these hooks are defined. + +** New face 'child-frame-border' and frame parameter 'child-frame-border-width'. +The face and width of child frames borders can now be determined +separately from those of normal frames. To minimize backward +incompatibility, child frames without a 'child-frame-border-width' +parameter will fall back to using 'internal-border-width'. However, +the new 'child-frame-border' face does constitute a breaking change +since child frames' borders no longer use the 'internal-border' face. + +--- +** 'run-at-time' now tries harder to implement the t TIME parameter. +If TIME is t, the timer runs at an integral multiple of REPEAT. +(I.e., if given a REPEAT of 60, it'll run at 08:11:00, 08:12:00, +08:13:00.) However, when a machine goes to sleep (or otherwise didn't +get a time slot to run when the timer was scheduled), the timer would +then fire every 60 seconds after the time the timer was fired. This +has now changed, and the timer code now recomputes the integral +multiple every time it runs, which means that if the laptop wakes at +08:16:43, it'll fire at that time, but then at 08:17:00, 08:18:00... + +--- +** 'parse-partial-sexp' now signals an error if TO is smaller than FROM. +Previously this would lead to the function interpreting FROM as TO and +vice versa, which would be confusing when passing in OLDSTATE, which +refers to the old state at FROM. + ++++ +** 'global-mode-string' constructs should end with a space. +This was previously not formalized, which led to combinations of modes +displaying data "smushed together" on the mode line. + ++++ +** 'overlays-in' now handles zero-length overlays slightly differently. +Previously, zero-length overlays at the end of the buffer were included +in the result (if the region queried for stopped at that position). +The same was not the case if the buffer had been narrowed to exclude +the real end of the buffer. This has now been changed, and +zero-length overlays at `point-max' are always included in the results. + +--- +** 'replace-match' now runs modification hooks slightly later. +The function is documented to leave point after the replacement text, +but this was not always the case if a modification hook inserted text +in front of the replaced text -- 'replace-match' would instead leave +point where the end of the inserted text would have been before the +hook ran. 'replace-match' now always leaves point after the +replacement text. + ++++ +** 'completing-read-default' sets completion variables buffer-locally. +'minibuffer-completion-table' and related variables are now set buffer-locally +in the minibuffer instead of being set via a global let-binding. + +** XML serialization functions now reject invalid characters. +Previously 'xml-print' would produce invalid XML when given a string +with characters that are not valid in XML (see +https://www.w3.org/TR/xml/#charsets). Now it rejects such strings. + + +--- +** JSON number parsing is now stricter. +Numbers with a leading plus sign, leading zeros, or a missing integer +component are now rejected by 'json-read' and friends. This makes +them more compliant with the JSON specification and consistent with +the native JSON parsing functions. + +** The JSON functions 'json-serialize', 'json-insert', +'json-parse-string', and 'json-parse-buffer' now implement some of the +semantics of RFC 8259 instead of the earlier RFC 4627. In particular, +these functions now accept top-level JSON values that are neither +arrays nor objects. + +--- +** Some JSON encoding functions are now obsolete. +The functions 'json-encode-number', 'json-encode-hash-table', +'json-encode-key', and 'json-encode-list' are now obsolete. + +The first two are kept as aliases of 'json-encode', which should be +used instead. Uses of 'json-encode-list' should be changed to call +one of 'json-encode', 'json-encode-alist', 'json-encode-plist', or +'json-encode-array' instead. + ++++ +** Native JSON functions now signal an error if libjansson is unavailable. +This affects 'json-serialize', 'json-insert', 'json-parse-string', +and 'json-parse-buffer'. This can happen if Emacs was compiled with +libjansson, but the DLL cannot be found and/or loaded by Emacs at run +time. Previously, Emacs would display a message and return nil in +these cases. + ++++ +** The use of positional arguments in 'define-minor-mode' is obsolete. +These were actually rendered obsolete in Emacs 21 but were never +marked as such. + +** 'pcomplete-ignore-case' is now an obsolete alias of 'completion-ignore-case'. + +** 'completions-annotations' face is not used when the caller puts own face. +This affects the suffix specified by completion 'annotation-function'. + ++++ +** An active minibuffer now has major mode 'minibuffer-mode', not the +erroneous 'minibuffer-inactive-mode' it formerly had. + +** When its first argument is a string, 'make-text-button' no longer +modifies the string's text properties; instead, it uses and returns +a copy of the string. This helps avoid trouble when strings are +shared or constants. + ++++ +** Some properties from completion tables are now preserved. +If 'minibuffer-allow-text-properties' is non-nil, doing completion +over a table of strings with properties will no longer remove all the +properties before returning. This affects things like 'completing-read'. + +** 'dns-query' now consistently uses Lisp integers to represent integers. +Formerly it made an exception for integer components of SOA records, +because SOA serial numbers can exceed fixnum ranges on 32-bit platforms. +Emacs now supports bignums so this old glitch is no longer needed. + ++++ +** The '&define' keyword in an Edebug specification now disables backtracking. +The implementation was buggy, and multiple '&define' forms in an '&or' +form should be exceedingly rare. See the Info node "(elisp) Backtracking" in +the Emacs Lisp reference manual for background. + ++++ +** The error 'ftp-error' belongs also to category 'remote-file-error'. + +** The WHEN argument of 'make-obsolete' and related functions is mandatory. +The use of those functions without a WHEN argument was marked obsolete +back in Emacs 23.1. The affected functions are: 'make-obsolete', +'define-obsolete-function-alias', 'make-obsolete-variable', +'define-obsolete-variable-alias'. + ++++ +** 'inhibit-nul-byte-detection' is renamed to 'inhibit-null-byte-detection'. + +--- +** Some functions are no longer considered safe by 'unsafep': +'replace-regexp-in-string', 'catch', 'throw', 'error', 'signal' +and 'play-sound-file'. + +--- +** 'ruby-use-smie' is declared obsolete. +SMIE is now always enabled and 'ruby-use-smie' only controls whether +indentation is done using SMIE or with the old ad-hoc code. + +--- +** 'sql-*-statement-starters' are no longer user options. +These variables describe facts about the SQL standard and +product-specific additions. There should be no need for users to +customize them. + +** The Lisp variables 'previous-system-messages-locale' and +'previous-system-time-locale' have been removed, as they were created +by mistake and were not useful to Lisp code. + +--- +** Function 'lm-maintainer' is replaced with 'lm-maintainers'. +The former is now declared obsolete. + +** 'facemenu.el' is no longer preloaded. +To use functions/variables from the package, you now have to say +'(require 'facemenu)' or similar. + +** 'facemenu-color-alist' is now obsolete, and is not used. + +** The variable 'keyboard-type' is obsolete and not dynamically scoped any more. + ++++ +** The 'values' variable is now obsolete. +Using it just contributes to the growth of the Emacs memory +footprint. + +--- +** The 'load-dangerous-libraries' variable is now obsolete. +It was used to allow loading Lisp libraries compiled by XEmacs, a +modified version of Emacs which is no longer actively maintained. +This is no longer supported, and setting this variable has no effect. + ++++ +** The macro 'with-displayed-buffer-window' is now obsolete. +Use macro 'with-current-buffer-window' with action alist entry 'body-function'. + +--- +** The rfc2368.el library is now obsolete. +Use rfc6068.el instead. The main difference is that +'rfc2368-parse-mailto-url' and 'rfc2368-unhexify-string' assumed that +the strings were all-ASCII, while 'rfc6068-parse-mailto-url' and +'rfc6068-unhexify-string' parse UTF-8 strings. + +--- +** The inversion.el library is now obsolete. + +--- +** The metamail.el library is now obsolete. + +** Edebug changes + +--- +*** 'get-edebug-spec' is obsolete, replaced by 'edebug-get-spec'. + ++++ +*** The spec operator ':name NAME' is obsolete, use '&name' instead. + ++++ +*** The spec element 'function-form' is obsolete, use 'form' instead. + ++++ +*** New function 'def-edebug-elem-spec' to define Edebug spec elements. +These used to be defined with 'def-edebug-spec' thus conflating the +two name spaces, which lead to name collisions. +The use of 'def-edebug-spec' to define Edebug spec elements is +declared obsolete. + +--- +** The sb-image.el library is now obsolete. +This was a compatibility kludge which is no longer needed. + +--- +** Some libraries obsolete since Emacs 23 have been removed: +ledit.el, lmenu.el, lucid.el and old-whitespace.el. + +--- +** Some functions and variables obsolete since Emacs 23 have been removed: +'GOLD-map', 'advertised-xscheme-send-previous-expression', +'allout-init', 'bookmark-jump-noselect', +'bookmark-read-annotation-text-func', 'buffer-menu-mode-hook', +'c-forward-into-nomenclature', 'char-coding-system-table', +'char-valid-p', 'charset-bytes', 'charset-id', 'charset-list', +'choose-completion-delete-max-match', 'complete-in-turn', +'completion-base-size', 'completion-common-substring', +'crm-minibuffer-complete', 'crm-minibuffer-complete-and-exit', +'crm-minibuffer-completion-help', 'custom-mode', 'custom-mode-hook', +'define-key-rebound-commands', 'define-mode-overload-implementation', +'detect-coding-with-priority', 'dirtrack-debug', +'dirtrack-debug-toggle', 'dynamic-completion-table', +'easy-menu-precalculate-equivalent-keybindings', +'epa-display-verify-result', 'epg-passphrase-callback-function', +'erc-announced-server-name', 'erc-default-coding-system', +'erc-process', 'erc-send-command', 'eshell-report-bug', +'eval-next-after-load', 'exchange-dot-and-mark', 'ffap-bug', +'ffap-submit-bug', 'ffap-version', 'file-cache-mouse-choose-completion', +'forward-point', 'generic-char-p', 'global-highlight-changes', +'hi-lock-face-history', 'hi-lock-regexp-history', +'highlight-changes-active-string', 'highlight-changes-initial-state', +'highlight-changes-passive-string', +'icalendar--datetime-to-noneuropean-date', 'image-mode-maybe', +'imenu-example--name-and-position', 'ispell-aspell-supports-utf8', +'lisp-mode-auto-fill', 'locate-file-completion', 'make-coding-system', +'menu-bar-files-menu', 'minibuffer-local-must-match-filename-map', +'mouse-choose-completion', 'mouse-major-mode-menu', +'mouse-popup-menubar', 'mouse-popup-menubar-stuff', +'newsticker-groups-filename', 'nnir-swish-e-index-file', +'nnmail-fix-eudora-headers', 'non-iso-charset-alist', +'nonascii-insert-offset', 'nonascii-translation-table', +'password-read-and-add', 'pre-abbrev-expand-hook', 'princ-list', +'print-help-return-message', 'process-filter-multibyte-p', +'read-file-name-predicate', 'remember-buffer', 'rmail-highlight-face', +'rmail-message-filter', 'semantic-after-idle-scheduler-reparse-hooks', +'semantic-after-toplevel-bovinate-hook', +'semantic-before-idle-scheduler-reparse-hooks', +'semantic-before-toplevel-bovination-hook', +'semantic-bovinate-from-nonterminal-full', +'semantic-bovinate-region-until-error', 'semantic-bovinate-toplevel', +'semantic-bovination-working-type', +'semantic-decorate-pending-decoration-hooks', +'semantic-edits-incremental-reparse-failed-hooks', +'semantic-eldoc-current-symbol-info', 'semantic-expand-nonterminal', +'semantic-file-token-stream', 'semantic-find-dependency', +'semantic-find-nonterminal', 'semantic-flex', 'semantic-flex-buffer', +'semantic-flex-keyword-get', 'semantic-flex-keyword-p', +'semantic-flex-keyword-put', 'semantic-flex-keywords', +'semantic-flex-list', 'semantic-flex-make-keyword-table', +'semantic-flex-map-keywords', 'semantic-flex-token-end', +'semantic-flex-token-start', 'semantic-flex-token-text', +'semantic-imenu-bucketize-type-parts', +'semantic-imenu-expand-type-parts', 'semantic-imenu-expandable-token', +'semantic-init-db-hooks', 'semantic-init-hooks', +'semantic-init-mode-hooks', 'semantic-java-prototype-nonterminal', +'semantic-nonterminal-abstract', 'semantic-nonterminal-full-name', +'semantic-nonterminal-leaf', 'semantic-nonterminal-protection', +'semantic-something-to-stream', 'semantic-tag-make-assoc-list', +'semantic-token-type-parent', 'semantic-toplevel-bovine-cache', +'semantic-toplevel-bovine-table', 'semanticdb-mode-hooks', +'set-coding-priority', 'set-process-filter-multibyte', +'shadows-compare-text-p', 'shell-dirtrack-toggle', +'speedbar-navigating-speed', 'speedbar-update-speed', 't-mouse-mode', +'term-dynamic-simple-complete', 'tooltip-hook', 'tpu-have-ispell', +'url-generate-unique-filename', 'url-temporary-directory', +'vc-arch-command', 'vc-default-working-revision' (variable), +'vc-mtn-command', 'vc-revert-buffer', 'vc-workfile-version', +'vcursor-toggle-vcursor-map', 'w32-focus-frame', 'w32-select-font', +'wisent-lex-make-token-table'. + +--- +** Some functions and variables obsolete since Emacs 22 have been removed: +'gnus-article-hide-pgp-hook', 'gnus-inews-mark-gcc-as-read', +'gnus-treat-display-xface', 'gnus-treat-strip-pgp', +'nnmail-spool-file'. -** In 'f90-mode', the backslash character ('\') no longer escapes. -For about a decade, the backslash character has no longer had a -special escape syntax in Fortran F90. To get the old behavior back, -say something like: +--- +** The obsolete function 'thread-alive-p' has been removed. - (modify-syntax-entry ?\\ "\\" f90-mode-syntax-table) +--- +** The variable 'force-new-style-backquotes' has been removed. +This removes the final remaining trace of old-style backquotes. -** In 'nroff-mode', 'center-line' is now bound to 'M-o M-s'. -The original key binding was 'M-s', which interfered with I-search, -since the latter uses 'M-s' as a prefix key of the search prefix map. +--- +** Some obsolete variable and function aliases in dbus.el have been removed. +In Emacs 24.3, the variable 'dbus-event-error-hooks' was renamed to +'dbus-event-error-functions' and the function +'dbus-call-method-non-blocking' was renamed to 'dbus-call-method'. +The old names, which were kept as obsolete aliases of the new names, +have now been removed. -** 'vc-print-branch-log' shows the change log for BRANCH from its root -directory instead of the default directory. + +* Lisp Changes in Emacs 28.1 ---- -** 'project-shell' and 'shell' now use 'pop-to-buffer-same-window'. -This is to keep the same behavior as Eshell. ++++ +** The 'interactive' syntax has been extended to allow listing applicable modes. +Forms like '(interactive "p" dired-mode)' can be used to annotate the +commands as being applicable for modes derived from 'dired-mode', +or if the mode is a minor mode, that the current buffer has that +minor mode activated. Note that using this form will create byte code +that is not compatible with byte code in previous Emacs versions. -** The escape sequence '\e[29~' in Xterm is now mapped to 'menu'. -Xterm sends this sequence for both 'F16' and 'Menu' keys -It used to be mapped to 'print' but we couldn't find a terminal -that uses this sequence for any kind of 'Print' key. -This makes the Menu key (see https://en.wikipedia.org/wiki/Menu_key) -work for `context-menu-mode` in Xterm. ++++ +** New forms to declare how completion should happen has been added. +'(declare (completion PREDICATE))' can be used as a general predicate +to say whether the command should be present when completing with +'M-x TAB'. '(declare (modes MODE...))' can be used as a short-hand +way of saying that the command should be present when completing from +buffers in major modes derived from MODE..., or, if it's a minor mode, +whether that minor mode is enabled in the current buffer. ---- -** New user option 'xterm-store-paste-on-kill-ring'. -If non-nil (the default), Emacs pushes pasted text onto the kill ring -(if using an xterm-like terminal that supports bracketed paste). -Setting this to nil inhibits that. ++++ +** 'define-minor-mode' now takes an ':interactive' argument. +This can be used for specifying which modes this minor mode is meant +for, or to make the new minor mode non-interactive. The default value +is t. - -* Incompatible Lisp Changes in Emacs 28.1 ++++ +** 'define-derived-mode' now takes an ':interactive' argument. +This can be used to control whether the defined mode is a command +or not, and is useful when defining commands that aren't meant to be +used by users directly. ---- -** 'run-at-time' now tries harder to implement the t TIME parameter. -If TIME is t, the timer runs at an integral multiple of REPEAT. -(I.e., if given a REPEAT of 60, it'll run at 08:11:00, 08:12:00, -08:13:00.) However, when a machine goes to sleep (or otherwise didn't -get a time slot to run when the timer was scheduled), the timer would -then fire every 60 seconds after the time the timer was fired. This -has now changed, and the timer code now recomputes the integral -multiple every time it runs, which means that if the laptop wakes at -08:16:43, it'll fire at that time, but then at 08:17:00, 08:18:00... ++++ +** 'define-globalized-minor-mode' now takes a ':predicate' parameter. +This can be used to control which major modes the minor mode should be +used in. ---- -** 'parse-partial-sexp' now signals an error if TO is smaller than FROM. -Previously this would lead to the function interpreting FROM as TO and -vice versa, which would be confusing when passing in OLDSTATE, which -refers to the old state at FROM. ++++ +** 'condition-case' now allows for a success handler. +It is written as '(:success BODY...)' where BODY is executed +whenever the protected form terminates without error, with the +specified variable bound to the the value of the protected form. +++ -** 'overlays-in' now handles zero-length overlays slightly differently. -Previously, zero-length overlays at the end of the buffer were included -in the result (if the region queried for stopped at that position). -The same was not the case if the buffer had been narrowed to exclude -the real end of the buffer. This has now been changed, and -zero-length overlays at `point-max' are always included in the results. +** A function can now be thrown to the 'exit' label in addition to t or nil. +The command loop will call it with zero arguments before returning. ---- -** 'replace-match' now runs modification hooks slightly later. -The function is documented to leave point after the replacement text, -but this was not always the case if a modification hook inserted text -in front of the replaced text -- 'replace-match' would instead leave -point where the end of the inserted text would have been before the -hook ran. 'replace-match' now always leaves point after the -replacement text. ++++ +** The behavior of 'format-spec' is now closer to that of 'format'. +In order for the two functions to behave more consistently, +'format-spec' now pads and truncates based on string width rather than +length, and also supports format specifications that include a +truncating precision field, such as "%.2a". --- -** 'kill-all-local-variables' has changed how it handles non-symbol hooks. -The function is documented to eliminate all buffer-local bindings -except variables with a 'permanent-local' property, or hooks that -have elements with a 'permanent-local-hook' property. In addition, it -would also keep lambda expressions in hooks sometimes. The latter has -now been changed: The function will now also remove these. +** 'defvar' detects the error of defining a variable currently lexically bound. +Such mixes are always signs that the outer lexical binding was an +error and should have used dynamic binding instead. --- -** Some floating-point numbers are now handled differently by the Lisp reader. -In previous versions of Emacs, numbers with a trailing dot and an exponent -were read as integers and the exponent ignored: 2.e6 was interpreted as the -integer 2. Such numerals are now read as floats with the exponent included: -2.e6 is now read as the floating-point value 2000000.0. -That is, '(read-from-string "1.e3")' => '(1000.0 . 4)' now. +** New variable 'inhibit-mouse-event-check'. +If bound to non-nil, a command with '(interactive "e")' doesn't signal +an error when invoked by input event that is not a mouse click (e.g., +a key sequence). +++ -** The 'lexical-binding' local variable is always enabled. -Previously, if 'enable-local-variables' was nil, a 'lexical-binding' -local variable would not be heeded. This has now changed, and a file -with a 'lexical-binding' cookie is always heeded. To revert to the -old behavior, set 'permanently-enabled-local-variables' to nil. +** Doc strings can now link to customization groups. +Text like "customization group `whitespace'" will be made into a +button. When clicked, it'll take the user to a Custom buffer +displaying that customization group. +++ -** 'completing-read-default' sets completion variables buffer-locally. -'minibuffer-completion-table' and related variables are now set buffer-locally -in the minibuffer instead of being set via a global let-binding. +** Buffers can now be created with certain hooks disabled. +The functions 'get-buffer-create' and 'generate-new-buffer' accept a +new optional argument INHIBIT-BUFFER-HOOKS. If non-nil, the new +buffer does not run the hooks 'kill-buffer-hook', +'kill-buffer-query-functions', and 'buffer-list-update-hook'. This +avoids slowing down internal or temporary buffers that are never +presented to users or passed on to other applications. +++ -** The use of positional arguments in 'define-minor-mode' is obsolete. -These were actually rendered obsolete in Emacs 21 but were never -marked as such. - -** 'facemenu-color-alist' is now obsolete, and is not used. +** New command 'make-directory-autoloads'. +This does the same as the old command 'update-directory-autoloads', +but has different semantics: Instead of passing in the output file via +the dynamically bound 'generated-autoload-file' variable, the output +file is now a explicit parameter. -** 'facemenu.el' is no longer preloaded. -To use functions/variables from the package, you now have to say -'(require 'facemenu)' or similar. +--- +** Dragging a file to Emacs will now also push the name of the file +onto 'file-name-history'. -** 'pcomplete-ignore-case' is now an obsolete alias of 'completion-ignore-case'. +--- +** The 'easymenu' library is now preloaded. -** 'completions-annotations' face is not used when the caller puts own face. -This affects the suffix specified by completion 'annotation-function'. +--- +** The 'iso-transl' library is now preloaded. +This means that keystrokes like 'Alt-[' are defined by default, +instead of only becoming available after doing (for instance) +'C-x 8 '. -** 'set-process-buffer' now updates the process mark. -The mark will be set to point to the end of the new buffer. +--- +** ':safe' settings in 'defcustom' are now propagated to the loaddefs files. +++ -** An active minibuffer now has major mode 'minibuffer-mode', not the -erroneous 'minibuffer-inactive-mode' it formerly had. +** ERT can now output more verbose test failure reports. +If the 'EMACS_TEST_VERBOSE' environment variable is set, failure +summaries will include the failing condition. + +** Byte compiler changes +++ -** Some properties from completion tables are now preserved. -If 'minibuffer-allow-text-properties' is non-nil, doing completion -over a table of strings with properties will no longer remove all the -properties before returning. This affects things like 'completing-read'. +*** New byte-compiler check for missing dynamic variable declarations. +It is meant as an (experimental) aid for converting Emacs Lisp code +to lexical binding, where dynamic (special) variables bound in one +file can affect code in another. For details, see the manual section +"(elisp) Converting to Lexical Binding". -** 'equal' no longer examines some contents of window configurations. -Instead, it considers window configurations to be equal only if they -are 'eq'. To compare contents, use 'compare-window-configurations' -instead. This change helps fix a bug in 'sxhash-equal', which returned -incorrect hashes for window configurations and some other objects. ++++ +*** 'byte-recompile-directory' can now compile symlinked ".el" files. +This is achieved by giving a non-nil FOLLOW-SYMLINKS parameter. -** When its first argument is a string, 'make-text-button' no longer -modifies the string's text properties; instead, it uses and returns -a copy of the string. This helps avoid trouble when strings are -shared or constants. +--- +*** The byte-compiler now warns about too wide documentation strings. +By default, it will warn if a documentation string is wider than the +largest of 'byte-compile-docstring-max-column' or 'fill-column' +characters. +++ -** Temporary buffers no longer run certain buffer hooks. -The macros 'with-temp-buffer' and 'with-temp-file' no longer run the -hooks 'kill-buffer-hook', 'kill-buffer-query-functions', and -'buffer-list-update-hook' for the temporary buffers they create. This -avoids slowing them down when a lot of these hooks are defined. +*** 'byte-compile-file' optional argument LOAD is now obsolete. +To load the file after byte-compiling, add a call to 'load' from Lisp +or use 'M-x emacs-lisp-byte-compile-and-load' interactively. -** New face 'child-frame-border' and frame parameter 'child-frame-border-width'. -The face and width of child frames borders can now be determined -separately from those of normal frames. To minimize backward -incompatibility, child frames without a 'child-frame-border-width' -parameter will fall back to using 'internal-border-width'. However, -the new 'child-frame-border' face does constitute a breaking change -since child frames' borders no longer use the 'internal-border' face. +** Macroexp +--- +*** New function 'macroexp-file-name' to know the name of the current file. +--- +*** New function 'macroexp-compiling-p' to know if we're compiling. +--- +*** New function 'macroexp-warn-and-return' to help emit warnings. +This used to be named 'macroexp--warn-and-return' and has proved useful +and well-behaved enough to lose the "internal" marker. + +** map.el + +*** Pcase 'map' pattern added keyword symbols abbreviation. +A pattern like '(map :sym)' binds the map's value for ':sym' to 'sym', +equivalent to '(map (:sym sym))'. --- -** The obsolete function 'thread-alive-p' has been removed. +*** The function 'map-copy' now uses 'copy-alist' on alists. +This is a slightly deeper copy than the previous 'copy-sequence'. -** 'dns-query' now consistently uses Lisp integers to represent integers. -Formerly it made an exception for integer components of SOA records, -because SOA serial numbers can exceed fixnum ranges on 32-bit platforms. -Emacs now supports bignums so this old glitch is no longer needed. +--- +*** The function 'map-contains-key' now supports plists. --- -** The new function 'dns-query-asynchronous' has been added. -It takes the same parameters as 'dns-query', but adds a callback -parameter. +*** More consistent duplicate key handling in 'map-merge-with'. +Until now, 'map-merge-with' promised to call its function argument +whenever multiple maps contained 'eql' keys. However, this did not +always coincide with the keys that were actually merged, which could +be 'equal' instead. The function argument is now called whenever keys +are merged, for greater consistency with 'map-merge' and 'map-elt'. -** The Lisp variables 'previous-system-messages-locale' and -'previous-system-time-locale' have been removed, as they were created -by mistake and were not useful to Lisp code. +** pcase ---- -** The 'load-dangerous-libraries' variable is now obsolete. -It was used to allow loading Lisp libraries compiled by XEmacs, a -modified version of Emacs which is no longer actively maintained. -This is no longer supported, and setting this variable has no effect. ++++ +*** The 'or' pattern now binds the union of the vars of its sub-patterns. +If a variable is not bound by the subpattern that matched, it gets bound +to nil. This was already sometimes the case, but it is now guaranteed. +++ -** The macro 'with-displayed-buffer-window' is now obsolete. -Use macro 'with-current-buffer-window' with action alist entry 'body-function'. +*** The 'pred' pattern can now take the form '(pred (not FUN))'. +This is like '(pred (lambda (x) (not (FUN x))))' but results +in better code. --- -** The inversion.el library is now obsolete. +*** New function 'pcase-compile-patterns' to write other macros. ---- -** The metamail.el library is now obsolete. +*** Added 'cl-type' pattern. +The new 'cl-type' pattern compares types using 'cl-typep', which allows +comparing simple types like '(cl-type integer)', as well as forms like +'(cl-type (integer 0 10))'. ---- -** Some obsolete variable and function aliases in dbus.el have been removed. -In Emacs 24.3, the variable 'dbus-event-error-hooks' was renamed to -'dbus-event-error-functions' and the function -'dbus-call-method-non-blocking' was renamed to 'dbus-call-method'. -The old names, which were kept as obsolete aliases of the new names, -have now been removed. +*** New macro 'pcase-setq' +This macro is the 'setq' equivalent of 'pcase-let', which allows for +destructuring patterns in a 'setq' form. ---- -** Some libraries obsolete since Emacs 23 have been removed: -ledit.el, lmenu.el, lucid.el and old-whitespace.el. +** Edebug specification lists can use some new keywords: ---- -** Some functions and variables obsolete since Emacs 23 have been removed: -'GOLD-map', 'advertised-xscheme-send-previous-expression', -'allout-init', 'bookmark-jump-noselect', -'bookmark-read-annotation-text-func', 'buffer-menu-mode-hook', -'c-forward-into-nomenclature', 'char-coding-system-table', -'char-valid-p', 'charset-bytes', 'charset-id', 'charset-list', -'choose-completion-delete-max-match', 'complete-in-turn', -'completion-base-size', 'completion-common-substring', -'crm-minibuffer-complete', 'crm-minibuffer-complete-and-exit', -'crm-minibuffer-completion-help', 'custom-mode', 'custom-mode-hook', -'define-key-rebound-commands', 'define-mode-overload-implementation', -'detect-coding-with-priority', 'dirtrack-debug', -'dirtrack-debug-toggle', 'dynamic-completion-table', -'easy-menu-precalculate-equivalent-keybindings', -'epa-display-verify-result', 'epg-passphrase-callback-function', -'erc-announced-server-name', 'erc-default-coding-system', -'erc-process', 'erc-send-command', 'eshell-report-bug', -'eval-next-after-load', 'exchange-dot-and-mark', 'ffap-bug', -'ffap-submit-bug', 'ffap-version', 'file-cache-mouse-choose-completion', -'forward-point', 'generic-char-p', 'global-highlight-changes', -'hi-lock-face-history', 'hi-lock-regexp-history', -'highlight-changes-active-string', 'highlight-changes-initial-state', -'highlight-changes-passive-string', -'icalendar--datetime-to-noneuropean-date', 'image-mode-maybe', -'imenu-example--name-and-position', 'ispell-aspell-supports-utf8', -'lisp-mode-auto-fill', 'locate-file-completion', 'make-coding-system', -'menu-bar-files-menu', 'minibuffer-local-must-match-filename-map', -'mouse-choose-completion', 'mouse-major-mode-menu', -'mouse-popup-menubar', 'mouse-popup-menubar-stuff', -'newsticker-groups-filename', 'nnir-swish-e-index-file', -'nnmail-fix-eudora-headers', 'non-iso-charset-alist', -'nonascii-insert-offset', 'nonascii-translation-table', -'password-read-and-add', 'pre-abbrev-expand-hook', 'princ-list', -'print-help-return-message', 'process-filter-multibyte-p', -'read-file-name-predicate', 'remember-buffer', 'rmail-highlight-face', -'rmail-message-filter', 'semantic-after-idle-scheduler-reparse-hooks', -'semantic-after-toplevel-bovinate-hook', -'semantic-before-idle-scheduler-reparse-hooks', -'semantic-before-toplevel-bovination-hook', -'semantic-bovinate-from-nonterminal-full', -'semantic-bovinate-region-until-error', 'semantic-bovinate-toplevel', -'semantic-bovination-working-type', -'semantic-decorate-pending-decoration-hooks', -'semantic-edits-incremental-reparse-failed-hooks', -'semantic-eldoc-current-symbol-info', 'semantic-expand-nonterminal', -'semantic-file-token-stream', 'semantic-find-dependency', -'semantic-find-nonterminal', 'semantic-flex', 'semantic-flex-buffer', -'semantic-flex-keyword-get', 'semantic-flex-keyword-p', -'semantic-flex-keyword-put', 'semantic-flex-keywords', -'semantic-flex-list', 'semantic-flex-make-keyword-table', -'semantic-flex-map-keywords', 'semantic-flex-token-end', -'semantic-flex-token-start', 'semantic-flex-token-text', -'semantic-imenu-bucketize-type-parts', -'semantic-imenu-expand-type-parts', 'semantic-imenu-expandable-token', -'semantic-init-db-hooks', 'semantic-init-hooks', -'semantic-init-mode-hooks', 'semantic-java-prototype-nonterminal', -'semantic-nonterminal-abstract', 'semantic-nonterminal-full-name', -'semantic-nonterminal-leaf', 'semantic-nonterminal-protection', -'semantic-something-to-stream', 'semantic-tag-make-assoc-list', -'semantic-token-type-parent', 'semantic-toplevel-bovine-cache', -'semantic-toplevel-bovine-table', 'semanticdb-mode-hooks', -'set-coding-priority', 'set-process-filter-multibyte', -'shadows-compare-text-p', 'shell-dirtrack-toggle', -'speedbar-navigating-speed', 'speedbar-update-speed', 't-mouse-mode', -'term-dynamic-simple-complete', 'tooltip-hook', 'tpu-have-ispell', -'url-generate-unique-filename', 'url-temporary-directory', -'vc-arch-command', 'vc-default-working-revision' (variable), -'vc-mtn-command', 'vc-revert-buffer', 'vc-workfile-version', -'vcursor-toggle-vcursor-map', 'w32-focus-frame', 'w32-select-font', -'wisent-lex-make-token-table'. ++++ +**** '&interpose SPEC FUN ARGS..' lets FUN control parsing after SPEC. +More specifically, FUN is called with 'HEAD PF ARGS..' where +PF is a parsing function that expects a single argument (the specs to +use) and HEAD is the code that matched SPEC. ---- -** Some functions and variables obsolete since Emacs 22 have been removed: -'gnus-article-hide-pgp-hook', 'gnus-inews-mark-gcc-as-read', -'gnus-treat-display-xface', 'gnus-treat-strip-pgp', -'nnmail-spool-file'. ++++ +**** '&error MSG' unconditionally aborts the current edebug instrumentation. -** The WHEN argument of 'make-obsolete' and related functions is mandatory. -The use of those functions without a WHEN argument was marked obsolete -back in Emacs 23.1. The affected functions are: 'make-obsolete', -'define-obsolete-function-alias', 'make-obsolete-variable', -'define-obsolete-variable-alias'. ++++ +**** '&name SPEC FUN' extracts the current name from the code matching SPEC. -** The variable 'keyboard-type' is obsolete and not dynamically scoped any more. +** Dynamic modules changes +++ -** The 'values' variable is now obsolete. -Using it just contributes to the growth of the Emacs memory -footprint. +*** The module header 'emacs-module.h' now contains type aliases +'emacs_function' and 'emacs_finalizer' for module functions and +finalizers, respectively. +++ -** The '&define' keyword in an Edebug specification now disables backtracking. -The implementation was buggy, and multiple '&define' forms in an '&or' -form should be exceedingly rare. See the Info node "(elisp) Backtracking" in -the Emacs Lisp reference manual for background. - ---- -** 'sql-*-statement-starters' are no longer user options. -These variables describe facts about the SQL standard and -product-specific additions. There should be no need for users to -customize them. +*** Module functions can now be made interactive. +Use 'make_interactive' to give a module function an interactive +specification. ---- -** Function 'lm-maintainer' is replaced with 'lm-maintainers'. -The former is now declared obsolete. ++++ +*** Module functions can now install an optional finalizer that is +called when the function object is garbage-collected. Use +'set_function_finalizer' to set the finalizer and +'get_function_finalizer' to retrieve it. - -* Lisp Changes in Emacs 28.1 ++++ +*** Modules can now open a channel to an existing pipe process using +the new module function 'open_channel'. Modules can use this +functionality to asynchronously send data back to Emacs. +++ -*** Doc strings can now link to customization groups. -Text like "customization group `whitespace'" will be made into a -button. When clicked, it'll take the user to a Custom buffer -displaying that customization group. +*** A new module API 'make_unibyte_string' is provided. +It can be used to create Lisp strings with arbitrary byte sequences +(a.k.a. "raw bytes"). +++ -*** New macro 'with-existing-directory'. -This macro binds 'default-directory' to some other existing directory -if 'default-directory' doesn't exist, and then executes the body forms. +** New function 'string-search'. +This function takes two string parameters and returns the position of +the first instance of the former string in the latter. +++ -*** New function 'file-name-concat'. -This appends file name components to a directory name and returns the -result. +** New function 'string-replace'. +This function works along the line of 'replace-regexp-in-string', but +matching on strings instead of regexps, and does not change the global +match state. +++ -*** New function 'split-string-shell-command'. +** New function 'split-string-shell-command'. This splits a shell command string into separate components, respecting quoting with single ('like this') and double ("like this") quotes, as well as backslash quoting (like\ this). ---- -*** ':safe' settings in 'defcustom' are now propagated to the loaddefs files. +** New string manipulation functions added to subr-x.el. +'string-clean-whitespace', 'string-fill', 'string-limit', +'string-lines', 'string-pad' and 'string-chop-newline'. +++ -** New function 'syntax-class-to-char'. -This does almost the opposite of 'string-to-syntax' -- it returns the -syntax descriptor (a character) given a raw syntax descriptor (an -integer). +** New function 'replace-regexp-in-region'. +++ -** New function 'buffer-local-boundp'. -This predicate says whether a symbol is bound in a specific buffer. +** New function 'replace-string-in-region'. ---- -** Emacs now attempts to test for high-rate subprocess output more fairly. -When several subprocesses produce output simultaneously at high rate, -Emacs will now by default attempt to service them all in a round-robin -fashion. Set the new variable 'process-prioritize-lower-fds' to a -non-nil value to get back the old behavior, whereby after reading -from a subprocess, Emacs would check for output of other subprocesses -in a way that is likely to read from the same process again. ++++ +** New function 'file-name-with-extension'. +This function allows a canonical way to set/replace the extension of a +file name. +++ -** New function 'sxhash-equal-including-properties'. -This is identical to 'sxhash-equal' but accounting also for string -properties. +** New function 'file-modes-number-to-symbolic' to convert a numeric +file mode specification into symbolic form. +++ -** 'unlock-buffer' displays warnings instead of signaling. -Instead of signaling 'file-error' conditions for file system level -errors, the function now calls 'display-warning' and continues as if -the error did not occur. +** New function 'file-name-concat'. +This appends file name components to a directory name and returns the +result. + ++++ +** New function 'file-backup-file-names'. +This function returns the list of file names of all the backup files +of its file argument. + ++++ +** New function 'directory-empty-p'. +This predicate tests whether a given file name is an accessible +directory and whether it contains no other directories or files. + ++++ +** New function 'buffer-local-boundp'. +This predicate says whether a symbol is bound in a specific buffer. +++ ** New function 'always'. This is identical to 'ignore', but returns t instead. +++ -** New forms to declare how completion should happen has been added. -'(declare (completion PREDICATE))' can be used as a general predicate -to say whether the command should be present when completing with -'M-x TAB'. '(declare (modes MODE...))' can be used as a short-hand -way of saying that the command should be present when completing from -buffers in major modes derived from MODE..., or, if it's a minor mode, -whether that minor mode is enabled in the current buffer. +** New function 'sxhash-equal-including-properties'. +This is identical to 'sxhash-equal' but accounting also for string +properties. -+++ -** The 'interactive' syntax has been extended to allow listing applicable modes. -Forms like '(interactive "p" dired-mode)' can be used to annotate the -commands as being applicable for modes derived from 'dired-mode', -or if the mode is a minor mode, that the current buffer has that -minor mode activated. Note that using this form will create byte code -that is not compatible with byte code in previous Emacs versions. +** New function 'buffer-line-statistics'. +This function returns some statistics about the line lengths in a buffer. + +--- +** New function 'color-values-from-color-spec'. +This can be used to parse RGB color specs in several formats and +convert them to a list '(R G B)' of primary color values. -+++ -** New buffer-local variable 'local-minor-modes'. -This permanently buffer-local variable holds a list of currently -enabled non-global minor modes in the current buffer (as a list of -symbols). +--- +** New function 'custom-add-choice'. +This function can be used by modes to add elements to the +'choice' customization type of a variable. -+++ -** New variable 'global-minor-modes'. -This variable holds a list of currently enabled global minor modes (as -a list of symbols). +--- +** New function 'decoded-time-period'. +It interprets a decoded time structure as a period and returns the +equivalent period in seconds. +++ -** 'define-minor-mode' now takes an ':interactive' argument. -This can be used for specifying which modes this minor mode is meant -for, or to make the new minor mode non-interactive. The default value -is t. +** New function 'dom-print'. +++ -** 'define-derived-mode' now takes an ':interactive' argument. -This can be used to control whether the defined mode is a command -or not, and is useful when defining commands that aren't meant to be -used by users directly. +** New function 'dom-remove-attribute'. --- -** The 'easymenu' library is now preloaded. - ---- -** New variable 'indent-line-ignored-functions'. -This allows modes to cycle through a set of indentation functions -appropriate for those modes. +** New function 'dns-query-asynchronous'. +It takes the same parameters as 'dns-query', but adds a callback +parameter. ** New function 'garbage-collect-maybe' to trigger GC early. --- -** 'defvar' detects the error of defining a variable currently lexically bound. -Such mixes are always signs that the outer lexical binding was an -error and should have used dynamic binding instead. +** New function 'get-locale-names'. +This utility function returns a list of locale names on the current +system. +++ -** New completion function 'affixation-function' to add prefix/suffix. -It accepts a list of completions and should return a list where -each element is a list with three elements: a completion, -a prefix string, and a suffix string. +** New function 'insert-into-buffer'. +This is like 'insert-buffer-substring', but works in the opposite +direction. +++ -** New completion function 'group-function' for grouping candidates. -It takes two arguments: a completion candidate and a 'transform' flag. +** New function 'json-available-p'. +This predicate returns non-nil if Emacs is built with libjansson +support, and it is available on the current system. -+++ -** 'read-char-from-minibuffer' and 'y-or-n-p' support 'help-form'. -If you bind 'help-form' to a non-nil value while calling these functions, -then pressing 'C-h' ('help-char') causes the function to evaluate 'help-form' -and display the result. +--- +** New function 'mail-header-parse-addresses-lax'. +This takes a comma-separated string and returns a list of mail/name +pairs. --- -** New variables 'read-char-choice-use-read-key' and 'y-or-n-p-use-read-key'. -When non-nil, then functions 'read-char-choice' and 'y-or-n-p' (respectively) -use the function 'read-key' to read a character instead of using the minibuffer. +** New function 'mail-header-parse-address-lax'. +Parse a string as a mail address-like string. --- -** New user option 'use-short-answers'. -When non-nil, the function 'y-or-n-p' is used instead of -'yes-or-no-p'. This eliminates the need to define an alias that maps -one to another in the init file. The same user option also controls -whether the function 'read-answer' accepts short answers. +** New function 'make-separator-line'. +Make a string appropriate for usage as a visual separator line. +++ -** 'set-window-configuration' now takes two optional parameters, -'dont-set-frame' and 'dont-set-miniwindow'. The first of these, when -non-nil, instructs the function not to select the frame recorded in -the configuration. The second prevents the current minibuffer being -replaced by the one stored in the configuration. +** New function 'object-intervals'. +This function returns a copy of the list of intervals (i.e., text +properties) in the object in question (which must either be a string +or a buffer). +++ -** 'define-globalized-minor-mode' now takes a ':predicate' parameter. -This can be used to control which major modes the minor mode should be -used in. +** New function 'process-lines-ignore-status'. +This is like 'process-lines', but does not signal an error if the +return status is non-zero. 'process-lines-handling-status' has also +been added, and takes a callback to handle the return status. +++ -** 'truncate-string-ellipsis' now uses '…' by default. -Modes that use 'truncate-string-to-width' with non-nil, non-string -argument ELLIPSIS, will now indicate truncation using '…' when -the selected frame can display it, and using "..." otherwise. +** New function 'require-theme'. +This function is like 'require', but searches 'custom-theme-load-path' +instead of 'load-path'. It can be used by Custom themes to load +supporting Lisp files when 'require' is unsuitable. +++ -** 'string-width' now accepts two optional arguments FROM and TO. -This allows calculating the width of a substring without consing a -new string. +** New function 'syntax-class-to-char'. +This does almost the opposite of 'string-to-syntax' -- it returns the +syntax descriptor (a character) given a raw syntax descriptor (an +integer). +++ -** New command 'make-directory-autoloads'. -This does the same as the old command 'update-directory-autoloads', -but has different semantics: Instead of passing in the output file via -the dynamically bound 'generated-autoload-file' variable, the output -file is now a explicit parameter. +** New functions 'null-device' and 'path-separator'. +These functions return the connection local value of the respective +variables. This can be used for remote hosts. +++ -** New function 'string-search'. -This function takes two string parameters and returns the position of -the first instance of the former string in the latter. +** New predicate functions 'length<', 'length>' and 'length='. +Using these functions may be more efficient than using 'length' (if +the length of a (long) list is being computed just to compare this +length to a number). +++ -** New function 'string-replace'. -This function works along the line of 'replace-regexp-in-string', but -matching on strings instead of regexps, and does not change the global -match state. +** New macro 'dlet' to dynamically bind variables. +++ -** New function 'process-lines-ignore-status'. -This is like 'process-lines', but does not signal an error if the -return status is non-zero. 'process-lines-handling-status' has also -been added, and takes a callback to handle the return status. - ---- -** 'ascii' is now a coding system alias for 'us-ascii'. +** New macro 'with-existing-directory'. +This macro binds 'default-directory' to some other existing directory +if 'default-directory' doesn't exist, and then executes the body forms. +++ -** New function 'file-name-with-extension'. -This function allows a canonical way to set/replace the extension of a -file name. +** New variable 'current-minibuffer-command'. +This is like 'this-command', but it is bound recursively when entering +the minibuffer. +++ -** New function 'file-backup-file-names'. -This function returns the list of file names of all the backup files -of its file argument. +** New variable 'inhibit-interaction' to make user prompts signal an error. +If this is bound to something non-nil, functions like +'read-from-minibuffer', 'read-char' (and related) will signal an +'inhibited-interaction' error. + +--- +** New variable 'indent-line-ignored-functions'. +This allows modes to cycle through a set of indentation functions +appropriate for those modes. +++ -** New utility function 'directory-empty-p'. -This predicate tests whether a given file name is an accessible -directory and whether it contains no other directories or files. +** New variable 'print-integers-as-characters' modifies integer printing. +If this variable is non-nil, character syntax is used for printing +numbers when this makes sense, such as '?A' for 65. +++ -** 'directory-files' now takes an additional COUNT parameter. -The parameter makes 'directory-files' return COUNT first file names -from a directory. If MATCH is also given, the function will return -first COUNT file names that match the expression. The same COUNT -parameter has been added to 'directory-files-and-attributes'. +** New variable 'tty-menu-calls-mouse-position-function'. +This controls whether 'mouse-position-function' is called by functions +that retrieve the mouse position when that happens during TTY menu +handling. Lisp programs that set 'mouse-position-function' should +also set this variable non-nil if they are compatible with the tty +menu handling. +++ -** The 'count-lines' function now takes an optional parameter to -ignore invisible lines. +** New variables that hold default buffer names for shell output. +The new constants 'shell-command-buffer-name' and +'shell-command-buffer-name-async' store the default buffer names +for the output of, respectively, synchronous and async shell +commands. --- -** 'count-words' now crosses field boundaries. -Originally, 'count-words' would stop counting at the first field -boundary it encountered; now it keeps counting all the way to the -region's (or buffer's) end. +** New variables 'read-char-choice-use-read-key' and 'y-or-n-p-use-read-key'. +When non-nil, then functions 'read-char-choice' and 'y-or-n-p' (respectively) +use the function 'read-key' to read a character instead of using the minibuffer. ---- -** New function 'custom-add-choice'. -This function can be used by modes to add elements to the -'choice' customization type of a variable. ++++ +** New variable 'global-minor-modes'. +This variable holds a list of currently enabled global minor modes (as +a list of symbols). +++ -** New function 'require-theme'. -This function is like 'require', but searches 'custom-theme-load-path' -instead of 'load-path'. It can be used by Custom themes to load -supporting Lisp files when 'require' is unsuitable. +** New buffer-local variable 'local-minor-modes'. +This permanently buffer-local variable holds a list of currently +enabled non-global minor modes in the current buffer (as a list of +symbols). +++ -** New function 'file-modes-number-to-symbolic' to convert a numeric -file mode specification into symbolic form. +** New completion function 'affixation-function' to add prefix/suffix. +It accepts a list of completions and should return a list where +each element is a list with three elements: a completion, +a prefix string, and a suffix string. +++ -** New macro 'dlet' to dynamically bind variables. +** New completion function 'group-function' for grouping candidates. +It takes two arguments: a completion candidate and a 'transform' flag. + ++++ +** New error symbol 'minibuffer-quit'. +Signaling it has almost the same effect as 'quit' except that it +doesn't cause keyboard macro termination. + ++++ +** New error 'remote-file-error', a subcategory of 'file-error'. +It is signaled if a remote file operation fails due to internal +reasons, and could block Emacs. It does not replace 'file-error' +signals for the usual cases. Timers, process filters and process +functions, which run remote file operations, shall protect themselves +against this error. + +If such an error occurs, please report this as bug via 'M-x report-emacs-bug'. +Until it is solved you could ignore such errors by performing + + (setq debug-ignored-errors (cons 'remote-file-error debug-ignored-errors)) + +** New macro 'named-let' added to subr-x.el. +It provides Scheme's "named let" looping construct. --- -** The variable 'force-new-style-backquotes' has been removed. -This removes the final remaining trace of old-style backquotes. +** Emacs now attempts to test for high-rate subprocess output more fairly. +When several subprocesses produce output simultaneously at high rate, +Emacs will now by default attempt to service them all in a round-robin +fashion. Set the new variable 'process-prioritize-lower-fds' to a +non-nil value to get back the old behavior, whereby after reading +from a subprocess, Emacs would check for output of other subprocesses +in a way that is likely to read from the same process again. -** Mode Lines +** 'set-process-buffer' now updates the process mark. +The mark will be set to point to the end of the new buffer. +++ -*** New user options to control the line/column numbers in the mode line. -'mode-line-position-line-format' is the line number format (when -'line-number-mode' is on), 'mode-line-position-column-format' is -the column number format (when 'column-number-mode' is on), and -'mode-line-position-column-line-format' is the combined format (when -both modes are on). +** 'unlock-buffer' displays warnings instead of signaling. +Instead of signaling 'file-error' conditions for file system level +errors, the function now calls 'display-warning' and continues as if +the error did not occur. +++ -*** New user option 'mode-line-compact'. -If non-nil, repeating spaces are compressed into a single space. If -'long', this is only done when the mode line is longer than the -current window width (in characters). +** 'read-char-from-minibuffer' and 'y-or-n-p' support 'help-form'. +If you bind 'help-form' to a non-nil value while calling these functions, +then pressing 'C-h' ('help-char') causes the function to evaluate 'help-form' +and display the result. +++ -*** 'global-mode-string' constructs should end with a space. -This was previously not formalized, which led to combinations of modes -displaying data "smushed together" on the mode line. - -** Changes in handling dynamic modules +** 'read-number' now has its own history variable. +Additionally, the function now accepts a HIST argument which can be +used to specify a custom history variable. +++ -*** The module header 'emacs-module.h' now contains type aliases -'emacs_function' and 'emacs_finalizer' for module functions and -finalizers, respectively. +** 'set-window-configuration' now takes two optional parameters, +'dont-set-frame' and 'dont-set-miniwindow'. The first of these, when +non-nil, instructs the function not to select the frame recorded in +the configuration. The second prevents the current minibuffer being +replaced by the one stored in the configuration. + +--- +** 'count-windows' now takes an optional parameter ALL-FRAMES. +The semantics are as with 'walk-windows'. +++ -*** Module functions can now be made interactive. -Use 'make_interactive' to give a module function an interactive -specification. +** 'truncate-string-ellipsis' now uses '…' by default. +Modes that use 'truncate-string-to-width' with non-nil, non-string +argument ELLIPSIS, will now indicate truncation using '…' when +the selected frame can display it, and using "..." otherwise. +++ -*** Module functions can now install an optional finalizer that is -called when the function object is garbage-collected. Use -'set_function_finalizer' to set the finalizer and -'get_function_finalizer' to retrieve it. +** 'string-width' now accepts two optional arguments FROM and TO. +This allows calculating the width of a substring without consing a +new string. +++ -*** Modules can now open a channel to an existing pipe process using -the new module function 'open_channel'. Modules can use this -functionality to asynchronously send data back to Emacs. +** 'directory-files' now takes an additional COUNT parameter. +The parameter makes 'directory-files' return COUNT first file names +from a directory. If MATCH is also given, the function will return +first COUNT file names that match the expression. The same COUNT +parameter has been added to 'directory-files-and-attributes'. +++ -*** A new module API 'make_unibyte_string' is provided. -It can be used to create Lisp strings with arbitrary byte sequences -(a.k.a. "raw bytes"). +** 'count-lines' now takes an optional parameter to +ignore invisible lines. + +--- +** 'count-words' now crosses field boundaries. +Originally, 'count-words' would stop counting at the first field +boundary it encountered; now it keeps counting all the way to the +region's (or buffer's) end. +++ ** 'file-modes', 'set-file-modes', and 'set-file-times' now have an optional argument specifying whether to follow symbolic links. +++ -** 'parse-time-string' can now parse ISO 8601 format strings. -These have the format like "2020-01-15T16:12:21-08:00". - ---- -** The new function 'decoded-time-period' has been added. -It interprets a decoded time structure as a period and returns the -equivalent period in seconds. - -+++ -** The new function 'dom-remove-attribute' has been added. +** 'format-seconds' can now be used for sub-second times. +The new optional "," parameter has been added, and +'(format-seconds "%mm %,1ss" 66.4)' will now result in "1m 6.4s". +++ -** The new function 'dom-print' has been added. +** 'parse-time-string' can now parse ISO 8601 format strings. +These have the format like "2020-01-15T16:12:21-08:00". --- ** 'make-network-process', 'make-serial-process' ':coding' behavior change. @@ -3798,17 +3827,8 @@ server based on that greeting. +++ ** 'open-gnutls-stream' now also accepts a ':coding' argument. -+++ -** New user option 'process-file-return-signal-string'. -It controls, whether 'process-file' returns a string when a remote -process is interrupted by a signal. - -+++ -** The behavior of 'format-spec' is now closer to that of 'format'. -In order for the two functions to behave more consistently, -'format-spec' now pads and truncates based on string width rather than -length, and also supports format specifications that include a -truncating precision field, such as "%.2a". +--- +** 'process-attributes' now works under OpenBSD, too. +++ ** 'format-spec' now takes an optional SPLIT parameter. @@ -3816,96 +3836,84 @@ If non-nil, 'format-spec' will split the resulting string into a list of strings, based on where the format specs (and expansions) were. --- -** New function 'color-values-from-color-spec'. -This can be used to parse RGB color specs in several formats and -convert them to a list '(R G B)' of primary color values. +** 'unload-feature' now also tries to undo additions to buffer-local hooks. --- -** User option 'uniquify-buffer-name-style' can now be a function. -This user option can be one of the predefined styles or a function to -personalize the uniquified buffer name. +** 'while-no-input-ignore-events' accepts more special events. +The special events 'dbus-event' and 'file-notify' are now ignored in +'while-no-input' when added to this variable. -+++ -** New variable 'tty-menu-calls-mouse-position-function'. -This controls whether 'mouse-position-function' is called by functions -that retrieve the mouse position when that happens during TTY menu -handling. Lisp programs that set 'mouse-position-function' should -also set this variable non-nil if they are compatible with the tty -menu handling. +--- +** 'start-process-shell-command' and 'start-file-process-shell-command' +do not support the old calling conventions any longer. +++ -** 'inhibit-nul-byte-detection' is renamed to 'inhibit-null-byte-detection'. - -** Byte compiler +** The 'uniquify' argument in 'auto-save-file-name-transforms' can be a symbol. +If this symbol is one of the members of 'secure-hash-algorithms', +Emacs constructs the nondirectory part of the auto-save file name by +applying that 'secure-hash' to the buffer file name. This avoids any +risk of excessively long file names. -+++ -*** New byte-compiler check for missing dynamic variable declarations. -It is meant as an (experimental) aid for converting Emacs Lisp code -to lexical binding, where dynamic (special) variables bound in one -file can affect code in another. For details, see the manual section -"(elisp) Converting to Lexical Binding". +--- +** Functions operating on local file names now check that the file names +don't contain any NUL bytes. This avoids subtle bugs caused by +xsilently using only the part of the file name until the first NUL byte. +++ -*** 'byte-recompile-directory' can now compile symlinked ".el" files. -This is achieved by giving a non-nil FOLLOW-SYMLINKS parameter. +** New user option 'process-file-return-signal-string'. +It controls, whether 'process-file' returns a string when a remote +process is interrupted by a signal. ---- -*** The byte-compiler now warns about too wide documentation strings. -By default, it will warn if a documentation string is wider than the -largest of 'byte-compile-docstring-max-column' or 'fill-column' -characters. +** EIEIO Changes +++ -*** 'byte-compile-file' optional argument LOAD is now obsolete. -To load the file after byte-compiling, add a call to 'load' from Lisp -or use 'M-x emacs-lisp-byte-compile-and-load' interactively. +*** The macro 'oref-default' can now be used with 'setf'. +It is now defined as a generalized variable that can be used with +'setf' to modify the value stored in a given class slot. --- -** 'unload-feature' now also tries to undo additions to buffer-local hooks. +*** 'form' in '(eql form)' specializers in 'cl-defmethod' is now evaluated. +This corresponds to the behavior of defmethod in Common Lisp Object System. +For compatibility, '(eql SYMBOL)' does not evaluate SYMBOL, for now. ---- -** Some functions are no longer considered safe by 'unsafep': -'replace-regexp-in-string', 'catch', 'throw', 'error', 'signal' -and 'play-sound-file'. +** D-Bus +++ -** New variable 'print-integers-as-characters' modifies integer printing. -If this variable is non-nil, character syntax is used for printing -numbers when this makes sense, such as '?A' for 65. +*** Property values can be typed explicitly. +'dbus-register-property' and 'dbus-set-property' accept now optional +type symbols. Both functions propagate D-Bus errors. +++ -** New error 'remote-file-error', a subcategory of 'file-error'. -It is signaled if a remote file operation fails due to internal -reasons, and could block Emacs. It does not replace 'file-error' -signals for the usual cases. Timers, process filters and process -functions, which run remote file operations, shall protect themselves -against this error. +*** Registered properties can have the new access type ':write'. -If such an error occurs, please report this as bug via 'M-x report-emacs-bug'. -Until it is solved you could ignore such errors by performing ++++ +*** In case of problems, handlers can emit proper D-Bus error messages now. - (setq debug-ignored-errors (cons 'remote-file-error debug-ignored-errors)) ++++ +*** D-Bus errors, which have been converted from incoming D-Bus error +messages, contain the error name of that message now. +++ -** The error 'ftp-error' belongs also to category 'remote-file-error'. +*** D-Bus messages can be monitored with the new command 'dbus-monitor'. +++ -** Buffers can now be created with certain hooks disabled. -The functions 'get-buffer-create' and 'generate-new-buffer' accept a -new optional argument INHIBIT-BUFFER-HOOKS. If non-nil, the new -buffer does not run the hooks 'kill-buffer-hook', -'kill-buffer-query-functions', and 'buffer-list-update-hook'. This -avoids slowing down internal or temporary buffers that are never -presented to users or passed on to other applications. +*** D-Bus events have changed their internal structure. +They carry now the destination and the error-name of an event. They +also keep the type information of their arguments. Use the +'dbus-event-*' accessor functions. --- -** 'start-process-shell-command' and 'start-file-process-shell-command' -do not support the old calling conventions any longer. +** 'text-scale-mode' can now adjust font size of the header line. +When the new buffer local variable 'text-scale-remap-header-line' +is non-nil, 'text-scale-adjust' will also scale the text in the header +line when displaying that buffer. + +This is useful for major modes that arrange their display in a tabular +form below the header line. It is enabled by default in +'tabulated-list-mode' and its derived modes. --- -** Functions operating on local file names now check that the file names -don't contain any NUL bytes. This avoids subtle bugs caused by -silently using only the part of the file name until the first NUL byte. +** 'ascii' is now a coding system alias for 'us-ascii'. ** New coding-systems for EBCDIC variants. New coding-systems 'ibm256', 'ibm273', 'ibm274', 'ibm277', 'ibm278', @@ -3916,47 +3924,46 @@ locales. They are also available as aliases 'ebcdic-cp-*' (e.g., 'cp278' for 'ibm278'). There are also new charsets 'ibm2xx' to support these coding-systems. ---- -** New function 'get-locale-names'. -This utility function returns a list of locale names on the current -system. ++++ +** New 'Bindat type expression' description language. +This new system is provided by the new macro 'bindat-type' and +obsoletes the old data layout specifications. It supports +arbitrary-size integers, recursive types, and more. See the Info node +"(elisp) Byte Packing" in the ELisp manual for more details. ---- -** 'while-no-input-ignore-events' accepts more special events. -The special events 'dbus-event' and 'file-notify' are now ignored in -'while-no-input' when added to this variable. + +* Changes in Emacs 28.1 on Non-Free Operating Systems +++ -** 'condition-case' now allows for a success handler. -It is written as '(:success BODY...)' where BODY is executed -whenever the protected form terminates without error, with the -specified variable bound to the the value of the protected form. +** On MS-Windows, Emacs can now use the native image API to display images. +Emacs can now use the MS-Windows GDI+ library to load and display +images in JPEG, PNG, GIF and TIFF formats. This support is enabled +unless Emacs was configured '--without-native-image-api'. + +This feature is experimental, and needs to be turned on to be used. +To turn this on, set the variable 'w32-use-native-image-API' to a +non-nil value. Please report any bugs you find while using the native +image API via 'M-x report-emacs-bug'. +++ -** The 'uniquify' argument in 'auto-save-file-name-transforms' can be a symbol. -If this symbol is one of the members of 'secure-hash-algorithms', -Emacs constructs the nondirectory part of the auto-save file name by -applying that 'secure-hash' to the buffer file name. This avoids any -risk of excessively long file names. +** On MS-Windows, Emacs can now toggle the IME. +A new function 'w32-set-ime-open-status' can now be used to disable +and enable the MS-Windows native Input Method Editor (IME) at run +time. A companion function 'w32-get-ime-open-status' returns the +current IME activation status. + +-- +** On macOS, 's-' and 's-' are now bound to +'move-beginning-of-line' and 'move-end-of-line' respectively. The commands +to select previous/next frame are still bound to 's-~' and 's-`'. +++ -** New user option 'kill-buffer-delete-auto-save-files'. -If non-nil, killing a buffer that has an auto-save file will prompt -the user for whether that file should be deleted. (Note that -'delete-auto-save-files', if non-nil, was previously documented to -result in deletion of auto-save files when killing a buffer without -unsaved changes, but this has apparently not worked for several -decades, so the documented semantics of this variable has been changed -to match the behaviour.) +** On macOS, Emacs can now load dynamic modules with a ".dylib" suffix. +'module-file-suffix' now has the value ".dylib" on macOS, but the +".so" suffix is supported as well. --- -** New variable 'inhibit-mouse-event-check'. -If bound to non-nil, a command with '(interactive "e")' doesn't signal -an error when invoked by input event that is not a mouse click (e.g., -a key sequence). - - -* Changes in Emacs 28.1 on Non-Free Operating Systems +** On macOS, the user option 'make-pointer-invisible' is now honored. --- ** On macOS, Xwidget is now supported. @@ -3979,35 +3986,9 @@ If non-nil, enable plugins in xwidget. (This is only available on macOS.) +++ -** On macOS, Emacs can now load dynamic modules with a ".dylib" suffix. -'module-file-suffix' now has the value ".dylib" on macOS, but the -".so" suffix is supported as well. - -+++ -** On MS-Windows, Emacs can now toggle the IME. -A new function 'w32-set-ime-open-status' can now be used to disable -and enable the MS-Windows native Input Method Editor (IME) at run -time. A companion function 'w32-get-ime-open-status' returns the -current IME activation status. - -+++ -** On MS-Windows, Emacs can now use the native image API to display images. -Emacs can now use the MS-Windows GDI+ library to load and display -images in JPEG, PNG, GIF and TIFF formats. This support is enabled -unless Emacs was configured '--without-native-image-api'. - -This feature is experimental, and needs to be turned on to be used. -To turn this on, set the variable 'w32-use-native-image-API' to a -non-nil value. Please report any bugs you find while using the native -image API via 'M-x report-emacs-bug'. - ---- -** The user option 'make-pointer-invisible' is now honored on macOS. - --- -** On macOS, 's-' and 's-' are now bound to -'move-beginning-of-line' and 'move-end-of-line' respectively. The commands -to select previous/next frame are still bound to 's-~' and 's-`'. +** New macOS Contacts back-end for EUDC. +This backend works on newer versions of macOS and is generally +preferred over the eudcb-mab.el backend. ---------------------------------------------------------------------- commit e7fc61f7399efaaac397b589f6017fbde98311ec Author: Stefan Kangas Date: Sun Sep 5 09:27:00 2021 +0200 Improve documentation of save-place-abbreviate-file-names * lisp/saveplace.el (save-place-abbreviate-file-names): Document why you might want to enable this option. diff --git a/lisp/saveplace.el b/lisp/saveplace.el index 2a95b39da8..8225588b9d 100644 --- a/lisp/saveplace.el +++ b/lisp/saveplace.el @@ -88,7 +88,9 @@ this happens automatically before saving `save-place-alist' to :type 'boolean) (defcustom save-place-abbreviate-file-names nil - "If non-nil, abbreviate file names before saving them." + "If non-nil, abbreviate file names before saving them. +This can simplify sharing the `save-place-file' file across +different hosts." :type 'boolean :version "28.1") commit c88c4467cb5ebab933056d14d1fdff8c1d7d5674 Author: Stefan Kangas Date: Sun Sep 5 07:54:35 2021 +0200 * etc/NEWS: Don't mention a fixed bug. diff --git a/etc/NEWS b/etc/NEWS index 72f0d661da..d1a9b7cf15 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -2831,11 +2831,6 @@ The width now depends of the width of the window, but will never be wider than the length of the longest buffer name, except that it will never be narrower than 19 characters. ---- -*** Movement commands in 'gomoku-mode' are fixed. -'gomoku-move-sw' and 'gomoku-move-ne' now work correctly, and -horizontal movements now stop at the edge of the board. - +++ *** New diary sexp 'diary-offset'. It offsets another diary sexp by a number of days. This is useful commit ff7867b4e7fae589489b530aeb157e09ac5834b8 Author: Stefan Kangas Date: Sat Sep 4 22:25:02 2021 +0200 ; * test/lisp/newcomment-tests.el: Fix copyright year. diff --git a/test/lisp/newcomment-tests.el b/test/lisp/newcomment-tests.el index 06c300a673..5485673b72 100644 --- a/test/lisp/newcomment-tests.el +++ b/test/lisp/newcomment-tests.el @@ -1,6 +1,6 @@ ;;; newcomment-tests.el -*- lexical-binding:t -*- -;; Copyright (C) 2010-2021 Free Software Foundation, Inc. +;; Copyright (C) 2021 Free Software Foundation, Inc. ;; This file is part of GNU Emacs. commit 71f8b55f46af307759fb30dcf3f784092dd8834d Author: Dmitry Gutov Date: Mon Sep 6 05:01:07 2021 +0300 project--files-in-directory: Fix handling of ignores * lisp/progmodes/project.el (project--files-in-directory): Pass "." as the DIR argument to 'find' because otherwise the ignore expression can match the project root directory name, which we don't want to happen (bug#50240). Fixup the resulting file names at the end with concatenation. Originally I thought it could lead to worse performance, but the results show equal or slightly better timings. * lisp/progmodes/xref.el (xref-matches-in-directory): Apply a similar fix. (xref--find-ignores-arguments): Use file-name-as-directory, so that when passed "." replace-match still had the expected effect. * test/lisp/progmodes/project-tests.el (project-ignores-bug-50240): New test. * test/lisp/progmodes/xref-tests.el (xref-matches-in-directory-filters-with-ignores): New test. diff --git a/lisp/progmodes/project.el b/lisp/progmodes/project.el index e420a4ccca..b6eea7e27e 100644 --- a/lisp/progmodes/project.el +++ b/lisp/progmodes/project.el @@ -302,11 +302,10 @@ to find the list of ignores for each directory." ;; expanded and not left for the shell command ;; to interpret. (localdir (file-name-unquote (file-local-name (expand-file-name dir)))) - (command (format "%s -H %s %s -type f %s -print0" + (dfn (directory-file-name localdir)) + (command (format "%s -H . %s -type f %s -print0" find-program - (shell-quote-argument - (directory-file-name localdir)) ; Bug#48471 - (xref--find-ignores-arguments ignores localdir) + (xref--find-ignores-arguments ignores "./") (if files (concat (shell-quote-argument "(") " " find-name-arg " " @@ -324,8 +323,9 @@ to find the list of ignores for each directory." (unless (zerop status) (error "File listing failed: %s" (buffer-string)))))))) (project--remote-file-names - (sort (split-string output "\0" t) - #'string<)))) + (mapcar (lambda (s) (concat dfn (substring s 1))) + (sort (split-string output "\0" t) + #'string<))))) (defun project--remote-file-names (local-files) "Return LOCAL-FILES as if they were on the system of `default-directory'. diff --git a/lisp/progmodes/xref.el b/lisp/progmodes/xref.el index e594624573..ec8b05d294 100644 --- a/lisp/progmodes/xref.el +++ b/lisp/progmodes/xref.el @@ -1553,18 +1553,18 @@ IGNORES is a list of glob patterns for files to ignore." ;; do that reliably enough, without creating false negatives? (command (xref--rgrep-command (xref--regexp-to-extended regexp) files - (directory-file-name - (file-name-unquote - (file-local-name (expand-file-name dir)))) + "." ignores)) - (def default-directory) + (local-dir (directory-file-name + (file-name-unquote + (file-local-name (expand-file-name dir))))) (buf (get-buffer-create " *xref-grep*")) (`(,grep-re ,file-group ,line-group . ,_) (car grep-regexp-alist)) (status nil) (hits nil)) (with-current-buffer buf (erase-buffer) - (setq default-directory def) + (setq default-directory dir) (setq status (process-file-shell-command command nil t)) (goto-char (point-min)) @@ -1577,7 +1577,7 @@ IGNORES is a list of glob patterns for files to ignore." (user-error "Search failed with status %d: %s" status (buffer-string))) (while (re-search-forward grep-re nil t) (push (list (string-to-number (match-string line-group)) - (match-string file-group) + (concat local-dir (substring (match-string file-group) 1)) (buffer-substring-no-properties (point) (line-end-position))) hits))) (xref--convert-hits (nreverse hits) regexp))) @@ -1746,6 +1746,11 @@ directory, used as the root of the ignore globs." (cl-assert (not (string-match-p "\\`~" dir))) (if (not ignores) "" + ;; TODO: All in-tree callers are passing in just "." or "./". + ;; We can simplify. + ;; And, if we ever end up deleting xref-matches-in-directory, move + ;; this function to the project package. + (setq dir (file-name-as-directory dir)) (concat (shell-quote-argument "(") " -path " diff --git a/test/lisp/progmodes/project-tests.el b/test/lisp/progmodes/project-tests.el index 68460a9fa5..1e3f258ac2 100644 --- a/test/lisp/progmodes/project-tests.el +++ b/test/lisp/progmodes/project-tests.el @@ -107,4 +107,19 @@ directory name (Bug#48471)." collect (file-relative-name file dir)))) (should (equal relative-files '("some-file")))))) +(ert-deftest project-ignores-bug-50240 () + "Check that `project-files' does not ignore all files. +When `project-ignores' includes a name matching project dir." + (skip-unless (executable-find find-program)) + (project-tests--with-temporary-directory dir + (make-empty-file (expand-file-name "some-file" dir)) + (let* ((project (make-project-tests--trivial + :root (file-name-as-directory dir) + :ignores (list (file-name-nondirectory + (directory-file-name dir))))) + (files (project-files project))) + (should (equal files + (list + (expand-file-name "some-file" dir))))))) + ;;; project-tests.el ends here diff --git a/test/lisp/progmodes/xref-tests.el b/test/lisp/progmodes/xref-tests.el index d29452243b..ff4b647ae0 100644 --- a/test/lisp/progmodes/xref-tests.el +++ b/test/lisp/progmodes/xref-tests.el @@ -52,6 +52,14 @@ (should (string-match-p "file1\\.txt\\'" (xref-location-group (nth 0 locs)))) (should (string-match-p "file2\\.txt\\'" (xref-location-group (nth 1 locs)))))) +(ert-deftest xref-matches-in-directory-filters-with-ignores () + (let ((locs (xref-matches-in-directory "bar" "*" xref-tests--data-dir + '("./file1.*")))) + (should (= 1 (length locs))) + (should (string-match-p "file2\\.txt\\'" (xref-location-group + (xref-item-location + (nth 0 locs))))))) + (ert-deftest xref-matches-in-directory-finds-two-matches-on-the-same-line () (let ((locs (xref-tests--locations-in-data-dir "foo"))) (should (= 2 (length locs))) commit 80d318aabbbf34761260104a0ddebde1ace559a6 Author: Dmitry Gutov Date: Mon Sep 6 02:32:46 2021 +0300 Try to fix vc-test-git06-version-diff on Hydra * test/lisp/vc/vc-tests.el (vc-test--version-diff): Fix Git backend when running in clean environment. (vc-test-git06-version-diff): Unskip on Hydra. diff --git a/test/lisp/vc/vc-tests.el b/test/lisp/vc/vc-tests.el index c20d1bdf6a..4169a96670 100644 --- a/test/lisp/vc/vc-tests.el +++ b/test/lisp/vc/vc-tests.el @@ -615,10 +615,10 @@ This checks also `vc-backend' and `vc-responsible-backend'." (when (eq backend 'Bzr) (setq tempdir (make-temp-file "vc-test--version-diff" t) process-environment (cons (format "BZR_HOME=%s" tempdir) - (cons - "EMAIL=john@doe.ee" - process-environment)))) - + process-environment))) + (when (memq backend '(Bzr Git)) + (setq process-environment (cons "EMAIL=john@doe.ee" + process-environment))) (unwind-protect (progn ;; Cleanup. @@ -797,9 +797,6 @@ This checks also `vc-backend' and `vc-responsible-backend'." (ert-get-test ',(intern (format "vc-test-%s01-register" backend-string)))))) - ;; FIXME git (2.18.1) commit fails with status 128 - why? - (skip-unless (not (and (eq 'Git ',backend) - (getenv "EMACS_HYDRA_CI")))) (vc-test--version-diff ',backend)) )))) commit 97aa8240d23c6ba9842dc8d76057cd0e972ec32e (refs/remotes/origin/emacs-27) Author: Glenn Morris Date: Sun Sep 5 15:50:50 2021 -0700 * doc/misc/efaq.texi: Misc copyedits. Prefer mailing lists to newgroups. (History of Emacs): Rename from "Status of Emacs". Move XEmacs node here. (Emacs for other operating systems): Merge all the "non-Unix" systems into a single node. diff --git a/doc/misc/efaq.texi b/doc/misc/efaq.texi index c718e34433..0be35396b8 100644 --- a/doc/misc/efaq.texi +++ b/doc/misc/efaq.texi @@ -86,7 +86,7 @@ Emacs, the Emacs manual is often the best starting point. * FAQ notation:: * General questions:: * Getting help:: -* Status of Emacs:: +* History of Emacs:: * Common requests:: * Bugs and problems:: * Compiling and installing Emacs:: @@ -215,11 +215,6 @@ completion, @kbd{?} for a list of possibilities, and @kbd{M-p} and @kbd{M-n} (or up-arrow and down-arrow) to see previous commands entered. An Emacs @dfn{command} is an @dfn{interactive} Emacs function. -@cindex @key{Do} key -Your system administrator may have bound other key sequences to invoke -@code{execute-extended-command}. A function key labeled @kbd{Do} is a -good candidate for this, on keyboards that have such a key. - If you need to run non-interactive Emacs functions, see @ref{Evaluating Emacs Lisp code}. @@ -231,7 +226,7 @@ Emacs Lisp code}. @cindex Info, finding topics in When we refer you to some @var{topic} in the Emacs manual, you can -read this manual node inside Emacs (assuming nothing is broken) by +read this manual node inside Emacs by typing @kbd{C-h i m emacs @key{RET} m @var{topic} @key{RET}}. This invokes Info, the GNU hypertext documentation browser. If you don't @@ -240,9 +235,8 @@ already know how to use Info, type @kbd{?} from within Info. If we refer to @var{topic}:@var{subtopic}, type @kbd{C-h i m emacs @key{RET} m @var{topic} @key{RET} m @var{subtopic} @key{RET}}. -If these commands don't work as expected, your system administrator may -not have installed the Info files, or may have installed them -improperly. In this case you should complain. +(If these commands don't work as expected, your system may be missing +the Info files, or they may not be installed properly.) If you are reading this FAQ in Info, you can simply press @key{RET} on a reference to follow it. @@ -323,8 +317,8 @@ Free Software Foundation, and related organizations. @menu * Real meaning of copyleft:: -* Guidelines for newsgroup postings:: -* Newsgroup archives:: +* Guidelines for mailing list postings:: +* Mailing list archives:: * Reporting bugs:: * Unsubscribing from Emacs lists:: * Contacting the FSF:: @@ -359,54 +353,53 @@ distribute any version of Emacs or a related program, and give the recipients the same freedom that you enjoyed. @end quotation -@node Guidelines for newsgroup postings -@section What are appropriate messages for the various Emacs newsgroups? -@cindex Newsgroups, appropriate messages for -@cindex GNU newsgroups, appropriate messages for -@cindex Usenet groups, appropriate messages for +@node Guidelines for mailing list postings +@section What are appropriate messages for the various Emacs mailing lists? @cindex Mailing lists, appropriate messages for -@cindex Posting messages to newsgroups - +@cindex Posting messages to mailing lists @cindex GNU mailing lists -The Emacs mailing lists are described at + +There are various Emacs mailing lists, described at @uref{https://savannah.gnu.org/mail/?group=emacs, the Emacs Savannah -page}. Some of them are gatewayed to newsgroups. +page}. -The newsgroup @uref{news:comp.emacs} is for discussion of Emacs programs -in general. The newsgroup @uref{news:gnu.emacs.help} is specifically -for GNU Emacs. It therefore makes no sense to cross-post to both -groups, since only one can be appropriate to any question. +The main ones are: @code{help-gnu-emacs}, @code{bug-gnu-emacs}, +and @code{emacs-devel}. Messages advocating ``non-free'' software are considered unacceptable on -any of the @code{gnu.*} newsgroups except for @uref{news:gnu.misc.discuss}, -which was created to hold the extensive flame-wars on the subject. +any of the @code{gnu.*} mailing lists (except for @code{gnu-misc-discuss}). ``Non-free'' software includes any software for which the end user can't -freely modify the source code and exchange enhancements. Be careful to -remove the @code{gnu.*} groups from the @samp{Newsgroups:} line when -posting a followup that recommends such software. +freely modify the source code and exchange enhancements. Please +remove GNU mailing lists from the recipients when +posting a reply that recommends such software. -@uref{news:gnu.emacs.bug} is a place where bug reports appear, but avoid -posting bug reports to this newsgroup directly (@pxref{Reporting bugs}). +@cindex newsgroups +Some of the GNU mailing lists are gatewayed to newsgroups. +The newsgroup @uref{news:comp.emacs} is for discussion of Emacs programs +in general. The newsgroup @uref{news:gnu.emacs.help} (i.e., the +@code{help-gnu-emacs} mailing list) is specifically +for GNU Emacs. It therefore makes no sense to cross-post to both +groups, since only one can be appropriate to any question. Finally, we recommend reading the @url{https://www.gnu.org/philosophy/kind-communication.html, GNU Kind Communications Guidelines} before posting to any GNU lists or newsgroups. -@node Newsgroup archives -@section Where can I get old postings to @uref{news:gnu.emacs.help} and other GNU groups? -@cindex Archived postings from @code{gnu.emacs.help} -@cindex Usenet archives for GNU groups -@cindex Old Usenet postings for GNU groups +@node Mailing list archives +@section Where can I find old postings to GNU mailing lists? +@cindex Mailing list archives The FSF has maintained archives of all of the GNU mailing lists for many years, although there may be some unintentional gaps in coverage. The archive can be browsed over the web at @uref{https://lists.gnu.org/r/, the GNU mail archive}. +@cindex Usenet archives for GNU groups +@cindex Old Usenet postings for GNU groups Web-based Usenet search services, such as @uref{http://groups.google.com/groups/dir?q=gnu&, Google}, also -archive the @code{gnu.*} groups. +archive the @code{gnu.*} newsgroups. @node Reporting bugs @section Where should I report bugs and other problems with Emacs? @@ -854,12 +847,9 @@ Emacs news, a history of recent user-visible changes @end table -More GNU information, including back issues of the @cite{GNU's -Bulletin}, are at - -@uref{https://www.gnu.org/bulletins/bulletins.html} and +More GNU and FSF information is available at -@uref{http://www.cs.pdx.edu/~trent/gnu/gnu.html} +@uref{https://www.gnu.org} and @uref{http://www.fsf.org} @node Help installing Emacs @section Where can I get help in installing Emacs? @@ -885,12 +875,9 @@ C-f} (@kbd{M-x view-emacs-FAQ}). The very latest version is available in the Emacs development repository (@pxref{Latest version of Emacs}). @c ------------------------------------------------------------ -@node Status of Emacs -@chapter Status of Emacs -@cindex Status of Emacs - -This chapter gives you basic information about Emacs, including the -status of its latest version. +@node History of Emacs +@chapter History of Emacs +@cindex History of Emacs @menu * Origin of the term Emacs:: @@ -903,6 +890,7 @@ status of its latest version. * New in Emacs 22:: * New in Emacs 21:: * New in Emacs 20:: +* Difference between Emacs and XEmacs:: @end menu @node Origin of the term Emacs @@ -941,7 +929,6 @@ conventions}). @cindex Latest version of Emacs @cindex Development, Emacs @cindex Repository, Emacs -@cindex Bazaar repository, Emacs Emacs @value{EMACSVER} is the current version as of this writing. A version number with two components (e.g., @samp{24.5}) indicates a released @@ -1466,6 +1453,43 @@ several languages in the same document; the ``Customize'' facility for modifying variables without having to use Lisp; and automatic conversion of files from Macintosh, Microsoft, and Unix platforms. + +@node Difference between Emacs and XEmacs +@section What is the difference between Emacs and XEmacs (formerly Lucid Emacs)? +@cindex XEmacs +@cindex Difference Emacs and XEmacs +@cindex Lucid Emacs +@cindex Epoch + +XEmacs was a branch version of Emacs that is no longer actively +developed. XEmacs was first called Lucid Emacs, and was initially +derived from a prerelease version of Emacs 19. In this FAQ, we use +the name ``Emacs'' only for the official version. + +XEmacs last released a new version on January 30, 2009, and it lacks +many important features that exists in Emacs. In the past, it was not +uncommon for Emacs packages to include code for compatibility with +XEmacs. Nowadays, although some packages still maintain such +compatibility code, several of the more popular built-in and third +party packages have either stopped supporting XEmacs or were developed +exclusively for Emacs. + +Some XEmacs code has been contributed to Emacs, and we would like to +use other parts, but the earlier XEmacs maintainers did not always +keep track of the authors of contributed code, which makes it +impossible for the FSF to get copyright papers signed for that code. +(The FSF requires these papers for all the code included in the Emacs +release, aside from generic C support packages that retain their +separate identity and are not integrated into the code of Emacs +proper.) + +If you want to talk about these two versions and distinguish them, +please call them ``Emacs'' and ``XEmacs.'' To contrast ``XEmacs'' +with ``GNU Emacs'' would be misleading, since XEmacs too has its +origin in the work of the GNU Project. Terms such as ``Emacsen'' and +``(X)Emacs'' are not wrong, but they are not very clear, so it +is better to write ``Emacs and XEmacs.'' + @c ------------------------------------------------------------ @node Common requests @chapter Common requests @@ -3356,6 +3380,7 @@ dired, @code{directory-listing-before-filename-regexp}. @menu * Installing Emacs:: +* Emacs for other operating systems:: * Problems building Emacs:: @end menu @@ -3368,9 +3393,7 @@ dired, @code{directory-listing-before-filename-regexp}. @cindex Source code, building Emacs from This answer is meant for users of Unix and Unix-like systems. Users of -other operating systems should see the series of questions beginning -with @ref{Emacs for MS-DOS}, which describe where to get non-Unix source -and binaries, and how to install Emacs on those systems. +other operating systems should see @xref{Emacs for other operating systems}. Most GNU/Linux distributions provide pre-built Emacs packages. If Emacs is not installed already, you can install it by running (as @@ -3389,20 +3412,20 @@ a list of sites that make them available. On @url{https://ftp.gnu.org}, the main GNU distribution site, sources are available as @c Don't include VER in the file name, because pretests are not there. -@uref{https://ftp.gnu.org/pub/gnu/emacs/emacs-VERSION.tar.gz} +@uref{https://ftp.gnu.org/pub/gnu/emacs/emacs-VERSION.tar.xz} -(Replace @samp{VERSION} with the relevant version number, e.g., @samp{23.1}.) +(Replace @samp{VERSION} with the relevant version number, e.g., @samp{27.1}.) @item Next uncompress and extract the source files. This requires -the @code{gzip} and @code{tar} programs, which are standard utilities. +the @code{xz} and @code{tar} programs, which are standard utilities. If your system does not have them, these can also be downloaded from @url{https://ftp.gnu.org}. GNU @code{tar} can uncompress and extract in a single-step: @example -tar -zxvf emacs-VERSION.tar.gz +tar -axvf emacs-VERSION.tar.xz @end example @item @@ -3416,9 +3439,8 @@ cd emacs-VERSION make # use Makefile to build components, then Emacs @end example -If the @code{make} completes successfully, the odds are fairly good that -the build has gone well. (@xref{Problems building Emacs}, if you weren't -successful.) +If the @code{make} completes successfully, you can go on to install it. +(@xref{Problems building Emacs}, if you weren't successful.) @item By default, Emacs is installed in @file{/usr/local}. To actually @@ -3433,6 +3455,46 @@ and any Emacs Info files that might be in @file{/usr/local/share/info/}. @end itemize +@node Emacs for other operating systems +@section Where can I get Emacs for macOS, MS Windows, etc? + +@cindex Apple computers, Emacs for +@cindex Macintosh, Emacs for +@cindex macOS, Emacs for +Beginning with version 22.1, Emacs supports macOS natively. +See the file @file{nextstep/INSTALL} in the distribution. + +@cindex FAQ for Emacs on MS-Windows +@cindex Emacs for MS-Windows +@cindex Microsoft Windows, Emacs for +There is a separate FAQ for Emacs on MS-Windows, +@pxref{Top,,,efaq-w32,FAQ for Emacs on MS Windows}. + +@cindex GNUstep, Emacs for +Beginning with version 23.1, Emacs supports GNUstep natively. +See the file @file{nextstep/INSTALL} in the distribution. + +@cindex MS-DOS, Emacs for +@cindex DOS, Emacs for +@cindex Compiling Emacs for DOS +@cindex Emacs for MS-DOS +To build Emacs from source for MS-DOS, see the instructions in the file +@file{msdos/INSTALL} in the distribution. The DOS port builds and runs +on plain DOS, and also on all versions of MS-Windows from version 3.X +onwards, including Windows XP and Vista. Pre-built binaries may be +available at +@uref{http://www.delorie.com/pub/djgpp/current/v2gnu/emacs.README} + +For a list of other implementations of Emacs (and Emacs +look-alikes), consult the list of ``Emacs implementations and literature,'' +available at + +@uref{http://www.finseth.com/emacs.html} + +Note that while many of these programs look similar to Emacs, they often +lack certain features, such as the Emacs Lisp extension language. + + @node Problems building Emacs @section What should I do if I have trouble building Emacs? @cindex Problems building Emacs @@ -3456,22 +3518,16 @@ problem (@pxref{Reporting bugs}). @cindex Finding Emacs and related packages @menu -* Finding Emacs on the Internet:: +* Downloading Emacs:: * Finding a package with particular functionality:: * Packages that do not come with Emacs:: * Spell-checkers:: * Current GNU distributions:: -* Difference between Emacs and XEmacs:: * Emacs for minimalists:: -* Emacs for MS-DOS:: -* Emacs for MS-Windows:: -* Emacs for GNUstep:: -* Emacs for macOS:: @end menu -@node Finding Emacs on the Internet -@section Where can I get Emacs on the net? -@cindex Finding Emacs on the Internet +@node Downloading Emacs +@section Downloading Emacs @cindex Downloading Emacs Information on downloading Emacs is available at @@ -3487,25 +3543,22 @@ archive sites that make GNU software available. @cindex Finding an Emacs Lisp package @cindex Functionality, finding a particular package -First of all, you should check to make sure that the package isn't -already available. For example, typing @kbd{M-x apropos @key{RET} -python @key{RET}} lists all functions and variables containing the -string @samp{python}. - -It is also possible that the package is on your system, but has not been -loaded. To see which packages are available for loading, look through -your computer's lisp directory (@pxref{File-name conventions}). The Lisp -source to most packages contains a short description of how they -should be loaded, invoked, and configured---so before you use or -modify a Lisp package, see if the author has provided any hints in the -source code. - The command @kbd{C-h p} (@code{finder-by-keyword}) allows you to browse -the constituent Emacs packages. +the packages that come with Emacs. For advice on how to find extra packages that are not part of Emacs, see @ref{Packages that do not come with Emacs}. +Other techniques that might be useful: + +Typing @kbd{M-x apropos @key{RET} python @key{RET}} lists all +functions and variables containing the string @samp{python}. + +You can look through your computer's lisp directory (@pxref{File-name +conventions}). The Lisp source to most packages contains a short +description of what they do and how they should be used. + + @c Note that M-x view-external-packages references this node. @node Packages that do not come with Emacs @section Where can I get Emacs Lisp packages that don't come with Emacs? @@ -3550,8 +3603,8 @@ additional extensions. @uref{https://wikemacs.org, WikEmacs} is an alternative wiki for Emacs. @uref{http://www.damtp.cam.ac.uk/user/sje30/emacs/ell.html, The Emacs -Lisp List (ELL)}, has pointers to many Emacs Lisp files, but at time -of writing it is no longer being updated. +Lisp List (ELL)}, is no longer being updated, but has pointers to +older Emacs Lisp files. It is impossible for us to list here all the sites that offer Emacs Lisp packages. If you are interested in a specific feature, then @@ -3602,42 +3655,6 @@ A list of sites mirroring @samp{ftp.gnu.org} can be found at @uref{https://www.gnu.org/prep/ftp} -@node Difference between Emacs and XEmacs -@section What is the difference between Emacs and XEmacs (formerly Lucid Emacs)? -@cindex XEmacs -@cindex Difference Emacs and XEmacs -@cindex Lucid Emacs -@cindex Epoch - -XEmacs was a branch version of Emacs that is no longer actively -developed. XEmacs was first called Lucid Emacs, and was initially -derived from a prerelease version of Emacs 19. In this FAQ, we use -the name ``Emacs'' only for the official version. - -XEmacs last released a new version on January 30, 2009, and it lacks -many important features that exists in Emacs. In the past, it was not -uncommon for Emacs packages to include code for compatibility with -XEmacs. Nowadays, although some packages still maintain such -compatibility code, several of the more popular built-in and third -party packages have either stopped supporting XEmacs or were developed -exclusively for Emacs. - -Some XEmacs code has been contributed to Emacs, and we would like to -use other parts, but the earlier XEmacs maintainers did not always -keep track of the authors of contributed code, which makes it -impossible for the FSF to get copyright papers signed for that code. -(The FSF requires these papers for all the code included in the Emacs -release, aside from generic C support packages that retain their -separate identity and are not integrated into the code of Emacs -proper.) - -If you want to talk about these two versions and distinguish them, -please call them ``Emacs'' and ``XEmacs.'' To contrast ``XEmacs'' -with ``GNU Emacs'' would be misleading, since XEmacs too has its -origin in the work of the GNU Project. Terms such as ``Emacsen'' and -``(X)Emacs'' are not wrong, but they are not very clear, so it -is better to write ``Emacs and XEmacs.'' - @node Emacs for minimalists @section I don't have enough disk space to install Emacs @cindex Zile @@ -3651,63 +3668,6 @@ information is available from @uref{https://www.gnu.org/software/zile/} - -@node Emacs for MS-DOS -@section Where can I get Emacs for MS-DOS? -@cindex MS-DOS, Emacs for -@cindex DOS, Emacs for -@cindex Compiling Emacs for DOS -@cindex Emacs for MS-DOS - -To build Emacs from source for MS-DOS, see the instructions in the file -@file{msdos/INSTALL} in the distribution. The DOS port builds and runs -on plain DOS, and also on all versions of MS-Windows from version 3.X -onwards, including Windows XP and Vista. - -The file @file{etc/PROBLEMS} contains some additional information -regarding Emacs under MS-DOS. - -A pre-built binary distribution of the old Emacs 24 is available, as -described at - -@uref{http://www.delorie.com/pub/djgpp/current/v2gnu/emacs.README} - -For a list of other MS-DOS implementations of Emacs (and Emacs -look-alikes), consult the list of ``Emacs implementations and literature,'' -available at - -@uref{http://www.finseth.com/emacs.html} - -Note that while many of these programs look similar to Emacs, they often -lack certain features, such as the Emacs Lisp extension language. - -@node Emacs for MS-Windows -@section Where can I get Emacs for Microsoft Windows? -@cindex FAQ for Emacs on MS-Windows -@cindex Emacs for MS-Windows -@cindex Microsoft Windows, Emacs for - -There is a separate FAQ for Emacs on MS-Windows, -@pxref{Top,,,efaq-w32,FAQ for Emacs on MS Windows}. -For MS-DOS, @pxref{Emacs for MS-DOS}. - - -@node Emacs for GNUstep -@section Where can I get Emacs for GNUstep? -@cindex GNUstep, Emacs for - -Beginning with version 23.1, Emacs supports GNUstep natively. -See the file @file{nextstep/INSTALL} in the distribution. - -@node Emacs for macOS -@section Where can I get Emacs for macOS? -@cindex Apple computers, Emacs for -@cindex Macintosh, Emacs for -@cindex macOS, Emacs for - -Beginning with version 22.1, Emacs supports macOS natively. -See the file @file{nextstep/INSTALL} in the distribution. - @c ------------------------------------------------------------ @node Key bindings @chapter Key bindings commit dd4be8ad3b0cbcd701a5d5f7221a7e4c2a69d6be Author: Glenn Morris Date: Sun Sep 5 14:04:43 2021 -0700 * test/lisp/vc/vc-tests.el (vc-test-git06-version-diff): Skip on hydra. diff --git a/test/lisp/vc/vc-tests.el b/test/lisp/vc/vc-tests.el index 16ef5cc2f9..c20d1bdf6a 100644 --- a/test/lisp/vc/vc-tests.el +++ b/test/lisp/vc/vc-tests.el @@ -797,6 +797,9 @@ This checks also `vc-backend' and `vc-responsible-backend'." (ert-get-test ',(intern (format "vc-test-%s01-register" backend-string)))))) + ;; FIXME git (2.18.1) commit fails with status 128 - why? + (skip-unless (not (and (eq 'Git ',backend) + (getenv "EMACS_HYDRA_CI")))) (vc-test--version-diff ',backend)) )))) commit d864389c34507f135089b3059264f9585092abda Author: Dmitry Gutov Date: Sun Sep 5 22:25:15 2021 +0300 * lisp/progmodes/xref.el: Bump the version again. diff --git a/lisp/progmodes/xref.el b/lisp/progmodes/xref.el index 2181ecf9f3..e594624573 100644 --- a/lisp/progmodes/xref.el +++ b/lisp/progmodes/xref.el @@ -1,7 +1,7 @@ ;;; xref.el --- Cross-referencing commands -*-lexical-binding:t-*- ;; Copyright (C) 2014-2021 Free Software Foundation, Inc. -;; Version: 1.2.1 +;; Version: 1.2.2 ;; Package-Requires: ((emacs "26.1")) ;; This is a GNU ELPA :core package. Avoid functionality that is not commit aecf4518a052517e6a5df0fec13cac493ff50ca0 Author: Eli Zaretskii Date: Sun Sep 5 21:24:22 2021 +0300 ; * lisp/indent.el (tab-first-completion): Fix :version tag. diff --git a/lisp/indent.el b/lisp/indent.el index a33d962009..aa2bfbceeb 100644 --- a/lisp/indent.el +++ b/lisp/indent.el @@ -81,7 +81,7 @@ This variable has no effect unless `tab-always-indent' is `complete'." (const :tag "Unless looking at a word" 'word) (const :tag "Unless at a word or parenthesis" 'word-or-paren) (const :tag "Unless at a word, parenthesis, or punctuation." 'word-or-paren-or-punct)) - :version "27.1") + :version "28.1") (defvar indent-line-ignored-functions '(indent-relative indent-relative-maybe commit c5b654b3f105b8be7e7bcf3ad3f424cf38afd8f5 Author: Lars Ingebrigtsen Date: Sun Sep 5 16:52:11 2021 +0200 Autoload cl-struct-slot-info * lisp/emacs-lisp/cl-macs.el (cl-struct-slot-info): Autoload (bug#50301). * test/lisp/emacs-lisp/memory-report-tests.el: Don't require cl-macs. diff --git a/lisp/emacs-lisp/cl-macs.el b/lisp/emacs-lisp/cl-macs.el index d878af4d84..4ea583d28f 100644 --- a/lisp/emacs-lisp/cl-macs.el +++ b/lisp/emacs-lisp/cl-macs.el @@ -3288,6 +3288,7 @@ STRUCT-TYPE is a symbol naming a struct type. Return `record', (push (cdr x) res)) (nreverse res))) +;;;###autoload (defun cl-struct-slot-info (struct-type) "Return a list of slot names of struct STRUCT-TYPE. Each entry is a list (SLOT-NAME . OPTS), where SLOT-NAME is a diff --git a/test/lisp/emacs-lisp/memory-report-tests.el b/test/lisp/emacs-lisp/memory-report-tests.el index 1e0ffdc86a..e352dd165f 100644 --- a/test/lisp/emacs-lisp/memory-report-tests.el +++ b/test/lisp/emacs-lisp/memory-report-tests.el @@ -19,7 +19,6 @@ (require 'ert) (require 'memory-report) -(require 'cl-macs) (defun setup-memory-report-tests () ;; Set the sizes on things based on a 64-bit architecture. (We're commit 7c7a47b86ebfa05734ebf67d49012c8e336801a6 Author: Eli Zaretskii Date: Sun Sep 5 13:33:46 2021 +0300 ; * etc/NEWS: Fix a recent change. diff --git a/etc/NEWS b/etc/NEWS index 1ec8dd058f..72f0d661da 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -556,10 +556,9 @@ including the newlines that separate the lines. ** Completion List Mode -*** New key bindings have been added to 'completion-list-mode': 'n' -and 'p' now navigate completions, and 'M-g M-c' switches to the -minibuffer, and you can also switch back to the completion list buffer -with 'M-g M-c'. +New key bindings have been added to 'completion-list-mode': 'n' and +'p' now navigate completions, and 'M-g M-c' switches to the +minibuffer and back to the completion list buffer. ** Benchmark *** New function 'benchmark-call' to measure the execution time of a function. commit 3d0276e98bd2e31c45592def9f53da031a1ae277 Author: Lars Ingebrigtsen Date: Sun Sep 5 12:02:16 2021 +0200 Improve the documentation around the read-key/minibuffer prompting * lisp/subr.el (read-char-choice-use-read-key): Explain the difference. (read-char-choice): Mention the variables. (y-or-n-p-use-read-key): Explain the difference. (y-or-n-p): Mention the variable (bug#50390). diff --git a/lisp/subr.el b/lisp/subr.el index 7426dcce50..6ae6d242a4 100644 --- a/lisp/subr.el +++ b/lisp/subr.el @@ -2872,9 +2872,23 @@ This function is used by the `interactive' code letter `n'." (defvar read-char-choice-use-read-key nil "Prefer `read-key' when reading a character by `read-char-choice'. -Otherwise, use the minibuffer.") +Otherwise, use the minibuffer. + +When using the minibuffer, the user is less constrained, and can +use the normal commands available in the minibuffer, and can, for +instance, switch to another buffer, do things there, and then +switch back again to the minibuffer before entering the +character. This is not possible when using `read-key', but using +`read-key' may be less confusing to some users.") (defun read-char-choice (prompt chars &optional inhibit-keyboard-quit) + "Read and return one of CHARS, prompting for PROMPT. +Any input that is not one of CHARS is ignored. + +By default, the minibuffer is used to read the key +non-modally (see `read-char-from-minibuffer'). If +`read-char-choice-use-read-key' is non-nil, the modal `read-key' +function is used instead (see `read-char-choice-with-read-key')." (if (not read-char-choice-use-read-key) (read-char-from-minibuffer prompt chars) (read-char-choice-with-read-key prompt chars inhibit-keyboard-quit))) @@ -3174,7 +3188,14 @@ Also discard all previous input in the minibuffer." (defvar y-or-n-p-use-read-key nil "Prefer `read-key' when answering a \"y or n\" question by `y-or-n-p'. -Otherwise, use the minibuffer.") +Otherwise, use the minibuffer. + +When using the minibuffer, the user is less constrained, and can +use the normal commands available in the minibuffer, and can, for +instance, switch to another buffer, do things there, and then +switch back again to the minibuffer before entering the +character. This is not possible when using `read-key', but using +`read-key' may be less confusing to some users.") (defun y-or-n-p (prompt) "Ask user a \"y or n\" question. @@ -3203,7 +3224,12 @@ responses, perform the requested window recentering or scrolling and ask again. Under a windowing system a dialog box will be used if `last-nonmenu-event' -is nil and `use-dialog-box' is non-nil." +is nil and `use-dialog-box' is non-nil. + +By default, this function uses the minibuffer to read the key. +If `y-or-n-p-use-read-key' is non-nil, `read-key' is used +instead (which means that the user can't change buffers (and the +like) while `y-or-n-p' is running)." (let ((answer 'recenter) (padded (lambda (prompt &optional dialog) (let ((l (length prompt))) commit 73a90cda4a8d38aa20a3e4758894d358ee78646c Author: Lars Ingebrigtsen Date: Sun Sep 5 11:34:32 2021 +0200 Clarify completion-list-mode NEWS entry * etc/NEWS: Clarify completion-list-mode entry (bug#50394). diff --git a/etc/NEWS b/etc/NEWS index 55fbcf2b64..1ec8dd058f 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -555,9 +555,11 @@ including the newlines that separate the lines. * Changes in Specialized Modes and Packages in Emacs 28.1 ** Completion List Mode -New key bindings have been added: 'n' and 'p' to navigate completions, -and 'M-g M-c' to switch to the minibuffer, and you can also switch back -to the completion list buffer with 'M-g M-c'. + +*** New key bindings have been added to 'completion-list-mode': 'n' +and 'p' now navigate completions, and 'M-g M-c' switches to the +minibuffer, and you can also switch back to the completion list buffer +with 'M-g M-c'. ** Benchmark *** New function 'benchmark-call' to measure the execution time of a function. commit 8f2e8add98cff07fb671f7a143d516e20df86566 Author: Eli Zaretskii Date: Sun Sep 5 12:30:35 2021 +0300 ; * doc/emacs/maintaining.texi (Looking Up Identifiers): Fix last change. diff --git a/doc/emacs/maintaining.texi b/doc/emacs/maintaining.texi index db5e00c4aa..e6cbb14ece 100644 --- a/doc/emacs/maintaining.texi +++ b/doc/emacs/maintaining.texi @@ -2156,15 +2156,19 @@ by typing @kbd{@key{RET}} or clicking @kbd{mouse-2} will pop a buffer showing the corresponding definition. If the value of the variable @code{xref-auto-jump-to-first-definition} is @code{move}, the first candidate is automatically selected, and if it's @code{t} or -@code{show}, the first candidate is automatically shown. +@code{show}, the first candidate is automatically shown. The default +value is @code{nil}, which just shows the candidates in the +@file{*xref*} buffer, but doesn't select any of them. @vindex xref-auto-jump-to-first-xref If the value of the variable @code{xref-auto-jump-to-first-xref} is -@code{t}, @emph{all} Xref commands automatically jump to the first result. -If the value is @code{show}, the first result is shown, but the window -showing the @file{*xref*} buffer is left selected. If the value is -@code{move}, the first result is selected in the @file{*xref*} buffer, -but is not shown. +@code{t}, @emph{all} Xref commands automatically jump to the first +result. If the value is @code{show}, the first result is shown, but +the window showing the @file{*xref*} buffer is left selected. If the +value is @code{move}, the first result is selected in the +@file{*xref*} buffer, but is not shown. The default value is +@code{nil}, which just shows the results in the @file{*xref*} buffer, +but doesn't select any of them. When entering the identifier argument to @kbd{M-.}, the usual minibuffer completion commands can be used (@pxref{Completion}), with commit 0972cbe42fe538ded8729c07116e0f98f9830d43 Author: Juri Linkov Date: Sun Sep 5 11:36:30 2021 +0300 * lisp/progmodes/xref.el: Fix defcustoms (bug#50067) * lisp/progmodes/xref.el (xref-auto-jump-to-first-definition) (xref-auto-jump-to-first-xref, xref-search-program): Fix defcustoms. diff --git a/lisp/progmodes/xref.el b/lisp/progmodes/xref.el index 86cbdf1fb9..2181ecf9f3 100644 --- a/lisp/progmodes/xref.el +++ b/lisp/progmodes/xref.el @@ -421,9 +421,10 @@ elements is negated: these commands will NOT prompt." `show' means to show the first result's location, but keep the focus on the Xref buffer's window. `move' means to only move point to the first result." - :type '(choice (const t :tag "Jump") - (const show :tag "Show") - (const move :tag "Move point only")) + :type '(choice (const :tag "Jump" t) + (const :tag "Show" show) + (const :tag "Move point only" move) + (const :tag "No auto-jump" nil)) :version "28.1" :package-version '(xref . "1.2.0")) @@ -432,9 +433,10 @@ focus on the Xref buffer's window. `show' means to show the first result's location, but keep the focus on the Xref buffer's window. `move' means to only move point to the first result." - :type '(choice (const t :tag "Jump") - (const show :tag "Show") - (const move :tag "Move point only")) + :type '(choice (const :tag "Jump" t) + (const :tag "Show" show) + (const :tag "Move point only" move) + (const :tag "No auto-jump" nil)) :version "28.1" :package-version '(xref . "1.2.0")) @@ -1628,7 +1630,7 @@ The template should have the following fields: "The program to use for regexp search inside files. This must reference a corresponding entry in `xref-search-program-alist'." - :type `(choice + :type '(choice (const :tag "Use Grep" grep) (const :tag "Use ripgrep" ripgrep) (symbol :tag "User defined")) commit 2ed2999ce59bb404509dd7f319c00f4085427cde Author: Eli Zaretskii Date: Sun Sep 5 10:59:07 2021 +0300 Improve documentation of new Xref options * doc/emacs/maintaining.texi (Looking Up Identifiers): * etc/NEWS: Document the new Xref user options. Move a lost Xref-related entry to the rest of them. diff --git a/doc/emacs/maintaining.texi b/doc/emacs/maintaining.texi index 8c5d19dcdd..db5e00c4aa 100644 --- a/doc/emacs/maintaining.texi +++ b/doc/emacs/maintaining.texi @@ -2145,6 +2145,7 @@ identifier at point, it prompts for the identifier. (If you want it to always prompt, customize @code{xref-prompt-for-identifier} to @code{t}.) +@vindex xref-auto-jump-to-first-definition If the specified identifier has only one definition, the command jumps to it. If the identifier has more than one possible definition (e.g., in an object-oriented language, or if there's a function and a @@ -2152,7 +2153,18 @@ variable by the same name), the command shows the candidate definitions in the @file{*xref*} buffer, together with the files in which these definitions are found. Selecting one of these candidates by typing @kbd{@key{RET}} or clicking @kbd{mouse-2} will pop a buffer -showing the corresponding definition. +showing the corresponding definition. If the value of the variable +@code{xref-auto-jump-to-first-definition} is @code{move}, the first +candidate is automatically selected, and if it's @code{t} or +@code{show}, the first candidate is automatically shown. + +@vindex xref-auto-jump-to-first-xref + If the value of the variable @code{xref-auto-jump-to-first-xref} is +@code{t}, @emph{all} Xref commands automatically jump to the first result. +If the value is @code{show}, the first result is shown, but the window +showing the @file{*xref*} buffer is left selected. If the value is +@code{move}, the first result is selected in the @file{*xref*} buffer, +but is not shown. When entering the identifier argument to @kbd{M-.}, the usual minibuffer completion commands can be used (@pxref{Completion}), with diff --git a/etc/NEWS b/etc/NEWS index 91fc7df91b..55fbcf2b64 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -2152,13 +2152,24 @@ sub-directory. *** 'project-find-file' doesn't use the string at point as default input. Now it's only suggested as part of the "future history". -** xref +** Xref --- *** Prefix arg of 'xref-goto-xref' quits the "*xref*" buffer. So typing 'C-u RET' in the "*xref*" buffer quits its window before navigating to the selected location. ++++ +*** New user options to automatically show the first Xref match. +The new option 'xref-auto-jump-to-first-definition' controls the +behavior of 'xref-find-definitions' and related commands: if it's t or +'show', the first match is automatically displayed; if it's 'move', +point in the *xref* buffer is automatically moved to the first match +without displaying it. +The new option 'xref-auto-jump-to-first-xref' changes the behavior of +all Xref commands in the same way as 'xref-auto-jump-to-first-definition' +affects the "find-definitions" commands. + *** New user options 'xref-search-program' and 'xref-search-program-alist'. So far 'grep' and 'ripgrep' are supported. 'ripgrep' seems to offer better performance in certain cases, in particular for case-insensitive @@ -2194,6 +2205,11 @@ supported, but we plan on removing it in a future version; at that time, the command 'xref-quit-and-goto-xref' will no longer have a key binding in 'xref--xref-buffer-mode-map'. +--- +*** New user option 'etags-xref-prefer-current-file'. +When non-nil, 'M-.' matches for identifiers in the file visited by the +current buffer will be shown first in the "*xref*" buffer. + ** json.el --- @@ -3937,11 +3953,6 @@ unsaved changes, but this has apparently not worked for several decades, so the documented semantics of this variable has been changed to match the behaviour.) ---- -** New user option 'etags-xref-prefer-current-file'. -When non-nil, matches for identifiers in the file visited by the -current buffer will be shown first in the "*xref*" buffer. - --- ** New variable 'inhibit-mouse-event-check'. If bound to non-nil, a command with '(interactive "e")' doesn't signal commit 1fdd898704629de550e2374cf0a06b7c519d6022 Author: Augusto Stoffel Date: Sat Sep 4 11:16:11 2021 +0200 Fixes for 'python-shell-send-string' and 'python-shell-send-file' * lisp/progmodes/python.el (python-shell-send-string): use a temporary file for sufficiently long strings. (python-shell-send-file, python-shell-eval-file-setup-code): Avoid showing "plumbing code" in the traceback (bug#32042). diff --git a/lisp/progmodes/python.el b/lisp/progmodes/python.el index 306cc3a542..d8ec032402 100644 --- a/lisp/progmodes/python.el +++ b/lisp/progmodes/python.el @@ -3127,12 +3127,18 @@ user-friendly message if there's no process running; defaults to t when called interactively." (interactive (list (read-string "Python command: ") nil t)) - (comint-send-string - (or process (python-shell-get-process-or-error msg)) - (format "exec(%s);__PYTHON_EL_eval(%s, %s)\n" - (python-shell--encode-string python-shell-eval-setup-code) - (python-shell--encode-string string) - (python-shell--encode-string (or (buffer-file-name) ""))))) + (let ((process (or process (python-shell-get-process-or-error msg))) + (code (format "exec(%s);__PYTHON_EL_eval(%s, %s)\n" + (python-shell--encode-string python-shell-eval-setup-code) + (python-shell--encode-string string) + (python-shell--encode-string (or (buffer-file-name) + ""))))) + (if (<= (string-bytes code) 4096) + (comint-send-string process code) + (let* ((temp-file-name (with-current-buffer (process-buffer process) + (python-shell--save-temp-file string))) + (file-name (or (buffer-file-name) temp-file-name))) + (python-shell-send-file file-name process temp-file-name t))))) (defvar python-shell-output-filter-in-progress nil) (defvar python-shell-output-filter-buffer nil) @@ -3372,6 +3378,18 @@ t when called interactively." nil ;; noop msg)))) + +(defconst python-shell-eval-file-setup-code + "\ +def __PYTHON_EL_eval_file(filename, tempname, encoding, delete): + import codecs, os + with codecs.open(tempname or filename, encoding=encoding) as file: + source = file.read().encode(encoding) + if delete and tempname: + os.remove(tempname) + return __PYTHON_EL_eval(source, filename)" + "Code used to evaluate files in inferior Python processes.") + (defun python-shell-send-file (file-name &optional process temp-file-name delete msg) "Send FILE-NAME to inferior Python PROCESS. @@ -3401,15 +3419,13 @@ t when called interactively." (comint-send-string process (format - (concat - "import codecs, os;" - "__pyfile = codecs.open('''%s''', encoding='''%s''');" - "__code = __pyfile.read().encode('''%s''');" - "__pyfile.close();" - (when (and delete temp-file-name) - (format "os.remove('''%s''');" temp-file-name)) - "exec(compile(__code, '''%s''', 'exec'));") - (or temp-file-name file-name) encoding encoding file-name)))) + "exec(%s);exec(%s);__PYTHON_EL_eval_file(%s, %s, %s, %s)\n" + (python-shell--encode-string python-shell-eval-setup-code) + (python-shell--encode-string python-shell-eval-file-setup-code) + (python-shell--encode-string file-name) + (python-shell--encode-string (or temp-file-name "")) + (python-shell--encode-string (symbol-name encoding)) + (if delete "True" "False"))))) (defun python-shell-switch-to-shell (&optional msg) "Switch to inferior Python process buffer. commit ba84ec8bd93b931be975ab8a8a7f0d7a2df7054a Author: Ian W Date: Fri Sep 3 20:53:24 2021 -0700 Fix error handling in 'ispell-init-process' * lisp/textmodes/ispell.el (ispell-init-process): When Ispell initialization reports an error, call 'ispell-accept-output' only if the Ispell process is still alive. (Bug#50370) Copyright-paperwork-exempt: yes diff --git a/lisp/textmodes/ispell.el b/lisp/textmodes/ispell.el index c2f6b35df8..3b9f1d3512 100644 --- a/lisp/textmodes/ispell.el +++ b/lisp/textmodes/ispell.el @@ -2923,7 +2923,14 @@ Keeps argument list for future Ispell invocations for no async support." ;; But first wait to see if some more output is going to arrive. ;; Otherwise we get cool errors like "Can't open ". (sleep-for 1) - (ispell-accept-output 3) + ;; Only call `ispell-accept-output' if the Ispell process + ;; is alive, to avoid showing an unhelpful error message + ;; about a missing process, instead of the error which + ;; reports why the Ispell process died. + (when (if ispell-async-processp + (process-live-p ispell-process) + ispell-process) + (ispell-accept-output 3)) (error "%s" (mapconcat #'identity ispell-filter "\n")))) (setq ispell-filter nil) ; Discard version ID line (let ((extended-char-mode (ispell-get-extended-character-mode))) commit e6f936eb4d28bf23eb367d4245a137284d5491ee Author: Michael Albinus Date: Sun Sep 5 09:23:30 2021 +0200 Cleanup tramp-tests.el * test/lisp/net/tramp-tests.el (tramp--test--deftest-direct-async-process): Fix macro declaration. (tramp-test29-start-file-process, tramp-test30-make-process): Do not run connection type test for direct async processes. diff --git a/test/lisp/net/tramp-tests.el b/test/lisp/net/tramp-tests.el index 9a9684dd73..27b37d4f19 100644 --- a/test/lisp/net/tramp-tests.el +++ b/test/lisp/net/tramp-tests.el @@ -4579,6 +4579,7 @@ This tests also `make-symbolic-link', `file-truename' and `add-name-to-file'." ;; Process connection type. (when (and (tramp--test-sh-p) + (not (tramp-direct-async-process-p)) ;; `executable-find' has changed the number of ;; parameters in Emacs 27.1, so we use `apply' for ;; older Emacsen. @@ -4635,8 +4636,9 @@ This tests also `make-symbolic-link', `file-truename' and `add-name-to-file'." "Define ert test `TEST-direct-async' for direct async processes. If UNSTABLE is non-nil, the test is tagged as `:unstable'." (declare (indent 1)) - ;; `make-process' supports file name handlers since Emacs 27. - (when (let ((file-name-handler-alist '(("" . #'tramp--test-always)))) + ;; `make-process' supports file name handlers since Emacs 27. We + ;; cannot use `tramp--test-always' during compilation of the macro. + (when (let ((file-name-handler-alist '(("" . (lambda (&rest _) t))))) (ignore-errors (make-process :file-handler t))) `(ert-deftest ,(intern (concat (symbol-name test) "-direct-async")) () ,docstring @@ -4829,6 +4831,7 @@ If UNSTABLE is non-nil, the test is tagged as `:unstable'." ;; Process connection type. (when (and (tramp--test-sh-p) + (not (tramp-direct-async-process-p)) ;; `executable-find' has changed the number of ;; parameters in Emacs 27.1, so we use `apply' for ;; older Emacsen. commit 76300b87d472354507a872fa84709df9d5d4a59b Author: Glenn Morris Date: Sat Sep 4 18:39:20 2021 -0700 * test/lisp/vc/vc-tests.el (vc-test-sccs06-version-diff): Fix it. diff --git a/test/lisp/vc/vc-tests.el b/test/lisp/vc/vc-tests.el index 39a68275a0..16ef5cc2f9 100644 --- a/test/lisp/vc/vc-tests.el +++ b/test/lisp/vc/vc-tests.el @@ -640,7 +640,7 @@ This checks also `vc-backend' and `vc-responsible-backend'." (with-current-buffer buff (progn ;; Optionally checkout file. - (when (or (eq backend 'RCS) (eq backend 'CVS)) + (when (memq backend '(RCS CVS SCCS)) (vc-checkout tmp-name)) ;; Checkin file. @@ -649,7 +649,7 @@ This checks also `vc-backend' and `vc-responsible-backend'." (log-edit-done)))) ;; Modify file content. - (when (or (eq backend 'RCS) (eq backend 'CVS)) + (when (memq backend '(RCS CVS SCCS)) (vc-checkout tmp-name)) (write-region "updatedtext" nil tmp-name nil 'nomessage) commit 94530e7ea9450e6b3eff255b80f76f8f7b051632 Author: Dmitry Gutov Date: Sun Sep 5 03:52:29 2021 +0300 Belated fix * lisp/progmodes/xref.el: (xref--show-xref-buffer): Fix support for xref-auto-jump-to-first-xref. diff --git a/lisp/progmodes/xref.el b/lisp/progmodes/xref.el index e959f601e9..86cbdf1fb9 100644 --- a/lisp/progmodes/xref.el +++ b/lisp/progmodes/xref.el @@ -1,7 +1,7 @@ ;;; xref.el --- Cross-referencing commands -*-lexical-binding:t-*- ;; Copyright (C) 2014-2021 Free Software Foundation, Inc. -;; Version: 1.2.0 +;; Version: 1.2.1 ;; Package-Requires: ((emacs "26.1")) ;; This is a GNU ELPA :core package. Avoid functionality that is not @@ -1042,13 +1042,16 @@ Return an alist of the form ((FILENAME . (XREF ...)) ...)." (assoc-default 'fetched-xrefs alist) (funcall fetcher))) (xref-alist (xref--analyze xrefs)) - (dd default-directory)) + (dd default-directory) + buf) (with-current-buffer (get-buffer-create xref-buffer-name) (setq default-directory dd) (xref--xref-buffer-mode) (xref--show-common-initialize xref-alist fetcher alist) (pop-to-buffer (current-buffer)) - (current-buffer)))) + (setq buf (current-buffer))) + (xref--auto-jump-first buf (assoc-default 'auto-jump alist)) + buf)) (defun xref--project-root (project) (if (fboundp 'project-root) commit c2983375055f1f8326734322d35dc45e83d47046 Author: Dmitry Gutov Date: Sun Sep 5 03:36:30 2021 +0300 * lisp/progmodes/xref.el: Bump version. diff --git a/lisp/progmodes/xref.el b/lisp/progmodes/xref.el index 45ee86cf5c..e959f601e9 100644 --- a/lisp/progmodes/xref.el +++ b/lisp/progmodes/xref.el @@ -1,7 +1,7 @@ ;;; xref.el --- Cross-referencing commands -*-lexical-binding:t-*- ;; Copyright (C) 2014-2021 Free Software Foundation, Inc. -;; Version: 1.1.0 +;; Version: 1.2.0 ;; Package-Requires: ((emacs "26.1")) ;; This is a GNU ELPA :core package. Avoid functionality that is not commit 1be8bfae6b1f9a0291a0be36fef0417a14657fc3 Author: Dmitry Gutov Date: Sun Sep 5 03:35:43 2021 +0300 Xref: automatic jumping to the first definition or reference * lisp/progmodes/xref.el (xref-auto-jump-to-first-definition) (xref-auto-jump-to-first-xref): New user options. Discussed in bug#50067. (xref--show-xrefs, xref--show-defs): Use them here. (xref--auto-jump-first): New function, handles different values. (xref-show-definitions-buffer) (xref-show-definitions-buffer-at-bottom): Use it. diff --git a/lisp/progmodes/xref.el b/lisp/progmodes/xref.el index 9045f941b1..45ee86cf5c 100644 --- a/lisp/progmodes/xref.el +++ b/lisp/progmodes/xref.el @@ -416,6 +416,28 @@ elements is negated: these commands will NOT prompt." :version "28.1" :package-version '(xref . "1.0.4")) +(defcustom xref-auto-jump-to-first-definition nil + "If t, `xref-find-definitions' always jumps to the first result. +`show' means to show the first result's location, but keep the +focus on the Xref buffer's window. +`move' means to only move point to the first result." + :type '(choice (const t :tag "Jump") + (const show :tag "Show") + (const move :tag "Move point only")) + :version "28.1" + :package-version '(xref . "1.2.0")) + +(defcustom xref-auto-jump-to-first-xref nil + "If t, xref commands always jump to the first result. +`show' means to show the first result's location, but keep the +focus on the Xref buffer's window. +`move' means to only move point to the first result." + :type '(choice (const t :tag "Jump") + (const show :tag "Show") + (const move :tag "Move point only")) + :version "28.1" + :package-version '(xref . "1.2.0")) + (defvar xref--marker-ring (make-ring xref-marker-ring-length) "Ring of markers to implement the marker stack.") @@ -1064,19 +1086,36 @@ Return an alist of the form ((FILENAME . (XREF ...)) ...)." (error-message-string err) 'face 'error))))))) +(defun xref--auto-jump-first (buf value) + (when value + (select-window (get-buffer-window buf)) + (goto-char (point-min))) + (cond + ((eq value t) + (xref-next-line-no-show) + (xref-goto-xref)) + ((eq value 'show) + (xref-next-line)) + ((eq value 'move) + (forward-line 1)))) + (defun xref-show-definitions-buffer (fetcher alist) "Show the definitions list in a regular window. When only one definition found, jump to it right away instead." - (let ((xrefs (funcall fetcher))) + (let ((xrefs (funcall fetcher)) + buf) (cond ((not (cdr xrefs)) (xref-pop-to-location (car xrefs) (assoc-default 'display-action alist))) (t - (xref--show-xref-buffer fetcher - (cons (cons 'fetched-xrefs xrefs) - alist)))))) + (setq buf + (xref--show-xref-buffer fetcher + (cons (cons 'fetched-xrefs xrefs) + alist))) + (xref--auto-jump-first buf (assoc-default 'auto-jump alist)) + buf)))) (define-obsolete-function-alias 'xref--show-defs-buffer #'xref-show-definitions-buffer "28.1") @@ -1092,7 +1131,8 @@ local keymap that binds `RET' to `xref-quit-and-goto-xref'." ;; XXX: Make percentage customizable maybe? (max-height (/ (window-height) 2)) (size-fun (lambda (window) - (fit-window-to-buffer window max-height)))) + (fit-window-to-buffer window max-height))) + buf) (cond ((not (cdr xrefs)) (xref-pop-to-location (car xrefs) @@ -1105,7 +1145,9 @@ local keymap that binds `RET' to `xref-quit-and-goto-xref'." (pop-to-buffer (current-buffer) `(display-buffer-in-direction . ((direction . below) (window-height . ,size-fun)))) - (current-buffer)))))) + (setq buf (current-buffer))) + (xref--auto-jump-first buf (assoc-default 'auto-jump alist)) + buf)))) (define-obsolete-function-alias 'xref--show-defs-buffer-at-bottom #'xref-show-definitions-buffer-at-bottom "28.1") @@ -1234,13 +1276,15 @@ definitions." (setq xrefs 'called-already))))))) (funcall xref-show-xrefs-function fetcher `((window . ,(selected-window)) - (display-action . ,display-action)))) + (display-action . ,display-action) + (auto-jump . ,xref-auto-jump-to-first-xref)))) (defun xref--show-defs (xrefs display-action) (xref--push-markers) (funcall xref-show-definitions-function xrefs `((window . ,(selected-window)) - (display-action . ,display-action)))) + (display-action . ,display-action) + (auto-jump . ,xref-auto-jump-to-first-definition)))) (defun xref--push-markers () (unless (region-active-p) (push-mark nil t)) commit 1d36043809cae3cbb5338e5bea47073bc56e082c Author: Dmitry Gutov Date: Sun Sep 5 02:44:08 2021 +0300 Fix test on machines with Bzr not set up * test/lisp/vc/vc-tests.el (vc-test--version-diff): Add EMAIL= to the environment to avoid potential failure. diff --git a/test/lisp/vc/vc-tests.el b/test/lisp/vc/vc-tests.el index 99de0d8824..39a68275a0 100644 --- a/test/lisp/vc/vc-tests.el +++ b/test/lisp/vc/vc-tests.el @@ -615,7 +615,9 @@ This checks also `vc-backend' and `vc-responsible-backend'." (when (eq backend 'Bzr) (setq tempdir (make-temp-file "vc-test--version-diff" t) process-environment (cons (format "BZR_HOME=%s" tempdir) - process-environment))) + (cons + "EMAIL=john@doe.ee" + process-environment)))) (unwind-protect (progn commit ea53f0df6538c83969afeec04e2fed8309667150 Author: Matthias Meulien Date: Sun Sep 5 02:32:49 2021 +0300 Add tests for vc-version-diff * test/lisp/vc/vc-tests.el (vc-test--version-diff): New function. (vc-test-%s06-version-diff): New family of tests. diff --git a/test/lisp/vc/vc-tests.el b/test/lisp/vc/vc-tests.el index dfe89c519b..99de0d8824 100644 --- a/test/lisp/vc/vc-tests.el +++ b/test/lisp/vc/vc-tests.el @@ -52,7 +52,7 @@ ;; - responsible-p (file) ;; - receive-file (file rev) ;; - unregister (file) DONE -;; * checkin (files comment) +;; * checkin (files comment) DONE ;; * find-revision (file rev buffer) ;; * checkout (file &optional rev) ;; * revert (file &optional contents-done) @@ -75,7 +75,7 @@ ;; - show-log-entry (revision) ;; - comment-history (file) ;; - update-changelog (files) -;; * diff (files &optional async rev1 rev2 buffer) +;; * diff (files &optional async rev1 rev2 buffer) DONE ;; - revision-completion-table (files) ;; - annotate-command (file buf &optional rev) ;; - annotate-time () @@ -110,6 +110,7 @@ (require 'ert) (require 'vc) +(require 'log-edit) (declare-function w32-application-type "w32proc.c") @@ -598,6 +599,74 @@ This checks also `vc-backend' and `vc-responsible-backend'." (if tempdir (delete-directory tempdir t)) (run-hooks 'vc-test--cleanup-hook))))) +(declare-function log-edit-done "vc/log-edit") + +(defun vc-test--version-diff (backend) + "Check the diff version of a repository." + + (let ((vc-handled-backends `(,backend)) + (default-directory + (file-name-as-directory + (expand-file-name + (make-temp-name "vc-test") temporary-file-directory))) + (process-environment process-environment) + tempdir + vc-test--cleanup-hook) + (when (eq backend 'Bzr) + (setq tempdir (make-temp-file "vc-test--version-diff" t) + process-environment (cons (format "BZR_HOME=%s" tempdir) + process-environment))) + + (unwind-protect + (progn + ;; Cleanup. + (add-hook + 'vc-test--cleanup-hook + `(lambda () (delete-directory ,default-directory 'recursive))) + + ;; Create empty repository. Check repository checkout model. + (make-directory default-directory) + (vc-test--create-repo-function backend) + + (let* ((tmp-name (expand-file-name "foo" default-directory)) + (files (list (file-name-nondirectory tmp-name)))) + ;; Write and register a new file. + (write-region "originaltext" nil tmp-name nil 'nomessage) + (vc-register (list backend files)) + + (let ((buff (find-file tmp-name))) + (with-current-buffer buff + (progn + ;; Optionally checkout file. + (when (or (eq backend 'RCS) (eq backend 'CVS)) + (vc-checkout tmp-name)) + + ;; Checkin file. + (vc-checkin files backend) + (insert "Testing vc-version-diff") + (log-edit-done)))) + + ;; Modify file content. + (when (or (eq backend 'RCS) (eq backend 'CVS)) + (vc-checkout tmp-name)) + (write-region "updatedtext" nil tmp-name nil 'nomessage) + + ;; Check version diff. + (vc-version-diff files nil nil) + (should (bufferp (get-buffer "*vc-diff*"))) + + (with-current-buffer "*vc-diff*" + (progn + (let ((rawtext (buffer-substring-no-properties (point-min) + (point-max)))) + (should (string-search "-originaltext" rawtext)) + (should (string-search "+updatedtext" rawtext))))))) + + ;; Save exit. + (ignore-errors + (if tempdir (delete-directory tempdir t)) + (run-hooks 'vc-test--cleanup-hook))))) + ;; Create the test cases. (defun vc-test--rcs-enabled () @@ -715,6 +784,18 @@ This checks also `vc-backend' and `vc-responsible-backend'." ;; "Really want to delete ...?" (skip-unless (not (eq 'CVS ',backend))) (vc-test--rename-file ',backend)) + + (ert-deftest + ,(intern (format "vc-test-%s06-version-diff" backend-string)) () + ,(format "Check `vc-version-diff' for the %s backend." + backend-string) + (skip-unless + (ert-test-passed-p + (ert-test-most-recent-result + (ert-get-test + ',(intern + (format "vc-test-%s01-register" backend-string)))))) + (vc-test--version-diff ',backend)) )))) (provide 'vc-tests) commit 88795df55229e49777a6bf4b53bc9b7b0a6b78d5 Author: Dmitry Gutov Date: Sun Sep 5 01:45:46 2021 +0300 Rename xref-select-and-{goto,show}-xref * lisp/progmodes/xref.el (xref-select-and-show-xref): Rename from xref-select-and-goto-xref (bug#35376). Update all references. diff --git a/doc/emacs/maintaining.texi b/doc/emacs/maintaining.texi index d17c6d3e75..8c5d19dcdd 100644 --- a/doc/emacs/maintaining.texi +++ b/doc/emacs/maintaining.texi @@ -2229,7 +2229,7 @@ With prefix argument, also bury the @file{*xref*} buffer. @item mouse-2 The same as @code{mouse-1}, but make the window displaying the @file{*xref*} buffer the selected window -(@code{xref-select-and-goto-xref}). +(@code{xref-select-and-show-xref}). @item n @itemx . diff --git a/lisp/progmodes/xref.el b/lisp/progmodes/xref.el index d495a4e292..9045f941b1 100644 --- a/lisp/progmodes/xref.el +++ b/lisp/progmodes/xref.el @@ -898,10 +898,10 @@ beginning of the line." (defvar xref--button-map (let ((map (make-sparse-keymap))) (define-key map [mouse-1] #'xref-goto-xref) - (define-key map [mouse-2] #'xref-select-and-goto-xref) + (define-key map [mouse-2] #'xref-select-and-show-xref) map)) -(defun xref-select-and-goto-xref (event) +(defun xref-select-and-show-xref (event) "Move point to the button and show the xref definition. The window showing the xref buffer will be selected." (interactive "e") @@ -910,8 +910,9 @@ The window showing the xref buffer will be selected." (or (get-text-property (point) 'xref-item) (xref--search-property 'xref-item)) (xref-show-location-at-point)) + (define-obsolete-function-alias - 'xref--mouse-2 #'xref-select-and-goto-xref "28.1") + 'xref--mouse-2 #'xref-select-and-show-xref "28.1") (defcustom xref-truncation-width 400 "The column to visually \"truncate\" each Xref buffer line to." commit 534e631b00a3b065016df23aa0f6b7d043e9ed86 Author: Basil L. Contovounesios Date: Sat Sep 4 17:04:26 2021 +0100 Avoid segfault in command-modes * src/data.c (Fcommand_modes): Check that bytecode object is interactive before accessing its interactive spec to avoid segfaulting (bug#50376). diff --git a/src/data.c b/src/data.c index ffca7e7535..27b642df28 100644 --- a/src/data.c +++ b/src/data.c @@ -1045,6 +1045,8 @@ The value, if non-nil, is a list of mode name symbols. */) if (COMPILEDP (fun)) { + if (PVSIZE (fun) <= COMPILED_INTERACTIVE) + return Qnil; Lisp_Object form = AREF (fun, COMPILED_INTERACTIVE); if (VECTORP (form)) /* New form -- the second element is the command modes. */ commit 0fe03c47409ebd702837fc74196d7344a916c495 Author: Stefan Kangas Date: Sat Sep 4 20:11:12 2021 +0200 ; * etc/NEWS: Fix copyright year; file recreated in 2019 for 28.1. diff --git a/etc/NEWS b/etc/NEWS index a96cba0cb0..91fc7df91b 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -1,6 +1,6 @@ GNU Emacs NEWS -- history of user-visible changes. -Copyright (C) 2017-2021 Free Software Foundation, Inc. +Copyright (C) 2019-2021 Free Software Foundation, Inc. See the end of the file for license conditions. Please send Emacs bug reports to 'bug-gnu-emacs@gnu.org'. commit 16a36732b80f4e9762b1230ee181c22e0f160109 Author: Basil L. Contovounesios Date: Sat Sep 4 17:06:39 2021 +0100 ; * etc/NEWS: Fix markup in recent example. diff --git a/etc/NEWS b/etc/NEWS index 506eaab0fc..a96cba0cb0 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -3449,7 +3449,7 @@ The former is now declared obsolete. +++ *** Doc strings can now link to customization groups. -Text like "customization group 'whitespace'" will be made into a +Text like "customization group `whitespace'" will be made into a button. When clicked, it'll take the user to a Custom buffer displaying that customization group. commit c78969d31bf57a83b4700a7cca44d4baaa06e9d9 Author: Stefan Monnier Date: Fri Sep 3 19:41:23 2021 -0400 * lisp/emacs-lisp/timer.el (timer-create): Don't inline it diff --git a/lisp/emacs-lisp/timer.el b/lisp/emacs-lisp/timer.el index 5c658eba80..44d70cde6b 100644 --- a/lisp/emacs-lisp/timer.el +++ b/lisp/emacs-lisp/timer.el @@ -34,7 +34,7 @@ (cl-defstruct (timer (:constructor nil) (:copier nil) - (:constructor timer-create ()) + (:constructor timer--create ()) (:type vector) (:conc-name timer--)) ;; nil if the timer is active (waiting to be triggered), @@ -55,6 +55,12 @@ ;; sleep, etc). integral-multiple) +(defun timer-create () + ;; BEWARE: This is not an eta-redex, because `timer--create' is inlinable + ;; whereas `timer-create' should not be because we don't want to + ;; hardcode the shape of timers in other .elc files. + (timer--create)) + (defun timerp (object) "Return t if OBJECT is a timer." (and (vectorp object) commit 0daad767047be33c0189d5e0131b126b49d35e6d Author: Eli Zaretskii Date: Sat Sep 4 13:34:32 2021 +0300 Improve documentation of line truncation and wrapping * doc/emacs/display.texi (Line Truncation, Visual Line Mode): * doc/lispref/display.texi (Truncation): Document that turning on line truncation disables wrapping, and vice versa. * src/buffer.c (syms_of_buffer) : * src/xdisp.c (syms_of_xdisp) : Warn against turning on when 'visual-line-mode' is in effect. * lisp/simple.el (visual-line-mode): Document that this mode disables line truncation. (Bug#29664) diff --git a/doc/emacs/display.texi b/doc/emacs/display.texi index ae345c11df..996c5a6654 100644 --- a/doc/emacs/display.texi +++ b/doc/emacs/display.texi @@ -1767,6 +1767,10 @@ multiple screen lines. Setting the variable @code{truncate-lines} in any way makes it local to the current buffer; until that time, the default value, which is normally @code{nil}, is in effect. + Since line truncation and word wrap (described in the next section) +are contradictory, @code{toggle-truncate-lines} disables word wrap +when it turns on line truncation. + If a split window becomes too narrow, Emacs may automatically enable line truncation. @xref{Split Window}, for the variable @code{truncate-partial-width-windows} which controls this. @@ -1797,6 +1801,10 @@ mode is enabled, the mode line shows the string @samp{wrap} in the mode display. The command @kbd{M-x global-visual-line-mode} toggles Visual Line mode in all buffers. + Since word wrap and line truncation (described in the previous +section) are contradictory, turning on @code{visual-line-mode} +disables line truncation. + @findex beginning-of-visual-line @findex end-of-visual-line @findex next-logical-line diff --git a/doc/lispref/display.texi b/doc/lispref/display.texi index ca438c10ce..510efaf271 100644 --- a/doc/lispref/display.texi +++ b/doc/lispref/display.texi @@ -152,6 +152,9 @@ truncation; a @samp{\} on the rightmost column indicates a line that wraps. (The display table can specify alternate characters to use for this; @pxref{Display Tables}). + Since wrapping and truncation of text contradict each other, Emacs +turns off line truncation when wrapping is requested, and vice versa. + @defopt truncate-lines If this buffer-local variable is non-@code{nil}, lines that extend beyond the right edge of the window are truncated; otherwise, they are diff --git a/lisp/simple.el b/lisp/simple.el index 37952a5bf4..800a927903 100644 --- a/lisp/simple.el +++ b/lisp/simple.el @@ -7777,7 +7777,9 @@ other purposes." When Visual Line mode is enabled, `word-wrap' is turned on in this buffer, and simple editing commands are redefined to act on visual lines, not logical lines. See Info node `Visual Line -Mode' for details." +Mode' for details. +Turning on this mode disables line truncation set up by +variables `truncate-lines' and `truncate-partial-width-windows'." :keymap visual-line-mode-map :group 'visual-line :lighter " Wrap" diff --git a/src/buffer.c b/src/buffer.c index 100ebc7e2d..4eb7ab6d6b 100644 --- a/src/buffer.c +++ b/src/buffer.c @@ -5805,7 +5805,10 @@ Note that this is overridden by the variable `truncate-partial-width-windows' if that variable is non-nil and this buffer is not full-frame width. -Minibuffers set this variable to nil. */); +Minibuffers set this variable to nil. + +Don't set this to a non-nil value when `visual-line-mode' is +turned on, as it could produce confusing results. */); DEFVAR_PER_BUFFER ("word-wrap", &BVAR (current_buffer, word_wrap), Qnil, doc: /* Non-nil means to use word-wrapping for continuation lines. diff --git a/src/xdisp.c b/src/xdisp.c index e853c8c223..b2fcc165a9 100644 --- a/src/xdisp.c +++ b/src/xdisp.c @@ -35136,7 +35136,10 @@ not span the full frame width. A value of nil means to respect the value of `truncate-lines'. -If `word-wrap' is enabled, you might want to reduce this. */); +If `word-wrap' is enabled, you might want to reduce the value of this. + +Don't set this to a non-nil value when `visual-line-mode' is +turned on, as it could produce confusing results. */); Vtruncate_partial_width_windows = make_fixnum (50); DEFVAR_BOOL("word-wrap-by-category", word_wrap_by_category, doc: /* commit a8de88e3300464eb382a65ea96da69f23d21ead2 Author: Lars Ingebrigtsen Date: Sat Sep 4 11:14:12 2021 +0200 Allow killing the diff buffer after `C-x v u' * doc/emacs/maintaining.texi (VC Undo): Document this. * lisp/vc/vc.el (vc-revert-show-diff): Allow a `kill' value. (vc-revert): Use it (bug#16902). diff --git a/doc/emacs/maintaining.texi b/doc/emacs/maintaining.texi index 008639d1a9..d17c6d3e75 100644 --- a/doc/emacs/maintaining.texi +++ b/doc/emacs/maintaining.texi @@ -1136,13 +1136,17 @@ Revert the work file(s) in the current VC fileset to the last revision @findex vc-revert @vindex vc-revert-show-diff If you want to discard all the changes you have made to the current -VC fileset, type @kbd{C-x v u} (@code{vc-revert}). This shows -you a diff between the work file(s) and the revision from which you -started editing, and asks for confirmation for discarding the changes. -If you agree, the fileset is reverted. If you don't want @kbd{C-x v -u} to show a diff, set the variable @code{vc-revert-show-diff} to -@code{nil} (you can still view the diff directly with @kbd{C-x v =}; -@pxref{Old Revisions}). +VC fileset, type @kbd{C-x v u} (@code{vc-revert}). This will ask you +for confirmation before discarding the changes. If you agree, the +fileset is reverted. + + If @code{vc-revert-show-diff} is non-@code{nil}, this command will +show you a diff between the work file(s) and the revision from which +you started editing. Afterwards, the diff buffer will either be +killed (if this variable is @code{kill}), or the buffer will be buried +(any other non-@code{nil} value). If you don't want @kbd{C-x v u} to +show a diff, set this variable to @code{nil} (you can still view the +diff directly with @kbd{C-x v =}; @pxref{Old Revisions}). On locking-based version control systems, @kbd{C-x v u} leaves files unlocked; you must lock again to resume editing. You can also use diff --git a/etc/NEWS b/etc/NEWS index ec81541e65..506eaab0fc 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -997,6 +997,11 @@ keys, add the following to your init file: ** Change Logs and VC ++++ +*** 'vc-revert-show-diff' now has a third possible value: 'kill'. +If this variable is 'kill', then the diff buffer will be killed after +the 'vc-revert' action instead of buried. + *** More VC commands can be used from non-file buffers. The relevant commands are those that don't change the VC state. The non-file buffers which can use VC commands are those that have diff --git a/lisp/vc/vc.el b/lisp/vc/vc.el index 8036be390a..f6ae27075f 100644 --- a/lisp/vc/vc.el +++ b/lisp/vc/vc.el @@ -860,7 +860,9 @@ See `run-hooks'." (defcustom vc-revert-show-diff t "If non-nil, `vc-revert' shows a `vc-diff' buffer before querying." - :type 'boolean + :type '(choice (const :tag "Show and bury afterwards" t) + (const :tag "Show and kill afterwards" kill) + (const :tag "Don't show" nil)) :version "24.1") ;; Header-insertion hair @@ -2757,7 +2759,7 @@ to the working revision (except for keyword expansion)." (if (= nfiles 1) "" "s")))))) (error "Revert canceled"))) (when diff-buffer - (quit-windows-on diff-buffer))) + (quit-windows-on diff-buffer (eq vc-revert-show-diff 'kill)))) (dolist (file files) (message "Reverting %s..." (vc-delistify files)) (vc-revert-file file) commit 56c98a4ad886376b3c73d6c8b9a96f6bca8f0f48 Author: Lars Ingebrigtsen Date: Sat Sep 4 10:38:50 2021 +0200 Improve error message in ielm on printing errors * lisp/ielm.el (ielm-eval-input): Don't claim that there's a bug on pp -- it may just be something that nests too far (bug#18012). diff --git a/lisp/ielm.el b/lisp/ielm.el index fd8dac74b7..39820a893a 100644 --- a/lisp/ielm.el +++ b/lisp/ielm.el @@ -440,8 +440,7 @@ nonempty, then flushes the buffer." (concat (buffer-string) aux)))))) (error (setq error-type "IELM Error") - (setq result (format "Error during pretty-printing (bug in pp): %S" - err))) + (setq result (format "Error during pretty-printing: %S" err))) (quit (setq error-type "IELM Error") (setq result "Quit during pretty-printing")))) (if error-type commit 239ca285f906173e547d65c4cf37b438ca88a615 Author: Lars Ingebrigtsen Date: Sat Sep 4 10:19:39 2021 +0200 Add a customization group link from whitespace-mode * lisp/whitespace.el (whitespace-mode): Add a link to the whitespace customization group to see the faces (bug#18296). diff --git a/lisp/whitespace.el b/lisp/whitespace.el index a2dc6ab981..a3a127474d 100644 --- a/lisp/whitespace.el +++ b/lisp/whitespace.el @@ -924,7 +924,10 @@ Any other value is treated as nil." "Toggle whitespace visualization (Whitespace mode). See also `whitespace-style', `whitespace-newline' and -`whitespace-display-mappings'." +`whitespace-display-mappings'. + +This mode uses a number of faces to visualize the whitespace; see +the customization group `whitespace' for details." :lighter " ws" :init-value nil :global nil commit 3f999c03c2842c72b832b7f59ba4c45c0ec725be Author: Lars Ingebrigtsen Date: Sat Sep 4 10:19:03 2021 +0200 Add support for customization group hyperlinks in doc strings * lisp/help-mode.el (help-customization-group): New button. (help-xref-customization-group-regexp): New const. (help-make-xrefs): Use them to allow making customization group buttons. diff --git a/doc/lispref/tips.texi b/doc/lispref/tips.texi index 8aa225a00c..f0eb1079ca 100644 --- a/doc/lispref/tips.texi +++ b/doc/lispref/tips.texi @@ -755,6 +755,14 @@ anchor}. The Info file name defaults to @samp{emacs}. For example, See Info node `Font Lock' and Info node `(elisp)Font Lock Basics'. @end smallexample +To link to a customization group, write the single-quoted name of the +group, preceded by @samp{customization group} (the first character in +each word is case-insensitive). For example, + +@smallexample +See the customization group `whitespace' for details. +@end smallexample + Finally, to create a hyperlink to URLs, write the single-quoted URL, preceded by @samp{URL}. For example, diff --git a/etc/NEWS b/etc/NEWS index a7b6d90492..ec81541e65 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -3442,6 +3442,12 @@ The former is now declared obsolete. * Lisp Changes in Emacs 28.1 ++++ +*** Doc strings can now link to customization groups. +Text like "customization group 'whitespace'" will be made into a +button. When clicked, it'll take the user to a Custom buffer +displaying that customization group. + +++ *** New macro 'with-existing-directory'. This macro binds 'default-directory' to some other existing directory diff --git a/lisp/help-mode.el b/lisp/help-mode.el index 87f26651e0..08182b71be 100644 --- a/lisp/help-mode.el +++ b/lisp/help-mode.el @@ -228,6 +228,11 @@ The format is (FUNCTION ARGS...).") 'help-function #'info 'help-echo (purecopy "mouse-2, RET: read this Info node")) +(define-button-type 'help-customization-group + :supertype 'help-xref + 'help-function #'customize-group + 'help-echo (purecopy "mouse-2, RET: display this customization group")) + (define-button-type 'help-url :supertype 'help-xref 'help-function #'browse-url @@ -437,6 +442,10 @@ when help commands related to multilingual environment (e.g., "\\<[Ii]nfo[ \t\n]+\\(node\\|anchor\\)[ \t\n]+['`‘]\\([^'’]+\\)['’]") "Regexp matching doc string references to an Info node.") +(defconst help-xref-customization-group-regexp + (purecopy "\\<[Cc]ustomization[ \t\n]+[Gg]roup[ \t\n]+['`‘]\\([^'’]+\\)['’]") + "Regexp matching doc string references to a customization group.") + (defconst help-xref-url-regexp (purecopy "\\<[Uu][Rr][Ll][ \t\n]+['`‘]\\([^'’]+\\)['’]") "Regexp matching doc string references to a URL.") @@ -543,6 +552,12 @@ that." (setq data ;; possible newlines if para filled (replace-regexp-in-string "[ \t\n]+" " " data t t))) (help-xref-button 2 'help-info data)))) + ;; Customization groups. + (save-excursion + (while (re-search-forward + help-xref-customization-group-regexp nil t) + (help-xref-button 1 'help-customization-group + (intern (match-string 1))))) ;; URLs (save-excursion (while (re-search-forward help-xref-url-regexp nil t) commit 7e7723796c2c9b46302d1d036e9ef54b9727113e Author: Lars Ingebrigtsen Date: Sat Sep 4 09:34:29 2021 +0200 Make multi-frame `M-x calendar' setup work when `pop-up-frames' * lisp/calendar/calendar.el (calendar): Make the calendar frame setup work when pop-up-frames is non-nil (bug#19256). diff --git a/lisp/calendar/calendar.el b/lisp/calendar/calendar.el index 76d6132eae..7c929ebed0 100644 --- a/lisp/calendar/calendar.el +++ b/lisp/calendar/calendar.el @@ -1308,7 +1308,9 @@ This function is suitable for execution in an init file." ;; Avoid loading cal-x unless it will be used. (if (and (memq calendar-setup '(one-frame two-frames calendar-only)) (display-multi-frame-p)) - (calendar-frame-setup calendar-setup arg) + ;; Calendar does its own frame setup. + (let ((pop-up-frames nil)) + (calendar-frame-setup calendar-setup arg)) (calendar-basic-setup arg))) (defun calendar-basic-setup (&optional arg nodisplay) commit 7ca949b7ef9f1efbeaccd459f8ef49cd971b8e8c Author: Lars Ingebrigtsen Date: Sat Sep 4 09:11:37 2021 +0200 Tweak hi-lock-mode doc string * lisp/hi-lock.el (hi-lock-mode): Tweak the doc string so that running hi-lock-mode in a *Help* buffer showing this help text won't issue an error (bug#20977). diff --git a/lisp/hi-lock.el b/lisp/hi-lock.el index 37b88b318d..4c924e9d52 100644 --- a/lisp/hi-lock.el +++ b/lisp/hi-lock.el @@ -344,9 +344,9 @@ which can be called interactively, are: When hi-lock is started and if the mode is not excluded or patterns rejected, the beginning of the buffer is searched for lines of the form: - Hi-lock: FOO + Hi-lock: (FOO ...) -where FOO is a list of patterns. The patterns must start before +where (FOO ...) is a list of patterns. The patterns must start before position \(number of characters into buffer) `hi-lock-file-patterns-range'. Patterns will be read until Hi-lock: end is found. A mode is excluded if it's in the list @@ -818,7 +818,7 @@ SPACES-REGEXP is a regexp to substitute spaces in font-lock search." (not (looking-at "\\s-*end"))) (condition-case nil (setq all-patterns (append (read (current-buffer)) all-patterns)) - (error (message "Invalid pattern list expression at %d" + (error (message "Invalid pattern list expression at line %d" (line-number-at-pos))))))) (when (and all-patterns hi-lock-mode commit c6b1f8daa74b2a7061ba8a378c92bdab870c25f4 Author: Lars Ingebrigtsen Date: Sat Sep 4 08:59:14 2021 +0200 Make `M-x term' offer completion * lisp/term.el (term): Have completion in the prompt (bug#21296). diff --git a/lisp/term.el b/lisp/term.el index b3870a814d..0bcd095283 100644 --- a/lisp/term.el +++ b/lisp/term.el @@ -1429,10 +1429,10 @@ The buffer is in Term mode; see `term-mode' for the commands to use in that buffer. \\Type \\[switch-to-buffer] to switch to another buffer." - (interactive (list (read-from-minibuffer "Run program: " - (or explicit-shell-file-name - (getenv "ESHELL") - shell-file-name)))) + (interactive (list (read-shell-command "Run program: " + (or explicit-shell-file-name + (getenv "ESHELL") + shell-file-name)))) (set-buffer (make-term "terminal" program)) (term-mode) (term-char-mode) commit ca7e76c6f98cb09a686bcda7890ca10fd374fb4f Author: Yuchen Pei Date: Sat Sep 4 08:28:57 2021 +0200 Add diary-offset to diary-lib.el * doc/emacs/calendar.texi: Document the change. * lisp/calendar/diary-lib.el (diary-offset): * test/lisp/calendar/icalendar-tests.el: Add a test (bug#50195). diff --git a/doc/emacs/calendar.texi b/doc/emacs/calendar.texi index 3750e78e70..18de721e28 100644 --- a/doc/emacs/calendar.texi +++ b/doc/emacs/calendar.texi @@ -1363,6 +1363,20 @@ the 11 above to @samp{'(1 2 3)} and have the entry apply to the last Thursday of January, February, and March. If the month is @code{t}, the entry applies to all months of the year. +@findex diary-offset +@example +%%(diary-offset '(diary-float t 3 4) 2) Monthly committee meeting +@end example + +@noindent +This entry applies to the Saturday after the third Thursday of each +month. The 2 specifies number of days after when the sexp +@w{@code{'(diary-float t 3 4)}} would evaluate to @code{t}. This is +useful when for example your organization has a committee meeting two +days after every monthly meeting which takes place on the third +Thursday, or if you would like to attend a virtual meeting scheduled +in a different timezone causing a difference in the date. + Each of the standard sexp diary entries takes an optional parameter specifying the name of a face or a single-character string to use when marking the entry in the calendar. Most generally, sexp diary entries diff --git a/etc/NEWS b/etc/NEWS index 3fede93eae..a7b6d90492 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -2814,6 +2814,14 @@ never be narrower than 19 characters. 'gomoku-move-sw' and 'gomoku-move-ne' now work correctly, and horizontal movements now stop at the edge of the board. ++++ +*** New diary sexp 'diary-offset'. +It offsets another diary sexp by a number of days. This is useful +when for example your organization has a committee meeting two days +after every monthly meeting which takes place on the third Thursday, +or if you would like to attend a virtual meeting scheduled in a +different timezone causing a difference in the date. + ** xterm-mouse mode --- diff --git a/lisp/calendar/diary-lib.el b/lisp/calendar/diary-lib.el index f57fe26058..9ca7ce3f00 100644 --- a/lisp/calendar/diary-lib.el +++ b/lisp/calendar/diary-lib.el @@ -2014,6 +2014,17 @@ string to use when highlighting the day in the calendar." (and (>= diff 0) (zerop (% diff n)) (cons mark (format entry cycle (diary-ordinal-suffix cycle)))))) +;; To be called from diary-sexp-entry, where DATE, ENTRY are bound. +(defun diary-offset (sexp days) + "Offsetted diary entry. Offsets SEXP by DAYS days. +Entry applies if the date is DAYS days after another diary-sexp SEXP." + (with-no-warnings (defvar date)) + (unless (integerp days) + (user-error "Days must be an integer")) + (let ((date (calendar-gregorian-from-absolute + (- (calendar-absolute-from-gregorian date) days)))) + (eval sexp))) + (defun diary-day-of-year () "Day of year and number of days remaining in the year of date diary entry." (with-no-warnings (defvar date)) diff --git a/test/lisp/calendar/icalendar-tests.el b/test/lisp/calendar/icalendar-tests.el index 6973f7e5c9..de2a891758 100644 --- a/test/lisp/calendar/icalendar-tests.el +++ b/test/lisp/calendar/icalendar-tests.el @@ -1442,6 +1442,13 @@ RRULE:FREQ=YEARLY;INTERVAL=1;BYMONTH=09;BYMONTHDAY=21 SUMMARY:ff birthday (%d years old)") + (icalendar-tests--test-export + nil + nil + "%%(diary-offset '(diary-float t 3 4) 1) asdf" + nil) + + ;; FIXME! ;; export 2004-10-28 monthly, weekly entries commit f9dcde3906b9c764b794d580d4d24691979f7d81 Author: Stefan Kangas Date: Sat Sep 4 09:05:22 2021 +0200 * etc/DISTRIB: Refer to gnu.org instead of the deleted file etc/GNU. diff --git a/etc/DISTRIB b/etc/DISTRIB index 610c347289..3dd1bf3d98 100644 --- a/etc/DISTRIB +++ b/etc/DISTRIB @@ -73,8 +73,7 @@ you can contribute. Your donations will help to support the development of additional GNU software. GNU/Linux systems (variants of GNU, based on the kernel Linux) have millions of users, but there is still much to be done. -For more information on GNU, see the file 'GNU' in this directory (see -above). +For more information on GNU, visit https://www.gnu.org/. Richard M Stallman Chief GNUisance, Founder of the FSF commit e1050492d1daa7a4059b99fa0587b80cd781d088 Author: Glenn Morris Date: Fri Sep 3 08:45:16 2021 -0700 * doc/misc/efaq.texi (Reporting bugs): Refer to the Emacs manual. That is better than having a separate, outdated text. diff --git a/doc/misc/efaq.texi b/doc/misc/efaq.texi index c0536e0e3a..c718e34433 100644 --- a/doc/misc/efaq.texi +++ b/doc/misc/efaq.texi @@ -415,27 +415,16 @@ archive the @code{gnu.*} groups. @cindex How to submit a bug report @cindex Reporting bugs -The correct way to report Emacs bugs is to use the command -@kbd{M-x report-emacs-bug}. It sets up a mail buffer with the -essential information and the correct e-mail address, -@email{bug-gnu-emacs@@gnu.org}. -Anything sent there also appears in the -newsgroup @uref{news:gnu.emacs.bug}, but please use e-mail instead of -news to submit the bug report. This ensures a reliable return address -so you can be contacted for further details. - -Be sure to read the ``Bugs'' section of the Emacs manual before reporting -a bug! The manual describes in detail how to submit a useful bug -report (@pxref{Bugs, , Reporting Bugs, emacs, The GNU Emacs Manual}). -(@xref{Emacs manual}, if you don't know how to read the manual.) - -RMS says: +Please see the Emacs manual for information on how to report bugs. +@xref{Checklist, , Checklist for Bug Reports, emacs, The GNU Emacs Manual}. + +It is better to report bugs as described there than to ask on the help +mailing list. RMS says: @quotation Sending bug reports to @url{https://lists.gnu.org/mailman/listinfo/help-gnu-emacs, -the help-gnu-emacs mailing list} -(which has the effect of posting on @uref{news:gnu.emacs.help}) is +the help-gnu-emacs mailing list} is undesirable because it takes the time of an unnecessarily large group of people, most of whom are just users and have no idea how to fix these problem. @@ -445,12 +434,12 @@ more likely to know what to do and have expressed a wish to receive more messages about Emacs than the others. @end quotation -RMS says it is sometimes fine to post to @uref{news:gnu.emacs.help}: +RMS says it is sometimes fine to post to the help list: @quotation If you have reported a bug and you don't hear about a possible fix, then after a suitable delay (such as a week) it is okay to post on -@code{gnu.emacs.help} asking if anyone can help you. +the help list asking if anyone can help you. @end quotation If you are unsure whether you have found a bug, consider the following commit b66d4616f0a19ac1d7e49adc4d9b536d12e40c4a Merge: e32c7d2a8d 0aa0410372 Author: Glenn Morris Date: Fri Sep 3 07:50:25 2021 -0700 Merge from origin/emacs-27 0aa0410372 (origin/emacs-27, emacs-27) Fix "Finder" description for m... commit e32c7d2a8d1635af5234a8ceabbdbe911abc9a7b Author: Augusto Stoffel Date: Fri Sep 3 14:26:51 2021 +0200 Change Python eval to send directly instead of using temporary files * lisp/progmodes/python.el (python-shell-eval-setup-code): New const for setting up eval (bug#49822). (python-shell--encode-string): New function. (python-shell-send-string): Use it to send commands directly instead of writing to a temporary file. (python-shell-send-string-no-output): Adjust sending. (python-shell-send-file): Ditto. diff --git a/lisp/progmodes/python.el b/lisp/progmodes/python.el index d5209d8d2f..306cc3a542 100644 --- a/lisp/progmodes/python.el +++ b/lisp/progmodes/python.el @@ -3081,6 +3081,45 @@ there for compatibility with CEDET.") (delete-trailing-whitespace)) temp-file-name)) +(defconst python-shell-eval-setup-code + "\ +def __PYTHON_EL_eval(source, filename): + import ast, sys + if sys.version_info[0] == 2: + from __builtin__ import compile, eval, globals + else: + from builtins import compile, eval, globals + sys.stdout.write('\\n') + try: + p, e = ast.parse(source, filename), None + except SyntaxError: + t, v, tb = sys.exc_info() + sys.excepthook(t, v, tb.tb_next) + return + if p.body and isinstance(p.body[-1], ast.Expr): + e = p.body.pop() + try: + g = globals() + exec(compile(p, filename, 'exec'), g, g) + if e: + return eval(compile(ast.Expression(e.value), filename, 'eval'), g, g) + except Exception: + t, v, tb = sys.exc_info() + sys.excepthook(t, v, tb.tb_next)" + "Code used to evaluate statements in inferior Python processes.") + +(defalias 'python-shell--encode-string + (let ((fun (if (and (fboundp 'json-serialize) + (>= emacs-major-version 28)) + 'json-serialize + (require 'json) + 'json-encode-string))) + (lambda (text) + (if (stringp text) + (funcall fun text) + (signal 'wrong-type-argument (list 'stringp text))))) + "Encode TEXT as a valid Python string.") + (defun python-shell-send-string (string &optional process msg) "Send STRING to inferior Python PROCESS. When optional argument MSG is non-nil, forces display of a @@ -3088,16 +3127,12 @@ user-friendly message if there's no process running; defaults to t when called interactively." (interactive (list (read-string "Python command: ") nil t)) - (let ((process (or process (python-shell-get-process-or-error msg)))) - (if (string-match ".\n+." string) ;Multiline. - (let* ((temp-file-name (with-current-buffer (process-buffer process) - (python-shell--save-temp-file string))) - (file-name (or (buffer-file-name) temp-file-name))) - (python-shell-send-file file-name process temp-file-name t)) - (comint-send-string process string) - (when (or (not (string-match "\n\\'" string)) - (string-match "\n[ \t].*\n?\\'" string)) - (comint-send-string process "\n"))))) + (comint-send-string + (or process (python-shell-get-process-or-error msg)) + (format "exec(%s);__PYTHON_EL_eval(%s, %s)\n" + (python-shell--encode-string python-shell-eval-setup-code) + (python-shell--encode-string string) + (python-shell--encode-string (or (buffer-file-name) ""))))) (defvar python-shell-output-filter-in-progress nil) (defvar python-shell-output-filter-buffer nil) @@ -3139,7 +3174,8 @@ Return the output." (inhibit-quit t)) (or (with-local-quit - (python-shell-send-string string process) + (comint-send-string + process (format "exec(%s)\n" (python-shell--encode-string string))) (while python-shell-output-filter-in-progress ;; `python-shell-output-filter' takes care of setting ;; `python-shell-output-filter-in-progress' to NIL after it @@ -3362,7 +3398,8 @@ t when called interactively." (temp-file-name (when temp-file-name (file-local-name (expand-file-name temp-file-name))))) - (python-shell-send-string + (comint-send-string + process (format (concat "import codecs, os;" @@ -3372,8 +3409,7 @@ t when called interactively." (when (and delete temp-file-name) (format "os.remove('''%s''');" temp-file-name)) "exec(compile(__code, '''%s''', 'exec'));") - (or temp-file-name file-name) encoding encoding file-name) - process))) + (or temp-file-name file-name) encoding encoding file-name)))) (defun python-shell-switch-to-shell (&optional msg) "Switch to inferior Python process buffer. commit 34550b44924cac96ece0ae0cd215dea433dd863a Author: Theodor Thornhill Date: Fri Sep 3 12:21:49 2021 +0200 Update to CSS Flexible Box Layout Module Level 2 * css-mode.el (css-property-alist): Update link. diff --git a/lisp/textmodes/css-mode.el b/lisp/textmodes/css-mode.el index a39a62aa68..d57f2d5493 100644 --- a/lisp/textmodes/css-mode.el +++ b/lisp/textmodes/css-mode.el @@ -323,8 +323,8 @@ ("place-items" align-items justify-items) ("place-self" justify-self align-self) - ;; CSS Flexible Box Layout Module Level 1 - ;; (https://www.w3.org/TR/css-flexbox-1/#property-index) + ;; CSS Flexible Box Layout Module Level 2 + ;; (https://www.w3.org/TR/css-flexbox-2/#property-index) ("flex" "none" flex-grow flex-shrink flex-basis) ("flex-basis" "auto" "content" width) ("flex-direction" "row" "row-reverse" "column" "column-reverse") commit 0a7424360ceb939364efe41c4d46869ed9793bed Author: Theodor Thornhill Date: Fri Sep 3 12:19:36 2021 +0200 Update to CSS Containment Module Level 2 * css-mode.el (css-property-alist): Update contain, and add content-visibility. diff --git a/lisp/textmodes/css-mode.el b/lisp/textmodes/css-mode.el index 8689c94bc5..a39a62aa68 100644 --- a/lisp/textmodes/css-mode.el +++ b/lisp/textmodes/css-mode.el @@ -274,9 +274,10 @@ ("color" color) ("opacity" alphavalue) - ;; CSS Containment Module Level 1 - ;; (https://www.w3.org/TR/css-contain-1/#property-index) - ("contain" "none" "strict" "content" "size" "layout" "paint") + ;; CSS Containment Module Level 2 + ;; (https://www.w3.org/TR/css-contain-2/#property-index) + ("contain" "none" "strict" "content" "size" "layout" "style" "paint") + ("content-visibility" "visible" "auto" "hidden") ;; CSS Grid Layout Module Level 2 ;; (https://www.w3.org/TR/css-grid-2/#property-index) commit 538a401b0c0ac245ad99b07605f0a69325eb511c Author: Theodor Thornhill Date: Fri Sep 3 12:14:32 2021 +0200 Update to CSS Grid Layout Module Level 2 * css-mode.el (css-property-alist): Update to the newer spec, and add the subgrid keywords diff --git a/lisp/textmodes/css-mode.el b/lisp/textmodes/css-mode.el index c2086d2fd3..8689c94bc5 100644 --- a/lisp/textmodes/css-mode.el +++ b/lisp/textmodes/css-mode.el @@ -278,8 +278,8 @@ ;; (https://www.w3.org/TR/css-contain-1/#property-index) ("contain" "none" "strict" "content" "size" "layout" "paint") - ;; CSS Grid Layout Module Level 1 - ;; (https://www.w3.org/TR/css-grid-1/#property-index) + ;; CSS Grid Layout Module Level 2 + ;; (https://www.w3.org/TR/css-grid-2/#property-index) ("grid" grid-template grid-template-rows "auto-flow" "dense" grid-auto-columns grid-auto-rows grid-template-columns) ("grid-area" grid-line) @@ -298,8 +298,8 @@ ("grid-template" "none" grid-template-rows grid-template-columns line-names string track-size line-names explicit-track-list) ("grid-template-areas" "none" string) - ("grid-template-columns" "none" track-list auto-track-list) - ("grid-template-rows" "none" track-list auto-track-list) + ("grid-template-columns" "none" track-list auto-track-list "subgrid") + ("grid-template-rows" "none" track-list auto-track-list "subgrid") ;; CSS Box Alignment Module Level 3 ;; (https://www.w3.org/TR/css-align-3/#property-index) commit 1778c90b57c7536e38c50b0eafd7040e0d1236ee Author: Theodor Thornhill Date: Fri Sep 3 12:07:47 2021 +0200 Clean up css-property-alist for alignment * css-mode.el (css-property-alist, css-value-class-alist): Provide new position related entries for use in css-property-alist. Make sure that property-alist reflect the spec: https://www.w3.org/TR/css-align-3/#property-index diff --git a/lisp/textmodes/css-mode.el b/lisp/textmodes/css-mode.el index f406afb7b6..c2086d2fd3 100644 --- a/lisp/textmodes/css-mode.el +++ b/lisp/textmodes/css-mode.el @@ -302,34 +302,25 @@ ("grid-template-rows" "none" track-list auto-track-list) ;; CSS Box Alignment Module Level 3 - ;; (https://www.w3.org/TR/css-align-3/#alignment-values) - ("align-content" "center" "start" "end" "flex-start" "flex-end" - "normal" "first" "last" "baseline" "space-between" "space-around" - "space-evenly" "stretch" "safe" "unsafe") - ("align-items" "normal" "stretch" "center" "start" "end" - "flex-start" "flex-end" "baseline" "first" "last" "baseline" - "safe" "unsafe") - ("align-self" "auto" "normal" "center" "start" "end" - "self-start" "self-end" "flex-start" "flex-end" - "baseline" "first" "last" "stretch" "safe" "unsafe") - ("justify-content" "center" "start" "end" "flex-start" "flex-end" - "left" "right" "normal" "space-between" "space-around" - "space-evenly" "stretch" "safe" "unsafe") - ("justify-items" "auto" "normal" "stretch" "center" "start" "end" - "flex-start" "flex-end" "self-start" "self-end" "left" "right" - "baseline" "first" "last" "legacy" "safe" "unsafe") - ("justify-self" "auto" "normal" "stretch" "center" "start" "end" - "flex-start" "flex-end" "self-start" "self-end" "left" "right" - "baseline" "first" "last" "safe" "unsafe") - ("place-content" "center" "start" "end" "left" "right" "flex-start" - "flex-end" "baseline" "first" "last" "space-evenly" "space-around" - "space-between") - ("place-items" "auto" "normal" "center" "start" "end" - "self-start" "self-end" "flex-start" "flex-end" - "left" "right" "baseline" "first" "last" "stretch") - ("place-self" "auto" "center" "start" "end" "self-start" "self-end" - "flex-start" "flex-end" "normal" "left" "right" "baseline" - "first" "last" "stretch") + ;; (https://www.w3.org/TR/css-align-3/#property-index) + ("align-content" + baseline-position content-distibution overflow-position content-position) + ("align-items" + "normal" "stretch" baseline-position overflow-position self-position) + ("align-self" + "auto" "normal" "stretch" + baseline-position overflow-position self-position) + ("justify-content" "normal" + content-distibution overflow-position content-position "left" "right") + ("justify-items" + "normal" "stretch" baseline-position overflow-position self-position + "left" "right" "legacy") + ("justify-self" + "auto" "normal" "stretch" baseline-position overflow-position self-position + "left" "right") + ("place-content" align-content justify-content) + ("place-items" align-items justify-items) + ("place-self" justify-self align-self) ;; CSS Flexible Box Layout Module Level 1 ;; (https://www.w3.org/TR/css-flexbox-1/#property-index) @@ -779,6 +770,13 @@ further value candidates, since that list would be infinite.") (padding-width length percentage) (position "left" "center" "right" "top" "bottom" percentage length) + (baseline-position "left" "right" "baseline") + (content-distribution + "space-between" "space-around" "space-evenly" "stretch") + (overflow-position "unsafe" "safe") + (content-position "center" "start" "end" "flex-start" "flex-end") + (self-position + "center" "start" "end" "self-start" "self-end" "flex-start" "flex-end") (radial-gradient "radial-gradient()") (relative-size "larger" "smaller") (repeat-style commit d0eaf7a3cf6875703179cd7a0c10f724ada9b34d Author: Lars Ingebrigtsen Date: Fri Sep 3 13:48:44 2021 +0200 Fix `describe-function' for autoloaded adviced functions * lisp/emacs-lisp/nadvice.el (advice--make-single-doc): Factor out. (advice--make-docstring): From here (bug#23523). Also include advices for autoloads. diff --git a/lisp/emacs-lisp/nadvice.el b/lisp/emacs-lisp/nadvice.el index bb86fa1264..41a9c7242b 100644 --- a/lisp/emacs-lisp/nadvice.el +++ b/lisp/emacs-lisp/nadvice.el @@ -85,41 +85,50 @@ Each element has the form (WHERE BYTECODE STACK) where: (if (eq bytecode (cadr elem)) (setq where (car elem)))) where)) +(defun advice--make-single-doc (flist function macrop) + (let ((where (advice--where flist))) + (concat + (format "This %s has %s advice: " + (if macrop "macro" "function") + where) + (let ((fun (advice--car flist))) + (if (symbolp fun) (format-message "`%S'." fun) + (let* ((name (cdr (assq 'name (advice--props flist)))) + (doc (documentation fun t)) + (usage (help-split-fundoc doc function))) + (if usage (setq doc (cdr usage))) + (if name + (if doc + (format "%s\n%s" name doc) + (format "%s" name)) + (or doc "No documentation"))))) + "\n"))) + (defun advice--make-docstring (function) "Build the raw docstring for FUNCTION, presumably advised." (let* ((flist (indirect-function function)) (docfun nil) (macrop (eq 'macro (car-safe flist))) (docstring nil)) - (if macrop (setq flist (cdr flist))) - (while (advice--p flist) - (let ((doc (aref flist 4)) - (where (advice--where flist))) + (when macrop + (setq flist (cdr flist))) + (if (and (autoloadp flist) + (get function 'advice--pending)) + (setq docstring + (advice--make-single-doc (get function 'advice--pending) + function macrop)) + (while (advice--p flist) ;; Hack attack! For advices installed before calling ;; Snarf-documentation, the integer offset into the DOC file will not ;; be installed in the "core unadvised function" but in the advice ;; object instead! So here we try to undo the damage. - (if (integerp doc) (setq docfun flist)) - (setq docstring - (concat - docstring - (format "This %s has %s advice: " - (if macrop "macro" "function") - where) - (let ((fun (advice--car flist))) - (if (symbolp fun) (format-message "`%S'." fun) - (let* ((name (cdr (assq 'name (advice--props flist)))) - (doc (documentation fun t)) - (usage (help-split-fundoc doc function))) - (if usage (setq doc (cdr usage))) - (if name - (if doc - (format "%s\n%s" name doc) - (format "%s" name)) - (or doc "No documentation"))))) - "\n"))) - (setq flist (advice--cdr flist))) - (unless docfun (setq docfun flist)) + (when (integerp (aref flist 4)) + (setq docfun flist)) + (setq docstring (concat docstring (advice--make-single-doc + flist function macrop)) + flist (advice--cdr flist)))) + (unless docfun + (setq docfun flist)) (let* ((origdoc (unless (eq function docfun) ;Avoid inf-loops. (documentation docfun t))) (usage (help-split-fundoc origdoc function))) commit 6dad558a9d3478adf3ece5b83a0710ffa6fc5bc9 Author: Lars Ingebrigtsen Date: Fri Sep 3 12:44:18 2021 +0200 Allow gud-mi to edit two executables with the same name * lisp/progmodes/gud.el (gud-common-init): Allow editing two executables with the same name (bug#22772). diff --git a/lisp/progmodes/gud.el b/lisp/progmodes/gud.el index 021c5a314c..d8c77f7f23 100644 --- a/lisp/progmodes/gud.el +++ b/lisp/progmodes/gud.el @@ -2780,14 +2780,24 @@ Commands: (expand-file-name file-subst) file-subst))) (filepart (and file-word (concat "-" (file-name-nondirectory file)))) - (existing-buffer (get-buffer (concat "*gud" filepart "*")))) + (buffer-name (concat "*gud" filepart "*")) + (existing-buffer (get-buffer buffer-name)) + error) + (when (and existing-buffer + (get-buffer-process existing-buffer)) + (if (equal (buffer-local-value 'default-directory existing-buffer) + default-directory) + ;; We're already debugging this executable. + (setq error t) + ;; Open a new window to debug an executable with the same name. + (setq buffer-name (generate-new-buffer-name buffer-name)))) (select-window (display-buffer - (get-buffer-create (concat "*gud" filepart "*")) + (get-buffer-create buffer-name) '((display-buffer-reuse-window display-buffer-in-previous-window display-buffer-same-window display-buffer-pop-up-window)))) - (when (and existing-buffer (get-buffer-process existing-buffer)) + (when error (error "This program is already being debugged")) ;; Set the dir, in case the buffer already existed with a different dir. (setq default-directory dir) @@ -2809,8 +2819,12 @@ Commands: (setq w (cdr w))) ;; Tramp has already been loaded if we are here. (if w (setcar w (setq file (file-local-name file))))) - (apply #'make-comint (concat "gud" filepart) program nil - (if massage-args (funcall massage-args file args) args)) + (apply #'make-comint-in-buffer + (concat "gud" filepart) (current-buffer) + program nil + (if massage-args + (funcall massage-args file args) + args)) ;; Since comint clobbered the mode, we don't set it until now. (gud-mode) (setq-local gud-target-name commit 0cabf8bc363cdeace84523b251752c0aac32b31b Author: Stefan Kangas Date: Fri Sep 3 11:13:53 2021 +0200 ; Fix typos diff --git a/ChangeLog.2 b/ChangeLog.2 index 7b40c54dc6..3e227675e0 100644 --- a/ChangeLog.2 +++ b/ChangeLog.2 @@ -35670,7 +35670,7 @@ 2015-04-08 Artur Malabarba * lisp/emacs-lisp/package.el (package-menu-mode): Mode-line notification - while dowloading information. + while downloading information. * lisp/emacs-lisp/package.el: More conservative `ensure-init-file' (package--ensure-init-file): Check file contents before visiting. diff --git a/ChangeLog.3 b/ChangeLog.3 index 8b872a0726..9ec19e91d7 100644 --- a/ChangeLog.3 +++ b/ChangeLog.3 @@ -33355,9 +33355,9 @@ Fix the handling of font backend supersedence on MS-Windows * src/w32font.c (syms_of_w32font): Don't make the Uniscribe - font backend "superceded" here, ... + font backend "superseded" here, ... * src/w32uniscribe.c (syms_of_w32uniscribe_for_pdumper): - ... make it "superceded" here, only if the HarfBuzz DLL was + ... make it "superseded" here, only if the HarfBuzz DLL was successfully loaded. This is because Emacs compiled with HarfBuzz support might run on a system without the DLL. * src/w32fns.c (Fx_create_frame, w32_create_tip_frame): @@ -36933,7 +36933,7 @@ electric--sort-post-self-insertion-hook. * lisp/emacs-lisp/syntax.el (syntax-propertize, syntax-ppss): - Use new `depth` arg to make sure noone accidentally gets added + Use new `depth` arg to make sure no one accidentally gets added after syntax-ppss-flush-cache. * doc/lispref/modes.texi (Setting Hooks): Document new `depth` arg. @@ -58138,7 +58138,7 @@ Use bignums when Emacs converts to and from system types like off_t for file sizes whose values can exceed fixnum range. - Formerly, Emacs sometimes generted floats and sometimes ad-hoc + Formerly, Emacs sometimes generated floats and sometimes ad-hoc conses of integers. Emacs still accepts floats and conses for these system types, in case some stray Lisp code is generating them, though this usage is obsolescent. @@ -133272,7 +133272,7 @@ (g_b_init_compare_string_w): Move declaration to file scope. * src/w32heap.c (dumped_data_commit): Now static. (FREEABLE_P): Avoid warnings about pointer comparison with integer. - (mmap_realloc): Cast to 'char *' for arithmetics on void pointers. + (mmap_realloc): Cast to 'char *' for arithmetic on void pointers. * src/w32console.c (ctrl_c_handler, sys_tputs, sys_tgetstr) (evalcost, cmputc, cmcheckmagic, cmcostinit, cmgoto, Wcm_clear): Provide prototypes. @@ -144146,7 +144146,7 @@ Move package test files to new directory. - * test/lisp/emacs-lisp/package-tests.el: Update resoruce file location. + * test/lisp/emacs-lisp/package-tests.el: Update resource file location. * test/data/package: Moved to test/lisp/emacs-lisp/package-resources 2015-11-24 Phillip Lord diff --git a/admin/nt/dist-build/build-zips.sh b/admin/nt/dist-build/build-zips.sh index 7bc6ea6a9e..4c3a52af6a 100755 --- a/admin/nt/dist-build/build-zips.sh +++ b/admin/nt/dist-build/build-zips.sh @@ -134,7 +134,7 @@ while getopts "gb:hnsiV:" opt; do echo " -g git update and worktree only" echo " -i build installer only" echo " -n do not configure" - echo " -s snaphot build" + echo " -s snapshot build" exit 0 ;; \?) diff --git a/configure.ac b/configure.ac index 6d204b6103..418a62fd5e 100644 --- a/configure.ac +++ b/configure.ac @@ -5667,7 +5667,7 @@ gl_INIT CFLAGS=$SAVE_CFLAGS LIBS=$SAVE_LIBS -# timer_getoverrun needs the same libarary as timer_settime +# timer_getoverrun needs the same library as timer_settime OLD_LIBS=$LIBS LIBS="$LIB_TIMER_TIME $LIBS" AC_CHECK_FUNCS(timer_getoverrun) diff --git a/doc/lispref/display.texi b/doc/lispref/display.texi index 7ab2896778..ca438c10ce 100644 --- a/doc/lispref/display.texi +++ b/doc/lispref/display.texi @@ -5970,7 +5970,7 @@ To @var{svg} add an embedded (raster) image placed at @code{:base-uri} specifies a (possibly non-existing) file name of the svg image to be created, thus all the embedded files are searched relatively to the @code{:base-uri} filename's directory. If -@code{:base-uri} is ommited, then filename from where svg image is +@code{:base-uri} is omitted, then filename from where svg image is loaded is used. Using @code{:base-uri} improves the performance of embedding large images, comparing to @code{svg-embed}, because all the work is done directly by librsvg. diff --git a/etc/NEWS b/etc/NEWS index 0fe988a19c..3fede93eae 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -3181,7 +3181,7 @@ refers to the old state at FROM. +++ ** 'overlays-in' now handles zero-length overlays slightly differently. -Previosly, zero-length overlays at the end of the buffer were included +Previously, zero-length overlays at the end of the buffer were included in the result (if the region queried for stopped at that position). The same was not the case if the buffer had been narrowed to exclude the real end of the buffer. This has now been changed, and diff --git a/etc/refcards/pl-refcard.tex b/etc/refcards/pl-refcard.tex index c9d96788c5..5c12dbfbf5 100644 --- a/etc/refcards/pl-refcard.tex +++ b/etc/refcards/pl-refcard.tex @@ -679,7 +679,7 @@ \section{Przestawianie} \key{przestaw {\bf linie}}{C-x C-t} \key{przestaw {\bf s-wyra/zenia}}{C-M-t} -% Removed -- there is no Polish disctionary for ispell. +% Removed -- there is no Polish dictionary for ispell. %\section{Spelling Check} % %\key{check spelling of current word}{M-\$} diff --git a/lib-src/etags.c b/lib-src/etags.c index 88b49f803e..bd4d4fcf53 100644 --- a/lib-src/etags.c +++ b/lib-src/etags.c @@ -6259,7 +6259,7 @@ test_objc_is_mercury (char *this_file, language **lang) } } - /* Fallback heuristic test. Not failsafe but errless in pratice. */ + /* Fallback heuristic test. Not failsafe but errless in practice. */ ratio = ((float) rule_signs + percentage_signs + mercury_dots) / lines; out: diff --git a/lisp/ChangeLog.7 b/lisp/ChangeLog.7 index 3de3f2f157..3dd8313c6a 100644 --- a/lisp/ChangeLog.7 +++ b/lisp/ChangeLog.7 @@ -15867,7 +15867,7 @@ the key line of an entry. * bibtex.el (bibtex-autokey-year-use-crossref-entry): New variable - to determine if crossreferenced entry should be used for autokey + to determine if cross-referenced entry should be used for autokey generation, if year field of current entry is absent. (bibtex-generate-autokey): Use this new variable. diff --git a/lisp/ChangeLog.8 b/lisp/ChangeLog.8 index 3027463e53..39e757bfff 100644 --- a/lisp/ChangeLog.8 +++ b/lisp/ChangeLog.8 @@ -1147,7 +1147,7 @@ (bibtex-submit-bug-report): Use bibtex-version and bibtex-maintainer-salutation. (bibtex-entry-field-alist): Made booktitle field optional for - @inproceedings entries when crossreferenced. + @inproceedings entries when cross-referenced. (bibtex-entry-field-alist): Add booktitle field to proceedings entry type (for cross referencing). Thanks to Wagner Toledo Correa for the suggestion. diff --git a/lisp/bookmark.el b/lisp/bookmark.el index ff9b8ab138..b340d379b3 100644 --- a/lisp/bookmark.el +++ b/lisp/bookmark.el @@ -27,7 +27,7 @@ ;; associates a string with a location in a certain file. Thus, you ;; can navigate your way to that location by providing the string. ;; -;; Type `M-x customize-group RET boomark RET' for user options. +;; Type `M-x customize-group RET bookmark RET' for user options. ;;; Code: diff --git a/lisp/emacs-lisp/comp-cstr.el b/lisp/emacs-lisp/comp-cstr.el index 3c5578217a..6a3f6046d1 100644 --- a/lisp/emacs-lisp/comp-cstr.el +++ b/lisp/emacs-lisp/comp-cstr.el @@ -152,7 +152,7 @@ Integer values are handled in the `range' slot.") (defun comp-cstrs-homogeneous (cstrs) "Check if constraints CSTRS are all homogeneously negated or non-negated. Return `pos' if they are all positive, `neg' if they are all -negated or nil othewise." +negated or nil otherwise." (cl-loop for cstr in cstrs unless (comp-cstr-neg cstr) diff --git a/lisp/emacs-lisp/map-ynp.el b/lisp/emacs-lisp/map-ynp.el index 0522b31f57..b95f11eab6 100644 --- a/lisp/emacs-lisp/map-ynp.el +++ b/lisp/emacs-lisp/map-ynp.el @@ -79,7 +79,7 @@ of the alist has the form (KEY FUNCTION HELP), where KEY is a character; FUNCTION is a function of one argument (an object from LIST); and HELP is a string. When the user presses KEY, FUNCTION is called; if it returns non-nil, the object is considered to have been \"acted upon\", -and `map-y-or-n-p' proceeeds to the next object from LIST. If +and `map-y-or-n-p' proceeds to the next object from LIST. If FUNCTION returns nil, the prompt is re-issued for the same object: this comes in handy if FUNCTION produces some display that will allow the user to make an intelligent decision whether the object in question diff --git a/lisp/erc/erc.el b/lisp/erc/erc.el index 73202016ba..e0fda41f8e 100644 --- a/lisp/erc/erc.el +++ b/lisp/erc/erc.el @@ -2271,7 +2271,7 @@ first element is the certificate key file name, and the second element is the certificate file name itself, or t, which means that `auth-source' will be queried for the key and the certificate. Authenticating using a TLS client certificate is -also refered to as \"CertFP\" (Certificate Fingerprint) +also referred to as \"CertFP\" (Certificate Fingerprint) authentication by various IRC networks. Example usage: diff --git a/lisp/language/japan-util.el b/lisp/language/japan-util.el index f3e3590645..feb75a198e 100644 --- a/lisp/language/japan-util.el +++ b/lisp/language/japan-util.el @@ -145,7 +145,7 @@ and HANKAKU belongs to `japanese-jisx0201-kana'.") (?p . ?p) (?q . ?q) (?r . ?r) (?s . ?s) (?t . ?t) (?u . ?u) (?v . ?v) (?w . ?w) (?x . ?x) (?y . ?y) (?z . ?z)) "Japanese JISX0208 alpha numeric character table. -Each element is of the form (ALPHA-NUMERIC . ASCII), where ALPHA-NUMERIC +Each element is of the form (ALPHANUMERIC . ASCII), where ALPHANUMERIC belongs to `japanese-jisx0208', ASCII belongs to `ascii'.") ;; Put properties 'jisx0208 and 'ascii to each Japanese alpha numeric diff --git a/lisp/net/dictionary.el b/lisp/net/dictionary.el index f33cbaf112..0f42af0911 100644 --- a/lisp/net/dictionary.el +++ b/lisp/net/dictionary.el @@ -86,7 +86,7 @@ You can specify here: (defcustom dictionary-port 2628 "The port of the dictionary server. -This port is propably always 2628 so there should be no need to modify it." +This port is probably always 2628 so there should be no need to modify it." :group 'dictionary :set #'dictionary-set-server-var :type 'number diff --git a/lisp/progmodes/cc-awk.el b/lisp/progmodes/cc-awk.el index 334e82114f..f1bc25db7f 100644 --- a/lisp/progmodes/cc-awk.el +++ b/lisp/progmodes/cc-awk.el @@ -658,7 +658,7 @@ ;; prevent a repeat invocation. See elisp/lispref page "Search-based ;; Fontification". ;; - ;; This function gives invalid GAWK namepace separators (::) + ;; This function gives invalid GAWK namespace separators (::) ;; font-lock-warning-face. "Invalid" here means there are spaces, etc., ;; around a separator, or there are more than one of them in an identifier. ;; Invalid separators inside function declaration parentheses are handled diff --git a/lisp/progmodes/cc-engine.el b/lisp/progmodes/cc-engine.el index c305cae754..77da98f626 100644 --- a/lisp/progmodes/cc-engine.el +++ b/lisp/progmodes/cc-engine.el @@ -7422,7 +7422,7 @@ multi-line strings (but not C++, for example)." t) (save-excursion (goto-char (match-end 1)) - (if (c-in-literal) ; a psuedo closer. + (if (c-in-literal) ; a pseudo closer. t (setq saved-match-data (match-data)) (setq found t) diff --git a/lisp/progmodes/elisp-mode.el b/lisp/progmodes/elisp-mode.el index 542f8ad0b1..ef36c1f087 100644 --- a/lisp/progmodes/elisp-mode.el +++ b/lisp/progmodes/elisp-mode.el @@ -1452,7 +1452,7 @@ Elisp eldoc behaviour. Consider variable docstrings and function signatures only, in this order. If none applies, returns nil. Changes to `eldoc-documentation-functions' and `eldoc-documentation-strategy' are _not_ reflected here. As such -it is preferrable to use ElDoc's interfaces directly.") +it is preferable to use ElDoc's interfaces directly.") (make-obsolete 'elisp-eldoc-documentation-function "use ElDoc's interfaces instead." "28.1") diff --git a/lisp/progmodes/hideif.el b/lisp/progmodes/hideif.el index 4a1da62c7e..a2f5d7286a 100644 --- a/lisp/progmodes/hideif.el +++ b/lisp/progmodes/hideif.el @@ -682,7 +682,7 @@ that form should be displayed.") (defconst hif-valid-token-list (mapcar 'cdr hif-token-alist)) (defconst hif-token-regexp - ;; The ordering of regexp grouping is crutial to `hif-strtok' + ;; The ordering of regexp grouping is crucial to `hif-strtok' (concat ;; hex/binary: "\\([+-]?0[xXbB]\\([[:xdigit:]']+\\)?\\.?\\([[:xdigit:]']+\\)?\\([pP]\\([+-]?[0-9]+\\)\\)?" diff --git a/lisp/progmodes/vhdl-mode.el b/lisp/progmodes/vhdl-mode.el index 5eeac8af3b..3fe67fabf1 100644 --- a/lisp/progmodes/vhdl-mode.el +++ b/lisp/progmodes/vhdl-mode.el @@ -4700,7 +4700,7 @@ Usage: `vhdl-project-alist'. - SPECIAL MENUES: + SPECIAL MENUS: As an alternative to the speedbar, an index menu can be added (set option `vhdl-index-menu' to non-nil) or made accessible as a mouse menu (e.g. add \"(global-set-key [S-down-mouse-3] \\='imenu)\" to your start-up diff --git a/lisp/textmodes/bibtex.el b/lisp/textmodes/bibtex.el index 5cece1aa3c..d5671ce14f 100644 --- a/lisp/textmodes/bibtex.el +++ b/lisp/textmodes/bibtex.el @@ -113,7 +113,7 @@ page-dashes Change double dashes in page field to single dash whitespace Delete whitespace at the beginning and end of fields. inherit-booktitle If entry contains a crossref field and the booktitle field is empty, set the booktitle field to the content - of the title field of the crossreferenced entry. + of the title field of the cross-referenced entry. realign Realign entries, so that field texts and perhaps equal signs (depending on the value of `bibtex-align-at-equal-sign') begin in the same column. @@ -1228,9 +1228,9 @@ See `bibtex-generate-autokey' for details." :type 'integer) (defcustom bibtex-autokey-use-crossref t - "If non-nil use fields from crossreferenced entry if necessary. + "If non-nil use fields from cross-referenced entry if necessary. If this variable is non-nil and some field has no entry, but a -valid crossref entry, the field from the crossreferenced entry is used. +valid crossref entry, the field from the cross-referenced entry is used. See `bibtex-generate-autokey' for details." :group 'bibtex-autokey :type 'boolean) @@ -2975,7 +2975,7 @@ The year part: `bibtex-autokey-year-length' digits (useful values are 2 and 4). 2. If both the year and date fields are absent, but the entry has a valid crossref field and `bibtex-autokey-use-crossref' is - non-nil, use the date or year field of the crossreferenced entry + non-nil, use the date or year field of the cross-referenced entry instead. The title part diff --git a/lisp/windmove.el b/lisp/windmove.el index f747c40943..ef970bb6c9 100644 --- a/lisp/windmove.el +++ b/lisp/windmove.el @@ -170,7 +170,7 @@ placement bugs in old versions of Emacs." (defcustom windmove-allow-all-windows nil "Whether the windmove commands are allowed to target all type of windows. -If this variable is set to non-nil, all windmove commmands will +If this variable is set to non-nil, all windmove commands will ignore the `no-other-window' parameter applied by `display-buffer-alist' or `set-window-parameter'." :type 'boolean diff --git a/src/fns.c b/src/fns.c index 5126439fd6..c39fce21c7 100644 --- a/src/fns.c +++ b/src/fns.c @@ -1174,7 +1174,7 @@ string_make_multibyte (Lisp_Object string) /* Convert STRING (if unibyte) to a multibyte string without changing - the number of characters. Characters 0200 trough 0237 are + the number of characters. Characters 0200 through 0237 are converted to eight-bit characters. */ Lisp_Object diff --git a/src/frame.c b/src/frame.c index ab5dcc3664..f95566818a 100644 --- a/src/frame.c +++ b/src/frame.c @@ -729,7 +729,7 @@ adjust_frame_size (struct frame *f, int new_text_width, int new_text_height, && (f->new_width >= 0 || f->new_height >= 0)) /* For implied resizes with inhibit 2 (external menu and tool bar) pick up any new sizes the display engine has not - processed yet. Otherwsie, we would request the old sizes + processed yet. Otherwise, we would request the old sizes which will make this request appear as a request to set new sizes and have the WM react accordingly which is not TRT. diff --git a/src/image.c b/src/image.c index bcd45eb451..206c7baa2f 100644 --- a/src/image.c +++ b/src/image.c @@ -10039,7 +10039,7 @@ svg_load_image (struct frame *f, struct image *img, char *contents, #if LIBRSVG_CHECK_VERSION (2, 46, 0) RsvgRectangle zero_rect, viewbox, out_logical_rect; - /* Try the instrinsic dimensions first. */ + /* Try the intrinsic dimensions first. */ gboolean has_width, has_height, has_viewbox; RsvgLength iwidth, iheight; double dpi = FRAME_DISPLAY_INFO (f)->resx; @@ -10074,7 +10074,7 @@ svg_load_image (struct frame *f, struct image *img, char *contents, } else { - /* We haven't found a useable set of sizes, so try working out + /* We haven't found a usable set of sizes, so try working out the visible area. */ rsvg_handle_get_geometry_for_layer (rsvg_handle, NULL, &zero_rect, &viewbox, diff --git a/src/nsterm.m b/src/nsterm.m index 4bdc67c10b..8d88f7bd3d 100644 --- a/src/nsterm.m +++ b/src/nsterm.m @@ -8369,14 +8369,14 @@ - (void)setParentChildRelationships #ifdef NS_IMPL_COCOA - /* We have to set the accesibility subroles and/or the collection + /* We have to set the accessibility subroles and/or the collection behaviors early otherwise child windows may not go fullscreen as expected later. */ #if MAC_OS_X_VERSION_MIN_REQUIRED < 101000 if ([child respondsToSelector:@selector(setAccessibilitySubrole:)]) #endif - /* Set the accessibilty subroles. */ + /* Set the accessibility subroles. */ if (parentFrame) [self setAccessibilitySubrole:NSAccessibilityFloatingWindowSubrole]; else diff --git a/test/lisp/net/socks-tests.el b/test/lisp/net/socks-tests.el index 71bdd74890..c0f90bc2d4 100644 --- a/test/lisp/net/socks-tests.el +++ b/test/lisp/net/socks-tests.el @@ -95,7 +95,7 @@ ;; From fedora.org: 2605:bc80:3010:600:dead:beef:cafe:fed9 ;; 5004 ~~> Version Status (OK) NOOP Addr-Type (4 -> IPv6) (socks-filter proc "\5\0\0\4\x26\x05\xbc\x80\x30\x10\x00\x60") - (ert-info ("State still waiting and response emtpy") + (ert-info ("State still waiting and response empty") (should (eq (process-get proc 'socks-state) socks-state-waiting)) (should-not (process-get proc 'socks-response))) (ert-info ("Scratch field holds partial payload of pending msg") diff --git a/test/lisp/progmodes/cperl-mode-resources/here-docs.pl b/test/lisp/progmodes/cperl-mode-resources/here-docs.pl index 8af4625fff..bb3d4871a9 100644 --- a/test/lisp/progmodes/cperl-mode-resources/here-docs.pl +++ b/test/lisp/progmodes/cperl-mode-resources/here-docs.pl @@ -17,7 +17,7 @@ =head1 DESCRIPTION =item * -All occurrences of the string "look-here" are fontified correcty. +All occurrences of the string "look-here" are fontified correctly. Note that we deliberately test the face, not the syntax property: Users won't care for the syntax property, but they see the face. Different implementations with different syntax properties have been diff --git a/test/lisp/textmodes/fill-tests.el b/test/lisp/textmodes/fill-tests.el index a4c7f447b5..fcc2c75709 100644 --- a/test/lisp/textmodes/fill-tests.el +++ b/test/lisp/textmodes/fill-tests.el @@ -54,7 +54,7 @@ (beg (line-beginning-position)) (end (line-end-position)) (fill-prefix (make-string (- pos beg) ?\s)) - ;; `fill-column' is too small to accomodate the current line + ;; `fill-column' is too small to accommodate the current line (fill-column (- end beg 10))) (fill-region-as-paragraph beg end nil nil pos)) (should (equal (buffer-string) string))))) @@ -69,7 +69,7 @@ (beg (line-beginning-position)) (end (line-end-position)) (fill-prefix (make-string (- pos beg) ?\s)) - ;; `fill-column' is too small to accomodate the current line + ;; `fill-column' is too small to accommodate the current line (fill-column (- end beg 10))) (fill-region-as-paragraph beg end nil nil pos)) (should (equal commit d1f324766631ad15b1e893463e93000298f44480 Author: Lars Ingebrigtsen Date: Fri Sep 3 10:40:21 2021 +0200 Make recent timer changes more backwards-compatible * lisp/emacs-lisp/timer.el (timerp, timer-event-handler): Make backwards-compatible with old .elc files that have their own versions of `timer-create'd structures. diff --git a/lisp/emacs-lisp/timer.el b/lisp/emacs-lisp/timer.el index f7715109c8..5c658eba80 100644 --- a/lisp/emacs-lisp/timer.el +++ b/lisp/emacs-lisp/timer.el @@ -57,7 +57,10 @@ (defun timerp (object) "Return t if OBJECT is a timer." - (and (vectorp object) (= (length object) 10))) + (and (vectorp object) + ;; Timers are now ten elements, but old .elc code may have + ;; shorter versions of `timer-create'. + (<= 9 (length object) 10))) (defsubst timer--check (timer) (or (timerp timer) (signal 'wrong-type-argument (list #'timerp timer)))) @@ -293,7 +296,8 @@ This function is called, by name, directly by the C code." repeats))))) ;; If we want integral multiples, we have to recompute ;; the repetition. - (when (and (timer--integral-multiple timer) + (when (and (> (length timer) 9) ; Backwards compatible. + (timer--integral-multiple timer) (not (timer--idle-delay timer))) (setf (timer--time timer) (timer-next-integral-multiple-of-time commit d67ce5ef106ce8fa29e7fb49f000bb1508934cfb Author: Lars Ingebrigtsen Date: Fri Sep 3 10:15:05 2021 +0200 Fix message in previous toggle-truncate-lines change * lisp/simple.el (toggle-truncate-lines): Fix message in previous change. diff --git a/lisp/simple.el b/lisp/simple.el index c6495166ff..37952a5bf4 100644 --- a/lisp/simple.el +++ b/lisp/simple.el @@ -8311,7 +8311,7 @@ non-nil." (if (and truncate-lines visual-line-mode) (progn (visual-line-mode -1) - (message " and `visual-line-mode' disabled")) + (format-message " and `visual-line-mode' disabled")) ""))) (defun toggle-word-wrap (&optional arg) commit e1c893f4a3ae005a76f34d2393fccb9a219abed1 Author: Lars Ingebrigtsen Date: Fri Sep 3 09:45:32 2021 +0200 Allow not putting pasted text onto the kill ring under xterm * lisp/term/xterm.el (xterm-paste): Don't put pasted text onto the kill ring (bug#28868). (xterm-store-paste-on-kill-ring): New user option. diff --git a/etc/NEWS b/etc/NEWS index bf371a18e4..0fe988a19c 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -3152,6 +3152,13 @@ It used to be mapped to 'print' but we couldn't find a terminal that uses this sequence for any kind of 'Print' key. This makes the Menu key (see https://en.wikipedia.org/wiki/Menu_key) work for `context-menu-mode` in Xterm. + +--- +** New user option 'xterm-store-paste-on-kill-ring'. +If non-nil (the default), Emacs pushes pasted text onto the kill ring +(if using an xterm-like terminal that supports bracketed paste). +Setting this to nil inhibits that. + * Incompatible Lisp Changes in Emacs 28.1 diff --git a/lisp/term/xterm.el b/lisp/term/xterm.el index 43a89ff31f..de5f000089 100644 --- a/lisp/term/xterm.el +++ b/lisp/term/xterm.el @@ -73,6 +73,13 @@ string bytes that can be copied is 3/4 of this value." :version "27.1" :type 'boolean) +(defcustom xterm-store-paste-on-kill-ring t + "If non-nil, pasting text into Emacs will put the text onto the kill ring. +This user option is only heeded when using a terminal using xterm +capabilities, and only when that terminal understands bracketed paste." + :version "28.1" + :type 'boolean) + (defconst xterm-paste-ending-sequence "\e[201~" "Characters sent by the terminal to end a bracketed paste.") @@ -100,9 +107,15 @@ Return the pasted text as a string." (interactive "e") (unless (eq (car-safe event) 'xterm-paste) (error "xterm-paste must be found to xterm-paste event")) - (let* ((pasted-text (nth 1 event)) - (interprogram-paste-function (lambda () pasted-text))) - (yank))) + (let ((pasted-text (nth 1 event))) + (if xterm-store-paste-on-kill-ring + ;; Put the text onto the kill ring and then insert it into the + ;; buffer. + (let ((interprogram-paste-function (lambda () pasted-text))) + (yank)) + ;; Insert the text without putting it onto the kill ring. + (push-mark) + (insert-for-yank pasted-text)))) ;; Put xterm-paste itself in global-map because, after translation, ;; it's just a normal input event. commit 4bdae17a74f1b6ea6b81066ce31f7ff5b45d3379 Author: Eli Zaretskii Date: Fri Sep 3 10:04:40 2021 +0300 * etc/NEWS: Announce recent change in 'toggle-truncate-lines'. diff --git a/etc/NEWS b/etc/NEWS index 6f6b8e108f..bf371a18e4 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -3092,6 +3092,11 @@ similar to prefix arguments, but are more flexible and discoverable. * Incompatible Editing Changes in Emacs 28.1 +--- +** 'toggle-truncate-lines' now disables 'visual-line-mode'. +This is for symmetry with 'visual-line-mode', which disables +'truncate-lines'. + ** 'electric-indent-mode' now also indents inside strings and comments, (unless the indentation function doesn't, of course). To recover the previous behavior you can use: commit 41db6943b988b16ac0e8d5f968ab18bb91a7638c Author: Stefan Kangas Date: Fri Sep 3 10:39:25 2021 +0200 Sync latest SKK-JISYO.L * leim/SKK-DIC/SKK-JISYO.L: Sync to current upstream version. diff --git a/leim/SKK-DIC/SKK-JISYO.L b/leim/SKK-DIC/SKK-JISYO.L index 78d6e08027..f1e06ccfca 100644 --- a/leim/SKK-DIC/SKK-JISYO.L +++ b/leim/SKK-DIC/SKK-JISYO.L @@ -46444,7 +46444,9 @@ zyklus / 󤴤 /Ź;code/Ź;ΰ/ 󤴤 /Ź沽/ 󤴤 /Ź渰;[]encryption key/ +󤴤 /Ź/ 󤴤礦 /ŹĢ/ +󤴤Ĥ /Ź̲/ 󤴤Ҥ礦 /Źɽ/ 󤴤֤ /Źʸ/ 󤵤 /Ż/ @@ -61914,6 +61916,7 @@ zyklus / // 礦 // ޤ /ü/ +Ĥ /̲/ Ƥ /Ū/Ũ;imaginary enemy/ Ƥ /Ũ/ // @@ -138362,6 +138365,7 @@ zyklus / ˤ夦 /󽽻;Make a wish!/ ˤ夦 /󽽻ͻ;󽽰ˡܵܵˡ/ ˤ夦ä /󽽻ᵤ/ +ˤ夦Ϥ餤 /Żʧ/ ˤ夦礦 /ž/ ˤ夦󤫤 /ſͳ/ ˤ夦 /;dualism/;[ŷʸ]double star/ @@ -138476,6 +138480,7 @@ zyklus / ˤ /ê/ ˤ // ˤ󤫤 /ʳ/2ʳ/ +ˤ󤫤ˤ󤷤礦 /ʳǧ/ ˤ󤫤Ĥ褦 /ʳ/ ˤ󤬤 /ʽŤ/ ˤ󤬤ޤ /ʹ;with a fallback/ commit f4805be0b96e3a86b65c958ca26b3d02f1db57e0 Author: Stefan Kangas Date: Fri Sep 3 10:34:57 2021 +0200 Update publicsuffix.txt from upstream * etc/publicsuffix.txt: Update from https://publicsuffix.org/list/public_suffix_list.dat dated 2021-09-02 22:13:03 UTC. diff --git a/etc/publicsuffix.txt b/etc/publicsuffix.txt index 1ede2b929a..986f110b04 100644 --- a/etc/publicsuffix.txt +++ b/etc/publicsuffix.txt @@ -734,7 +734,6 @@ gouv.ci // cl : https://www.nic.cl // Confirmed by .CL registry cl -aprendemas.cl co.cl gob.cl gov.cl @@ -4594,15 +4593,17 @@ gob.mx edu.mx net.mx -// my : http://www.mynic.net.my/ +// my : http://www.mynic.my/ +// Available strings: https://mynic.my/resources/domains/buying-a-domain/ my +biz.my com.my -net.my -org.my -gov.my edu.my +gov.my mil.my name.my +net.my +org.my // mz : http://www.uem.mz/ // Submitted by registry @@ -6085,8 +6086,10 @@ biz.ss com.ss edu.ss gov.ss +me.ss net.ss org.ss +sch.ss // st : http://www.nic.st/html/policyrules/ st @@ -6095,7 +6098,6 @@ com.st consulado.st edu.st embaixada.st -gov.st mil.st net.st org.st @@ -6712,9 +6714,10 @@ mil.vc edu.vc // ve : https://registro.nic.ve/ -// Submitted by registry +// Submitted by registry nic@nic.ve and nicve@conatel.gob.ve ve arts.ve +bib.ve co.ve com.ve e12.ve @@ -6726,7 +6729,9 @@ info.ve int.ve mil.ve net.ve +nom.ve org.ve +rar.ve rec.ve store.ve tec.ve @@ -6805,6 +6810,9 @@ yt // xn--90ae ("bg", Bulgarian) : BG бг +// xn--mgbcpq6gpa1a ("albahrain", Arabic) : BH +البحرين + // xn--90ais ("bel", Belarusian/Russian Cyrillic) : BY // Operated by .by registry бел @@ -6937,6 +6945,9 @@ yt // xn--80ao21a ("Kaz", Kazakh) : KZ қаз +// xn--q7ce6a ("Lao", Lao) : LA +ລາວ + // xn--fzc2c9e2c ("Lanka", Sinhalese-Sinhala) : LK // https://nic.lk ලංකා @@ -7062,7 +7073,13 @@ yt xxx // ye : http://www.y.net.ye/services/domain_name.htm -*.ye +ye +com.ye +edu.ye +gov.ye +net.ye +mil.ye +org.ye // za : https://www.zadna.org.za/content/page/domain-information/ ac.za @@ -7111,7 +7128,7 @@ org.zw // newGTLDs -// List of new gTLDs imported from https://www.icann.org/resources/registries/gtlds/v2/gtlds.json on 2020-11-30T20:26:10Z +// List of new gTLDs imported from https://www.icann.org/resources/registries/gtlds/v2/gtlds.json on 2021-08-19T15:13:52Z // This list is auto-generated, don't edit it manually. // aaa : 2015-02-26 American Automobile Association, Inc. aaa @@ -7137,7 +7154,7 @@ abc // able : 2015-06-25 Able Inc. able -// abogado : 2014-04-24 Minds + Machines Group Limited +// abogado : 2014-04-24 Registry Services, LLC abogado // abudhabi : 2015-07-30 Abu Dhabi Systems and Information Centre @@ -7335,7 +7352,7 @@ autos // avianca : 2015-01-08 Avianca Holdings S.A. avianca -// aws : 2015-06-25 Amazon Registry Services, Inc. +// aws : 2015-06-25 AWS Registry LLC aws // axa : 2013-12-19 AXA Group Operations SAS @@ -7413,7 +7430,7 @@ beats // beauty : 2015-12-03 XYZ.COM LLC beauty -// beer : 2014-01-09 Minds + Machines Group Limited +// beer : 2014-01-09 Registry Services, LLC beer // bentley : 2014-12-18 Bentley Motors Limited @@ -7530,7 +7547,7 @@ bridgestone // broadway : 2014-12-22 Celebrate Broadway, Inc. broadway -// broker : 2014-12-11 Dotbroker Registry Limited +// broker : 2014-12-11 Dog Beach, LLC broker // brother : 2015-01-29 Brother Industries, Ltd. @@ -7623,15 +7640,12 @@ careers // cars : 2014-11-13 XYZ.COM LLC cars -// casa : 2013-11-21 Minds + Machines Group Limited +// casa : 2013-11-21 Registry Services, LLC casa // case : 2015-09-03 CNH Industrial N.V. case -// caseih : 2015-09-03 CNH Industrial N.V. -caseih - // cash : 2014-03-06 Binky Moon, LLC cash @@ -7656,9 +7670,6 @@ cbre // cbs : 2015-08-06 CBS Domains Inc. cbs -// ceb : 2015-04-09 The Corporate Executive Board Company -ceb - // center : 2013-11-07 Binky Moon, LLC center @@ -7671,7 +7682,7 @@ cern // cfa : 2014-08-28 CFA Institute cfa -// cfd : 2014-12-11 DotCFD Registry Limited +// cfd : 2014-12-11 ShortDot SA cfd // chanel : 2015-04-09 Chanel International B.V. @@ -7749,7 +7760,7 @@ clothing // cloud : 2015-04-16 Aruba PEC S.p.A. cloud -// club : 2013-11-08 .CLUB DOMAINS, LLC +// club : 2013-11-08 Registry Services, LLC club // clubmed : 2015-06-25 Club Méditerranée S.A. @@ -7806,7 +7817,7 @@ contact // contractors : 2013-09-10 Binky Moon, LLC contractors -// cooking : 2013-11-21 Minds + Machines Group Limited +// cooking : 2013-11-21 Registry Services, LLC cooking // cookingchannel : 2015-07-02 Lifestyle Domain Holdings, Inc. @@ -7839,7 +7850,7 @@ credit // creditcard : 2014-03-20 Binky Moon, LLC creditcard -// creditunion : 2015-01-22 CUNA Performance Resources, LLC +// creditunion : 2015-01-22 DotCooperation LLC creditunion // cricket : 2014-10-09 dot Cricket Limited @@ -7896,7 +7907,7 @@ day // dclk : 2014-11-20 Charleston Road Registry Inc. dclk -// dds : 2015-05-07 Minds + Machines Group Limited +// dds : 2015-05-07 Registry Services, LLC dds // deal : 2015-06-25 Amazon Registry Services, Inc. @@ -7935,7 +7946,7 @@ dentist // desi : 2013-11-14 Desi Networks LLC desi -// design : 2014-11-07 Top Level Design, LLC +// design : 2014-11-07 Registry Services, LLC design // dev : 2014-10-16 Charleston Road Registry Inc. @@ -8124,7 +8135,7 @@ farm // farmers : 2015-07-09 Farmers Insurance Exchange farmers -// fashion : 2014-07-03 Minds + Machines Group Limited +// fashion : 2014-07-03 Registry Services, LLC fashion // fast : 2014-12-18 Amazon Registry Services, Inc. @@ -8175,10 +8186,10 @@ firmdale // fish : 2013-12-12 Binky Moon, LLC fish -// fishing : 2013-11-21 Minds + Machines Group Limited +// fishing : 2013-11-21 Registry Services, LLC fishing -// fit : 2014-11-07 Minds + Machines Group Limited +// fit : 2014-11-07 Registry Services, LLC fit // fitness : 2014-03-06 Binky Moon, LLC @@ -8217,7 +8228,7 @@ football // ford : 2014-11-13 Ford Motor Company ford -// forex : 2014-12-11 Dotforex Registry Limited +// forex : 2014-12-11 Dog Beach, LLC forex // forsale : 2014-05-22 Dog Beach, LLC @@ -8256,10 +8267,7 @@ ftr // fujitsu : 2015-07-30 Fujitsu Limited fujitsu -// fujixerox : 2015-07-23 Xerox DNHC LLC -fujixerox - -// fun : 2016-01-14 DotSpace Inc. +// fun : 2016-01-14 Radix FZC fun // fund : 2014-03-20 Binky Moon, LLC @@ -8295,7 +8303,7 @@ games // gap : 2015-07-31 The Gap, Inc. gap -// garden : 2014-06-26 Minds + Machines Group Limited +// garden : 2014-06-26 Registry Services, LLC garden // gay : 2019-05-23 Top Level Design, LLC @@ -8511,13 +8519,13 @@ homesense // honda : 2014-12-18 Honda Motor Co., Ltd. honda -// horse : 2013-11-21 Minds + Machines Group Limited +// horse : 2013-11-21 Registry Services, LLC horse // hospital : 2016-10-20 Binky Moon, LLC hospital -// host : 2014-04-17 DotHost Inc. +// host : 2014-04-17 Radix FZC host // hosting : 2014-05-29 UNR Corp. @@ -8640,9 +8648,6 @@ itau // itv : 2015-07-09 ITV Services Limited itv -// iveco : 2015-09-03 CNH Industrial N.V. -iveco - // jaguar : 2014-11-13 Jaguar Land Rover Ltd jaguar @@ -8715,6 +8720,9 @@ kfh // kia : 2015-07-09 KIA MOTORS CORPORATION kia +// kids : 2021-08-13 DotKids Foundation Limited +kids + // kim : 2013-09-23 Afilias Limited kim @@ -8793,7 +8801,7 @@ latino // latrobe : 2014-06-16 La Trobe University latrobe -// law : 2015-01-22 LW TLD Limited +// law : 2015-01-22 Registry Services, LLC law // lawyer : 2014-03-20 Dog Beach, LLC @@ -8922,10 +8930,7 @@ ltda // lundbeck : 2015-08-06 H. Lundbeck A/S lundbeck -// lupin : 2014-11-07 LUPIN LIMITED -lupin - -// luxe : 2014-01-09 Minds + Machines Group Limited +// luxe : 2014-01-09 Registry Services, LLC luxe // luxury : 2013-10-17 Luxury Partners, LLC @@ -8964,7 +8969,7 @@ market // marketing : 2013-11-07 Binky Moon, LLC marketing -// markets : 2014-12-11 Dotmarkets Registry Limited +// markets : 2014-12-11 Dog Beach, LLC markets // marriott : 2014-10-09 Marriott Worldwide Corporation @@ -9093,6 +9098,9 @@ mtn // mtr : 2015-03-12 MTR Corporation Limited mtr +// music : 2021-05-04 DotMusic Limited +music + // mutual : 2015-04-02 Northwestern Mutual MU TLD Registry, LLC mutual @@ -9102,9 +9110,6 @@ nab // nagoya : 2013-10-24 GMO Registry, Inc. nagoya -// nationwide : 2015-07-23 Nationwide Mutual Insurance Company -nationwide - // natura : 2015-03-12 NATURA COSMÉTICOS S.A. natura @@ -9132,9 +9137,6 @@ neustar // new : 2014-01-30 Charleston Road Registry Inc. new -// newholland : 2015-09-03 CNH Industrial N.V. -newholland - // news : 2014-12-18 Dog Beach, LLC news @@ -9207,7 +9209,7 @@ nyc // obi : 2014-09-25 OBI Group Holding SE & Co. KGaA obi -// observer : 2015-04-30 Top Level Spectrum, Inc. +// observer : 2015-04-30 Dog Beach, LLC observer // off : 2015-07-23 Johnson Shareholdings, Inc. @@ -9243,12 +9245,9 @@ ong // onl : 2013-09-16 iRegistry GmbH onl -// online : 2015-01-15 DotOnline Inc. +// online : 2015-01-15 Radix FZC online -// onyourside : 2015-07-23 Nationwide Mutual Insurance Company -onyourside - // ooo : 2014-01-09 INFIBEAM AVENUES LIMITED ooo @@ -9402,7 +9401,7 @@ pramerica // praxi : 2013-12-05 Praxi S.p.A. praxi -// press : 2014-04-03 DotPress Inc. +// press : 2014-04-03 Radix FZC press // prime : 2015-06-25 Amazon Registry Services, Inc. @@ -9474,7 +9473,7 @@ realestate // realtor : 2014-05-29 Real Estate Domains LLC realtor -// realty : 2015-03-19 Fegistry, LLC +// realty : 2015-03-19 Dog Beach, LLC realty // recipes : 2013-10-17 Binky Moon, LLC @@ -9564,7 +9563,7 @@ rocher // rocks : 2013-11-14 Dog Beach, LLC rocks -// rodeo : 2013-12-19 Minds + Machines Group Limited +// rodeo : 2013-12-19 Registry Services, LLC rodeo // rogers : 2015-08-06 Rogers Communications Canada Inc. @@ -9642,7 +9641,7 @@ saxo // sbi : 2015-03-12 STATE BANK OF INDIA sbi -// sbs : 2014-11-07 SPECIAL BROADCASTING SERVICE CORPORATION +// sbs : 2014-11-07 ShortDot SA sbs // sca : 2014-03-13 SVENSKA CELLULOSA AKTIEBOLAGET SCA (publ) @@ -9765,7 +9764,7 @@ sina // singles : 2013-08-27 Binky Moon, LLC singles -// site : 2015-01-15 DotSite Inc. +// site : 2015-01-15 Radix FZC site // ski : 2015-04-09 Afilias Limited @@ -9825,7 +9824,7 @@ soy // spa : 2019-09-19 Asia Spa and Wellness Promotion Council Limited spa -// space : 2014-04-03 DotSpace Inc. +// space : 2014-04-03 Radix FZC space // sport : 2017-11-16 Global Association of International Sports Federations (GAISF) @@ -9834,9 +9833,6 @@ sport // spot : 2015-02-26 Amazon Registry Services, Inc. spot -// spreadbetting : 2014-12-11 Dotspreadbetting Registry Limited -spreadbetting - // srl : 2015-05-07 InterNetX, Corp srl @@ -9867,7 +9863,7 @@ stockholm // storage : 2014-12-22 XYZ.COM LLC storage -// store : 2015-04-09 DotStore Inc. +// store : 2015-04-09 Radix FZC store // stream : 2016-01-08 dot Stream Limited @@ -9894,7 +9890,7 @@ supply // support : 2013-10-24 Binky Moon, LLC support -// surf : 2014-01-09 Minds + Machines Group Limited +// surf : 2014-01-09 Registry Services, LLC surf // surgery : 2014-03-20 Binky Moon, LLC @@ -9957,7 +9953,7 @@ tdk // team : 2015-03-05 Binky Moon, LLC team -// tech : 2015-01-30 Personals TLD Inc. +// tech : 2015-01-30 Radix FZC tech // technology : 2013-09-13 Binky Moon, LLC @@ -9984,7 +9980,7 @@ theatre // tiaa : 2015-07-23 Teachers Insurance and Annuity Association of America tiaa -// tickets : 2015-02-05 Accent Media Limited +// tickets : 2015-02-05 XYZ.COM LLC tickets // tienda : 2013-11-14 Binky Moon, LLC @@ -10050,7 +10046,7 @@ toys // trade : 2014-01-23 Elite Registry Limited trade -// trading : 2014-12-11 Dottrading Registry Limited +// trading : 2014-12-11 Dog Beach, LLC trading // training : 2013-11-07 Binky Moon, LLC @@ -10101,7 +10097,7 @@ unicom // university : 2014-03-06 Binky Moon, LLC university -// uno : 2013-09-11 DotSite Inc. +// uno : 2013-09-11 Radix FZC uno // uol : 2014-05-01 UBN INTERNET LTDA. @@ -10152,7 +10148,7 @@ villas // vin : 2015-06-18 Binky Moon, LLC vin -// vip : 2015-01-22 Minds + Machines Group Limited +// vip : 2015-01-22 Registry Services, LLC vip // virgin : 2014-09-25 Virgin Enterprises Limited @@ -10173,7 +10169,7 @@ vivo // vlaanderen : 2014-02-06 DNS.be vzw vlaanderen -// vodka : 2013-12-19 Minds + Machines Group Limited +// vodka : 2013-12-19 Registry Services, LLC vodka // volkswagen : 2015-05-14 Volkswagen Group of America Inc. @@ -10215,7 +10211,7 @@ wanggou // watch : 2013-11-14 Binky Moon, LLC watch -// watches : 2014-12-22 Richemont DNS Inc. +// watches : 2014-12-22 Afilias Limited watches // weather : 2015-01-08 International Business Machines Corporation @@ -10230,10 +10226,10 @@ webcam // weber : 2015-06-04 Saint-Gobain Weber SA weber -// website : 2014-04-03 DotWebsite Inc. +// website : 2014-04-03 Radix FZC website -// wedding : 2014-04-24 Minds + Machines Group Limited +// wedding : 2014-04-24 Registry Services, LLC wedding // weibo : 2015-03-05 Sina Corporation @@ -10275,7 +10271,7 @@ wolterskluwer // woodside : 2015-07-09 Woodside Petroleum Limited woodside -// work : 2013-12-19 Minds + Machines Group Limited +// work : 2013-12-19 Registry Services, LLC work // works : 2013-11-14 Binky Moon, LLC @@ -10593,7 +10589,7 @@ xyz // yachts : 2014-01-09 XYZ.COM LLC yachts -// yahoo : 2015-04-02 Yahoo! Domain Services Inc. +// yahoo : 2015-04-02 Oath Inc. yahoo // yamaxun : 2014-12-18 Amazon Registry Services, Inc. @@ -10605,7 +10601,7 @@ yandex // yodobashi : 2014-11-20 YODOBASHI CAMERA CO.,LTD. yodobashi -// yoga : 2014-05-29 Minds + Machines Group Limited +// yoga : 2014-05-29 Registry Services, LLC yoga // yokohama : 2013-12-12 GMO Registry, Inc. @@ -10652,11 +10648,22 @@ ltd.ua // 611coin : https://611project.org/ 611.to +// Aaron Marais' Gitlab pages: https://lab.aaronleem.co.za +// Submitted by Aaron Marais +graphox.us + +// accesso Technology Group, plc. : https://accesso.com/ +// Submitted by accesso Team +*.devcdnaccesso.com + // Adobe : https://www.adobe.com/ -// Submitted by Ian Boston +// Submitted by Ian Boston and Lars Trieloff adobeaemcloud.com -adobeaemcloud.net *.dev.adobeaemcloud.com +hlx.live +adobeaemcloud.net +hlx.page +hlx3.page // Agnat sp. z o.o. : https://domena.pl // Submitted by Przemyslaw Plewa @@ -10722,6 +10729,10 @@ us-west-2.elasticbeanstalk.com *.elb.amazonaws.com *.elb.amazonaws.com.cn +// Amazon Global Accelerator : https://aws.amazon.com/global-accelerator/ +// Submitted by Daniel Massaguer +awsglobalaccelerator.com + // Amazon S3 : https://aws.amazon.com/s3/ // Submitted by Luke Wells s3.amazonaws.com @@ -10792,6 +10803,15 @@ tele.amune.org // Submitted by Apigee Security Team apigee.io +// Appspace : https://www.appspace.com +// Submitted by Appspace Security Team +appspacehosted.com +appspaceusercontent.com + +// Appudo UG (haftungsbeschränkt) : https://www.appudo.com +// Submitted by Alexander Hochbaum +appudo.net + // Aptible : https://www.aptible.com/ // Submitted by Thomas Orozco on-aptible.com @@ -10817,15 +10837,27 @@ sweetpepper.org // Submitted by Vincent Tseng myasustor.com +// Atlassian : https://atlassian.com +// Submitted by Sam Smyth +cdn.prod.atlassian-dev.net + // AVM : https://avm.de // Submitted by Andreas Weise myfritz.net +// AVStack Pte. Ltd. : https://avstack.io +// Submitted by Jasper Hugo +onavstack.net + // AW AdvisorWebsites.com Software Inc : https://advisorwebsites.com // Submitted by James Kennedy *.awdev.ca *.advisor.ws +// AZ.pl sp. z.o.o: https://az.pl +// Submited by Krzysztof Wolski +ecommerce-shop.pl + // b-data GmbH : https://www.b-data.io // Submitted by Olivier Benz b-data.io @@ -10838,6 +10870,11 @@ backplaneapp.io // Submitted by Petros Angelatos balena-devices.com +// University of Banja Luka : https://unibl.org +// Domains for Republic of Srpska administrative entity. +// Submitted by Marko Ivanovic +rs.ba + // Banzai Cloud // Submitted by Janos Matyas *.banzai.cloud @@ -10853,6 +10890,10 @@ betainabox.com // Submitted by Nathan O'Sullivan bnr.la +// Bitbucket : http://bitbucket.org +// Submitted by Andy Ortlieb +bitbucket.io + // Blackbaud, Inc. : https://www.blackbaud.com // Submitted by Paul Crowder blackbaudcdn.net @@ -10861,10 +10902,18 @@ blackbaudcdn.net // Submitted by Luke Bratch of.je +// Blue Bite, LLC : https://bluebite.com +// Submitted by Joshua Weiss +bluebite.io + // Boomla : https://boomla.com // Submitted by Tibor Halter boomla.net +// Boutir : https://www.boutir.com +// Submitted by Eric Ng Ka Ka +boutir.com + // Boxfuse : https://boxfuse.com // Submitted by Axel Fontaine boxfuse.io @@ -10878,6 +10927,10 @@ square7.de bplaced.net square7.net +// Brendly : https://brendly.rs +// Submitted by Dusan Radovanovic +shop.brendly.rs + // BrowserSafetyMark // Submitted by Dave Tharp browsersafetymark.io @@ -10888,15 +10941,21 @@ uk0.bigv.io dh.bytemark.co.uk vm.bytemark.co.uk +// Caf.js Labs LLC : https://www.cafjs.com +// Submitted by Antonio Lain +cafjs.com + // callidomus : https://www.callidomus.com/ // Submitted by Marcus Popp mycd.eu // Carrd : https://carrd.co // Submitted by AJ +drr.ac +uwu.ai carrd.co crd.co -uwu.ai +ju.mp // CentralNic : http://www.centralnic.com/names/domains // Submitted by registry @@ -10962,11 +11021,6 @@ nz.basketball radio.am radio.fm -// Globe Hosting SRL : https://www.globehosting.com/ -// Submitted by Gavin Brown -co.ro -shop.ro - // c.la : http://www.c.la/ c.la @@ -10974,6 +11028,10 @@ c.la // Submitted by B. Blechschmidt certmgr.org +// Cityhost LLC : https://cityhost.ua +// Submitted by Maksym Rivtin +cx.ua + // Civilized Discourse Construction Kit, Inc. : https://www.discourse.org/ // Submitted by Rishabh Nambiar & Michael Brown discourse.group @@ -10988,14 +11046,22 @@ virtueeldomein.nl cleverapps.io // Clerk : https://www.clerk.dev -// Submitted by Colin Sidoti +// Submitted by Colin Sidoti +clerk.app +clerkstage.app *.lcl.dev +*.lclstage.dev *.stg.dev +*.stgstage.dev // Clic2000 : https://clic2000.fr // Submitted by Mathilde Blanchemanche clic2000.net +// ClickRising : https://clickrising.com/ +// Submitted by Umut Gumeli +clickrising.net + // Cloud66 : https://www.cloud66.com/ // Submitted by Khash Sajadi c66.me @@ -11016,8 +11082,8 @@ cloudcontrolled.com cloudcontrolapp.com // Cloudera, Inc. : https://www.cloudera.com/ -// Submitted by Philip Langdale -cloudera.site +// Submitted by Kedarnath Waikar +*.cloudera.site // Cloudflare, Inc. : https://www.cloudflare.com/ // Submitted by Cloudflare Team @@ -11166,18 +11232,37 @@ dyndns.dappnode.io // Submitted by Paul Biggar builtwithdark.com +// DataDetect, LLC. : https://datadetect.com +// Submitted by Andrew Banchich +demo.datadetect.com +instance.datadetect.com + // Datawire, Inc : https://www.datawire.io // Submitted by Richard Li edgestack.me +// DDNS5 : https://ddns5.com +// Submitted by Cameron Elliott +ddns5.com + // Debian : https://www.debian.org/ // Submitted by Peter Palfrader / Debian Sysadmin Team debian.net +// Deno Land Inc : https://deno.com/ +// Submitted by Luca Casonato +deno.dev +deno-staging.dev + // deSEC : https://desec.io/ // Submitted by Peter Thomassen dedyn.io +// Diher Solutions : https://diher.solutions +// Submitted by Didi Hermawan +*.rss.my.id +*.diher.solutions + // DNS Africa Ltd https://dns.business // Submitted by Calvin Browne jozi.biz @@ -11195,6 +11280,10 @@ shop.th // Submitted by Paul Fang drayddns.com +// DreamCommerce : https://shoper.pl/ +// Submitted by Konrad Kotarba +shoparena.pl + // DreamHost : http://www.dreamhost.com/ // Submitted by Andrew Farmer dreamhosters.com @@ -11554,10 +11643,26 @@ blogsite.xyz // Submitted by Dominik Menke dynv6.net +// Ellucian : https://ellucian.com +// Submitted by Josue Colon +elluciancrmadvance.com +elluciancrmadvise.com +elluciancrmrecruit.com + // E4YOU spol. s.r.o. : https://e4you.cz/ // Submitted by Vladimir Dudr e4.cz +// eero : https://eero.com/ +// Submitted by Yue Kang +eero.online +eero-stage.online + +// Elementor : Elementor Ltd. +// Submitted by Anton Barkan +elementor.cloud +elementor.cool + // En root‽ : https://en-root.org // Submitted by Emmanuel Raviart en-root.fr @@ -11565,6 +11670,7 @@ en-root.fr // Enalean SAS: https://www.enalean.com // Submitted by Thomas Cottier mytuleap.com +tuleap-partners.com // ECG Robotics, Inc: https://ecgrobotics.org // Submitted by @@ -11575,11 +11681,6 @@ staging.onred.one // Submitted by Jacob Bunk Nielsen service.one -// Enonic : http://enonic.com/ -// Submitted by Erik Kaareng-Sunde -enonic.io -customer.enonic.io - // EU.org https://eu.org/ // Submitted by Pierre Beyssac eu.org @@ -11639,6 +11740,10 @@ tr.eu.org uk.eu.org us.eu.org +// Eurobyte : https://eurobyte.ru +// Submitted by Evgeniy Subbotin +eurodir.ru + // Evennode : http://www.evennode.com/ // Submitted by Michal Kralik eu-1.evennode.com @@ -11749,6 +11854,7 @@ u.channelsdvr.net // Fastly Inc. : http://www.fastly.com/ // Submitted by Fastly Security +edgecompute.app fastly-terrarium.com fastlylb.net map.fastlylb.net @@ -11768,10 +11874,6 @@ myfast.host fastvps.site myfast.space -// Featherhead : https://featherhead.xyz/ -// Submitted by Simon Menke -fhapp.xyz - // Fedora : https://fedoraproject.org/ // submitted by Patrick Uiterwijk fedorainfracloud.org @@ -11782,10 +11884,11 @@ app.os.stg.fedoraproject.org // FearWorks Media Ltd. : https://fearworksmedia.co.uk // submitted by Keith Fairley -conn.uk -copro.uk couk.me ukco.me +conn.uk +copro.uk +hosp.uk // Fermax : https://fermax.com/ // submitted by Koen Van Isterdael @@ -11809,6 +11912,14 @@ filegear-sg.me // Submitted by Chris Raynor firebaseapp.com +// Firewebkit : https://www.firewebkit.com +// Submitted by Majid Qureshi +fireweb.app + +// FLAP : https://www.flap.cloud +// Submitted by Louis Chemineau +flap.id + // fly.io: https://fly.io // Submitted by Kurt Mackey fly.dev @@ -11819,6 +11930,24 @@ shw.io // Submitted by Jonathan Rudenberg flynnhosting.net +// Forgerock : https://www.forgerock.com +// Submitted by Roderick Parr +forgeblocks.com +id.forgerock.io + +// Framer : https://www.framer.com +// Submitted by Koen Rouwhorst +framer.app +framercanvas.com + +// Frusky MEDIA&PR : https://www.frusky.de +// Submitted by Victor Pupynin +*.frusky.de + +// RavPage : https://www.ravpage.co.il +// Submitted by Roni Horowitz +ravpage.co.il + // Frederik Braun https://frederik-braun.com // Submitted by Frederik Braun 0e.vc @@ -11836,6 +11965,10 @@ freeboxos.fr // Submitted by Daniel Stone freedesktop.org +// freemyip.com : https://freemyip.com +// Submitted by Cadence +freemyip.com + // FunkFeuer - Verein zur Förderung freier Netze : https://www.funkfeuer.at // Submitted by Daniel A. Maierhofer wien.funkfeuer.at @@ -11867,10 +12000,19 @@ gentlentapis.com lab.ms cdn-edges.net +// Ghost Foundation : https://ghost.org +// Submitted by Matt Hanley +ghost.io + +// GignoSystemJapan: http://gsj.bz +// Submitted by GignoSystemJapan +gsj.bz + // GitHub, Inc. // Submitted by Patrick Toomey -github.io githubusercontent.com +githubpreview.dev +github.io // GitLab, Inc. // Submitted by Alex Hanselka @@ -11885,12 +12027,21 @@ gitpage.si // Submitted by Mads Hartmann glitch.me +// Global NOG Alliance : https://nogalliance.org/ +// Submitted by Sander Steffann +nog.community + +// Globe Hosting SRL : https://www.globehosting.com/ +// Submitted by Gavin Brown +co.ro +shop.ro + // GMO Pepabo, Inc. : https://pepabo.com/ // Submitted by dojineko lolipop.io // GOV.UK Platform as a Service : https://www.cloud.service.gov.uk/ -// Submitted by Tom Whitwell +// Submitted by Tom Whitwell cloudapps.digital london.cloudapps.digital @@ -11929,7 +12080,6 @@ withyoutube.com cloud.goog translate.goog cloudfunctions.net - blogspot.ae blogspot.al blogspot.am @@ -12005,14 +12155,19 @@ blogspot.tw blogspot.ug blogspot.vn -// Aaron Marais' Gitlab pages: https://lab.aaronleem.co.za -// Submitted by Aaron Marais -graphox.us +// Goupile : https://goupile.fr +// Submitted by Niels Martignene +goupile.fr // Group 53, LLC : https://www.group53.com // Submitted by Tyler Todd awsmppl.com +// GünstigBestellen : https://günstigbestellen.de +// Submitted by Furkan Akkoc +günstigbestellen.de +günstigliefern.de + // Hakaran group: http://hakaran.cz // Submited by Arseniy Sokolov fin.ci @@ -12034,6 +12189,10 @@ hashbang.sh hasura.app hasura-app.io +// Heilbronn University of Applied Sciences - Faculty Informatics (GitLab Pages): https://www.hs-heilbronn.de +// Submitted by Richard Zowalla +pages.it.hs-heilbronn.de + // Hepforge : https://www.hepforge.org // Submitted by David Grellscheid hepforge.org @@ -12051,24 +12210,26 @@ ravendb.me development.run ravendb.run +// home.pl S.A.: https://home.pl +// Submited by Krzysztof Wolski +homesklep.pl + // Hong Kong Productivity Council: https://www.hkpc.org/ // Submitted by SECaaS Team secaas.hk // HOSTBIP REGISTRY : https://www.hostbip.com/ // Submitted by Atanunu Igbunuroghene -bpl.biz orx.biz -ng.city biz.gl -ng.ink col.ng firm.ng gen.ng ltd.ng ngo.ng -ng.school +edu.scot sch.so +org.yt // HostyHosting (hostyhosting.com) hostyhosting.io @@ -12086,6 +12247,19 @@ moonscale.net // Submitted by Hannu Aronsson iki.fi +// Impertrix Solutions : +// Submitted by Zhixiang Zhao +impertrixcdn.com +impertrix.com + +// Incsub, LLC: https://incsub.com/ +// Submitted by Aaron Edwards +smushcdn.com +wphostedmail.com +wpmucdn.com +tempurl.host +wpmudev.host + // Individual Network Berlin e.V. : https://www.in-berlin.de/ // Submitted by Christian Seitz dyn-berlin.de @@ -12178,7 +12352,8 @@ vip.jelastic.cloud jele.cloud it1.eur.aruba.jenv-aruba.cloud it1.jenv-aruba.cloud -it1-eur.jenv-arubabiz.cloud +keliweb.cloud +cs.keliweb.cloud oxa.cloud tn.oxa.cloud uk.oxa.cloud @@ -12190,13 +12365,9 @@ us.reclaim.cloud ch.trendhosting.cloud de.trendhosting.cloud jele.club +amscompute.com clicketcloud.com -ams.cloudswitches.com -au.cloudswitches.com -sg.cloudswitches.com dopaas.com -elastyco.com -nv.elastyco.com hidora.com paas.hosted-by-previder.com rag-cloud.hosteur.com @@ -12211,29 +12382,26 @@ lon.wafaicloud.com ryd.wafaicloud.com j.scaleforce.com.cy jelastic.dogado.eu -paas.leviracloud.eu fi.cloudplatform.fi demo.datacenter.fi paas.datacenter.fi jele.host mircloud.host +paas.beebyte.io +sekd1.beebyteapp.io jele.io -ocs.opusinteractive.io -cloud.unispace.io -cloud-de.unispace.io cloud-fr1.unispace.io jc.neen.it cloud.jelastic.open.tim.it jcloud.kz upaas.kazteleport.kz -jl.serv.net.mx cloudjiffy.net fra1-de.cloudjiffy.net west1-us.cloudjiffy.net -ams1.jls.docktera.net jls-sto1.elastx.net jls-sto2.elastx.net jls-sto3.elastx.net +faststacks.net fr-1.paas.massivegrid.net lon-1.paas.massivegrid.net lon-2.paas.massivegrid.net @@ -12244,8 +12412,7 @@ jelastic.saveincloud.net nordeste-idc.saveincloud.net j.scaleforce.net jelastic.tsukaeru.net -atl.jelastic.vps-host.net -njs.jelastic.vps-host.net +sdscloud.pl unicloud.pl mircloud.ru jelastic.regruhosting.ru @@ -12265,6 +12432,10 @@ myjino.ru *.spectrum.myjino.ru *.vps.myjino.ru +// Jotelulu S.L. : https://jotelulu.com +// Submitted by Daniel Fariña +jotelulu.cloud + // Joyent : https://www.joyent.com/ // Submitted by Brian Bennett *.triton.zone @@ -12296,10 +12467,20 @@ knightpoint.systems // Submitted by DisposaBoy oya.to +// Katholieke Universiteit Leuven: https://www.kuleuven.be +// Submitted by Abuse KU Leuven +kuleuven.cloud +ezproxy.kuleuven.be + // .KRD : http://nic.krd/data/krd/Registration%20Policy.pdf co.krd edu.krd +// Krellian Ltd. : https://krellian.com +// Submitted by Ben Francis +krellian.net +webthings.io + // LCube - Professional hosting e.K. : https://www.lcube-webhosting.de // Submitted by Lars Laehn git-repos.de @@ -12357,6 +12538,14 @@ loginline.io loginline.services loginline.site +// Lokalized : https://lokalized.nl +// Submitted by Noah Taheij +servers.run + +// Lõhmus Family, The +// Submitted by Heiki Lõhmus +lohmus.me + // LubMAN UMCS Sp. z o.o : https://lubman.pl/ // Submitted by Ireneusz Maliszewski krasnik.pl @@ -12393,6 +12582,7 @@ barsy.online barsy.org barsy.pro barsy.pub +barsy.ro barsy.shop barsy.site barsy.support @@ -12411,15 +12601,34 @@ mayfirst.org // Submitted by Ilya Zaretskiy hb.cldmail.ru +// Mail Transfer Platform : https://www.neupeer.com +// Submitted by Li Hui +cn.vu + +// Maze Play: https://www.mazeplay.com +// Submitted by Adam Humpherys +mazeplay.com + // mcpe.me : https://mcpe.me // Submitted by Noa Heyl mcpe.me // McHost : https://mchost.ru // Submitted by Evgeniy Subbotin +mcdir.me mcdir.ru +mcpre.ru vps.mcdir.ru +// Mediatech : https://mediatech.by +// Submitted by Evgeniy Kozhuhovskiy +mediatech.by +mediatech.dev + +// Medicom Health : https://medicomhealth.com +// Submitted by Michael Olson +hra.health + // Memset hosting : https://www.memset.com // Submitted by Tom Whitwell miniserver.com @@ -12460,6 +12669,10 @@ westus2.azurestaticapps.net // Submitted by Robert Böttinger csx.cc +// Mintere : https://mintere.com/ +// Submitted by Ben Aubin +mintere.site + // MobileEducation, LLC : https://joinforte.com // Submitted by Grayson Martin forte.id @@ -12482,8 +12695,11 @@ pp.ru // Submitted by Paul Cammish hostedpi.com customer.mythic-beasts.com +caracal.mythic-beasts.com +fentiger.mythic-beasts.com lynx.mythic-beasts.com ocelot.mythic-beasts.com +oncilla.mythic-beasts.com onza.mythic-beasts.com sphinx.mythic-beasts.com vs.mythic-beasts.com @@ -12538,6 +12754,20 @@ nh-serv.co.uk // Submitted by Jeff Wheelhouse nfshost.com +// Noop : https://noop.app +// Submitted by Nathaniel Schweinberg +*.developer.app +noop.app + +// Northflank Ltd. : https://northflank.com/ +// Submitted by Marco Suter +*.northflank.app +*.code.run + +// Noticeable : https://noticeable.io +// Submitted by Laurent Pellegrino +noticeable.news + // Now-DNS : https://now-dns.com // Submitted by Steve Russell dnsking.ch @@ -12676,60 +12906,6 @@ pcloud.host // Submitted by Matthew Brown nyc.mn -// NymNom : https://nymnom.com/ -// Submitted by NymNom -nom.ae -nom.af -nom.ai -nom.al -nym.by -nom.bz -nym.bz -nom.cl -nym.ec -nom.gd -nom.ge -nom.gl -nym.gr -nom.gt -nym.gy -nym.hk -nom.hn -nym.ie -nom.im -nom.ke -nym.kz -nym.la -nym.lc -nom.li -nym.li -nym.lt -nym.lu -nom.lv -nym.me -nom.mk -nym.mn -nym.mx -nom.nu -nym.nz -nym.pe -nym.pt -nom.pw -nom.qa -nym.ro -nom.rs -nom.si -nym.sk -nom.st -nym.su -nym.sx -nom.tj -nym.tw -nom.ug -nom.uy -nom.vc -nom.vg - // Observable, Inc. : https://observablehq.com // Submitted by Mike Bostock static.observableusercontent.com @@ -12762,18 +12938,29 @@ opensocial.site // Submitted by Sven Marnach opencraft.hosting +// OpenResearch GmbH: https://openresearch.com/ +// Submitted by Philipp Schmid +orsites.com + // Opera Software, A.S.A. // Submitted by Yngve Pettersen operaunite.com -// Oursky Limited : https://skygear.io/ -// Submited by Skygear Developer +// Oursky Limited : https://authgear.com/, https://skygear.io/ +// Submited by Authgear Team , Skygear Developer +authgear-staging.com +authgearapps.com skygearapp.com // OutSystems // Submitted by Duarte Santos outsystemscloud.com +// OVHcloud: https://ovhcloud.com +// Submitted by Vincent Cassé +*.webpaas.ovh.net +*.hosting.ovh.net + // OwnProvider GmbH: http://www.ownprovider.com // Submitted by Jan Moennich ownprovider.com @@ -12803,6 +12990,10 @@ pagefrontapp.com // Submitted by Yann Guichard pagexl.com +// Paywhirl, Inc : https://paywhirl.com/ +// Submitted by Daniel Netzer +*.paywhirl.com + // pcarrier.ca Software Inc: https://pcarrier.ca/ // Submitted by Pierre Carrier bar0.net @@ -12834,8 +13025,6 @@ perspecta.cloud // PE Ulyanov Kirill Sergeevich : https://airy.host // Submitted by Kirill Ulyanov lk3.ru -ra-ru.ru -zsew.ru // Planet-Work : https://www.planet-work.com/ // Submitted by Frédéric VANNIÈRE @@ -12848,6 +13037,7 @@ ent.platform.sh eu.platform.sh us.platform.sh *.platformsh.site +*.tst.site // Platter: https://platter.dev // Submitted by Patrick Flor @@ -12869,6 +13059,13 @@ dyn53.io // Submitted by Zulfais co.bn +// Postman, Inc : https://postman.com +// Submitted by Rahul Dhawan +postman-echo.com +pstmn.io +mock.pstmn.io +httpbin.org + // prgmr.com : https://prgmr.com/ // Submitted by Sarah Newman xen.prgmr.com @@ -12898,6 +13095,11 @@ byen.site // Submitted by Kor Nielsen pubtls.org +// PythonAnywhere LLP: https://www.pythonanywhere.com +// Submitted by Giles Thomas +pythonanywhere.com +eu.pythonanywhere.com + // QOTO, Org. // Submitted by Jeffrey Phillips Freeman qoto.io @@ -12910,6 +13112,10 @@ qualifioapp.com // Submitted by Dani Biro qbuser.com +// Rad Web Hosting: https://radwebhosting.com +// Submitted by Scott Claeys +cloudsite.builders + // Redstar Consultants : https://www.redstarconsultants.com/ // Submitted by Jons Slemmer instantcloud.cn @@ -12973,6 +13179,7 @@ onrender.com // Repl.it : https://repl.it // Submitted by Mason Clayton repl.co +id.repl.co repl.run // Resin.io : https://resin.io @@ -12989,10 +13196,31 @@ hzc.io wellbeingzone.eu wellbeingzone.co.uk +// Rico Developments Limited : https://adimo.co +// Submitted by Colin Brown +adimo.co.uk + +// Riseup Networks : https://riseup.net +// Submitted by Micah Anderson +itcouldbewor.se + // Rochester Institute of Technology : http://www.rit.edu/ // Submitted by Jennifer Herting git-pages.rit.edu +// Rusnames Limited: http://rusnames.ru/ +// Submitted by Sergey Zotov +биз.рус +ком.рус +крым.рус +мир.рус +мск.рус +орг.рус +самара.рус +сочи.рус +спб.рус +я.рус + // Sandstorm Development Group, Inc. : https://sandcats.io/ // Submitted by Asheesh Laroia sandcats.io @@ -13009,6 +13237,7 @@ schokokeks.net // Scottish Government: https://www.gov.scot // Submitted by Martin Ellis gov.scot +service.gov.scot // Scry Security : http://www.scrysec.com // Submitted by Shante Adam @@ -13031,16 +13260,33 @@ spdns.org // Submitted by Artem Kondratev seidat.net +// Sellfy : https://sellfy.com +// Submitted by Yuriy Romadin +sellfy.store + // Senseering GmbH : https://www.senseering.de // Submitted by Felix Mönckemeyer senseering.net +// Sendmsg: https://www.sendmsg.co.il +// Submitted by Assaf Stern +minisite.ms + +// Service Magnet : https://myservicemagnet.com +// Submitted by Dave Sanders +magnet.page + // Service Online LLC : http://drs.ua/ // Submitted by Serhii Bulakh biz.ua co.ua pp.ua +// Shift Crypto AG : https://shiftcrypto.ch +// Submitted by alex +shiftcrypto.dev +shiftcrypto.io + // ShiftEdit : https://shiftedit.net/ // Submitted by Adam Jimenez shiftedit.io @@ -13049,6 +13295,10 @@ shiftedit.io // Submitted by Alex Bowers myshopblocks.com +// Shopify : https://www.shopify.com +// Submitted by Alex Richter +myshopify.com + // Shopit : https://www.shopitcommerce.com/ // Submitted by Craig McMahon shopitsite.com @@ -13083,16 +13333,43 @@ beta.bounty-full.com // Submitted by Aral Balkan small-web.org +// Smoove.io : https://www.smoove.io/ +// Submitted by Dan Kozak +vp4.me + +// Snowplow Analytics : https://snowplowanalytics.com/ +// Submitted by Ian Streeter +try-snowplow.com + +// SourceHut : https://sourcehut.org +// Submitted by Drew DeVault +srht.site + // Stackhero : https://www.stackhero.io // Submitted by Adrien Gillon stackhero-network.com +// Staclar : https://staclar.com +// Submitted by Matthias Merkel +novecore.site + // staticland : https://static.land // Submitted by Seth Vincent static.land dev.static.land sites.static.land +// Storebase : https://www.storebase.io +// Submitted by Tony Schirmer +storebase.store + +// Strategic System Consulting (eApps Hosting): https://www.eapps.com/ +// Submitted by Alex Oancea +vps-host.net +atl.jelastic.vps-host.net +njs.jelastic.vps-host.net +ric.jelastic.vps-host.net + // Sony Interactive Entertainment LLC : https://sie.com/ // Submitted by David Coles playstation-cloud.com @@ -13110,6 +13387,28 @@ spacekit.io // Submitted by Stefan Neufeind customer.speedpartner.de +// Spreadshop (sprd.net AG) : https://www.spreadshop.com/ +// Submitted by Martin Breest +myspreadshop.at +myspreadshop.com.au +myspreadshop.be +myspreadshop.ca +myspreadshop.ch +myspreadshop.com +myspreadshop.de +myspreadshop.dk +myspreadshop.es +myspreadshop.fi +myspreadshop.fr +myspreadshop.ie +myspreadshop.it +myspreadshop.net +myspreadshop.nl +myspreadshop.no +myspreadshop.pl +myspreadshop.se +myspreadshop.co.uk + // Standard Library : https://stdlib.com // Submitted by Jacob Lee api.stdlib.com @@ -13131,10 +13430,12 @@ user.srcf.net // Submitted by Dan Miller temp-dns.com -// Swisscom Application Cloud: https://developer.swisscom.com -// Submitted by Matthias.Winzeler -applicationcloud.io -scapp.io +// Supabase : https://supabase.io +// Submitted by Inian Parameshwaran +supabase.co +supabase.in +supabase.net +su.paba.se // Symfony, SAS : https://symfony.com/ // Submitted by Fabien Potencier @@ -13163,6 +13464,10 @@ synology.me vpnplus.to direct.quickconnect.to +// Tabit Technologies Ltd. : https://tabit.cloud/ +// Submitted by Oren Agiv +tabitorder.co.il + // TAIFUN Software AG : http://taifun-software.de // Submitted by Bjoern Henke taifun-dns.de @@ -13190,13 +13495,17 @@ gwiddle.co.uk // Thingdust AG : https://thingdust.com/ // Submitted by Adrian Imboden +*.firenet.ch +*.svc.firenet.ch +reservd.com thingdustdata.com cust.dev.thingdust.io cust.disrec.thingdust.io cust.prod.thingdust.io cust.testing.thingdust.io -*.firenet.ch -*.svc.firenet.ch +reservd.dev.thingdust.io +reservd.disrec.thingdust.io +reservd.testing.thingdust.io // Tlon.io : https://tlon.io // Submitted by Mark Staarink @@ -13204,11 +13513,20 @@ arvo.network azimuth.network tlon.network +// Tor Project, Inc. : https://torproject.org +// Submitted by Antoine Beaupré bloxcms.com townnews-staging.com +// TradableBits: https://tradablebits.com +// Submitted by Dmitry Khrisanov dmitry@tradablebits.com +tbits.me + // TrafficPlex GmbH : https://www.trafficplex.de/ // Submitted by Phillipp Röll 12hp.at @@ -13336,7 +13654,6 @@ at.md de.md jp.md to.md -uwu.nu indie.porn vxl.sh ch.tc @@ -13369,6 +13686,13 @@ fastblog.net // Submitted by Arnold Hendriks *.webhare.dev +// WebHotelier Technologies Ltd: https://www.webhotelier.net/ +// Submitted by Apostolos Tsakpinis +reserve-online.net +reserve-online.com +bookonline.app +hotelwithflight.com + // WeDeploy by Liferay, Inc. : https://www.wedeploy.com // Submitted by Henrique Vicente wedeploy.io @@ -13396,15 +13720,29 @@ daemon.panel.gg // WoltLab GmbH : https://www.woltlab.com // Submitted by Tim Düsterhus +woltlab-demo.com myforum.community community-pro.de diskussionsbereich.de community-pro.net meinforum.net -// www.com.vc : http://www.com.vc -// Submitted by Li Hui -cn.vu +// Woods Valldata : https://www.woodsvalldata.co.uk/ +// Submitted by Chris Whittle +affinitylottery.org.uk +raffleentry.org.uk +weeklylottery.org.uk + +// WP Engine : https://wpengine.com/ +// Submitted by Michael Smith +// Submitted by Brandon DuRette +wpenginepowered.com +js.wpenginepowered.com + +// Wix.com, Inc. : https://www.wix.com +// Submitted by Shahar Talmi +wixsite.com +editorx.io // XenonCloud GbR: https://xenoncloud.net // Submitted by Julian Uphoff @@ -13448,6 +13786,7 @@ ybo.trade // Yunohost : https://yunohost.org // Submitted by Valentin Grimaud +ynh.fr nohost.me noho.st @@ -13466,26 +13805,4 @@ basicserver.io virtualserver.io enterprisecloud.nu -// Mintere : https://mintere.com/ -// Submitted by Ben Aubin -mintere.site - -// Cityhost LLC : https://cityhost.ua -// Submitted by Maksym Rivtin -cx.ua - -// WP Engine : https://wpengine.com/ -// Submitted by Michael Smith -// Submitted by Brandon DuRette -wpenginepowered.com -js.wpenginepowered.com - -// Impertrix Solutions : -// Submitted by Zhixiang Zhao -impertrixcdn.com -impertrix.com - -// GignoSystemJapan: http://gsj.bz -// Submitted by GignoSystemJapan -gsj.bz // ===END PRIVATE DOMAINS=== commit 0d3ae350c91c84b11f7d5fb0913fb7d294bc756f Author: Lars Ingebrigtsen Date: Fri Sep 3 08:36:03 2021 +0200 Make toggle-truncate-lines disable visual-line-mode * lisp/simple.el (toggle-truncate-lines): Disable `visual-line-mode' (bug#29664). diff --git a/lisp/simple.el b/lisp/simple.el index d6c448b36a..c6495166ff 100644 --- a/lisp/simple.el +++ b/lisp/simple.el @@ -8306,8 +8306,13 @@ non-nil." (if (eq buffer (window-buffer window)) (set-window-hscroll window 0))) nil t))) - (message "Truncate long lines %s" - (if truncate-lines "enabled" "disabled"))) + (message "Truncate long lines %s%s" + (if truncate-lines "enabled" "disabled") + (if (and truncate-lines visual-line-mode) + (progn + (visual-line-mode -1) + (message " and `visual-line-mode' disabled")) + ""))) (defun toggle-word-wrap (&optional arg) "Toggle whether to use word-wrapping for continuation lines. commit 0034067f4722a081fb5bba333d07a856656e8b42 Author: Stefan Kangas Date: Wed Jul 28 13:42:05 2021 +0200 Avoid cl-lib alias for cadadr and friends * lisp/edmacro.el (edmacro-fix-menu-commands): * lisp/frameset.el (frameset-move-onscreen): * lisp/htmlfontify.el (hfy-face-at, hfy-merge-adjacent-spans) (hfy-mark-tag-names): * lisp/mail/footnote.el (footnote--make-hole) (footnote-back-to-message): * lisp/net/eudc.el (eudc-get-email, eudc-get-phone): * lisp/net/rcirc.el (rcirc-make-trees, rcirc-handler-333) (rcirc-authenticate): * lisp/play/5x5.el (5x5-draw-grid, 5x5-solver): * lisp/play/decipher.el (decipher-insert-frequency-counts): * lisp/ses.el (ses-relocate-range): * test/lisp/emacs-lisp/edebug-tests.el (edebug-tests-step-into-macro-error) (edebug-tests-error-stepping-into-subr): Avoid using cl-lib aliases for cadadr and friends that now reside in subr.el. diff --git a/lisp/edmacro.el b/lisp/edmacro.el index 9e4a71c336..e18aad1c3f 100644 --- a/lisp/edmacro.el +++ b/lisp/edmacro.el @@ -612,7 +612,7 @@ This function assumes that the events can be stored in a string." ((eq (car ev) 'switch-frame)) ((equal ev '(menu-bar)) (push 'menu-bar result)) - ((equal (cl-cadadr ev) '(menu-bar)) + ((equal (cadadr ev) '(menu-bar)) (push (vector 'menu-bar (car ev)) result)) ;; It would be nice to do pop-up menus, too, but not enough ;; info is recorded in macros to make this possible. diff --git a/lisp/frameset.el b/lisp/frameset.el index 6aa94f8be5..cdbac0a48c 100644 --- a/lisp/frameset.el +++ b/lisp/frameset.el @@ -882,7 +882,7 @@ For the description of FORCE-ONSCREEN, see `frameset-restore'. When forced onscreen, frames wider than the monitor's workarea are converted to fullwidth, and frames taller than the workarea are converted to fullheight. NOTE: This only works for non-iconified frames." - (pcase-let* ((`(,left ,top ,width ,height) (cl-cdadr (frame-monitor-attributes frame))) + (pcase-let* ((`(,left ,top ,width ,height) (cdadr (frame-monitor-attributes frame))) (right (+ left width -1)) (bottom (+ top height -1)) (fr-left (frameset-compute-pos (frame-parameter frame 'left) left right)) diff --git a/lisp/htmlfontify.el b/lisp/htmlfontify.el index 3b961989e3..e63910d857 100644 --- a/lisp/htmlfontify.el +++ b/lisp/htmlfontify.el @@ -1238,7 +1238,7 @@ return a `defface' style list of face properties instead of a face symbol." (setq fprops (cdr fprops))) ;; ((prop val)) (setq p (caar fprops)) - (setq v (cl-cadar fprops)) + (setq v (cadar fprops)) (setq fprops (cdr fprops))) (if (listp (cdr fprops)) (progn @@ -1358,8 +1358,8 @@ Returns a modified copy of FACE-MAP." ;;(push (car tmp-map) reduced-map) ;;(push (cadr tmp-map) reduced-map) (while tmp-map - (setq first-start (cl-cadddr tmp-map) - first-stop (cl-caddr tmp-map) + (setq first-start (cadddr tmp-map) + first-stop (caddr tmp-map) last-start (cadr tmp-map) last-stop (car tmp-map) map-buf tmp-map @@ -1372,8 +1372,8 @@ Returns a modified copy of FACE-MAP." (not (re-search-forward "[^ \t\n\r]" (car last-start) t)))) (setq map-buf (cddr map-buf) span-start first-start - first-start (cl-cadddr map-buf) - first-stop (cl-caddr map-buf) + first-start (cadddr map-buf) + first-stop (caddr map-buf) last-start (cadr map-buf) last-stop (car map-buf))) (push span-stop reduced-map) @@ -1888,7 +1888,7 @@ property, with a value of \"tag.line-number\"." (lambda (TLIST) (if (string= file (car TLIST)) (let* ((line (cadr TLIST) ) - (chr (cl-caddr TLIST)) + (chr (caddr TLIST)) (link (format "%s.%d" TAG line) )) (put-text-property (+ 1 chr) (+ 2 chr) diff --git a/lisp/mail/footnote.el b/lisp/mail/footnote.el index 995ae5f916..b765602281 100644 --- a/lisp/mail/footnote.el +++ b/lisp/mail/footnote.el @@ -713,7 +713,7 @@ Return the footnote number to use." (save-excursion (let (rc) (dolist (alist-elem footnote--markers-alist) - (when (<= (point) (cl-caddr alist-elem)) + (when (<= (point) (caddr alist-elem)) (unless rc (setq rc (car alist-elem))) (save-excursion @@ -835,7 +835,7 @@ being set it is automatically widened." (when note (when footnote-narrow-to-footnotes-when-editing (widen)) - (goto-char (cl-caddr (assq note footnote--markers-alist))) + (goto-char (caddr (assq note footnote--markers-alist))) (when (looking-at (footnote--current-regexp)) (goto-char (match-end 0)))))) diff --git a/lisp/net/eudc.el b/lisp/net/eudc.el index 6459c52afe..517913ff01 100644 --- a/lisp/net/eudc.el +++ b/lisp/net/eudc.el @@ -664,7 +664,7 @@ If ERROR is non-nil, report an error if there is none." (let ((result (eudc-query (list (cons 'name name)) '(email))) email) (if (null (cdr result)) - (setq email (cl-cdaar result)) + (setq email (cdaar result)) (error "Multiple match--use the query form")) (if error (if email @@ -682,7 +682,7 @@ If ERROR is non-nil, report an error if there is none." (let ((result (eudc-query (list (cons 'name name)) '(phone))) phone) (if (null (cdr result)) - (setq phone (cl-cdaar result)) + (setq phone (cdaar result)) (error "Multiple match--use the query form")) (if error (if phone diff --git a/lisp/net/rcirc.el b/lisp/net/rcirc.el index e7aec505b0..9d242c47cd 100644 --- a/lisp/net/rcirc.el +++ b/lisp/net/rcirc.el @@ -2408,7 +2408,7 @@ prefix with another element in PAIRS." (when (and (listp x) (listp (cadr x))) (setcdr x (if (> (length (cdr x)) 1) (rcirc-make-trees (cdr x)) - (setcdr x (list (cl-cdadr x))))))) + (setcdr x (list (cdadr x))))))) alist))) ;;; /commands these are called with 3 args: PROCESS, TARGET, which is @@ -3234,7 +3234,7 @@ RFC1459." (with-current-buffer buffer (let ((setter (nth 2 args)) (time (current-time-string - (string-to-number (cl-cadddr args))))) + (string-to-number (cadddr args))))) (rcirc-print process sender "TOPIC" (cadr args) (format "%s (%s on %s)" rcirc-topic setter time)))))) @@ -3344,7 +3344,7 @@ Passwords are stored in `rcirc-authinfo' (which see)." (server (car i)) (nick (nth 2 i)) (method (cadr i)) - (args (cl-cdddr i))) + (args (cdddr i))) (when (and (string-match server rcirc-server)) (if (and (memq method '(nickserv chanserv bitlbee)) (string-match nick rcirc-nick)) diff --git a/lisp/play/5x5.el b/lisp/play/5x5.el index 3630c199bc..64d43c3d48 100644 --- a/lisp/play/5x5.el +++ b/lisp/play/5x5.el @@ -315,7 +315,7 @@ Quit current game \\[5x5-quit-game]" (save-excursion (goto-char grid-org) (beginning-of-line (+ 1 (/ 5x5-y-scale 2))) - (let ((solution-grid (cl-cdadr 5x5-solver-output))) + (let ((solution-grid (cdadr 5x5-solver-output))) (dotimes (y 5x5-grid-size) (save-excursion (forward-char (+ 1 (/ (1+ 5x5-x-scale) 2))) @@ -746,9 +746,9 @@ Solutions are sorted from least to greatest Hamming weight." ;; The Hamming Weight is computed by matrix reduction ;; with an ad-hoc operator. (math-reduce-vec - ;; (cl-cadadr '(vec (mod x 2))) => x - (lambda (r x) (+ (if (integerp r) r (cl-cadadr r)) - (cl-cadadr x))) + ;; (cadadr '(vec (mod x 2))) => x + (lambda (r x) (+ (if (integerp r) r (cadadr r)) + (cadadr x))) solution); car (5x5-vec-to-grid (calcFunc-arrange solution 5x5-grid-size));cdr diff --git a/lisp/play/decipher.el b/lisp/play/decipher.el index 47ed6e28b5..a80cb21151 100644 --- a/lisp/play/decipher.el +++ b/lisp/play/decipher.el @@ -769,8 +769,8 @@ TOTAL is the total number of letters in the ciphertext." (while temp-list (insert (caar temp-list) (format "%4d%3d%% " - (cl-cadar temp-list) - (floor (* 100.0 (cl-cadar temp-list)) total))) + (cadar temp-list) + (floor (* 100.0 (cadar temp-list)) total))) (setq temp-list (nthcdr 4 temp-list))) (insert ?\n) (setq freq-list (cdr freq-list) diff --git a/lisp/ses.el b/lisp/ses.el index 81c27144a5..cc8c35d699 100644 --- a/lisp/ses.el +++ b/lisp/ses.el @@ -1677,7 +1677,7 @@ if the range was altered." (funcall field (ses-sym-rowcol min)))) ;; This range has changed size. (setq ses-relocate-return 'range)) - `(ses-range ,min ,max ,@(cl-cdddr range))))) + `(ses-range ,min ,max ,@(cdddr range))))) (defun ses-relocate-all (minrow mincol rowincr colincr) "Alter all cell values, symbols, formulas, and reference-lists to relocate diff --git a/test/lisp/emacs-lisp/edebug-tests.el b/test/lisp/emacs-lisp/edebug-tests.el index 2f45050e2e..f8fa223da4 100644 --- a/test/lisp/emacs-lisp/edebug-tests.el +++ b/test/lisp/emacs-lisp/edebug-tests.el @@ -723,7 +723,7 @@ test and possibly others should be updated." (edebug-on-error nil) error-message (command-error-function (lambda (&rest args) - (setq error-message (cl-cadar args))))) + (setq error-message (cadar args))))) (edebug-tests-run-kbd-macro "@" (edebug-tests-should-be-at "format-node" "start") "SPC" (edebug-tests-should-be-at "format-node" "vectorp") @@ -744,7 +744,7 @@ test and possibly others should be updated." (edebug-on-error nil) (error-message "") (command-error-function (lambda (&rest args) - (setq error-message (cl-cadar args))))) + (setq error-message (cadar args))))) (edebug-tests-run-kbd-macro "@ SPC SPC SPC SPC SPC" (edebug-tests-should-be-at "try-flavors" "macro") commit 07e8ff7f0f35160953c2666f2ee4863852e0453f Author: Stefan Kangas Date: Wed Jul 28 13:31:40 2021 +0200 Move cl-lib tests for caaXr to subr-tests.el * test/lisp/emacs-lisp/cl-lib-tests.el (cl-test-caaar) (cl-test-caadr): Move tests using a cl-lib alias from here... * test/lisp/subr-tests.el (subr-test-caaar, subr-test-caadr): ...to here. The functions under test are in subr.el. diff --git a/test/lisp/emacs-lisp/cl-lib-tests.el b/test/lisp/emacs-lisp/cl-lib-tests.el index a5ec62b9c4..a132d73638 100644 --- a/test/lisp/emacs-lisp/cl-lib-tests.el +++ b/test/lisp/emacs-lisp/cl-lib-tests.el @@ -417,22 +417,6 @@ (should-error (cl-nth-value -1 (cl-values 2 3)) :type 'args-out-of-range) (should (string= (cl-nth-value 0 "only lists") "only lists"))) -(ert-deftest cl-test-caaar () - (should (null (cl-caaar '()))) - (should (null (cl-caaar '(() (2))))) - (should (null (cl-caaar '((() (2)) (a b))))) - (should-error (cl-caaar '(1 2)) :type 'wrong-type-argument) - (should-error (cl-caaar '((1 2))) :type 'wrong-type-argument) - (should (= 1 (cl-caaar '(((1 2) (3 4)))))) - (should (null (cl-caaar '((() (3 4))))))) - -(ert-deftest cl-test-caadr () - (should (null (cl-caadr '()))) - (should (null (cl-caadr '(1)))) - (should-error (cl-caadr '(1 2)) :type 'wrong-type-argument) - (should (= 2 (cl-caadr '(1 (2 3))))) - (should (equal '((2) (3)) (cl-caadr '((1) (((2) (3))) (4)))))) - (ert-deftest cl-test-ldiff () (let ((l '(1 2 3))) (should (null (cl-ldiff '() '()))) diff --git a/test/lisp/subr-tests.el b/test/lisp/subr-tests.el index c1f8225ec8..54bee7bc75 100644 --- a/test/lisp/subr-tests.el +++ b/test/lisp/subr-tests.el @@ -61,6 +61,25 @@ (quote (0 font-lock-keyword-face)))))))) + +;;;; List functions. + +(ert-deftest subr-test-caaar () + (should (null (caaar '()))) + (should (null (caaar '(() (2))))) + (should (null (caaar '((() (2)) (a b))))) + (should-error (caaar '(1 2)) :type 'wrong-type-argument) + (should-error (caaar '((1 2))) :type 'wrong-type-argument) + (should (= 1 (caaar '(((1 2) (3 4)))))) + (should (null (caaar '((() (3 4))))))) + +(ert-deftest subr-test-caadr () + (should (null (caadr '()))) + (should (null (caadr '(1)))) + (should-error (caadr '(1 2)) :type 'wrong-type-argument) + (should (= 2 (caadr '(1 (2 3))))) + (should (equal '((2) (3)) (caadr '((1) (((2) (3))) (4)))))) + ;;;; Keymap support. commit e588fa45ceb59a3eb04e67b32c55d0181c2a581a Author: Theodor Thornhill Date: Fri Sep 3 08:14:48 2021 +0200 Add CSS Box Alignment Module Level 3 to css-mode * lisp/textmodes/css-mode.el (css-property-alist): Consolidate `align-{contents, items, self}', as well as the corresponding values for `justify-{contents, items, self}' and `place-{contents, items, self}'. Values extracted from the flex part and into its own block (bug#50345). diff --git a/lisp/textmodes/css-mode.el b/lisp/textmodes/css-mode.el index 3bcd9c9766..f406afb7b6 100644 --- a/lisp/textmodes/css-mode.el +++ b/lisp/textmodes/css-mode.el @@ -301,14 +301,38 @@ ("grid-template-columns" "none" track-list auto-track-list) ("grid-template-rows" "none" track-list auto-track-list) + ;; CSS Box Alignment Module Level 3 + ;; (https://www.w3.org/TR/css-align-3/#alignment-values) + ("align-content" "center" "start" "end" "flex-start" "flex-end" + "normal" "first" "last" "baseline" "space-between" "space-around" + "space-evenly" "stretch" "safe" "unsafe") + ("align-items" "normal" "stretch" "center" "start" "end" + "flex-start" "flex-end" "baseline" "first" "last" "baseline" + "safe" "unsafe") + ("align-self" "auto" "normal" "center" "start" "end" + "self-start" "self-end" "flex-start" "flex-end" + "baseline" "first" "last" "stretch" "safe" "unsafe") + ("justify-content" "center" "start" "end" "flex-start" "flex-end" + "left" "right" "normal" "space-between" "space-around" + "space-evenly" "stretch" "safe" "unsafe") + ("justify-items" "auto" "normal" "stretch" "center" "start" "end" + "flex-start" "flex-end" "self-start" "self-end" "left" "right" + "baseline" "first" "last" "legacy" "safe" "unsafe") + ("justify-self" "auto" "normal" "stretch" "center" "start" "end" + "flex-start" "flex-end" "self-start" "self-end" "left" "right" + "baseline" "first" "last" "safe" "unsafe") + ("place-content" "center" "start" "end" "left" "right" "flex-start" + "flex-end" "baseline" "first" "last" "space-evenly" "space-around" + "space-between") + ("place-items" "auto" "normal" "center" "start" "end" + "self-start" "self-end" "flex-start" "flex-end" + "left" "right" "baseline" "first" "last" "stretch") + ("place-self" "auto" "center" "start" "end" "self-start" "self-end" + "flex-start" "flex-end" "normal" "left" "right" "baseline" + "first" "last" "stretch") + ;; CSS Flexible Box Layout Module Level 1 ;; (https://www.w3.org/TR/css-flexbox-1/#property-index) - ("align-content" "flex-start" "flex-end" "center" "space-between" - "space-around" "stretch") - ("align-items" "flex-start" "flex-end" "center" "baseline" - "stretch") - ("align-self" "auto" "flex-start" "flex-end" "center" "baseline" - "stretch") ("flex" "none" flex-grow flex-shrink flex-basis) ("flex-basis" "auto" "content" width) ("flex-direction" "row" "row-reverse" "column" "column-reverse") @@ -316,8 +340,6 @@ ("flex-grow" number) ("flex-shrink" number) ("flex-wrap" "nowrap" "wrap" "wrap-reverse") - ("justify-content" "flex-start" "flex-end" "center" - "space-between" "space-around") ("order" integer) ;; CSS Fonts Module Level 3 commit 5ae02f90fe79d09357fa9fbc2673ba44e2e64a5e Author: Theodor Thornhill Date: Fri Sep 3 08:13:49 2021 +0200 Add selection to css-pseudo-element-ids * lisp/textmodes/css-mode.el (css-pseudo-element-ids): Add selection as an element id (bug#50345). diff --git a/lisp/textmodes/css-mode.el b/lisp/textmodes/css-mode.el index 61a2f6b3bc..3bcd9c9766 100644 --- a/lisp/textmodes/css-mode.el +++ b/lisp/textmodes/css-mode.el @@ -57,7 +57,7 @@ "Identifiers for pseudo-classes.") (defconst css-pseudo-element-ids - '("after" "before" "first-letter" "first-line") + '("after" "before" "first-letter" "first-line" "selection") "Identifiers for pseudo-elements.") (defconst css-at-ids commit 7a4d823b398cf40c10ec31b2944c714c672c24b7 Author: Lars Ingebrigtsen Date: Thu Sep 2 18:44:55 2021 +0200 Fix `revert-buffer' message in `find-file-select' * lisp/files.el (find-file-noselect): Refer to revert-buffer-quick here since we're in a file-based buffer. diff --git a/lisp/files.el b/lisp/files.el index bd87b99575..7e4bdab507 100644 --- a/lisp/files.el +++ b/lisp/files.el @@ -2351,7 +2351,7 @@ the various files." ((not query-about-changed-file) (message (substitute-command-keys - "File %s changed on disk. \\[revert-buffer] to load new contents%s") + "File %s changed on disk. \\[revert-buffer-quick] to load new contents%s") (file-name-nondirectory filename) (if (buffer-modified-p buf) " and discard your edits" commit d9dabdb38175612cbb37fd75eddca7e02e013bc2 Author: Lars Ingebrigtsen Date: Fri Sep 3 07:46:39 2021 +0200 Fix memory-report test failure * test/lisp/emacs-lisp/memory-report-tests.el: Fix test build failure. diff --git a/test/lisp/emacs-lisp/memory-report-tests.el b/test/lisp/emacs-lisp/memory-report-tests.el index e352dd165f..1e0ffdc86a 100644 --- a/test/lisp/emacs-lisp/memory-report-tests.el +++ b/test/lisp/emacs-lisp/memory-report-tests.el @@ -19,6 +19,7 @@ (require 'ert) (require 'memory-report) +(require 'cl-macs) (defun setup-memory-report-tests () ;; Set the sizes on things based on a 64-bit architecture. (We're commit 0a18899f06949884b3078c13054233d635f36d6d Author: Dmitry Gutov Date: Fri Sep 3 03:34:18 2021 +0300 Fix recently broken vc-delete-file with Git * lisp/vc/vc-git.el (vc-git-delete-file): Treat FILE as string, not list (bug#50334). diff --git a/lisp/vc/vc-git.el b/lisp/vc/vc-git.el index a5431abb40..037fbcbc48 100644 --- a/lisp/vc/vc-git.el +++ b/lisp/vc/vc-git.el @@ -1556,7 +1556,7 @@ This requires git 1.8.4 or later, for the \"-L\" option of \"git log\"." (or (vc-git-symbolic-commit next-rev) next-rev))) (defun vc-git-delete-file (file) - (vc-git-command nil 0 (vc-git--literal-pathspecs file) "rm" "-f" "--")) + (vc-git-command nil 0 (vc-git--literal-pathspec file) "rm" "-f" "--")) (defun vc-git-rename-file (old new) (vc-git-command nil 0 (list old new) "mv" "-f" "--")) commit 926e69b20792630d0b6ac21c2a914703962722e4 Author: Glenn Morris Date: Thu Sep 2 17:16:18 2021 -0700 More fixes for recently added vc-rename test * test/lisp/vc/vc-tests.el (vc-test-cvs05-rename-file): Skip. (vc-test-sccs05-rename-file): Treat like RCS. diff --git a/test/lisp/vc/vc-tests.el b/test/lisp/vc/vc-tests.el index f2807a3f06..dfe89c519b 100644 --- a/test/lisp/vc/vc-tests.el +++ b/test/lisp/vc/vc-tests.el @@ -589,7 +589,7 @@ This checks also `vc-backend' and `vc-responsible-backend'." (should (file-exists-p new-name)) (should (equal (vc-state new-name) - (if (eq backend 'RCS) + (if (memq backend '(RCS SCCS)) 'up-to-date 'added))))) @@ -711,6 +711,9 @@ This checks also `vc-backend' and `vc-responsible-backend'." (ert-get-test ',(intern (format "vc-test-%s01-register" backend-string)))))) + ;; CVS calls vc-delete-file, which insists on prompting + ;; "Really want to delete ...?" + (skip-unless (not (eq 'CVS ',backend))) (vc-test--rename-file ',backend)) )))) commit 0db50c3fd5580cfa077d81c484a29f2821ceb02d Author: Tassilo Horn Date: Thu Sep 2 22:07:16 2021 +0200 Support forges by type rather than by host Formerly, bug-reference-setup-from-vc-alist basically had one entry per host (like gitlab.com). Restructure so that it's easy to add new hosts being just an instance of some type of forge such as SourceHut, Gitea, or GitLab. While we're at it, add support for gitea.com, salsa.debian.org, and framagit.org, the latter two being GitLab instances. * lisp/progmodes/bug-reference.el (bug-reference-gitea-instances) (bug-reference-gitlab-instances,bug-reference-sourcehut-instances): New variables listing online instances of those forges. (bug-reference--setup-from-vc-alist): New function (and variable for caching) using the former three new variables to generate suitable VC auto-setup alist. (bug-reference-try-setup-from-vc): Use both bug-reference-setup-from-vc-alist and bug-reference--setup-from-vc-alist. diff --git a/lisp/progmodes/bug-reference.el b/lisp/progmodes/bug-reference.el index 9b9c58eb1f..c0c9d5e659 100644 --- a/lisp/progmodes/bug-reference.el +++ b/lisp/progmodes/bug-reference.el @@ -153,95 +153,144 @@ The second subexpression should match the bug reference (usually a number)." (push (match-string i url) groups)) (funcall bug-url-fmt (nreverse groups)))))) -(defvar bug-reference-setup-from-vc-alist - `(;; - ;; GNU projects on savannah. - ;; - ;; Not all of them use debbugs but that doesn't really matter - ;; because the auto-setup is only performed if - ;; `bug-reference-url-format' and `bug-reference-bug-regexp' - ;; aren't set already. - ("git\\.\\(?:sv\\|savannah\\)\\.gnu\\.org:" - "\\<\\([Bb]ug ?#?\\)\\([0-9]+\\(?:#[0-9]+\\)?\\)\\>" - ,(lambda (_) "https://debbugs.gnu.org/%s")) - ;; - ;; GitHub projects. - ;; - ;; Here #17 may refer to either an issue or a pull request but - ;; visiting the issue/17 web page will automatically redirect to - ;; the pull/17 page if 17 is a PR. Explicit user/project#17 links - ;; to possibly different projects are also supported. - ("[/@]github.com[/:]\\([.A-Za-z0-9_/-]+\\)\\.git" - "\\([.A-Za-z0-9_/-]+\\)?\\(?:#\\)\\([0-9]+\\)\\>" - ,(lambda (groups) - (let ((ns-project (nth 1 groups))) - (lambda () - (concat "https://github.com/" - (or - ;; Explicit user/proj#18 link. - (match-string 1) - ns-project) - "/issues/" - (match-string 2)))))) - ;; - ;; Codeberg projects. - ;; - ;; The systematics is exactly as for Github projects. - ("[/@]codeberg.org[/:]\\([.A-Za-z0-9_/-]+\\)\\.git" - "\\([.A-Za-z0-9_/-]+\\)?\\(?:#\\)\\([0-9]+\\)\\>" - ,(lambda (groups) - (let ((ns-project (nth 1 groups))) - (lambda () - (concat "https://codeberg.org/" - (or - ;; Explicit user/proj#18 link. - (match-string 1) - ns-project) - "/issues/" - (match-string 2)))))) - ;; - ;; GitLab projects. - ;; - ;; Here #18 is an issue and !17 is a merge request. Explicit - ;; namespace/project#18 or namespace/project!17 references to - ;; possibly different projects are also supported. - ("[/@]gitlab.com[/:]\\([.A-Za-z0-9_/-]+\\)\\.git" - "\\(?1:[.A-Za-z0-9_/-]+\\)?\\(?3:[#!]\\)\\(?2:[0-9]+\\)\\>" - ,(lambda (groups) - (let ((ns-project (nth 1 groups))) - (lambda () - (concat "https://gitlab.com/" - (or (match-string 1) - ns-project) - "/-/" - (if (string= (match-string 3) "#") - "issues/" - "merge_requests/") - (match-string 2)))))) - ;; - ;; Sourcehut projects. - ;; - ;; #19 is an issue. Other project's issues can be referenced as - ;; #~user/project#19. - ;; - ;; Caveat: The code assumes that a project on git.sr.ht or - ;; hg.sr.ht has a tracker of the same name on todo.sh.ht. That's - ;; a very common setup but all sr.ht services are loosely coupled, - ;; so you can have a repo without tracker, or a repo with a - ;; tracker using a different name, etc. So we can only try to - ;; make a good guess. - ("[/@]\\(?:git\\|hg\\).sr.ht[/:]\\(~[.A-Za-z0-9_/-]+\\)" - "\\(~[.A-Za-z0-9_/-]+\\)?\\(?:#\\)\\([0-9]+\\)\\>" - ,(lambda (groups) - (let ((ns-project (nth 1 groups))) - (lambda () - (concat "https://todo.sr.ht/" - (or - ;; Explicit user/proj#18 link. - (match-string 1) - ns-project) - "/" - (match-string 2))))))) +(defvar bug-reference-gitea-instances '("gitea.com" + "codeberg.org") + "List of Gitea forge instances. +When the value is changed after bug-reference has already been +loaded, and performed an auto-setup, evaluate +`(bug-reference--setup-from-vc-alist t)' for rebuilding the value +of `bug-reference--setup-from-vc-alist'.") + +(defvar bug-reference-gitlab-instances '("gitlab.com" + "salsa.debian.org" + "framagit.org") + "List of GitLab forge instances. +When the value is changed after bug-reference has already been +loaded, and performed an auto-setup, evaluate +`(bug-reference--setup-from-vc-alist t)' for rebuilding the value +of `bug-reference--setup-from-vc-alist'.") + +(defvar bug-reference-sourcehut-instances '("sr.ht") + "List of SourceHut forge instances. +When the value is changed after bug-reference has already been +loaded, and performed an auto-setup, evaluate +`(bug-reference--setup-from-vc-alist t)' for rebuilding the value +of `bug-reference--setup-from-vc-alist'.") + +(defvar bug-reference--setup-from-vc-alist nil + "An alist for setting up ‘bug-reference-mode’ based on VC URL. +This is like `bug-reference-setup-from-vc-alist' but generated +for the known free software forges from the variables +`bug-reference-gitea-instances', +`bug-reference-gitlab-instances', and +`bug-reference-sourcehut-instances'.") + +(defun bug-reference--setup-from-vc-alist (&optional rebuild) + (if (and bug-reference--setup-from-vc-alist + (null rebuild)) + bug-reference--setup-from-vc-alist + (setq bug-reference--setup-from-vc-alist + `(;; + ;; GNU projects on savannah. + ;; + ;; Not all of them use debbugs but that doesn't really + ;; matter because the auto-setup is only performed if + ;; `bug-reference-url-format' and + ;; `bug-reference-bug-regexp' aren't set already. + ("git\\.\\(?:sv\\|savannah\\)\\.gnu\\.org:" + "\\<\\([Bb]ug ?#?\\)\\([0-9]+\\(?:#[0-9]+\\)?\\)\\>" + ,(lambda (_) "https://debbugs.gnu.org/%s")) + ;; + ;; GitHub projects. + ;; + ;; Here #17 may refer to either an issue or a pull request + ;; but visiting the issue/17 web page will automatically + ;; redirect to the pull/17 page if 17 is a PR. Explicit + ;; user/project#17 links to possibly different projects + ;; are also supported. + ("[/@]github.com[/:]\\([.A-Za-z0-9_/-]+\\)\\.git" + "\\([.A-Za-z0-9_/-]+\\)?\\(?:#\\)\\([0-9]+\\)\\>" + ,(lambda (groups) + (let ((ns-project (nth 1 groups))) + (lambda () + (concat "https://github.com/" + (or + ;; Explicit user/proj#18 link. + (match-string 1) + ns-project) + "/issues/" + (match-string 2)))))) + ;; + ;; Gitea instances. + ;; + ;; The systematics is exactly as for Github projects. + (,(concat "[/@]" + (regexp-opt bug-reference-gitea-instances t) + "[/:]\\([.A-Za-z0-9_/-]+\\)\\.git") + "\\([.A-Za-z0-9_/-]+\\)?\\(?:#\\)\\([0-9]+\\)\\>" + ,(lambda (groups) + (let ((host (nth 1 groups)) + (ns-project (nth 2 groups))) + (lambda () + (concat "https://" host "/" + (or + ;; Explicit user/proj#18 link. + (match-string 1) + ns-project) + "/issues/" + (match-string 2)))))) + ;; + ;; GitLab instances. + ;; + ;; Here #18 is an issue and !17 is a merge request. + ;; Explicit namespace/project#18 or namespace/project!17 + ;; references to possibly different projects are also + ;; supported. + (,(concat "[/@]" + (regexp-opt bug-reference-gitlab-instances t) + "[/:]\\([.A-Za-z0-9_/-]+\\)\\.git") + "\\(?1:[.A-Za-z0-9_/-]+\\)?\\(?3:[#!]\\)\\(?2:[0-9]+\\)\\>" + ,(lambda (groups) + (let ((host (nth 1 groups)) + (ns-project (nth 2 groups))) + (lambda () + (concat "https://" host "/" + (or (match-string 1) + ns-project) + "/-/" + (if (string= (match-string 3) "#") + "issues/" + "merge_requests/") + (match-string 2)))))) + ;; + ;; Sourcehut instances. + ;; + ;; #19 is an issue. Other project's issues can be + ;; #referenced as ~user/project#19. + ;; + ;; Caveat: The code assumes that a project on git.sr.ht or + ;; hg.sr.ht has a tracker of the same name on todo.sh.ht. + ;; That's a very common setup but all sr.ht services are + ;; loosely coupled, so you can have a repo without + ;; tracker, or a repo with a tracker using a different + ;; name, etc. So we can only try to make a good guess. + (,(concat "[/@]\\(?:git\\|hg\\)." + (regexp-opt bug-reference-sourcehut-instances t) + "[/:]\\(~[.A-Za-z0-9_/-]+\\)") + "\\(~[.A-Za-z0-9_/-]+\\)?\\(?:#\\)\\([0-9]+\\)\\>" + ,(lambda (groups) + (let ((host (nth 1 groups)) + (ns-project (nth 2 groups))) + (lambda () + (concat "https://todo." host "/" + (or + ;; Explicit user/proj#18 link. + (match-string 1) + ns-project) + "/" + (match-string 2)))))))))) + +(defvar bug-reference-setup-from-vc-alist nil "An alist for setting up `bug-reference-mode' based on VC URL. Each element has the form (URL-REGEXP BUG-REGEXP URL-FORMAT-FN). @@ -256,7 +305,8 @@ URL-REGEXP against the VCS URL and returns the value to be set as (defun bug-reference-try-setup-from-vc () "Try setting up `bug-reference-mode' based on VC information. Test each configuration in `bug-reference-setup-from-vc-alist' -and apply it if applicable." +and `bug-reference--setup-from-vc-alist' and apply it if +applicable." (let ((file-or-dir (or buffer-file-name ;; Catches modes such as vc-dir and Magit. default-directory))) @@ -269,7 +319,9 @@ and apply it if applicable." (vc-call-backend backend 'repository-url))))) (when url (catch 'found - (dolist (config bug-reference-setup-from-vc-alist) + (dolist (config (append + bug-reference-setup-from-vc-alist + (bug-reference--setup-from-vc-alist))) (when (apply #'bug-reference-maybe-setup-from-vc url config) (throw 'found t))))))))) commit 6372a3f6e51c35b7b993a423d8ce7b06880f9004 Author: Juri Linkov Date: Thu Sep 2 20:34:28 2021 +0300 * lisp/abbrev.el: Improve docstrings of inverse commands (bug#50303) * lisp/abbrev.el (add-mode-abbrev, add-global-abbrev) (inverse-add-mode-abbrev, inverse-add-global-abbrev): Add interlinking to opposite commands in docstrings. diff --git a/lisp/abbrev.el b/lisp/abbrev.el index 54783db2c3..f370bd3ea6 100644 --- a/lisp/abbrev.el +++ b/lisp/abbrev.el @@ -288,6 +288,10 @@ or zero means the region is the expansion. A negative argument means to undefine the specified abbrev. Reads the abbreviation in the minibuffer. +See also `inverse-add-mode-abbrev', which performs the opposite task: +if the abbrev text is already in the buffer, use this command to +define an abbrev by specifying the expansion in the minibuffer. + Don't use this function in a Lisp program; use `define-abbrev' instead." (interactive "p") (add-abbrev @@ -304,6 +308,10 @@ expansion; or zero means the region is the expansion. A negative argument means to undefine the specified abbrev. This command uses the minibuffer to read the abbreviation. +See also `inverse-add-global-abbrev', which performs the opposite task: +if the abbrev text is already in the buffer, use this command to +define an abbrev by specifying the expansion in the minibuffer. + Don't use this function in a Lisp program; use `define-abbrev' instead." (interactive "p") (add-abbrev global-abbrev-table "Global" arg)) @@ -330,7 +338,11 @@ Don't use this function in a Lisp program; use `define-abbrev' instead." "Define last word before point as a mode-specific abbrev. With prefix argument N, defines the Nth word before point. This command uses the minibuffer to read the expansion. -Expands the abbreviation after defining it." +Expands the abbreviation after defining it. + +See also `add-mode-abbrev', which performs the opposite task: +if the expansion is already in the buffer, use this command +to define an abbrev by specifying the abbrev in the minibuffer." (interactive "p") (inverse-add-abbrev (if only-global-abbrevs @@ -343,7 +355,11 @@ Expands the abbreviation after defining it." "Define last word before point as a global (mode-independent) abbrev. With prefix argument N, defines the Nth word before point. This command uses the minibuffer to read the expansion. -Expands the abbreviation after defining it." +Expands the abbreviation after defining it. + +See also `add-global-abbrev', which performs the opposite task: +if the expansion is already in the buffer, use this command +to define an abbrev by specifying the abbrev in the minibuffer." (interactive "p") (inverse-add-abbrev global-abbrev-table "Global" n)) commit c7997c8c982f50120b4286326df179300b6240a0 Author: Eli Zaretskii Date: Thu Sep 2 19:07:25 2021 +0300 ; * doc/emacs/dired.texi (Operating on Files): Fix last change. diff --git a/doc/emacs/dired.texi b/doc/emacs/dired.texi index d6b9e7139e..540abc3f3b 100644 --- a/doc/emacs/dired.texi +++ b/doc/emacs/dired.texi @@ -852,8 +852,8 @@ different systems put @command{chown} in different places). @cindex changing file time (in Dired) @item T @var{timestamp} @key{RET} Touch the specified files (@code{dired-do-touch}). This means -updating their modification times to @var{timestamp}. This is like -the shell command @code{touch}. +updating their modification times to @var{timestamp}, which defaults +to the present time. This is like the shell command @command{touch}. @findex dired-do-print @kindex P @r{(Dired)} commit 3d264907497d1f536a4a36e95a89c15e280bca7b Author: Eli Zaretskii Date: Thu Sep 2 18:49:01 2021 +0300 Fix expansion of non-ASCII $HOME * src/fileio.c (Fexpand_file_name): Make the file name multibyte if the value of $HOME is multibyte. (Bug#50266) diff --git a/src/fileio.c b/src/fileio.c index 13c99bee10..0db8ed793b 100644 --- a/src/fileio.c +++ b/src/fileio.c @@ -1307,6 +1307,8 @@ the root directory. */) newdir = SSDATA (hdir); newdirlim = newdir + SBYTES (hdir); } + else if (!multibyte && STRING_MULTIBYTE (tem)) + multibyte = 1; #ifdef DOS_NT collapse_newdir = false; #endif commit 110db95e13535cb6b364ac9ca3490dca7ea9ac50 Author: Eli Zaretskii Date: Thu Sep 2 14:58:41 2021 +0300 Fix 'clone-frame' on TTY frames * src/frame.c (Fmake_terminal_frame): Make a separate copy of the faces for the new frame before calling modify-frame-parameters, as on TTY frames that needs the faces already set up. (Bug#34715) diff --git a/src/frame.c b/src/frame.c index 74ef2afdb1..ab5dcc3664 100644 --- a/src/frame.c +++ b/src/frame.c @@ -1406,11 +1406,6 @@ affects all frames on the same terminal device. */) (t->display_info.tty->name ? build_string (t->display_info.tty->name) : Qnil)); - /* On terminal frames the `minibuffer' frame parameter is always - virtually t. Avoid that a different value in parms causes - complaints, see Bug#24758. */ - store_in_alist (&parms, Qminibuffer, Qt); - Fmodify_frame_parameters (frame, parms); /* Make the frame face hash be frame-specific, so that each frame could change its face definitions independently. */ @@ -1423,6 +1418,12 @@ affects all frames on the same terminal device. */) for (idx = 0; idx < table->count; ++idx) set_hash_value_slot (table, idx, Fcopy_sequence (HASH_VALUE (table, idx))); + /* On terminal frames the `minibuffer' frame parameter is always + virtually t. Avoid that a different value in parms causes + complaints, see Bug#24758. */ + store_in_alist (&parms, Qminibuffer, Qt); + Fmodify_frame_parameters (frame, parms); + f->can_set_window_size = true; f->after_make_frame = true; commit bfb2dd0e9d95882fe4907ff5f2ab3c857b415368 Author: Eli Zaretskii Date: Thu Sep 2 13:43:00 2021 +0300 Improve a recent change in 'mule-cmds.el' * lisp/international/mule-cmds.el (select-safe-coding-system--format-list): Display codepoints in hex and as characters. Display the ellipsis in a better place. Enlarge the limit to 5 codepoints, as the display is now easier to grasp. (select-safe-coding-system-interactively): Don't use 'select-safe-coding-system--format-list' for "rejected" coding-systems, as those don't come with characters and positions. diff --git a/lisp/international/mule-cmds.el b/lisp/international/mule-cmds.el index a883c231cb..abccc4f72c 100644 --- a/lisp/international/mule-cmds.el +++ b/lisp/international/mule-cmds.el @@ -663,19 +663,23 @@ overrides that argument.") codings)) (defun select-safe-coding-system--format-list (list) - (let ((spec " %-20s %6s %10s %s\n")) - (insert (format spec "Coding System" "Pos" "Code Point" "")) + (let ((spec1 " %-20s %6s %-10s %s\n") + (spec2 " %-20s %6s #x%-8X %c\n") + (nmax 5)) + (insert (format spec1 "Coding System" "Pos" "Codepoint" "Char")) (cl-loop for (coding . pairs) in list do (cl-loop for pair in pairs - ;; If there's a lot, only do the first three. - for i from 1 upto 3 + ;; If there's a lot, only do the first five. + for i from 1 upto nmax do (insert - (format spec + (format spec2 (if (= i 1) coding "") - (car pair) (cdr pair) - (if (and (= i 3) (> (length pairs) 3)) - "..." - "")))))) + (car pair) + (cdr pair) + (cdr pair)))) + (if (> (length pairs) nmax) + (insert (format spec1 "" "..." "" ""))))) + (insert "\n")) (defun select-safe-coding-system-interactively (from to codings unsafe @@ -736,14 +740,18 @@ DEFAULT is the coding system to use by default in the query." (concat " \"" (if (> (length from) 10) (concat (substring from 0 10) "...\"") (concat from "\""))) - (format-message " text\nin the buffer `%s'" bufname)) + (format-message + " the following\nproblematic characters in the buffer `%s'" + bufname)) ":\n") (select-safe-coding-system--format-list unsafe) (when rejected (insert "These safely encode the text in the buffer, but are not recommended for encoding text in this context, e.g., for sending an email message.\n ") - (select-safe-coding-system--format-list rejected)) + (dolist (x rejected) + (princ " ") (princ x)) + (insert "\n")) (when unsafe (insert (if rejected "The other coding systems" "However, each of them") commit 28dc18a553c7edbe93aabc4417618f4608265d36 Author: Lars Ingebrigtsen Date: Thu Sep 2 10:51:39 2021 +0200 Make the coding system warning prettier * lisp/international/mule-cmds.el (select-safe-coding-system--format-list): New function to display the coding system information in a more readable format (bug#31062). (select-safe-coding-system-interactively): Use it. diff --git a/lisp/international/mule-cmds.el b/lisp/international/mule-cmds.el index 8494d54091..a883c231cb 100644 --- a/lisp/international/mule-cmds.el +++ b/lisp/international/mule-cmds.el @@ -662,6 +662,22 @@ overrides that argument.") (delq 'no-conversion (copy-sequence codings)))) codings)) +(defun select-safe-coding-system--format-list (list) + (let ((spec " %-20s %6s %10s %s\n")) + (insert (format spec "Coding System" "Pos" "Code Point" "")) + (cl-loop for (coding . pairs) in list + do (cl-loop for pair in pairs + ;; If there's a lot, only do the first three. + for i from 1 upto 3 + do (insert + (format spec + (if (= i 1) coding "") + (car pair) (cdr pair) + (if (and (= i 3) (> (length pairs) 3)) + "..." + "")))))) + (insert "\n")) + (defun select-safe-coding-system-interactively (from to codings unsafe &optional rejected default) "Select interactively a coding system for the region FROM ... TO. @@ -722,19 +738,12 @@ DEFAULT is the coding system to use by default in the query." (concat from "\""))) (format-message " text\nin the buffer `%s'" bufname)) ":\n") - (let ((pos (point)) - (fill-prefix " ")) - (dolist (x (append rejected unsafe)) - (princ " ") (princ x)) - (insert "\n") - (fill-region-as-paragraph pos (point))) + (select-safe-coding-system--format-list unsafe) (when rejected (insert "These safely encode the text in the buffer, but are not recommended for encoding text in this context, e.g., for sending an email message.\n ") - (dolist (x rejected) - (princ " ") (princ x)) - (insert "\n")) + (select-safe-coding-system--format-list rejected)) (when unsafe (insert (if rejected "The other coding systems" "However, each of them") commit d7fb11b6d71ec67746bade24fa5cff1ecdc5d45d Author: Lars Ingebrigtsen Date: Thu Sep 2 10:22:52 2021 +0200 Reformat up-list and backward-up-list doc strings * lisp/emacs-lisp/lisp.el (backward-up-list): Reformat the doc string into several paragraphs (bug#31349). (up-list): Ditto and fix the "start" to be "end". diff --git a/lisp/emacs-lisp/lisp.el b/lisp/emacs-lisp/lisp.el index 2495277ba2..9b38d86e2c 100644 --- a/lisp/emacs-lisp/lisp.el +++ b/lisp/emacs-lisp/lisp.el @@ -186,12 +186,16 @@ report errors as appropriate for this kind of usage." This command will also work on other parentheses-like expressions defined by the current language mode. With ARG, do this that many times. A negative argument means move forward but still to -a less deep spot. If ESCAPE-STRINGS is non-nil (as it is -interactively), move out of enclosing strings as well. If -NO-SYNTAX-CROSSING is non-nil (as it is interactively), prefer to -break out of any enclosing string instead of moving to the start -of a list broken across multiple strings. On error, location of -point is unspecified." +a less deep spot. + +If ESCAPE-STRINGS is non-nil (as it is interactively), move out +of enclosing strings as well. + +If NO-SYNTAX-CROSSING is non-nil (as it is interactively), prefer +to break out of any enclosing string instead of moving to the +start of a list broken across multiple strings. + +On error, location of point is unspecified." (interactive "^p\nd\nd") (up-list (- (or arg 1)) escape-strings no-syntax-crossing)) @@ -200,12 +204,16 @@ point is unspecified." This command will also work on other parentheses-like expressions defined by the current language mode. With ARG, do this that many times. A negative argument means move backward but still to -a less deep spot. If ESCAPE-STRINGS is non-nil (as it is -interactively), move out of enclosing strings as well. If -NO-SYNTAX-CROSSING is non-nil (as it is interactively), prefer to -break out of any enclosing string instead of moving to the start -of a list broken across multiple strings. On error, location of -point is unspecified." +a less deep spot. + +If ESCAPE-STRINGS is non-nil (as it is interactively), move out +of enclosing strings as well. + +If NO-SYNTAX-CROSSING is non-nil (as it is interactively), prefer +to break out of any enclosing string instead of moving to the +end of a list broken across multiple strings. + +On error, location of point is unspecified." (interactive "^p\nd\nd") (or arg (setq arg 1)) (let ((inc (if (> arg 0) 1 -1)) commit b099942113445bb42f397f85429f6a7579a7a98b Author: Lars Ingebrigtsen Date: Thu Sep 2 09:57:30 2021 +0200 isearch*-lax-whitespace doc string improvements * lisp/isearch.el (isearch-regexp-lax-whitespace): * lisp/isearch.el (isearch-lax-whitespace): Mention the key binding in the doc string (bug#31790). diff --git a/lisp/isearch.el b/lisp/isearch.el index 922ab0f6ad..1c776a06e1 100644 --- a/lisp/isearch.el +++ b/lisp/isearch.el @@ -869,7 +869,8 @@ When you enter a space or spaces in ordinary incremental search, it will match any sequence matched by the regexp defined by the variable `search-whitespace-regexp'. If the value is nil, each space you type matches literally, against one space. You can toggle the value of this -variable by the command `isearch-toggle-lax-whitespace'.") +variable by the command `isearch-toggle-lax-whitespace', usually bound to +`M-s SPC' during isearch.") (defvar isearch-regexp-lax-whitespace nil "If non-nil, a space will match a sequence of whitespace chars. @@ -877,7 +878,8 @@ When you enter a space or spaces in regexp incremental search, it will match any sequence matched by the regexp defined by the variable `search-whitespace-regexp'. If the value is nil, each space you type matches literally, against one space. You can toggle the value of this -variable by the command `isearch-toggle-lax-whitespace'.") +variable by the command `isearch-toggle-lax-whitespace', usually bound to +`M-s SPC' during isearch.") (defvar isearch-cmds nil "Stack of search status elements. commit 0f3e34ec374414d437c8a5ebd406637c0f3b755f Author: Lars Ingebrigtsen Date: Thu Sep 2 09:49:06 2021 +0200 Fix documentation of `dired-do-touch' * doc/emacs/dired.texi (Operating on Files): Fix documentation of `dired-do-touch' (bug#50323). diff --git a/doc/emacs/dired.texi b/doc/emacs/dired.texi index e84ed0f7b6..d6b9e7139e 100644 --- a/doc/emacs/dired.texi +++ b/doc/emacs/dired.texi @@ -852,7 +852,7 @@ different systems put @command{chown} in different places). @cindex changing file time (in Dired) @item T @var{timestamp} @key{RET} Touch the specified files (@code{dired-do-touch}). This means -updating their modification times to the present time. This is like +updating their modification times to @var{timestamp}. This is like the shell command @code{touch}. @findex dired-do-print commit d8d5dc45656233fdccc3709093a16e2562cd4a40 Author: Yikai Zhao Date: Thu Sep 2 09:37:06 2021 +0200 memory-report: support calculating size for structures * lisp/emacs-lisp/memory-report.el (memory-report--object-size-1): Add support for cl-defstruct types (bug#50301). diff --git a/lisp/emacs-lisp/memory-report.el b/lisp/emacs-lisp/memory-report.el index aee2a0079c..3166d33e02 100644 --- a/lisp/emacs-lisp/memory-report.el +++ b/lisp/emacs-lisp/memory-report.el @@ -29,7 +29,7 @@ (require 'seq) (require 'subr-x) -(eval-when-compile (require 'cl-lib)) +(require 'cl-lib) (defvar memory-report--type-size (make-hash-table)) @@ -243,6 +243,19 @@ by counted more than once." value) total)) +;; All cl-defstruct types. +(cl-defmethod memory-report--object-size-1 (counted (value cl-structure-object)) + (let ((struct-type (type-of value))) + (apply #'+ + (memory-report--size 'vector) + (mapcar (lambda (slot) + (if (eq (car slot) 'cl-tag-slot) + 0 + (memory-report--object-size + counted + (cl-struct-slot-value struct-type (car slot) value)))) + (cl-struct-slot-info struct-type))))) + (defun memory-report--format (bytes) (setq bytes (/ bytes 1024.0)) (let ((units '("KiB" "MiB" "GiB" "TiB"))) diff --git a/test/lisp/emacs-lisp/memory-report-tests.el b/test/lisp/emacs-lisp/memory-report-tests.el index 0c0297b5fc..e352dd165f 100644 --- a/test/lisp/emacs-lisp/memory-report-tests.el +++ b/test/lisp/emacs-lisp/memory-report-tests.el @@ -68,6 +68,14 @@ (vector string string)) 124)))) +(ert-deftest memory-report-sizes-structs () + (cl-defstruct memory-report-test-struct + (item0 nil) + (item1 nil)) + (let ((s (make-memory-report-test-struct :item0 "hello" :item1 "world"))) + (should (= (memory-report-object-size s) + 90)))) + (provide 'memory-report-tests) ;;; memory-report-tests.el ends here commit 891be6f14065950465bf6e360013ceae0cb955bd Author: Lars Ingebrigtsen Date: Thu Sep 2 09:19:54 2021 +0200 Fix up previous ebfn2ps tweak * lisp/progmodes/ebnf2ps.el (ebnf-print-buffer): Remove NOOP decode step. diff --git a/lisp/progmodes/ebnf2ps.el b/lisp/progmodes/ebnf2ps.el index 3be3d7032d..6ad55fc142 100644 --- a/lisp/progmodes/ebnf2ps.el +++ b/lisp/progmodes/ebnf2ps.el @@ -2248,9 +2248,7 @@ number, prompt the user for the name of the file to save in." ;; Make non-ASCII work (sort of). (lambda (string) (ps-output t (and string - (encode-coding-string - (decode-coding-string string 'utf-8) - 'iso-8859-1)))))) + (encode-coding-string string 'iso-8859-1)))))) (ebnf-print-region (point-min) (point-max) filename))) ;;;###autoload commit 7d7e8a9c15cd509e731686f8e63fc1d574f4b5c0 Author: Lars Ingebrigtsen Date: Thu Sep 2 08:43:48 2021 +0200 Add a test for bug#50320 in sh-script diff --git a/test/lisp/progmodes/sh-script-tests.el b/test/lisp/progmodes/sh-script-tests.el index 5bdce6260a..c21010c8b4 100644 --- a/test/lisp/progmodes/sh-script-tests.el +++ b/test/lisp/progmodes/sh-script-tests.el @@ -37,4 +37,15 @@ "relative-path/to/configure --prefix=$prefix\\ --with-x")))) +(ert-deftest test-basic-sh-indentation () + (with-temp-buffer + (insert "myecho () {\necho foo\n}\n") + (shell-script-mode) + (indent-region (point-min) (point-max)) + (should (equal (buffer-string) + "myecho () { + echo foo +} +")))) + ;;; sh-script-tests.el ends here commit f143260d04614ab45fe3fe505f1f2b7af2326294 Author: Lars Ingebrigtsen Date: Thu Sep 2 08:41:30 2021 +0200 Revert "Tweak sh-script-mode indentation further" This reverts commit 6392bc37ab3b7eb83465d9b2248d21173373ae73. The changes led to errors throughout (bug#50320). diff --git a/lisp/progmodes/sh-script.el b/lisp/progmodes/sh-script.el index 7507579d16..201d1fd164 100644 --- a/lisp/progmodes/sh-script.el +++ b/lisp/progmodes/sh-script.el @@ -1775,7 +1775,7 @@ Does not preserve point." (goto-char p) nil)))) (while - (progn (skip-syntax-backward ".w_'()") + (progn (skip-syntax-backward ".w_'") (or (not (zerop (skip-syntax-backward "\\"))) (when (eq ?\\ (char-before (1- (point)))) (let ((p (point))) diff --git a/test/lisp/progmodes/sh-script-tests.el b/test/lisp/progmodes/sh-script-tests.el index 82c2d5168c..5bdce6260a 100644 --- a/test/lisp/progmodes/sh-script-tests.el +++ b/test/lisp/progmodes/sh-script-tests.el @@ -35,17 +35,6 @@ (should (equal (buffer-substring-no-properties (point-min) (point-max)) "relative-path/to/configure --prefix=$prefix\\ - --with-x"))) - (with-temp-buffer - (insert "${path_to_root}/configure --prefix=$prefix\\ - --with-x") - (shell-script-mode) - (goto-char (point-min)) - (forward-line 1) - (indent-for-tab-command) - (should (equal - (buffer-substring-no-properties (point-min) (point-max)) - "${path_to_root}/configure --prefix=$prefix\\ - --with-x")))) + --with-x")))) ;;; sh-script-tests.el ends here commit f3c5355c6b0576521693ed8da30a5dcd7a22a04c Author: Stephen Gildea Date: Wed Sep 1 20:42:28 2021 -0700 tramp-auto-save-directory: make private * lisp/net/tramp.el (tramp-handle-make-auto-save-file-name): chmod 0700 tramp-auto-save-directory when creating Thanks to Michael Albinus for reviewing this patch. diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el index 11c417f832..9ed9da9243 100644 --- a/lisp/net/tramp.el +++ b/lisp/net/tramp.el @@ -5419,7 +5419,8 @@ this file, if that variable is non-nil." ;; Create directory. (unless (or (null tramp-auto-save-directory) (file-exists-p tramp-auto-save-directory)) - (make-directory tramp-auto-save-directory t)) + (make-directory tramp-auto-save-directory t) + (set-file-modes tramp-auto-save-directory #o0700)) (let ((system-type (if (and (stringp tramp-auto-save-directory) commit f85b8678c4a08fd91d9b5f32dcde2f0b21bc6e38 Author: Eli Zaretskii Date: Wed Sep 1 19:27:43 2021 +0300 Fix segfault with invalid key-translation-map binding * src/keyboard.c (access_keymap_keyremap): Don't assume an invalid function is specified as a symbol. Reported by Perry E. Metzger . diff --git a/src/keyboard.c b/src/keyboard.c index 6a8c33ae3b..f6139b30e7 100644 --- a/src/keyboard.c +++ b/src/keyboard.c @@ -9188,8 +9188,7 @@ access_keymap_keyremap (Lisp_Object map, Lisp_Object key, Lisp_Object prompt, /* If the function returned something invalid, barf--don't ignore it. */ if (! (NILP (next) || VECTORP (next) || STRINGP (next))) - error ("Function %s returns invalid key sequence", - SSDATA (SYMBOL_NAME (tem))); + signal_error ("Function returns invalid key sequence", tem); } return next; } commit c42bb9d75caeb94fc0223aab27a7819930288aef Author: Lars Ingebrigtsen Date: Wed Sep 1 16:27:06 2021 +0200 Filter out the `name' parameter in clone-frame * lisp/frame.el (clone-frame): Filter out the `name' parameter, because two frames shouldn't have the same name and this will lead to a warning. diff --git a/lisp/frame.el b/lisp/frame.el index f36a34db7d..60234fc2ae 100644 --- a/lisp/frame.el +++ b/lisp/frame.el @@ -798,7 +798,10 @@ also select the new frame." (interactive "i\nP") (if use-default-parameters (make-frame-command) - (let* ((default-frame-alist (frame-parameters frame)) + (let* ((default-frame-alist (seq-filter + (lambda (elem) + (not (eq (car elem) 'name))) + (frame-parameters frame))) (new-frame (make-frame))) (unless (display-graphic-p) (select-frame new-frame)) commit b3a9d8cd3dd8d65969d853e9e16e95bb51e61dd3 Author: Lars Ingebrigtsen Date: Wed Sep 1 12:15:21 2021 +0200 Don't have epg bug out on non-existent packages * lisp/epg.el (epg--start): We may be called from contexts where the directory doesn't exist, but we need to have an existing directory here for the process (bug#32004). diff --git a/lisp/epg.el b/lisp/epg.el index 67d723b961..a461afac34 100644 --- a/lisp/epg.el +++ b/lisp/epg.el @@ -657,16 +657,17 @@ callback data (if any)." :sentinel #'ignore :noquery t)) (setf (epg-context-error-buffer context) (process-buffer error-process)) - (with-file-modes 448 - (setq process (make-process :name "epg" - :buffer buffer - :command (cons (epg-context-program context) - args) - :connection-type 'pipe - :coding 'raw-text - :filter #'epg--process-filter - :stderr error-process - :noquery t))) + (with-existing-directory + (with-file-modes 448 + (setq process (make-process :name "epg" + :buffer buffer + :command (cons (epg-context-program context) + args) + :connection-type 'pipe + :coding 'raw-text + :filter #'epg--process-filter + :stderr error-process + :noquery t)))) (setf (epg-context-process context) process))) (defun epg--process-filter (process input) commit 6a6de68dafd27238577e92a7a79e97f3f1a6e381 Author: Lars Ingebrigtsen Date: Wed Sep 1 12:13:19 2021 +0200 Add new macro `with-existing-directory' * doc/lispref/files.texi (Testing Accessibility): Document it. * lisp/subr.el (with-existing-directory): New macro (bug#32004). diff --git a/doc/lispref/files.texi b/doc/lispref/files.texi index 266501d46d..d104570452 100644 --- a/doc/lispref/files.texi +++ b/doc/lispref/files.texi @@ -936,6 +936,16 @@ file in @file{/foo/} will give an error: @end example @end defun +@defmac with-existing-directory body@dots{} +This macro ensures that @code{default-directory} is bound to an +existing directory before executing @var{body}. If +@code{default-directory} already exists, that's preferred, and +otherwise some other directory is used. This macro can be useful, for +instance, when calling an external command that requires that it's +running in a directory that exists. The chosen directory is not +guaranteed to be writable. +@end defmac + @defun access-file filename string If you can read @var{filename} this function returns @code{nil}; otherwise it signals an error diff --git a/etc/NEWS b/etc/NEWS index 0e1edd648d..6f6b8e108f 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -3422,6 +3422,11 @@ The former is now declared obsolete. * Lisp Changes in Emacs 28.1 ++++ +*** New macro 'with-existing-directory'. +This macro binds 'default-directory' to some other existing directory +if 'default-directory' doesn't exist, and then executes the body forms. + +++ *** New function 'file-name-concat'. This appends file name components to a directory name and returns the diff --git a/lisp/subr.el b/lisp/subr.el index 0a31ef2b29..7426dcce50 100644 --- a/lisp/subr.el +++ b/lisp/subr.el @@ -4593,6 +4593,19 @@ MODES is as for `set-default-file-modes'." ,@body) (set-default-file-modes ,umask))))) +(defmacro with-existing-directory (&rest body) + "Execute BODY with `default-directory' bound to an existing directory. +If `default-directory' is already an existing directory, it's not changed." + (declare (indent 0) (debug t)) + `(let ((default-directory (seq-find (lambda (dir) + (and dir + (file-exists-p dir))) + (list default-directory + (expand-file-name "~/") + (getenv "TMPDIR") + "/tmp/") + "/"))) + ,@body)) ;;; Matching and match data. diff --git a/test/lisp/subr-tests.el b/test/lisp/subr-tests.el index 21b8a27858..c1f8225ec8 100644 --- a/test/lisp/subr-tests.el +++ b/test/lisp/subr-tests.el @@ -740,5 +740,13 @@ See https://debbugs.gnu.org/cgi/bugreport.cgi?bug=19350." 1)) (should (equal (buffer-string) "new bar zot foobar")))) +(ert-deftest test-with-existing-directory () + (let ((dir (make-temp-name "/tmp/not-exist-"))) + (let ((default-directory dir)) + (should-not (file-exists-p default-directory))) + (with-existing-directory + (should-not (equal dir default-directory)) + (should (file-exists-p default-directory))))) + (provide 'subr-tests) ;;; subr-tests.el ends here commit a15f549a57dae3b88f92628a9a271d1f40858896 Author: Glenn Morris Date: Wed Sep 1 06:45:01 2021 -0700 ; Auto-commit of loaddefs files. diff --git a/lisp/ldefs-boot.el b/lisp/ldefs-boot.el index e6ac5d54fc..542cbef9f5 100644 --- a/lisp/ldefs-boot.el +++ b/lisp/ldefs-boot.el @@ -2938,6 +2938,13 @@ from `browse-url-elinks-wrapper'. \(fn URL &optional NEW-WINDOW)" t nil) +(autoload 'browse-url-button-open "browse-url" "\ +Follow the link under point using `browse-url'. +If EXTERNAL (the prefix if used interactively), open with the +external browser instead of the default one. + +\(fn &optional EXTERNAL MOUSE-EVENT)" t nil) + (autoload 'browse-url-button-open-url "browse-url" "\ Open URL using `browse-url'. If `current-prefix-arg' is non-nil, use @@ -3394,6 +3401,16 @@ Parse a rectangle as a matrix of numbers and push it on the Calculator stack. \(fn TOP BOT ARG)" t nil) +(autoload 'calc-grab-sum-down "calc" "\ +Parse a rectangle as a matrix of numbers and sum its columns. + +\(fn TOP BOT ARG)" t nil) + +(autoload 'calc-grab-sum-across "calc" "\ +Parse a rectangle as a matrix of numbers and sum its rows. + +\(fn TOP BOT ARG)" t nil) + (autoload 'calc-embedded "calc" "\ Start Calc Embedded mode on the formula surrounding point. @@ -6852,8 +6869,11 @@ or call the function `global-cwarn-mode'.") (autoload 'global-cwarn-mode "cwarn" "\ Toggle Cwarn mode in all buffers. With prefix ARG, enable Global Cwarn mode if ARG is positive; -otherwise, disable it. If called from Lisp, enable the mode if ARG is -omitted or nil. +otherwise, disable it. + +If called from Lisp, toggle the mode if ARG is `toggle'. +Enable the mode if ARG is nil, omitted, or is a positive number. +Disable the mode if ARG is a negative number. Cwarn mode is enabled in all buffers where `turn-on-cwarn-mode-if-enabled' would do it. @@ -8121,11 +8141,17 @@ Keybindings: (autoload 'dired-jump "dired" "\ Jump to Dired buffer corresponding to current buffer. -If in a file, Dired the current directory and move to file's line. +If in a buffer visiting a file, Dired that file's directory and +move to that file's line in the directory listing. + +If the current buffer isn't visiting a file, Dired `default-directory'. + If in Dired already, pop up a level and goto old directory's line. In case the proper Dired file line cannot be found, refresh the dired buffer and try again. + When OTHER-WINDOW is non-nil, jump to Dired buffer in other window. + When FILE-NAME is non-nil, jump to its line in Dired. Interactively with prefix argument, read FILE-NAME. @@ -8365,8 +8391,11 @@ or call the function `global-display-fill-column-indicator-mode'.") (autoload 'global-display-fill-column-indicator-mode "display-fill-column-indicator" "\ Toggle Display-Fill-Column-Indicator mode in all buffers. With prefix ARG, enable Global Display-Fill-Column-Indicator mode if -ARG is positive; otherwise, disable it. If called from Lisp, enable -the mode if ARG is omitted or nil. +ARG is positive; otherwise, disable it. + +If called from Lisp, toggle the mode if ARG is `toggle'. +Enable the mode if ARG is nil, omitted, or is a positive number. +Disable the mode if ARG is a negative number. Display-Fill-Column-Indicator mode is enabled in all buffers where `display-fill-column-indicator--turn-on' would do it. @@ -8442,8 +8471,11 @@ or call the function `global-display-line-numbers-mode'.") (autoload 'global-display-line-numbers-mode "display-line-numbers" "\ Toggle Display-Line-Numbers mode in all buffers. With prefix ARG, enable Global Display-Line-Numbers mode if ARG is -positive; otherwise, disable it. If called from Lisp, enable the mode -if ARG is omitted or nil. +positive; otherwise, disable it. + +If called from Lisp, toggle the mode if ARG is `toggle'. +Enable the mode if ARG is nil, omitted, or is a positive number. +Disable the mode if ARG is a negative number. Display-Line-Numbers mode is enabled in all buffers where `display-line-numbers--turn-on' would do it. @@ -8733,9 +8765,9 @@ BODY contains code to execute each time the mode is enabled or disabled. named variable, or a generalized variable. PLACE can also be of the form (GET . SET), where GET is an expression that returns the current state, and SET is - a function that takes one argument, the new state, and - sets it. If you specify a :variable, this function does - not define a MODE variable (nor any of the terms used + a function that takes one argument, the new state, which should + be assigned to PLACE. If you specify a :variable, this function + does not define a MODE variable (nor any of the terms used in :variable). :after-hook A single lisp form which is evaluated after the mode hooks have been run. It should not be quoted. @@ -15274,8 +15306,11 @@ or call the function `global-goto-address-mode'.") (autoload 'global-goto-address-mode "goto-addr" "\ Toggle Goto-Address mode in all buffers. With prefix ARG, enable Global Goto-Address mode if ARG is positive; -otherwise, disable it. If called from Lisp, enable the mode if ARG -is omitted or nil. +otherwise, disable it. + +If called from Lisp, toggle the mode if ARG is `toggle'. +Enable the mode if ARG is nil, omitted, or is a positive number. +Disable the mode if ARG is a negative number. Goto-Address mode is enabled in all buffers where `goto-addr-mode--turn-on' would do it. @@ -15570,9 +15605,14 @@ directories if your program contains sources from more than one directory. \(fn COMMAND-LINE)" t nil) (autoload 'perldb "gud" "\ -Run perldb on program FILE in buffer *gud-FILE*. -The directory containing FILE becomes the initial working directory -and source-file directory for your debugger. +Debug a perl program with gud. +Interactively, this will prompt you for a command line. + +Noninteractively, COMMAND-LINE should be on the form +\"perl -d perl-file.pl\". + +The directory containing the perl program becomes the initial +working directory and source-file directory for your debugger. \(fn COMMAND-LINE)" t nil) @@ -16462,8 +16502,11 @@ or call the function `global-hi-lock-mode'.") (autoload 'global-hi-lock-mode "hi-lock" "\ Toggle Hi-Lock mode in all buffers. With prefix ARG, enable Global Hi-Lock mode if ARG is positive; -otherwise, disable it. If called from Lisp, enable the mode if ARG is -omitted or nil. +otherwise, disable it. + +If called from Lisp, toggle the mode if ARG is `toggle'. +Enable the mode if ARG is nil, omitted, or is a positive number. +Disable the mode if ARG is a negative number. Hi-Lock mode is enabled in all buffers where `turn-on-hi-lock-if-enabled' would do it. @@ -16860,8 +16903,11 @@ or call the function `global-highlight-changes-mode'.") (autoload 'global-highlight-changes-mode "hilit-chg" "\ Toggle Highlight-Changes mode in all buffers. With prefix ARG, enable Global Highlight-Changes mode if ARG is -positive; otherwise, disable it. If called from Lisp, enable the mode if -ARG is omitted or nil. +positive; otherwise, disable it. + +If called from Lisp, toggle the mode if ARG is `toggle'. +Enable the mode if ARG is nil, omitted, or is a positive number. +Disable the mode if ARG is a negative number. Highlight-Changes mode is enabled in all buffers where `highlight-changes-mode-turn-on' would do it. @@ -17462,17 +17508,50 @@ evaluate `(default-value 'icomplete-vertical-mode)'. The mode's hook is called both when the mode is enabled and when it is disabled. +If none of these modes are on, turn on `icomplete-mode'. + As many completion candidates as possible are displayed, depending on the value of `max-mini-window-height', and the way the mini-window is resized depends on `resize-mini-windows'. +\(fn &optional ARG)" t nil) + +(defvar fido-vertical-mode nil "\ +Non-nil if Fido-Vertical mode is enabled. +See the `fido-vertical-mode' command +for a description of this minor mode. +Setting this variable directly does not take effect; +either customize it (see the info node `Easy Customization') +or call the function `fido-vertical-mode'.") + +(custom-autoload 'fido-vertical-mode "icomplete" nil) + +(autoload 'fido-vertical-mode "icomplete" "\ +Toggle vertical candidate display in `fido-mode'. +When turning on, if non-vertical `fido-mode' is off, turn it on. +If it's on, just add the vertical display. + +This is a minor mode. If called interactively, toggle the +`Fido-Vertical mode' mode. If the prefix argument is positive, enable +the mode, and if it is zero or negative, disable the mode. + +If called from Lisp, toggle the mode if ARG is `toggle'. Enable the +mode if ARG is nil, omitted, or is a positive number. Disable the +mode if ARG is a negative number. + +To check whether the minor mode is enabled in the current buffer, +evaluate `(default-value 'fido-vertical-mode)'. + +The mode's hook is called both when the mode is enabled and when it is +disabled. + \(fn &optional ARG)" t nil) (when (locate-library "obsolete/iswitchb") (autoload 'iswitchb-mode "iswitchb" "Toggle Iswitchb mode." t) (make-obsolete 'iswitchb-mode "use `icomplete-mode' or `ido-mode' instead." "24.4")) -(register-definition-prefixes "icomplete" '("fido-vertical-mode" "icomplete-")) +(register-definition-prefixes "icomplete" '("icomplete-")) ;;;*** @@ -19860,7 +19939,7 @@ Create lambda form for macro bound to symbol or key. ;;;;;; 0 0)) ;;; Generated autoloads from language/korea-util.el -(defvar default-korean-keyboard (purecopy (if (string-match "3" (or (getenv "HANGUL_KEYBOARD_TYPE") "")) "3" "")) "\ +(defvar default-korean-keyboard (purecopy (if (string-search "3" (or (getenv "HANGUL_KEYBOARD_TYPE") "")) "3" "")) "\ The kind of Korean keyboard for Korean (Hangul) input method. \"\" for 2, \"3\" for 3, and \"3f\" for 3f.") @@ -20139,8 +20218,11 @@ or call the function `global-linum-mode'.") (autoload 'global-linum-mode "linum" "\ Toggle Linum mode in all buffers. With prefix ARG, enable Global Linum mode if ARG is positive; -otherwise, disable it. If called from Lisp, enable the mode if ARG is -omitted or nil. +otherwise, disable it. + +If called from Lisp, toggle the mode if ARG is `toggle'. +Enable the mode if ARG is nil, omitted, or is a positive number. +Disable the mode if ARG is a negative number. Linum mode is enabled in all buffers where `linum-on' would do it. @@ -20534,7 +20616,10 @@ This function is primarily meant for when you're displaying the result to the user: Many prettifications are applied to the result returned. If you want to decode an address for further non-display use, you should probably use -`mail-header-parse-address' instead. +`mail-header-parse-address' instead. Also see +`mail-header-parse-address-lax' for a function that's less strict +than `mail-header-parse-address', but does less post-processing +to the results. \(fn ADDRESS &optional ALL)" nil nil) @@ -21057,7 +21142,7 @@ Default bookmark handler for Man buffers. ;;;### (autoloads nil "map" "emacs-lisp/map.el" (0 0 0 0)) ;;; Generated autoloads from emacs-lisp/map.el -(push (purecopy '(map 3 0)) package--builtin-versions) +(push (purecopy '(map 3 1)) package--builtin-versions) (register-definition-prefixes "map" '("map-")) @@ -22479,7 +22564,7 @@ The default is 20. If LIMIT is negative, do not limit the listing. \(fn &optional LIMIT)" t nil) -(register-definition-prefixes "mule-diag" '("charset-history" "describe-font-internal" "insert-section" "list-" "print-" "sort-listed-character-sets")) +(register-definition-prefixes "mule-diag" '("charset-history" "describe-font-internal" "insert-section" "list-" "mule--kbd-at" "print-" "sort-listed-character-sets")) ;;;*** @@ -22603,7 +22688,9 @@ QUALITY can be: `approximate', in which case we may cut some corners to avoid excessive work. `exact', in which case we may end up re-(en/de)coding a large - part of the file/buffer, this can be expensive and slow. + part of the file/buffer, this can be expensive and slow. (It + is an error to request the `exact' method when the buffer's + EOL format is not yet decided.) nil, in which case we may return nil rather than an approximation. \(fn BYTE &optional QUALITY CODING-SYSTEM)" nil nil) @@ -22617,7 +22704,9 @@ QUALITY can be: `approximate', in which case we may cut some corners to avoid excessive work. `exact', in which case we may end up re-(en/de)coding a large - part of the file/buffer, this can be expensive and slow. + part of the file/buffer, this can be expensive and slow. (It + is an error to request the `exact' method when the buffer's + EOL format is not yet decided.) nil, in which case we may return nil rather than an approximation. \(fn POSITION &optional QUALITY CODING-SYSTEM)" nil nil) @@ -22629,13 +22718,13 @@ QUALITY can be: ;;;### (autoloads nil "mwheel" "mwheel.el" (0 0 0 0)) ;;; Generated autoloads from mwheel.el -(defcustom mouse-wheel-mode t "\ +(defvar mouse-wheel-mode t "\ Non-nil if Mouse-Wheel mode is enabled. See the `mouse-wheel-mode' command for a description of this minor mode. Setting this variable directly does not take effect; either customize it (see the info node `Easy Customization') -or call the function `mouse-wheel-mode'." :set #'custom-set-minor-mode :initialize 'custom-initialize-delay :type 'boolean :group 'mouse) +or call the function `mouse-wheel-mode'.") (custom-autoload 'mouse-wheel-mode "mwheel" nil) @@ -25099,6 +25188,19 @@ of the elements of LIST is performed as if by `pcase-let'. (function-put 'pcase-dolist 'lisp-indent-function '1) +(autoload 'pcase-setq "pcase" "\ +Assign values to variables by destructuring with `pcase'. +PATTERNS are normal `pcase' patterns, and VALUES are expression. + +Evaluation happens sequentially as in `setq' (not in parallel). + +An example: (pcase-setq `((,a) [(,b)]) '((1) [(2)])) + +VAL is presumed to match PAT. Failure to match may signal an error or go +undetected, binding variables to arbitrary values, such as nil. + +\(fn PATTERNS VALUE PATTERN VALUES ...)" nil t) + (autoload 'pcase-defmacro "pcase" "\ Define a new kind of pcase PATTERN, by macro expansion. Patterns of the form (NAME ...) will be expanded according @@ -26303,7 +26405,7 @@ Open profile FILENAME. ;;;### (autoloads nil "project" "progmodes/project.el" (0 0 0 0)) ;;; Generated autoloads from progmodes/project.el -(push (purecopy '(project 0 6 0)) package--builtin-versions) +(push (purecopy '(project 0 6 1)) package--builtin-versions) (autoload 'project-current "project" "\ Return the project instance in DIRECTORY, defaulting to `default-directory'. @@ -28076,10 +28178,10 @@ disabled. ;;;*** -;;;### (autoloads nil "rfc2368" "mail/rfc2368.el" (0 0 0 0)) -;;; Generated autoloads from mail/rfc2368.el +;;;### (autoloads nil "rfc6068" "mail/rfc6068.el" (0 0 0 0)) +;;; Generated autoloads from mail/rfc6068.el -(register-definition-prefixes "rfc2368" '("rfc2368-")) +(register-definition-prefixes "rfc6068" '("rfc6068-")) ;;;*** @@ -28919,7 +29021,8 @@ Zero-width assertions: these all match the empty string in specific places. \(literal EXPR) Match the literal string from evaluating EXPR at run time. \(regexp EXPR) Match the string regexp from evaluating EXPR at run time. -\(eval EXPR) Match the rx sexp from evaluating EXPR at compile time. +\(eval EXPR) Match the rx sexp from evaluating EXPR at macro-expansion + (compile) time. Additional constructs can be defined using `rx-define' and `rx-let', which see. @@ -30799,7 +30902,7 @@ then `snmpv2-mode-hook'." t nil) ;;;### (autoloads nil "so-long" "so-long.el" (0 0 0 0)) ;;; Generated autoloads from so-long.el -(push (purecopy '(so-long 1 0)) package--builtin-versions) +(push (purecopy '(so-long 1 1 1)) package--builtin-versions) (autoload 'so-long-commentary "so-long" "\ View the so-long documentation in `outline-mode'." t nil) @@ -32117,6 +32220,14 @@ Truncate STRING to LENGTH, replacing initial surplus with \"...\". \(fn STRING LENGTH)" nil nil) +(autoload 'string-clean-whitespace "subr-x" "\ +Clean up whitespace in STRING. +All sequences of whitespaces in STRING are collapsed into a +single space character, and leading/trailing whitespace is +removed. + +\(fn STRING)" nil nil) + (autoload 'string-lines "subr-x" "\ Split STRING into a list of lines. If OMIT-NULLS, empty lines will be removed from the results. @@ -32184,8 +32295,11 @@ or call the function `global-subword-mode'.") (autoload 'global-subword-mode "subword" "\ Toggle Subword mode in all buffers. With prefix ARG, enable Global Subword mode if ARG is positive; -otherwise, disable it. If called from Lisp, enable the mode if ARG is -omitted or nil. +otherwise, disable it. + +If called from Lisp, toggle the mode if ARG is `toggle'. +Enable the mode if ARG is nil, omitted, or is a positive number. +Disable the mode if ARG is a negative number. Subword mode is enabled in all buffers where `(lambda nil \(subword-mode 1))' would do it. @@ -32235,8 +32349,11 @@ or call the function `global-superword-mode'.") (autoload 'global-superword-mode "subword" "\ Toggle Superword mode in all buffers. With prefix ARG, enable Global Superword mode if ARG is positive; -otherwise, disable it. If called from Lisp, enable the mode if ARG is -omitted or nil. +otherwise, disable it. + +If called from Lisp, toggle the mode if ARG is `toggle'. +Enable the mode if ARG is nil, omitted, or is a positive number. +Disable the mode if ARG is a negative number. Superword mode is enabled in all buffers where `(lambda nil \(superword-mode 1))' would do it. @@ -32372,8 +32489,11 @@ or call the function `global-tab-line-mode'.") (autoload 'global-tab-line-mode "tab-line" "\ Toggle Tab-Line mode in all buffers. With prefix ARG, enable Global Tab-Line mode if ARG is positive; -otherwise, disable it. If called from Lisp, enable the mode if ARG is -omitted or nil. +otherwise, disable it. + +If called from Lisp, toggle the mode if ARG is `toggle'. +Enable the mode if ARG is nil, omitted, or is a positive number. +Disable the mode if ARG is a negative number. Tab-Line mode is enabled in all buffers where `tab-line-mode--turn-on' would do it. @@ -33727,12 +33847,16 @@ positions of the thing found. Return the THING at point. THING should be a symbol specifying a type of syntactic entity. Possibilities include `symbol', `list', `sexp', `defun', -`filename', `url', `email', `uuid', `word', `sentence', `whitespace', -`line', `number', and `page'. +`filename', `existing-filename', `url', `email', `uuid', `word', +`sentence', `whitespace', `line', `number', and `page'. When the optional argument NO-PROPERTIES is non-nil, strip text properties from the return value. +If the current buffer uses fields (see Info node `(elisp)Fields'), +this function will narrow to the field before identifying the +thing at point. + See the file `thingatpt.el' for documentation on how to define a symbol as a valid THING. @@ -34165,25 +34289,37 @@ Valid ZONE values are described in the documentation of `format-time-string'. (put 'time-stamp-pattern 'safe-local-variable 'stringp) (autoload 'time-stamp "time-stamp" "\ -Update the time stamp string(s) in the buffer. -A template in a file can be automatically updated with a new time stamp -every time you save the file. Add this line to your init file: - (add-hook \\='before-save-hook \\='time-stamp) -or customize option `before-save-hook'. -Normally the template must appear in the first 8 lines of a file and -look like one of the following: +Update any time stamp string(s) in the buffer. +This function looks for a time stamp template and updates it with +the current date, time, and/or other info. + +The template, which you manually create on one of the first 8 lines +of the file before running this function, by default can look like +one of the following (your choice): Time-stamp: <> Time-stamp: \" \" -The time stamp is written between the brackets or quotes: +This function writes the current time between the brackets or quotes, +by default formatted like this: Time-stamp: <2020-08-07 17:10:21 gildea> -The time stamp is updated only if the variable -`time-stamp-active' is non-nil. -The format of the time stamp is set by the variable -`time-stamp-pattern' or `time-stamp-format'. -The variables `time-stamp-pattern', `time-stamp-line-limit', -`time-stamp-start', `time-stamp-end', `time-stamp-count', and -`time-stamp-inserts-lines' control finding the template." t nil) +Although you can run this function manually to update a time stamp +once, usually you want automatic time stamp updating. + +A time stamp can be automatically updated with current information +every time you save a file. To enable time-stamping for all files, +customize option `before-save-hook' or add this line to your init file: + (add-hook \\='before-save-hook \\='time-stamp) + +To enable automatic time-stamping for only a specific file, add +this line to a local variables list near the end of the file: + eval: (add-hook \\='before-save-hook \\='time-stamp nil t) + +If the file has no time-stamp template, this function does nothing. + +You can set `time-stamp-pattern' in a files's local variables list +to customize the information in the time stamp and where it is written. + +The time stamp is updated only if `time-stamp-active' is non-nil." t nil) (autoload 'time-stamp-toggle-active "time-stamp" "\ Toggle `time-stamp-active', setting whether \\[time-stamp] updates a buffer. @@ -34219,6 +34355,9 @@ updating. With prefix ARG, turn mode line display on if and only if ARG is positive. Returns the new status of timeclock mode line display (non-nil means on). +If using a customized `timeclock-workday' value, this should be +set before switching this mode on. + \(fn &optional ARG)" t nil) (autoload 'timeclock-in "timeclock" "\ @@ -35508,7 +35647,9 @@ or call the function `url-handler-mode'.") (custom-autoload 'url-handler-mode "url-handlers" nil) (autoload 'url-handler-mode "url-handlers" "\ -Toggle using `url' library for URL filenames (URL Handler mode). +Handle URLs as if they were file names throughout Emacs. +After switching on this minor mode, Emacs file primitives handle +URLs. For instance: This is a minor mode. If called interactively, toggle the `Url-Handler mode' mode. If the prefix argument is positive, enable @@ -35524,6 +35665,12 @@ evaluate `(default-value 'url-handler-mode)'. The mode's hook is called both when the mode is enabled and when it is disabled. + (file-exists-p \"https://www.gnu.org/\") + => t + +and `C-x C-f https://www.gnu.org/ RET' will give you the HTML at +that URL in a buffer. + \(fn &optional ARG)" t nil) (autoload 'url-file-handler "url-handlers" "\ @@ -36483,11 +36630,6 @@ log entries should be gathered. \(fn &rest ARGS)" t nil) -(autoload 'vc-branch-part "vc" "\ -Return the branch part of a revision number REV. - -\(fn REV)" nil nil) - (register-definition-prefixes "vc" '("vc-" "with-vc-properties")) ;;;*** @@ -38984,6 +39126,8 @@ definition for IDENTIFIER, display it in the selected window. Otherwise, display the list of the possible definitions in a buffer where the user can select from the list. +Use \\[xref-pop-marker-stack] to return back to where you invoked this command. + \(fn IDENTIFIER)" t nil) (autoload 'xref-find-definitions-other-window "xref" "\ @@ -39012,6 +39156,12 @@ This command is intended to be bound to a mouse event. \(fn EVENT)" t nil) +(autoload 'xref-find-references-at-mouse "xref" "\ +Find references to the identifier at or around mouse click. +This command is intended to be bound to a mouse event. + +\(fn EVENT)" t nil) + (autoload 'xref-find-apropos "xref" "\ Find all meaningful symbols that match PATTERN. The argument has the same meaning as in `apropos'. commit c0243d9e8218183f6b8724d7143e62e271e17189 Author: Kien Nguyen Date: Wed Sep 1 18:56:51 2021 +0900 * Add a dll loader entry for gcc_jit_context_new_cast (bug#50315) * src/comp.c: Add a dll loader entry for 'gcc_jit_context_new_cast' (bug#50315). diff --git a/src/comp.c b/src/comp.c index 3ea2836560..7e21331e66 100644 --- a/src/comp.c +++ b/src/comp.c @@ -71,6 +71,7 @@ along with GNU Emacs. If not, see . */ #undef gcc_jit_context_new_binary_op #undef gcc_jit_context_new_call #undef gcc_jit_context_new_call_through_ptr +#undef gcc_jit_context_new_cast #undef gcc_jit_context_new_comparison #undef gcc_jit_context_new_field #undef gcc_jit_context_new_function @@ -176,6 +177,9 @@ DEF_DLL_FN (gcc_jit_rvalue *, gcc_jit_context_new_call, DEF_DLL_FN (gcc_jit_rvalue *, gcc_jit_context_new_call_through_ptr, (gcc_jit_context *ctxt, gcc_jit_location *loc, gcc_jit_rvalue *fn_ptr, int numargs, gcc_jit_rvalue **args)); +DEF_DLL_FN (gcc_jit_rvalue *, gcc_jit_context_new_cast, + (gcc_jit_context *ctxt, gcc_jit_location *loc, + gcc_jit_rvalue *rvalue, gcc_jit_type *type)); DEF_DLL_FN (gcc_jit_rvalue *, gcc_jit_context_new_comparison, (gcc_jit_context *ctxt, gcc_jit_location *loc, enum gcc_jit_comparison op, gcc_jit_rvalue *a, gcc_jit_rvalue *b)); @@ -288,6 +292,7 @@ init_gccjit_functions (void) LOAD_DLL_FN (library, gcc_jit_context_new_binary_op); LOAD_DLL_FN (library, gcc_jit_context_new_call); LOAD_DLL_FN (library, gcc_jit_context_new_call_through_ptr); + LOAD_DLL_FN (library, gcc_jit_context_new_cast); LOAD_DLL_FN (library, gcc_jit_context_new_comparison); LOAD_DLL_FN (library, gcc_jit_context_new_field); LOAD_DLL_FN (library, gcc_jit_context_new_function); @@ -358,6 +363,7 @@ init_gccjit_functions (void) #define gcc_jit_context_new_binary_op fn_gcc_jit_context_new_binary_op #define gcc_jit_context_new_call fn_gcc_jit_context_new_call #define gcc_jit_context_new_call_through_ptr fn_gcc_jit_context_new_call_through_ptr +#define gcc_jit_context_new_cast fn_gcc_jit_context_new_cast #define gcc_jit_context_new_comparison fn_gcc_jit_context_new_comparison #define gcc_jit_context_new_field fn_gcc_jit_context_new_field #define gcc_jit_context_new_function fn_gcc_jit_context_new_function commit 2c662e6d66165db8ead2f4d19a61af521807b8ba Author: Drew Adams Date: Wed Sep 1 11:42:48 2021 +0200 Add new command `clone-frame' * doc/emacs/frames.texi (Creating Frames): Document it. * lisp/frame.el (clone-frame): New command and keystroke (bug#34715). diff --git a/doc/emacs/frames.texi b/doc/emacs/frames.texi index 22f22efaca..a32181e73b 100644 --- a/doc/emacs/frames.texi +++ b/doc/emacs/frames.texi @@ -452,7 +452,14 @@ buffer to select: @item C-x 5 2 @kindex C-x 5 2 @findex make-frame-command -Create a new frame (@code{make-frame-command}). +Create a new frame using the default frame parameters +(@code{make-frame-command}). + +@item C-x 5 c +@kindex C-x 5 c +@findex clone-frame +Create a new frame using the parameters of the current frame +(@code{clone-frame}). @item C-x 5 b @var{bufname} @key{RET} Select buffer @var{bufname} in another frame. This runs diff --git a/etc/NEWS b/etc/NEWS index 66006db8e0..0e1edd648d 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -343,6 +343,11 @@ commands. The new keystrokes are 'C-x x g' ('revert-buffer-quick'), ** Commands 'set-frame-width' and 'set-frame-height' can now get their input using the minibuffer. ++++ +** New command 'clone-frame' (bound to 'C-x 5 c'). +This is like 'C-x 5 2', but uses the frame parameters of the current +frame instead of 'default-frame-alist'. + --- ** New help window when Emacs prompts before opening a large file. Commands like 'find-file' or 'visit-tags-table' ask to visit a file diff --git a/lisp/frame.el b/lisp/frame.el index 28601b81a4..f36a34db7d 100644 --- a/lisp/frame.el +++ b/lisp/frame.el @@ -787,6 +787,23 @@ When called from Lisp, returns the new frame." (make-frame) (select-frame (make-frame)))) +(defun clone-frame (&optional frame use-default-parameters) + "Make a new frame with the same parameters as FRAME. +With a prefix arg (USE-DEFAULT-PARAMETERS), use +`default-frame-alist' instead. + +FRAME defaults to the selected frame. The frame is created on the +same terminal as FRAME. If the terminal is a text-only terminal then +also select the new frame." + (interactive "i\nP") + (if use-default-parameters + (make-frame-command) + (let* ((default-frame-alist (frame-parameters frame)) + (new-frame (make-frame))) + (unless (display-graphic-p) + (select-frame new-frame)) + new-frame))) + (defvar before-make-frame-hook nil "Functions to run before `make-frame' creates a new frame.") @@ -2807,6 +2824,7 @@ See also `toggle-frame-maximized'." (define-key ctl-x-5-map "0" #'delete-frame) (define-key ctl-x-5-map "o" #'other-frame) (define-key ctl-x-5-map "5" #'other-frame-prefix) +(define-key ctl-x-5-map "c" #'clone-frame) (define-key global-map [f11] #'toggle-frame-fullscreen) (define-key global-map [(meta f10)] #'toggle-frame-maximized) (define-key esc-map [f10] #'toggle-frame-maximized) commit a4e3e0f89e1e06fd87e809f8b578fae59c34a9a0 Author: Glenn Morris Date: Wed Sep 1 11:26:51 2021 +0200 Make set-foreground-color display completions using foreground colors * lisp/faces.el (defined-colors-with-face-attributes): Also create colors for foregrounds (bug#33799). (read-color): Also allow varying the foreground color. * lisp/frame.el (set-foreground-color): Vary the foreground color. diff --git a/lisp/faces.el b/lisp/faces.el index a3a6f1b78d..a5aef757b1 100644 --- a/lisp/faces.el +++ b/lisp/faces.el @@ -1795,18 +1795,21 @@ If FRAME is nil, that stands for the selected frame." (mapcar 'car (tty-color-alist frame)))) (defalias 'x-defined-colors 'defined-colors) -(defun defined-colors-with-face-attributes (&optional frame) +(defun defined-colors-with-face-attributes (&optional frame foreground) "Return a list of colors supported for a particular frame. See `defined-colors' for arguments and return value. In contrast to `defined-colors' the elements of the returned list are color strings with text properties, that make the color names render -with the color they represent as background color." +with the color they represent as background color (if FOREGROUND +is nil; otherwise use the foreground color)." (mapcar (lambda (color-name) - (let ((foreground (readable-foreground-color color-name)) - (color (copy-sequence color-name))) - (propertize color 'face (list :foreground foreground - :background color)))) + (let ((color (copy-sequence color-name))) + (propertize color 'face + (if foreground + (list :foreground color) + (list :foreground (readable-foreground-color color-name) + :background color))))) (defined-colors frame))) (defun readable-foreground-color (color) @@ -1915,7 +1918,8 @@ If omitted or nil, that stands for the selected frame's display." (x-display-grayscale-p display) (> (tty-color-gray-shades display) 2))) -(defun read-color (&optional prompt convert-to-RGB allow-empty-name msg) +(defun read-color (&optional prompt convert-to-RGB allow-empty-name msg + foreground) "Read a color name or RGB triplet. Completion is available for color names, but not for RGB triplets. @@ -1942,13 +1946,18 @@ If optional arg ALLOW-EMPTY-NAME is non-nil, the user is allowed to enter an empty color name (the empty string). Interactively, or with optional arg MSG non-nil, print the -resulting color name in the echo area." +resulting color name in the echo area. + +Interactively, displays a list of colored completions. If optional +argument FOREGROUND is non-nil, shows them as foregrounds, otherwise +as backgrounds." (interactive "i\np\ni\np") ; Always convert to RGB interactively. (let* ((completion-ignore-case t) (colors (append '("foreground at point" "background at point") (if allow-empty-name '("")) (if (display-color-p) - (defined-colors-with-face-attributes) + (defined-colors-with-face-attributes + nil foreground) (defined-colors)))) (color (completing-read (or prompt "Color (name or #RGB triplet): ") diff --git a/lisp/frame.el b/lisp/frame.el index 146fe278b3..28601b81a4 100644 --- a/lisp/frame.el +++ b/lisp/frame.el @@ -1507,7 +1507,7 @@ To get the frame's current background color, use `frame-parameters'." "Set the foreground color of the selected frame to COLOR-NAME. When called interactively, prompt for the name of the color to use. To get the frame's current foreground color, use `frame-parameters'." - (interactive (list (read-color "Foreground color: "))) + (interactive (list (read-color "Foreground color: " nil nil nil t))) (modify-frame-parameters (selected-frame) (list (cons 'foreground-color color-name))) (or window-system commit fffcc7ab25021fd9d73d50cf685a77777d38265c Author: Lars Ingebrigtsen Date: Wed Sep 1 10:32:49 2021 +0200 Fix (setf (map-elt map key) (my-func)) * lisp/emacs-lisp/map.el (map-elt): Ensure that the value isn't referenced more than once (bug#50290). diff --git a/lisp/emacs-lisp/map.el b/lisp/emacs-lisp/map.el index 988a62a4e3..77431f0c59 100644 --- a/lisp/emacs-lisp/map.el +++ b/lisp/emacs-lisp/map.el @@ -119,14 +119,16 @@ or array." ((key key) (default default) (testfn testfn)) (funcall do `(map-elt ,mgetter ,key ,default) (lambda (v) - `(condition-case nil - ;; Silence warnings about the hidden 4th arg. - (with-no-warnings (map-put! ,mgetter ,key ,v ,testfn)) - (map-not-inplace - ,(funcall msetter - `(map-insert ,mgetter ,key ,v)) - ;; Always return the value. - ,v)))))))) + (macroexp-let2 nil v v + `(condition-case nil + ;; Silence warnings about the hidden 4th arg. + (with-no-warnings + (map-put! ,mgetter ,key ,v ,testfn)) + (map-not-inplace + ,(funcall msetter + `(map-insert ,mgetter ,key ,v)) + ;; Always return the value. + ,v))))))))) ;; `testfn' is deprecated. (advertised-calling-convention (map key &optional default) "27.1")) ;; Can't use `cl-defmethod' with `advertised-calling-convention'. diff --git a/test/lisp/emacs-lisp/map-tests.el b/test/lisp/emacs-lisp/map-tests.el index 658ed2e711..c0f0dbc92b 100644 --- a/test/lisp/emacs-lisp/map-tests.el +++ b/test/lisp/emacs-lisp/map-tests.el @@ -521,5 +521,14 @@ Evaluate BODY for each created map." 'value2)) (should (equal (map-elt ht 'key) 'value2)))) +(ert-deftest test-setf-map-with-function () + (let ((num 0) + (map nil)) + (setf (map-elt map 'foo) + (funcall (lambda () + (cl-incf num)))) + ;; Check that the function is only called once. + (should (= num 1)))) + (provide 'map-tests) ;;; map-tests.el ends here commit 4a1505904e3606046c201f87deec1171f7d4d406 Author: Lars Ingebrigtsen Date: Wed Sep 1 10:14:33 2021 +0200 Autoload calc-grab-sum-across and calc-grab-sum-down * lisp/calc/calc.el (calc-grab-sum-down): (calc-grab-sum-across): Autoload, since they can be used from outside Calc (bug#50311). diff --git a/lisp/calc/calc.el b/lisp/calc/calc.el index a10b317830..27a6cff627 100644 --- a/lisp/calc/calc.el +++ b/lisp/calc/calc.el @@ -3397,12 +3397,14 @@ and all digits are kept, regardless of Calc's current precision." (require 'calc-ext) (calc-do-grab-rectangle top bot arg)) +;;;###autoload (defun calc-grab-sum-down (top bot arg) "Parse a rectangle as a matrix of numbers and sum its columns." (interactive "r\nP") (require 'calc-ext) (calc-do-grab-rectangle top bot arg 'calcFunc-reduced)) +;;;###autoload (defun calc-grab-sum-across (top bot arg) "Parse a rectangle as a matrix of numbers and sum its rows." (interactive "r\nP") commit 45793b195cf36adfff26d94e65e15429ff9c2235 Author: Miha Rihtaršič Date: Wed Sep 1 10:10:44 2021 +0200 In batch mode, avoid killing Emacs with C-g in the minibuffer * src/keyboard.c (Fcommand_error_default_function): Don't kill emacs when handling the minibuffer-quit condition (bug#48603). diff --git a/src/keyboard.c b/src/keyboard.c index 81ff9df153..6a8c33ae3b 100644 --- a/src/keyboard.c +++ b/src/keyboard.c @@ -1009,25 +1009,28 @@ Default value of `command-error-function'. */) (Lisp_Object data, Lisp_Object context, Lisp_Object signal) { struct frame *sf = SELECTED_FRAME (); - Lisp_Object conditions; + Lisp_Object conditions = Fget (XCAR (data), Qerror_conditions); + int is_minibuffer_quit = !NILP (Fmemq (Qminibuffer_quit, conditions)); CHECK_STRING (context); /* If the window system or terminal frame hasn't been initialized - yet, or we're not interactive, write the message to stderr and exit. */ - if (!sf->glyphs_initialized_p - /* The initial frame is a special non-displaying frame. It - will be current in daemon mode when there are no frames - to display, and in non-daemon mode before the real frame - has finished initializing. If an error is thrown in the - latter case while creating the frame, then the frame - will never be displayed, so the safest thing to do is - write to stderr and quit. In daemon mode, there are - many other potential errors that do not prevent frames - from being created, so continuing as normal is better in - that case. */ - || (!IS_DAEMON && FRAME_INITIAL_P (sf)) - || noninteractive) + yet, or we're not interactive, write the message to stderr and exit. + Don't do this for the minibuffer-quit condition. */ + if (!is_minibuffer_quit + && (!sf->glyphs_initialized_p + /* The initial frame is a special non-displaying frame. It + will be current in daemon mode when there are no frames + to display, and in non-daemon mode before the real frame + has finished initializing. If an error is thrown in the + latter case while creating the frame, then the frame + will never be displayed, so the safest thing to do is + write to stderr and quit. In daemon mode, there are + many other potential errors that do not prevent frames + from being created, so continuing as normal is better in + that case. */ + || (!IS_DAEMON && FRAME_INITIAL_P (sf)) + || noninteractive)) { print_error_message (data, Qexternal_debugging_output, SSDATA (context), signal); @@ -1036,12 +1039,10 @@ Default value of `command-error-function'. */) } else { - conditions = Fget (XCAR (data), Qerror_conditions); - clear_message (1, 0); message_log_maybe_newline (); - if (!NILP (Fmemq (Qminibuffer_quit, conditions))) + if (is_minibuffer_quit) { Fding (Qt); } commit a0be0cdbd23947e59b4108125a20c7f9c800a052 Author: Marco Centurion Date: Wed Sep 1 09:37:12 2021 +0200 Use "gzip -d" instead of "gunzip" * lisp/dired-aux.el (dired-compress-file-suffixes): Use "gzip -d" instead of "gunzip" since we already assume that "gzip" exists on the system (bug#10990). Copyright-paperwork-exempt: yes diff --git a/lisp/dired-aux.el b/lisp/dired-aux.el index 0b8c693b29..8e00af8f96 100644 --- a/lisp/dired-aux.el +++ b/lisp/dired-aux.el @@ -1137,12 +1137,12 @@ present. A FMT of \"\" will suppress the messaging." ("\\.tar\\.gz\\'" "" "gzip -dc %i | tar -xf -") ("\\.tar\\.xz\\'" "" "xz -dc %i | tar -xf -") ("\\.tgz\\'" "" "gzip -dc %i | tar -xf -") - ("\\.gz\\'" "" "gunzip") + ("\\.gz\\'" "" "gzip -d") ("\\.lz\\'" "" "lzip -d") ("\\.Z\\'" "" "uncompress") ;; For .z, try gunzip. It might be an old gzip file, ;; or it might be from compact? pack? (which?) but gunzip handles both. - ("\\.z\\'" "" "gunzip") + ("\\.z\\'" "" "gzip -d") ("\\.dz\\'" "" "dictunzip") ("\\.tbz\\'" ".tar" "bunzip2") ("\\.bz2\\'" "" "bunzip2") commit 8761d30da0c4d7d9fd59c192bc283e17b04c5db3 Author: Philip Kaludercic Date: Tue Aug 31 22:24:02 2021 +0200 Avoid failing if vc backend doesn't implement ignore-completion-table * project.el (project-ignores): Handle vc-not-supported signals diff --git a/lisp/progmodes/project.el b/lisp/progmodes/project.el index ae9bf03571..e420a4ccca 100644 --- a/lisp/progmodes/project.el +++ b/lisp/progmodes/project.el @@ -604,7 +604,9 @@ backend implementation of `project-external-roots'.") (replace-match "./" t t entry 1) (concat "./" entry))) (t entry))) - (vc-call-backend backend 'ignore-completion-table root)))) + (condition-case nil + (vc-call-backend backend 'ignore-completion-table root) + (vc-not-supported () nil))))) (project--value-in-dir 'project-vc-ignores root) (mapcar (lambda (dir) commit e5c481b61c26bcf83779db9fb3ac6b96bc50ab2e Author: Michael Albinus Date: Tue Aug 31 10:09:38 2021 +0200 ; Add comment to tramp-read-passwd for debugging diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el index 0973b5b444..11c417f832 100644 --- a/lisp/net/tramp.el +++ b/lisp/net/tramp.el @@ -5590,6 +5590,9 @@ verbosity of 6." (string-prefix-p comm process-name) (throw 'result t))))))) +;; When calling "emacs -Q", `auth-source-search' won't be called. If +;; you want to debug exactly this case, call "emacs -Q --eval '(setq +;; tramp-cache-read-persistent-data t)'" instead. (defun tramp-read-passwd (proc &optional prompt) "Read a password from user (compat function). Consults the auth-source package. commit 03dcceeeeeda6cefe4c0a79be328dd44b289b20b Author: Lars Ingebrigtsen Date: Tue Aug 31 04:50:18 2021 +0200 Rename xref--mouse-2 and adjust documentation * doc/emacs/maintaining.texi (Xref Commands): `mouse-1' is bound to `xref-goto-xref', not `mouse-2' (bug#35376). (Xref Commands): Mention what `mouse-2' does. * lisp/progmodes/xref.el (xref--button-map): Adjust. (xref-select-and-goto-xref): Rename from xref--mouse-2 (bug#35376). diff --git a/doc/emacs/maintaining.texi b/doc/emacs/maintaining.texi index 3205e6dbdf..008639d1a9 100644 --- a/doc/emacs/maintaining.texi +++ b/doc/emacs/maintaining.texi @@ -2218,10 +2218,15 @@ the special XREF mode: @table @kbd @item @key{RET} -@itemx mouse-2 +@itemx mouse-1 Display the reference on the current line (@code{xref-goto-xref}). With prefix argument, also bury the @file{*xref*} buffer. +@item mouse-2 +The same as @code{mouse-1}, but make the window displaying the +@file{*xref*} buffer the selected window +(@code{xref-select-and-goto-xref}). + @item n @itemx . @findex xref-next-line diff --git a/lisp/progmodes/xref.el b/lisp/progmodes/xref.el index d004a0c32c..d495a4e292 100644 --- a/lisp/progmodes/xref.el +++ b/lisp/progmodes/xref.el @@ -898,17 +898,20 @@ beginning of the line." (defvar xref--button-map (let ((map (make-sparse-keymap))) (define-key map [mouse-1] #'xref-goto-xref) - (define-key map [mouse-2] #'xref--mouse-2) + (define-key map [mouse-2] #'xref-select-and-goto-xref) map)) -(defun xref--mouse-2 (event) - "Move point to the button and show the xref definition." +(defun xref-select-and-goto-xref (event) + "Move point to the button and show the xref definition. +The window showing the xref buffer will be selected." (interactive "e") (mouse-set-point event) (forward-line 0) (or (get-text-property (point) 'xref-item) (xref--search-property 'xref-item)) (xref-show-location-at-point)) +(define-obsolete-function-alias + 'xref--mouse-2 #'xref-select-and-goto-xref "28.1") (defcustom xref-truncation-width 400 "The column to visually \"truncate\" each Xref buffer line to." commit bd17fe1d9e82ababab84b11cd689dcb0315742dd Author: Lars Ingebrigtsen Date: Tue Aug 31 04:31:01 2021 +0200 Fix point placement after ispell-complete-word * lisp/textmodes/ispell.el (ispell-complete-word): Leave point at the end of the inserted word instead of a less than useful amount of distance from the start of the word (bug#37552). diff --git a/lisp/textmodes/ispell.el b/lisp/textmodes/ispell.el index 632b00111a..c2f6b35df8 100644 --- a/lisp/textmodes/ispell.el +++ b/lisp/textmodes/ispell.el @@ -3636,8 +3636,7 @@ sequence inside of a word. Standard ispell choices are then available." ;; FIXME: completion-at-point-function. (interactive "P") - (let ((cursor-location (point)) - (case-fold-search-val case-fold-search) + (let ((case-fold-search-val case-fold-search) (word (ispell-get-word nil "\\*")) ; force "previous-word" processing. start end possibilities replacement) (setq start (car (cdr word)) @@ -3674,18 +3673,12 @@ Standard ispell choices are then available." (ispell-add-per-file-word-list word)) (replacement ; REPLACEMENT WORD (delete-region start end) - (setq word (if (atom replacement) replacement (car replacement)) - cursor-location (+ (- (length word) (- end start)) - cursor-location)) - (insert word) - (if (not (atom replacement)) ; recheck spelling of replacement. - (progn - (goto-char cursor-location) - (ispell-word nil t))))) + (insert (if (atom replacement) replacement (car replacement))) + (unless (atom replacement) ; recheck spelling of replacement. + (ispell-word nil t)))) (if (get-buffer ispell-choices-buffer) (kill-buffer ispell-choices-buffer)))) - (ispell-pdict-save ispell-silently-savep) - (goto-char cursor-location))) + (ispell-pdict-save ispell-silently-savep))) ;;;###autoload commit b61282138804d126a53d718f2d2b0549bf087afa Author: Lars Ingebrigtsen Date: Tue Aug 31 04:13:58 2021 +0200 call-process doc string clarification * src/callproc.c (Fcall_process): Explicitly say that "output" means both stdout and stderr (bug#37906). diff --git a/src/callproc.c b/src/callproc.c index 675b78daf3..fa43f97384 100644 --- a/src/callproc.c +++ b/src/callproc.c @@ -232,6 +232,8 @@ directory where the process is run (see below). If you want to make the input come from an Emacs buffer, use `call-process-region' instead. Third argument DESTINATION specifies how to handle program's output. +(\"Output\" here means both standard output and standard error +output.) If DESTINATION is a buffer, or t that stands for the current buffer, it means insert output in that buffer before point. If DESTINATION is nil, it means discard output; 0 means discard commit 31b06ea36f8c04fe30e57e7efc9d422a6b21f216 Author: Lars Ingebrigtsen Date: Tue Aug 31 03:47:45 2021 +0200 Make calc plotting through gnuplot work on non-X gnuplots * lisp/calc/calc-graph.el (calc-graph-plot): Fall back on "dumb" if we don't support the terminal (bug#50237). (calc-gnuplot-command): Say whether the command errored out. diff --git a/lisp/calc/calc-graph.el b/lisp/calc/calc-graph.el index 9ac24bf188..9dfdba3930 100644 --- a/lisp/calc/calc-graph.el +++ b/lisp/calc/calc-graph.el @@ -391,6 +391,13 @@ ((>= calc-gnuplot-version 3) "dumb") (t "postscript")))) + (unless (equal device calc-graph-last-device) + (setq calc-graph-last-device device) + (unless (calc-gnuplot-command "set terminal" device) + ;; If gnuplot doesn't support the terminal, then set it + ;; to "dumb". + (calc-gnuplot-command "set terminal dumb") + (setq device "dumb"))) (if (equal device "dumb") (setq device (format "dumb %d %d" (1- (frame-width)) (1- (frame-height))))) @@ -404,10 +411,6 @@ (setq tempoutfile (calc-temp-file-name -1) output tempoutfile)) (setq output (eval output t))) - (or (equal device calc-graph-last-device) - (progn - (setq calc-graph-last-device device) - (calc-gnuplot-command "set terminal" device))) (or (equal output calc-graph-last-output) (progn (setq calc-graph-last-output output) @@ -1411,6 +1414,8 @@ This \"dumb\" driver will be present in Gnuplot 3.0." (calc-graph-view-trail))) (defun calc-gnuplot-command (&rest args) + "Send ARGS to Gnuplot. +Returns nil if Gnuplot signalled an error." (calc-graph-init) (let ((cmd (concat (mapconcat 'identity args " ") "\n"))) (or (calc-graph-w32-p) @@ -1428,9 +1433,11 @@ This \"dumb\" driver will be present in Gnuplot 3.0." (or (calc-graph-w32-p) (accept-process-output (and (not calc-graph-no-wait) calc-gnuplot-process))) - (calc-gnuplot-check-for-errors) - (if (get-buffer-window calc-gnuplot-buffer) - (calc-graph-view-trail))))) + (prog1 + ;; Return nil if we got an error. + (not (calc-gnuplot-check-for-errors)) + (if (get-buffer-window calc-gnuplot-buffer) + (calc-graph-view-trail)))))) (defun calc-graph-init-buffers () (or (and calc-gnuplot-buffer commit 65ddaaf41ffc2b6f49ddf8a5f689dd24ab0a0a98 Author: Lars Ingebrigtsen Date: Tue Aug 31 03:17:21 2021 +0200 Fix abnf parsing of elements * lisp/progmodes/ebnf-abn.el (ebnf-abn-lex): Make parsing work (bug#39663). diff --git a/lisp/progmodes/ebnf-abn.el b/lisp/progmodes/ebnf-abn.el index 2a37110f6a..c3b240ad8b 100644 --- a/lisp/progmodes/ebnf-abn.el +++ b/lisp/progmodes/ebnf-abn.el @@ -530,13 +530,14 @@ See documentation for variable `ebnf-abn-lex'." (let ((prose-p (= (following-char) ?<))) (when prose-p (forward-char) - (or (looking-at ebnf-abn-non-terminal-letter-chars) + (or (looking-at (concat "[" ebnf-abn-non-terminal-letter-chars "]")) (error "Invalid prose value"))) (setq ebnf-abn-lex (ebnf-buffer-substring ebnf-abn-non-terminal-chars)) (when prose-p (or (= (following-char) ?>) (error "Invalid prose value")) + (forward-char) (setq ebnf-abn-lex (concat "<" ebnf-abn-lex ">")))) 'non-terminal) ;; equal: =, =/ commit 50765f3f511d467ff024dda7c84530c759253d18 Author: Lars Ingebrigtsen Date: Tue Aug 31 03:04:22 2021 +0200 Make run-at-time try harder to run at integral multiples * lisp/emacs-lisp/timer.el (timer): Add new slot integral-multiple. (timerp): Adjust. (timer-event-handler): Recompute the delay if requested (bug#39099). (run-at-time): Mark the timer as recomputable if given a t parameter. * src/keyboard.c (decode_timer): Adjust. diff --git a/etc/NEWS b/etc/NEWS index 657e12900f..66006db8e0 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -3145,6 +3145,17 @@ work for `context-menu-mode` in Xterm. * Incompatible Lisp Changes in Emacs 28.1 +--- +** 'run-at-time' now tries harder to implement the t TIME parameter. +If TIME is t, the timer runs at an integral multiple of REPEAT. +(I.e., if given a REPEAT of 60, it'll run at 08:11:00, 08:12:00, +08:13:00.) However, when a machine goes to sleep (or otherwise didn't +get a time slot to run when the timer was scheduled), the timer would +then fire every 60 seconds after the time the timer was fired. This +has now changed, and the timer code now recomputes the integral +multiple every time it runs, which means that if the laptop wakes at +08:16:43, it'll fire at that time, but then at 08:17:00, 08:18:00... + --- ** 'parse-partial-sexp' now signals an error if TO is smaller than FROM. Previously this would lead to the function interpreting FROM as TO and diff --git a/lisp/emacs-lisp/timer.el b/lisp/emacs-lisp/timer.el index 36de29a73a..f7715109c8 100644 --- a/lisp/emacs-lisp/timer.el +++ b/lisp/emacs-lisp/timer.el @@ -29,6 +29,8 @@ (eval-when-compile (require 'cl-lib)) +;; If you change this structure, you also have to change `timerp' +;; (below) and decode_timer in keyboard.c. (cl-defstruct (timer (:constructor nil) (:copier nil) @@ -46,11 +48,16 @@ repeat-delay function args ;What to do when triggered. idle-delay ;If non-nil, this is an idle-timer. - psecs) + psecs + ;; A timer may be created with `t' as the TIME, which means that we + ;; want to run at specific integral multiples of `repeat-delay'. We + ;; then have to recompute this (because the machine may have gone to + ;; sleep, etc). + integral-multiple) (defun timerp (object) "Return t if OBJECT is a timer." - (and (vectorp object) (= (length object) 9))) + (and (vectorp object) (= (length object) 10))) (defsubst timer--check (timer) (or (timerp timer) (signal 'wrong-type-argument (list #'timerp timer)))) @@ -284,6 +291,13 @@ This function is called, by name, directly by the C code." (if (> repeats timer-max-repeats) (timer-inc-time timer (* (timer--repeat-delay timer) repeats))))) + ;; If we want integral multiples, we have to recompute + ;; the repetition. + (when (and (timer--integral-multiple timer) + (not (timer--idle-delay timer))) + (setf (timer--time timer) + (timer-next-integral-multiple-of-time + (current-time) (timer--repeat-delay timer)))) ;; Place it back on the timer-list before running ;; timer--function, so it can cancel-timer itself. (timer-activate timer t cell) @@ -340,45 +354,44 @@ This function returns a timer object which you can use in `cancel-timer'." (interactive "sRun at time: \nNRepeat interval: \naFunction: ") - (or (null repeat) - (and (numberp repeat) (< 0 repeat)) - (error "Invalid repetition interval")) + (when (and repeat + (numberp repeat) + (< repeat 0)) + (error "Invalid repetition interval")) - ;; Special case: nil means "now" and is useful when repeating. - (if (null time) + (let ((timer (timer-create))) + ;; Special case: nil means "now" and is useful when repeating. + (unless time (setq time (current-time))) - ;; Special case: t means the next integral multiple of REPEAT. - (if (and (eq time t) repeat) - (setq time (timer-next-integral-multiple-of-time (current-time) repeat))) + ;; Special case: t means the next integral multiple of REPEAT. + (when (and (eq time t) repeat) + (setq time (timer-next-integral-multiple-of-time (current-time) repeat)) + (setf (timer--integral-multiple timer) t)) - ;; Handle numbers as relative times in seconds. - (if (numberp time) + ;; Handle numbers as relative times in seconds. + (when (numberp time) (setq time (timer-relative-time nil time))) - ;; Handle relative times like "2 hours 35 minutes" - (if (stringp time) - (let ((secs (timer-duration time))) - (if secs - (setq time (timer-relative-time nil secs))))) - - ;; Handle "11:23pm" and the like. Interpret it as meaning today - ;; which admittedly is rather stupid if we have passed that time - ;; already. (Though only Emacs hackers hack Emacs at that time.) - (if (stringp time) - (progn - (require 'diary-lib) - (let ((hhmm (diary-entry-time time)) - (now (decode-time))) - (if (>= hhmm 0) - (setq time - (encode-time 0 (% hhmm 100) (/ hhmm 100) - (decoded-time-day now) - (decoded-time-month now) - (decoded-time-year now) - (decoded-time-zone now))))))) + ;; Handle relative times like "2 hours 35 minutes". + (when (stringp time) + (when-let ((secs (timer-duration time))) + (setq time (timer-relative-time nil secs)))) + + ;; Handle "11:23pm" and the like. Interpret it as meaning today + ;; which admittedly is rather stupid if we have passed that time + ;; already. (Though only Emacs hackers hack Emacs at that time.) + (when (stringp time) + (require 'diary-lib) + (let ((hhmm (diary-entry-time time)) + (now (decode-time))) + (when (>= hhmm 0) + (setq time (encode-time 0 (% hhmm 100) (/ hhmm 100) + (decoded-time-day now) + (decoded-time-month now) + (decoded-time-year now) + (decoded-time-zone now)))))) - (let ((timer (timer-create))) (timer-set-time timer time repeat) (timer-set-function timer function args) (timer-activate timer) diff --git a/src/keyboard.c b/src/keyboard.c index 2e4c4e6aab..81ff9df153 100644 --- a/src/keyboard.c +++ b/src/keyboard.c @@ -4234,7 +4234,7 @@ decode_timer (Lisp_Object timer, struct timespec *result) { Lisp_Object *vec; - if (! (VECTORP (timer) && ASIZE (timer) == 9)) + if (! (VECTORP (timer) && ASIZE (timer) == 10)) return false; vec = XVECTOR (timer)->contents; if (! NILP (vec[0])) commit d2ad64b7a524450bd1a4f59a5e0801abb0637b32 Author: Dmitry Gutov Date: Tue Aug 31 02:47:31 2021 +0300 Move the expansion of abbreviated names to vc-git.el * lisp/vc/vc-git.el (vc-git--literal-pathspec): Perform the expansion of abbreviated file names here instead (bug#39452). * lisp/vc/vc.el (vc-root-diff, vc-print-root-log): Undo the recent change. diff --git a/lisp/vc/vc-git.el b/lisp/vc/vc-git.el index 1cd200cd13..a5431abb40 100644 --- a/lisp/vc/vc-git.el +++ b/lisp/vc/vc-git.el @@ -245,7 +245,11 @@ included in the completions." (defun vc-git--literal-pathspec (file) "Prepend :(literal) path magic to FILE." ;; Good example of file name that needs this: "test[56].xx". - (and file (concat ":(literal)" (file-local-name file)))) + (let ((lname (file-local-name file))) + ;; Expand abbreviated file names. + (when (file-name-absolute-p lname) + (setq lname (expand-file-name lname))) + (and file (concat ":(literal)" lname)))) (defun vc-git--literal-pathspecs (files) "Prepend :(literal) path magic to FILES." diff --git a/lisp/vc/vc.el b/lisp/vc/vc.el index 38204ef91c..8036be390a 100644 --- a/lisp/vc/vc.el +++ b/lisp/vc/vc.el @@ -2055,9 +2055,9 @@ saving the buffer." ;; here, this way the *vc-diff* buffer is setup correctly, so ;; relative file names work. (let ((default-directory rootdir)) - (vc-diff-internal - t (list backend (list (expand-file-name rootdir)) working-revision) nil nil - (called-interactively-p 'interactive)))))) + (vc-diff-internal + t (list backend (list rootdir) working-revision) nil nil + (called-interactively-p 'interactive)))))) ;;;###autoload (defun vc-root-dir () @@ -2603,8 +2603,8 @@ with its diffs (if the underlying VCS supports that)." (setq backend (vc-responsible-backend rootdir)) (unless backend (error "Directory is not version controlled"))) - (setq default-directory (expand-file-name rootdir)) - (vc-print-log-internal backend (list default-directory) revision revision limit + (setq default-directory rootdir) + (vc-print-log-internal backend (list rootdir) revision revision limit (when with-diff 'with-diff)))) ;;;###autoload commit a1887cc5e6c63d89f8495148d32a6927f84f1571 Author: Harald Jörg Date: Mon Aug 30 18:53:51 2021 +0200 ; cperl-mode.el: Fix border cases of inserting with elisp * lisp/progmodes/cperl-mode.el (cperl-unwind-to-safe): Replace (and extend) inline comment by a docstring. Handle edge cases when inserting text with elisp (related to Bug#28962). (cperl-process-here-doc): Add syntax-type `here-doc-start'. (cperl-find-pods-heres): Make sure that the results of this function are immediately visible. * test/lisp/progmodes/cperl-mode-tests.el (cperl-test-bug-14343): Add test cases for "empty" here-documents and inserting at the edges of a here-document. diff --git a/lisp/progmodes/cperl-mode.el b/lisp/progmodes/cperl-mode.el index 727deaba5f..f518501c67 100644 --- a/lisp/progmodes/cperl-mode.el +++ b/lisp/progmodes/cperl-mode.el @@ -3338,8 +3338,10 @@ Works before syntax recognition is done." ;; Each non-literal part is marked `syntax-type' ==> `pod' ;; Each literal part is marked `syntax-type' ==> `in-pod' ;; b) HEREs: +;; The point before start is marked `here-doc-start' ;; Start-to-end is marked `here-doc-group' ==> t ;; The body is marked `syntax-type' ==> `here-doc' +;; and is also marked as style 2 comment ;; The delimiter is marked `syntax-type' ==> `here-doc-delim' ;; c) FORMATs: ;; First line (to =) marked `first-format-line' ==> t @@ -3356,8 +3358,36 @@ Works before syntax recognition is done." ;; (value: 0 in //o, 1 if "interpolated variable" is whole-REx, t otherwise). (defun cperl-unwind-to-safe (before &optional end) - ;; if BEFORE, go to the previous start-of-line on each step of unwinding - (let ((pos (point))) + "Move point back to a safe place, back up one extra line if BEFORE. +A place is \"safe\" if it is not within POD, a here-document, a +format, a quote-like expression, a subroutine attribute list or a +multiline declaration. These places all have special syntactical +rules and need to be parsed as a whole. If END, return the +position of the end of the unsafe construct." + (let ((pos (point)) + (state (syntax-ppss))) + ;; Check edge cases for here-documents first + (when before ; we need a safe start for parsing + (cond + ((or (equal (get-text-property (cperl-1- (point)) 'syntax-type) + 'here-doc-start) + (equal (syntax-after (cperl-1- (point))) + (string-to-syntax "> c"))) + ;; point is either immediately after the start of a here-doc + ;; (which may consist of nothing but one newline) or + ;; immediately after the now-outdated end marker of the + ;; here-doc. In both cases we need to back up to the line + ;; where the here-doc delimiters are defined. + (forward-char -1) + (cperl-backward-to-noncomment (point-min)) + (beginning-of-line)) + ((eq 2 (nth 7 state)) + ;; point is somewhere in a here-document. Back up to the line + ;; where the here-doc delimiters are defined. + (goto-char (nth 8 state)) ; beginning of this here-doc + (cperl-backward-to-noncomment ; skip back over more + (point-min)) ; here-documents (if any) + (beginning-of-line)))) ; skip back over here-doc starters (while (and pos (progn (beginning-of-line) (get-text-property (setq pos (point)) 'syntax-type))) @@ -3657,6 +3687,8 @@ This is part of `cperl-find-pods-heres' (below)." ;; the whole construct: (put-text-property here-doc-start (cperl-1+ here-doc-start) 'front-sticky '(syntax-type)) (cperl-commentify (match-beginning 0) (1- here-doc-end) nil) + (put-text-property (1- here-doc-start) here-doc-start + 'syntax-type 'here-doc-start) (when (> (match-beginning 0) here-doc-start) ;; here-document has non-zero length (cperl-modify-syntax-type (1- here-doc-start) (string-to-syntax "< c")) @@ -3698,6 +3730,7 @@ recursive calls in starting lines of here-documents." cperl-syntax-state nil cperl-syntax-done-to min)) (or max (setq max (point-max))) + (font-lock-flush min max) (let* (go tmpend face head-face b e bb tag qtag b1 e1 argument i c tail tb is-REx is-x-REx REx-subgr-start REx-subgr-end was-subgr i2 hairy-RE diff --git a/test/lisp/progmodes/cperl-mode-tests.el b/test/lisp/progmodes/cperl-mode-tests.el index c03eb52f17..5f3ba4d016 100644 --- a/test/lisp/progmodes/cperl-mode-tests.el +++ b/test/lisp/progmodes/cperl-mode-tests.el @@ -245,6 +245,9 @@ issued by CPerl mode." (defconst cperl--tests-heredoc-face (if (equal cperl-test-mode 'perl-mode) 'perl-heredoc 'font-lock-string-face)) +(defconst cperl--tests-heredoc-delim-face + (if (equal cperl-test-mode 'perl-mode) 'perl-heredoc + 'font-lock-constant-face)) (ert-deftest cperl-test-heredocs () "Test that HERE-docs are fontified with the appropriate face." @@ -430,10 +433,10 @@ under timeout control." "Verify that inserting text into a HERE-doc string with Elisp does not break fontification." (with-temp-buffer - (insert "my $string = < Date: Mon Aug 30 18:26:46 2021 +0200 Implement proper type conversion in native compiler * src/comp.c (enum cast_kind_of_type): Remove. (comp_t): Add cast_ptr_to_int, cast_int_to_ptr, remove cast_type_sizes, cast_type_kind, cast_type_names, cast_union_fields, cast_union_field_biggest_type. (emit_coerce): Remove check for type size. (struct cast_type): Remove bytes_size. (define_type_punning): New function. (define_cast_from_to): Implement proper type conversion. (define_cast_functions): Adjust. (bug#50230) diff --git a/src/comp.c b/src/comp.c index 74a5337f8d..3ea2836560 100644 --- a/src/comp.c +++ b/src/comp.c @@ -499,13 +499,6 @@ static f_reloc_t freloc; #define NUM_CAST_TYPES 15 -enum cast_kind_of_type - { - kind_unsigned, - kind_signed, - kind_pointer - }; - typedef struct { EMACS_INT len; gcc_jit_rvalue *r_val; @@ -571,14 +564,9 @@ typedef struct { be used for the scope. */ gcc_jit_type *cast_union_type; gcc_jit_function *cast_functions_from_to[NUM_CAST_TYPES][NUM_CAST_TYPES]; - /* We add one to make space for the last member which is the "biggest_type" - member. */ - gcc_jit_type *cast_types[NUM_CAST_TYPES + 1]; - size_t cast_type_sizes[NUM_CAST_TYPES + 1]; - enum cast_kind_of_type cast_type_kind[NUM_CAST_TYPES + 1]; - const char *cast_type_names[NUM_CAST_TYPES + 1]; - gcc_jit_field *cast_union_fields[NUM_CAST_TYPES + 1]; - size_t cast_union_field_biggest_type; + gcc_jit_function *cast_ptr_to_int; + gcc_jit_function *cast_int_to_ptr; + gcc_jit_type *cast_types[NUM_CAST_TYPES]; gcc_jit_function *func; /* Current function being compiled. */ bool func_has_non_local; /* From comp-func has-non-local slot. */ EMACS_INT func_speed; /* From comp-func speed slot. */ @@ -1113,13 +1101,6 @@ emit_coerce (gcc_jit_type *new_type, gcc_jit_rvalue *obj) int old_index = type_to_cast_index (old_type); int new_index = type_to_cast_index (new_type); - if (comp.cast_type_sizes[old_index] < comp.cast_type_sizes[new_index] - && comp.cast_type_kind[new_index] == kind_signed) - xsignal3 (Qnative_ice, - build_string ("FIXME: sign extension not implemented"), - build_string (comp.cast_type_names[old_index]), - build_string (comp.cast_type_names[new_index])); - /* Lookup the appropriate cast function in the cast matrix. */ return gcc_jit_context_new_call (comp.ctxt, NULL, @@ -3111,30 +3092,17 @@ define_thread_state_struct (void) gcc_jit_type_get_pointer (gcc_jit_struct_as_type (comp.thread_state_s)); } -struct cast_type -{ - gcc_jit_type *type; - const char *name; - size_t bytes_size; - enum cast_kind_of_type kind; -}; - static gcc_jit_function * -define_cast_from_to (struct cast_type from, int from_index, struct cast_type to, - int to_index) +define_type_punning (const char *name, + gcc_jit_type *from, gcc_jit_field *from_field, + gcc_jit_type *to, gcc_jit_field *to_field) { - /* FIXME: sign extension not implemented. */ - if (comp.cast_type_sizes[from_index] < comp.cast_type_sizes[to_index] - && comp.cast_type_kind[to_index] == kind_signed) - return NULL; - - char *name = format_string ("cast_from_%s_to_%s", from.name, to.name); gcc_jit_param *param = gcc_jit_context_new_param (comp.ctxt, NULL, - from.type, "arg"); + from, "arg"); gcc_jit_function *result = gcc_jit_context_new_function (comp.ctxt, NULL, GCC_JIT_FUNCTION_INTERNAL, - to.type, + to, name, 1, ¶m, @@ -3148,26 +3116,63 @@ define_cast_from_to (struct cast_type from, int from_index, struct cast_type to, comp.cast_union_type, "union_cast"); - /* Zero the union first. */ gcc_jit_block_add_assignment (entry_block, NULL, gcc_jit_lvalue_access_field (tmp_union, NULL, - comp.cast_union_fields[NUM_CAST_TYPES]), - gcc_jit_context_new_rvalue_from_int ( - comp.ctxt, - comp.cast_types[NUM_CAST_TYPES], - 0)); - - gcc_jit_block_add_assignment (entry_block, NULL, - gcc_jit_lvalue_access_field (tmp_union, NULL, - comp.cast_union_fields[from_index]), + from_field), gcc_jit_param_as_rvalue (param)); gcc_jit_block_end_with_return (entry_block, NULL, gcc_jit_rvalue_access_field ( gcc_jit_lvalue_as_rvalue (tmp_union), - NULL, - comp.cast_union_fields[to_index])); + NULL, to_field)); + + return result; +} + +struct cast_type +{ + gcc_jit_type *type; + const char *name; + bool is_ptr; +}; + +static gcc_jit_function * +define_cast_from_to (struct cast_type from, struct cast_type to) +{ + char *name = format_string ("cast_from_%s_to_%s", from.name, to.name); + gcc_jit_param *param = gcc_jit_context_new_param (comp.ctxt, NULL, + from.type, "arg"); + gcc_jit_function *result + = gcc_jit_context_new_function (comp.ctxt, + NULL, + GCC_JIT_FUNCTION_INTERNAL, + to.type, name, + 1, ¶m, 0); + DECL_BLOCK (entry_block, result); + + gcc_jit_rvalue *tmp = gcc_jit_param_as_rvalue (param); + if (from.is_ptr != to.is_ptr) + { + if (from.is_ptr) + { + tmp = gcc_jit_context_new_cast (comp.ctxt, NULL, + tmp, comp.void_ptr_type); + tmp = gcc_jit_context_new_call (comp.ctxt, NULL, + comp.cast_ptr_to_int, 1, &tmp); + } + else + { + tmp = gcc_jit_context_new_cast (comp.ctxt, NULL, + tmp, comp.uintptr_type); + tmp = gcc_jit_context_new_call (comp.ctxt, NULL, + comp.cast_int_to_ptr, 1, &tmp); + } + } + + tmp = gcc_jit_context_new_cast (comp.ctxt, NULL, tmp, to.type); + + gcc_jit_block_end_with_return (entry_block, NULL, tmp); return result; } @@ -3176,69 +3181,58 @@ static void define_cast_functions (void) { struct cast_type cast_types[NUM_CAST_TYPES] - = { { comp.bool_type, "bool", sizeof (bool), kind_unsigned }, - { comp.char_ptr_type, "char_ptr", sizeof (char *), kind_pointer }, - { comp.int_type, "int", sizeof (int), kind_signed }, - { comp.lisp_cons_ptr_type, "cons_ptr", sizeof (struct Lisp_Cons *), - kind_pointer }, - { comp.lisp_obj_ptr_type, "lisp_obj_ptr", sizeof (Lisp_Object *), - kind_pointer }, - { comp.lisp_word_tag_type, "lisp_word_tag", sizeof (Lisp_Word_tag), - kind_unsigned }, - { comp.lisp_word_type, "lisp_word", sizeof (Lisp_Word), - LISP_WORDS_ARE_POINTERS ? kind_pointer : kind_signed }, - { comp.long_long_type, "long_long", sizeof (long long), kind_signed }, - { comp.long_type, "long", sizeof (long), kind_signed }, - { comp.ptrdiff_type, "ptrdiff", sizeof (ptrdiff_t), kind_signed }, - { comp.uintptr_type, "uintptr", sizeof (uintptr_t), kind_unsigned }, - { comp.unsigned_long_long_type, "unsigned_long_long", - sizeof (unsigned long long), kind_unsigned }, - { comp.unsigned_long_type, "unsigned_long", sizeof (unsigned long), - kind_unsigned }, - { comp.unsigned_type, "unsigned", sizeof (unsigned), kind_unsigned }, - { comp.void_ptr_type, "void_ptr", sizeof (void*), kind_pointer } }; - - /* Find the biggest size. It should be unsigned long long, but to be - sure we find it programmatically. */ - size_t biggest_size = 0; - for (int i = 0; i < NUM_CAST_TYPES; ++i) - biggest_size = max (biggest_size, cast_types[i].bytes_size); + = { { comp.bool_type, "bool", false }, + { comp.char_ptr_type, "char_ptr", true }, + { comp.int_type, "int", false }, + { comp.lisp_cons_ptr_type, "lisp_cons_ptr", true }, + { comp.lisp_obj_ptr_type, "lisp_obj_ptr", true }, + { comp.lisp_word_tag_type, "lisp_word_tag", false }, + { comp.lisp_word_type, "lisp_word", LISP_WORDS_ARE_POINTERS }, + { comp.long_long_type, "long_long", false }, + { comp.long_type, "long", false }, + { comp.ptrdiff_type, "ptrdiff", false }, + { comp.uintptr_type, "uintptr", false }, + { comp.unsigned_long_long_type, "unsigned_long_long", false }, + { comp.unsigned_long_type, "unsigned_long", false }, + { comp.unsigned_type, "unsigned", false }, + { comp.void_ptr_type, "void_ptr", true } }; + gcc_jit_field *cast_union_fields[2]; + + /* Define the union used for type punning. */ + cast_union_fields[0] = gcc_jit_context_new_field (comp.ctxt, + NULL, + comp.void_ptr_type, + "void_ptr"); + cast_union_fields[1] = gcc_jit_context_new_field (comp.ctxt, + NULL, + comp.uintptr_type, + "uintptr"); - /* Define the union used for casting. */ - for (int i = 0; i < NUM_CAST_TYPES; ++i) - { - comp.cast_types[i] = cast_types[i].type; - comp.cast_union_fields[i] = gcc_jit_context_new_field (comp.ctxt, - NULL, - cast_types[i].type, - cast_types[i].name); - comp.cast_type_names[i] = cast_types[i].name; - comp.cast_type_sizes[i] = cast_types[i].bytes_size; - comp.cast_type_kind[i] = cast_types[i].kind; - } + comp.cast_union_type + = gcc_jit_context_new_union_type (comp.ctxt, + NULL, + "cast_union", + 2, cast_union_fields); + + comp.cast_ptr_to_int = define_type_punning ("cast_pointer_to_uintptr_t", + comp.void_ptr_type, + cast_union_fields[0], + comp.uintptr_type, + cast_union_fields[1]); + comp.cast_int_to_ptr = define_type_punning ("cast_uintptr_t_to_pointer", + comp.uintptr_type, + cast_union_fields[1], + comp.void_ptr_type, + cast_union_fields[0]); - gcc_jit_type *biggest_type = gcc_jit_context_get_int_type (comp.ctxt, - biggest_size, - false); - comp.cast_types[NUM_CAST_TYPES] = biggest_type; - comp.cast_union_fields[NUM_CAST_TYPES] = - gcc_jit_context_new_field (comp.ctxt, NULL, biggest_type, "biggest_type"); - comp.cast_type_names[NUM_CAST_TYPES] = "biggest_type"; - comp.cast_type_sizes[NUM_CAST_TYPES] = biggest_size; - comp.cast_type_kind[NUM_CAST_TYPES] = kind_unsigned; - - comp.cast_union_type = - gcc_jit_context_new_union_type (comp.ctxt, - NULL, - "cast_union", - NUM_CAST_TYPES + 1, - comp.cast_union_fields); + for (int i = 0; i < NUM_CAST_TYPES; ++i) + comp.cast_types[i] = cast_types[i].type; /* Define the cast functions using a matrix. */ for (int i = 0; i < NUM_CAST_TYPES; ++i) for (int j = 0; j < NUM_CAST_TYPES; ++j) comp.cast_functions_from_to[i][j] = - define_cast_from_to (cast_types[i], i, cast_types[j], j); + define_cast_from_to (cast_types[i], cast_types[j]); } static void commit ebd7c52f1169fb61a5f9a4a02959e5eedba79d86 Author: Stefan Monnier Date: Mon Aug 30 10:52:25 2021 -0400 (cperl-test-bug-14343): Make it work for perl-mode * test/lisp/progmodes/cperl-mode-tests.el (cperl--tests-heredoc-face): New const. (cperl-test-heredocs, cperl-test-bug-14343): Use it. (cperl-test-identify-no-heredoc): Remove left-over message. diff --git a/test/lisp/progmodes/cperl-mode-tests.el b/test/lisp/progmodes/cperl-mode-tests.el index 9ab260cc7c..c03eb52f17 100644 --- a/test/lisp/progmodes/cperl-mode-tests.el +++ b/test/lisp/progmodes/cperl-mode-tests.el @@ -205,7 +205,6 @@ point in the distant past, and is still broken in perl-mode. " (dolist (code not-here-docs) (with-temp-buffer (insert code "\n\n") - (message "inserting: %S" code) (funcall cperl-test-mode) (goto-char (point-min)) (forward-line 1) @@ -243,13 +242,15 @@ issued by CPerl mode." (defvar perl-continued-statement-offset) (defvar perl-indent-level) +(defconst cperl--tests-heredoc-face + (if (equal cperl-test-mode 'perl-mode) 'perl-heredoc + 'font-lock-string-face)) + (ert-deftest cperl-test-heredocs () "Test that HERE-docs are fontified with the appropriate face." (require 'perl-mode) (let ((file (ert-resource-file "here-docs.pl")) (cperl-continued-statement-offset perl-continued-statement-offset) - (target-font (if (equal cperl-test-mode 'perl-mode) 'perl-heredoc - 'font-lock-string-face)) (case-fold-search nil)) (with-temp-buffer (insert-file-contents file) @@ -262,7 +263,7 @@ issued by CPerl mode." (while (search-forward "look-here" nil t) (should (equal (get-text-property (match-beginning 0) 'face) - target-font)) + cperl--tests-heredoc-face)) (beginning-of-line) (should (null (looking-at "[ \t]"))) (forward-line 1))) @@ -428,7 +429,6 @@ under timeout control." (ert-deftest cperl-test-bug-14343 () "Verify that inserting text into a HERE-doc string with Elisp does not break fontification." - (skip-unless (eq cperl-test-mode #'cperl-mode)) (with-temp-buffer (insert "my $string = < Date: Mon Aug 30 10:47:16 2021 -0400 * test/lisp/progmodes/cperl-mode-tests.el: Adjust here-doc tests for perl-mode (cperl-test-identify-heredoc, cperl-test-identify-no-heredoc): Tweak tests so they can also be used for perl-mode. diff --git a/test/lisp/progmodes/cperl-mode-tests.el b/test/lisp/progmodes/cperl-mode-tests.el index 1d7565ae46..9ab260cc7c 100644 --- a/test/lisp/progmodes/cperl-mode-tests.el +++ b/test/lisp/progmodes/cperl-mode-tests.el @@ -158,66 +158,61 @@ point in the distant past, and is still broken in perl-mode. " "Test whether a construct containing \"<<\" followed by a bareword is properly identified for a here-document if appropriate." - (skip-unless (eq cperl-test-mode #'cperl-mode)) (let ((here-docs '("$text .= <>) { ...; }" ; double angle bracket operator + '("while (<<>>) {" ; double angle bracket operator "expr < Date: Mon Aug 30 09:16:21 2021 -0400 * etc/NEWS: Fix typo diff --git a/etc/NEWS b/etc/NEWS index 9fb064052d..657e12900f 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -1494,7 +1494,7 @@ deleting. Use rfc6068.el instead. The main difference is that 'rfc2368-parse-mailto-url' and 'rfc2368-unhexify-string' assumed that the strings were all-ASCII, while 'rfc6068-parse-mailto-url' and -'rfc2068-unhexify-string' parse UTF-8 strings. +'rfc6068-unhexify-string' parse UTF-8 strings. +++ *** New function 'def-edebug-elem-spec' to define Edebug spec elements. commit 9e67ef88f2047a5afdfaf6d6447273724d56a07b Author: Eli Zaretskii Date: Mon Aug 30 15:48:35 2021 +0300 Improve documentation of 'ispell-hunspell-add-multi-dic' * lisp/textmodes/ispell.el (ispell-hunspell-add-multi-dic): Explain in the doc string how to call from Lisp. (Bug#50241) diff --git a/lisp/textmodes/ispell.el b/lisp/textmodes/ispell.el index 67852998f4..632b00111a 100644 --- a/lisp/textmodes/ispell.el +++ b/lisp/textmodes/ispell.el @@ -1039,7 +1039,11 @@ did." Invoke this command before you want to start Hunspell for the first time with a particular combination of dictionaries. The first dictionary -in the list must have an affix file where Hunspell affix files are kept." +in the list must have an affix file where Hunspell affix files are kept. + +If you invoke this from Lisp, make sure to precede it with +a call to `ispell-set-spellchecker-params', as `ispell-change-dictionary' +calls it only when invoked interactively." (interactive "sMulti-dictionary combination: ") ;; Make sure the first dictionary in the list is known to us. (let ((first-dict (car (split-string dict "," t)))) commit b654420b1b9bd6f1da489278a7e18de7d1bf71dd Author: Eli Zaretskii Date: Mon Aug 30 15:42:32 2021 +0300 Minor improvement in 'get-locale-names' on MS-Windows * lisp/international/mule-cmds.el (get-locale-names): Delete duplicate locales from the list returned by the MS-Windows implementation. diff --git a/lisp/international/mule-cmds.el b/lisp/international/mule-cmds.el index dc09dad2cb..8494d54091 100644 --- a/lisp/international/mule-cmds.el +++ b/lisp/international/mule-cmds.el @@ -2616,7 +2616,7 @@ is returned. Thus, for instance, if charset \"ISO8859-2\", ;; On Windows we have a built-in method to get the names. ((and (fboundp 'w32-get-locale-info) (fboundp 'w32-get-valid-locale-ids)) - (mapcar #'w32-get-locale-info (w32-get-valid-locale-ids))) + (delete-dups (mapcar #'w32-get-locale-info (w32-get-valid-locale-ids)))) ;; Unix-ey hosts should have a command to output locales currently ;; defined by the OS. ((executable-find "locale") commit 670b423ebcc7b792381a9f59938b7a6ff6838bf9 Author: Lars Ingebrigtsen Date: Mon Aug 30 04:54:12 2021 +0200 Fix typo in kill-buffer-delete-auto-save-files NEWS entry diff --git a/etc/NEWS b/etc/NEWS index 5beea33dfb..9fb064052d 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -3878,7 +3878,7 @@ risk of excessively long file names. +++ ** New user option 'kill-buffer-delete-auto-save-files'. If non-nil, killing a buffer that has an auto-save file will prompt -the user for whether that buffer should be deleted. (Note that +the user for whether that file should be deleted. (Note that 'delete-auto-save-files', if non-nil, was previously documented to result in deletion of auto-save files when killing a buffer without unsaved changes, but this has apparently not worked for several commit c221f17b1ce448ed52b37e9e380a99f22b30963c Author: Lars Ingebrigtsen Date: Mon Aug 30 03:14:08 2021 +0200 Make some non-ASCII work in ebnf2ps * lisp/progmodes/ebnf2ps.el (ebnf-print-buffer): Make non-ASCII work slightly better (bug#39663). diff --git a/lisp/progmodes/ebnf2ps.el b/lisp/progmodes/ebnf2ps.el index 884104a16f..3be3d7032d 100644 --- a/lisp/progmodes/ebnf2ps.el +++ b/lisp/progmodes/ebnf2ps.el @@ -2244,8 +2244,14 @@ the PostScript image in a file with that name. If FILENAME is a number, prompt the user for the name of the file to save in." (interactive (list (ps-print-preprint current-prefix-arg))) (ebnf-log-header "(ebnf-print-buffer %S)" filename) - (ebnf-print-region (point-min) (point-max) filename)) - + (cl-letf (((symbol-function 'ps-output-string) + ;; Make non-ASCII work (sort of). + (lambda (string) + (ps-output t (and string + (encode-coding-string + (decode-coding-string string 'utf-8) + 'iso-8859-1)))))) + (ebnf-print-region (point-min) (point-max) filename))) ;;;###autoload (defun ebnf-print-region (from to &optional filename) commit 6885c62a104dcf52378860d8f951dbdce52b73c5 Author: Lars Ingebrigtsen Date: Mon Aug 30 02:23:37 2021 +0200 Fix typo in previous custom.texi change * doc/emacs/custom.texi (Init Syntax): Fix typo in previous change -- it's customize-set-variable. diff --git a/doc/emacs/custom.texi b/doc/emacs/custom.texi index 2ff6b8c762..9220a2078f 100644 --- a/doc/emacs/custom.texi +++ b/doc/emacs/custom.texi @@ -2377,8 +2377,8 @@ mode when you set them with Customize, but ordinary @code{setq} won't do that; to enable the mode in your init file, call the minor mode command. Finally, a few customizable user options are initialized in complex ways, and these have to be set either via the customize -interface (@pxref{Customization}) or by using @code{set-variable} -(@pxref{Examining}). +interface (@pxref{Customization}) or by using +@code{customize-set-variable} (@pxref{Examining}). The second argument to @code{setq} is an expression for the new value of the variable. This can be a constant, a variable, or a @@ -2531,7 +2531,7 @@ Change the coding system used when using the clipboard (@pxref{Communication Coding}). @example -(set-variable 'selection-coding-system 'utf-8) +(customize-set-variable 'selection-coding-system 'utf-8) @end example @item commit 1dc79aa8fc4f9cfd675c5c2ad744c9d85a185515 Author: Lars Ingebrigtsen Date: Mon Aug 30 02:03:15 2021 +0200 Make epg use rfc6068 for decoding %-encoded strings * lisp/epg.el (epg--decode-percent-escape-as-utf-8): Make obsolete and adjust callers. (epg--decode-hexstring): Ditto. * lisp/mail/rfc6068.el (rfc6068-unhexify-string): Allow returning non-decoded octets (bug#39689). diff --git a/lisp/epg.el b/lisp/epg.el index 9d6295594f..67d723b961 100644 --- a/lisp/epg.el +++ b/lisp/epg.el @@ -25,6 +25,7 @@ ;;; Prelude (require 'epg-config) +(require 'rfc6068) (eval-when-compile (require 'cl-lib)) (define-error 'epg-error "GPG error") @@ -432,7 +433,7 @@ callback data (if any)." (and user-id (concat " " (if (stringp user-id) - (epg--decode-percent-escape-as-utf-8 user-id) + (rfc6068-unhexify-string user-id) (epg-decode-dn user-id)))) (and (epg-signature-validity signature) (format " (trust %s)" (epg-signature-validity signature))) @@ -777,7 +778,7 @@ callback data (if any)." (user-id (match-string 2 string)) (entry (assoc key-id epg-user-id-alist))) (condition-case nil - (setq user-id (epg--decode-percent-escape-as-utf-8 user-id)) + (setq user-id (rfc6068-unhexify-string user-id)) (error)) (if entry (setcdr entry user-id) @@ -906,7 +907,7 @@ callback data (if any)." (condition-case nil (if (eq (epg-context-protocol context) 'CMS) (setq user-id (epg-dn-from-string user-id)) - (setq user-id (epg--decode-percent-escape-as-utf-8 user-id))) + (setq user-id (rfc6068-unhexify-string user-id))) (error)) (if entry (setcdr entry user-id) @@ -1182,7 +1183,7 @@ callback data (if any)." (user-id (match-string 2 string)) (entry (assoc key-id epg-user-id-alist))) (condition-case nil - (setq user-id (epg--decode-percent-escape-as-utf-8 user-id)) + (setq user-id (rfc6068-unhexify-string user-id)) (error)) (if entry (setcdr entry user-id) @@ -2061,9 +2062,11 @@ If you are unsure, use synchronous version of this function string)) (defun epg--decode-percent-escape-as-utf-8 (string) + (declare (obsolete rfc6068-unhexify-string "28.1")) (decode-coding-string (epg--decode-percent-escape string) 'utf-8)) (defun epg--decode-hexstring (string) + (declare (obsolete rfc6068-unhexify-string "28.1")) (let ((index 0)) (while (eq index (string-match "[[:xdigit:]][[:xdigit:]]" string index)) (setq string (replace-match (string (string-to-number @@ -2114,7 +2117,7 @@ The return value is an alist mapping from types to values." value (epg--decode-quotedstring (match-string 0 string))) (if (eq index (string-match "#\\([[:xdigit:]]+\\)" string index)) (setq index (match-end 0) - value (epg--decode-hexstring (match-string 1 string))) + value (rfc6068-unhexify-string (match-string 1 string) t)) (if (eq index (string-match "\"\\([^\\\"]\\|\\\\.\\)*\"" string index)) (setq index (match-end 0) diff --git a/lisp/mail/rfc6068.el b/lisp/mail/rfc6068.el index 6198342116..34fd7b5df4 100644 --- a/lisp/mail/rfc6068.el +++ b/lisp/mail/rfc6068.el @@ -22,17 +22,24 @@ ;;; Commentary: ;;; Code: -(defun rfc6068-unhexify-string (string) - "Unhexify STRING -- e.g. `hello%20there' -> `hello there'." - (decode-coding-string - (with-temp-buffer - (set-buffer-multibyte nil) - (insert string) - (goto-char (point-min)) - (while (re-search-forward "%\\([[:xdigit:]]\\{2\\}\\)" nil t) - (replace-match (string (string-to-number (match-string 1) 16)) t t)) - (buffer-string)) - 'utf-8)) +(defun rfc6068-unhexify-string (string &optional inhibit-decode) + "Unhexify STRING -- e.g. `hello%20there' -> `hello there'. +STRING is assumed to be a percentage-encoded utf-8 string. + +If INHIBIT-DECODE is non-nil, return the resulting raw byte +string instead of decoding as utf-8." + (let ((string + (with-temp-buffer + (set-buffer-multibyte nil) + (insert string) + (goto-char (point-min)) + (while (re-search-forward "%\\([[:xdigit:]]\\{2\\}\\)" nil t) + (replace-match (string (string-to-number (match-string 1) 16)) + t t)) + (buffer-string)))) + (if inhibit-decode + string + (decode-coding-string string 'utf-8)))) (defun rfc6068-parse-mailto-url (mailto-url) "Parse MAILTO-URL, and return an alist of header-name, header-value pairs. commit 7dabcb15118674be4a6254f1d69d44a3db20c7c4 Author: Lars Ingebrigtsen Date: Mon Aug 30 01:56:10 2021 +0200 Make rfc2368 obsolete and add rfc6068 * lisp/obsolete/rfc2368.el: Moved here and made obsolete. * lisp/mail/rfc6068.el (rfc6068-unhexify-string): New file. diff --git a/etc/NEWS b/etc/NEWS index 9651ce101b..5beea33dfb 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -1489,6 +1489,13 @@ deleting. +++ **** The spec element 'function-form' is obsolete, use 'form' instead. +--- +*** rfc2368.el is now obsolete. +Use rfc6068.el instead. The main difference is that +'rfc2368-parse-mailto-url' and 'rfc2368-unhexify-string' assumed that +the strings were all-ASCII, while 'rfc6068-parse-mailto-url' and +'rfc2068-unhexify-string' parse UTF-8 strings. + +++ *** New function 'def-edebug-elem-spec' to define Edebug spec elements. These used to be defined with 'def-edebug-spec' thus conflating the diff --git a/lisp/mail/rfc6068.el b/lisp/mail/rfc6068.el new file mode 100644 index 0000000000..6198342116 --- /dev/null +++ b/lisp/mail/rfc6068.el @@ -0,0 +1,76 @@ +;;; rfc6068.el --- support for rfc6068 -*- lexical-binding: t -*- + +;; Copyright (C) 2021 Free Software Foundation, Inc. + +;; Keywords: mail + +;; This file is part of GNU Emacs. + +;; GNU Emacs is free software: you can redistribute it and/or modify +;; it under the terms of the GNU General Public License as published by +;; the Free Software Foundation, either version 3 of the License, or +;; (at your option) any later version. + +;; GNU Emacs is distributed in the hope that it will be useful, +;; but WITHOUT ANY WARRANTY; without even the implied warranty of +;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;; GNU General Public License for more details. + +;; You should have received a copy of the GNU General Public License +;; along with GNU Emacs. If not, see . + +;;; Commentary: +;;; Code: + +(defun rfc6068-unhexify-string (string) + "Unhexify STRING -- e.g. `hello%20there' -> `hello there'." + (decode-coding-string + (with-temp-buffer + (set-buffer-multibyte nil) + (insert string) + (goto-char (point-min)) + (while (re-search-forward "%\\([[:xdigit:]]\\{2\\}\\)" nil t) + (replace-match (string (string-to-number (match-string 1) 16)) t t)) + (buffer-string)) + 'utf-8)) + +(defun rfc6068-parse-mailto-url (mailto-url) + "Parse MAILTO-URL, and return an alist of header-name, header-value pairs. +MAILTO-URL should be a RFC 6068 (mailto) compliant url. A cons cell w/ a +key of `Body' is a special case and is considered a header for this purpose. +The returned alist is intended for use w/ the `compose-mail' interface. +Note: make sure MAILTO-URL has been \"unhtmlized\" (e.g., & -> &), before +calling this function." + (let ((case-fold-search t) + headers-alist) + (setq mailto-url (string-replace "\n" " " mailto-url)) + (when (string-match "^\\(mailto:\\)\\([^?]+\\)?\\(\\?\\(.*\\)\\)*" + mailto-url) + (let ((address (match-string 2 mailto-url)) + (query (match-string 4 mailto-url))) + ;; Build alist of header name-value pairs. + (when query + (setq headers-alist + (mapcar + (lambda (x) + (let* ((pair (split-string x "=")) + (name (car pair)) + (value (cadr pair))) + ;; Return ("Header-Name" . "header-value"). + (cons + (capitalize (rfc6068-unhexify-string name)) + (rfc6068-unhexify-string value)))) + (split-string query "&")))) + + (when address + (setq address (rfc6068-unhexify-string address)) + ;; Deal with multiple 'To' recipients. + (if-let ((elem (assoc "To" headers-alist))) + (setcdr elem (concat address ", " (cdr elem))) + (push (cons "To" address) headers-alist))) + + headers-alist)))) + +(provide 'rfc6068) + +;;; rfc6068.el ends here diff --git a/lisp/net/browse-url.el b/lisp/net/browse-url.el index c8ca70cc1f..73b8c439f2 100644 --- a/lisp/net/browse-url.el +++ b/lisp/net/browse-url.el @@ -1603,7 +1603,7 @@ used instead of `browse-url-new-window-flag'." ;; --- mailto --- -(autoload 'rfc2368-parse-mailto-url "rfc2368") +(autoload 'rfc6068-parse-mailto-url "rfc2368") ;;;###autoload (defun browse-url-mail (url &optional new-window) @@ -1622,7 +1622,7 @@ When called non-interactively, optional second argument NEW-WINDOW is used instead of `browse-url-new-window-flag'." (interactive (browse-url-interactive-arg "Mailto URL: ")) (save-excursion - (let* ((alist (rfc2368-parse-mailto-url url)) + (let* ((alist (rfc6068-parse-mailto-url url)) (to (assoc "To" alist)) (subject (assoc "Subject" alist)) (body (assoc "Body" alist)) diff --git a/lisp/mail/rfc2368.el b/lisp/obsolete/rfc2368.el similarity index 99% rename from lisp/mail/rfc2368.el rename to lisp/obsolete/rfc2368.el index b96f15d3e6..8a842b0cf3 100644 --- a/lisp/mail/rfc2368.el +++ b/lisp/obsolete/rfc2368.el @@ -4,6 +4,7 @@ ;; Author: Sen Nagata ;; Keywords: mail +;; Obsolete-since: 28.1 ;; This file is part of GNU Emacs. diff --git a/test/lisp/mail/rfc6068-tests.el b/test/lisp/mail/rfc6068-tests.el new file mode 100644 index 0000000000..caf8230cb1 --- /dev/null +++ b/test/lisp/mail/rfc6068-tests.el @@ -0,0 +1,52 @@ +;;; rfc6068-tests.el --- Tests for rfc6068.el -*- lexical-binding:t -*- + +;; Copyright (C) 2020-2021 Free Software Foundation, Inc. + +;; This file is part of GNU Emacs. + +;; GNU Emacs is free software: you can redistribute it and/or modify +;; it under the terms of the GNU General Public License as published by +;; the Free Software Foundation, either version 3 of the License, or +;; (at your option) any later version. + +;; GNU Emacs is distributed in the hope that it will be useful, +;; but WITHOUT ANY WARRANTY; without even the implied warranty of +;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;; GNU General Public License for more details. + +;; You should have received a copy of the GNU General Public License +;; along with GNU Emacs. If not, see . + +;;; Commentary: + +;;; Code: + +(require 'ert) +(require 'rfc6068) + +(ert-deftest rfc6068-unhexify-string () + (should (equal (rfc6068-unhexify-string "hello%20there") "hello there")) + (should (equal (rfc6068-unhexify-string "caf%C3%A9") "café"))) + +(ert-deftest rfc6068-parse-mailto-url () + (should + (equal + (rfc6068-parse-mailto-url "mailto:foo@example.org?subject=Foo&bar=baz") + '(("To" . "foo@example.org") ("Subject" . "Foo") ("Bar" . "baz")))) + (should + (equal + (rfc6068-parse-mailto-url "mailto:foo@bar.com?to=bar@example.org") + '(("To" . "foo@bar.com, bar@example.org")))) + (should + (equal (rfc6068-parse-mailto-url "mailto:foo@bar.com?subject=bar%20baz") + '(("To" . "foo@bar.com") ("Subject" . "bar baz")))) + (should + (equal (rfc6068-parse-mailto-url "mailto:foo@bar.com?subject=bar%20baz&to=other@bar.com") + '(("Subject" . "bar baz") ("To" . "foo@bar.com, other@bar.com")))) + (should + (equal (rfc6068-parse-mailto-url "mailto:user@example.org?subject=caf%C3%A9&body=caf%C3%A9") + '(("To" . "user@example.org") ("Subject" . "café") ("Body" . "café"))))) + +(provide 'rfc6068-tests) + +;;; rfc6068-tests.el ends here diff --git a/test/lisp/mail/rfc2368-tests.el b/test/lisp/obsolete/rfc2368-tests.el similarity index 100% rename from test/lisp/mail/rfc2368-tests.el rename to test/lisp/obsolete/rfc2368-tests.el commit 31226b034136769723c69679a4a302299fbb9e7b Author: Lars Ingebrigtsen Date: Mon Aug 30 01:20:30 2021 +0200 Only look for the port command on MacOS * configure.ac: Only look for the port command on MacOS (bug#50259). diff --git a/configure.ac b/configure.ac index a1deb7b0dd..6d204b6103 100644 --- a/configure.ac +++ b/configure.ac @@ -1335,7 +1335,9 @@ if test -n "$BREW"; then fi # Check MacPorts on macOS. -AC_PATH_PROG(HAVE_MACPORTS, port) +if test $opsys = darwin; then + AC_PATH_PROG(HAVE_MACPORTS, port) +fi ## Require makeinfo >= 4.13 (last of the 4.x series) to build the manuals. : ${MAKEINFO:=makeinfo} commit 5da9b3d2bdde0c9d23cdcd9d55883878900daa78 Author: Lars Ingebrigtsen Date: Sun Aug 29 22:37:30 2021 +0200 Move vc-branch-p and vc-branch-part from vc.el to vc-rcs.el and rename * lisp/vc/vc-rcs.el (vc-rcs-branch-p): Renamed from `vc-branch-p' (old name made into obsolete alias) and moved from vc.el. (vc-rcs-branch-part): Renamed from `vc-branch-part' (old name made into obsolete alias) and moved from vc.el. diff --git a/lisp/vc/vc-cvs.el b/lisp/vc/vc-cvs.el index c8f36fb76e..ec6dc282dc 100644 --- a/lisp/vc/vc-cvs.el +++ b/lisp/vc/vc-cvs.el @@ -24,9 +24,9 @@ ;;; Code: +(require 'vc-rcs) (eval-when-compile (require 'vc)) -(declare-function vc-branch-p "vc" (rev)) (declare-function vc-checkout "vc" (file &optional rev)) (declare-function vc-expand-dirs "vc" (file-or-dir-list backend)) (declare-function vc-read-revision "vc" @@ -451,17 +451,17 @@ REV is the revision to check out." ((string= first-revision "") (setq status (vc-cvs-merge-news file))) (t - (if (not (vc-branch-p first-revision)) + (if (not (vc-rcs-branch-p first-revision)) (setq second-revision (vc-read-revision "Second revision: " (list file) 'CVS nil - (concat (vc-branch-part first-revision) "."))) + (concat (vc-rcs-branch-part first-revision) "."))) ;; We want to merge an entire branch. Set revisions ;; accordingly, so that vc-cvs-merge understands us. (setq second-revision first-revision) ;; first-revision must be the starting point of the branch - (setq first-revision (vc-branch-part first-revision))) + (setq first-revision (vc-rcs-branch-part first-revision))) (setq status (vc-cvs-merge file first-revision second-revision)))) status)) @@ -542,14 +542,12 @@ Will fail unless you have administrative privileges on the repo." ;;; History functions ;;; -(declare-function vc-rcs-print-log-cleanup "vc-rcs" ()) ;; Follows vc-cvs-command, which uses vc-do-command from vc-dispatcher. (declare-function vc-exec-after "vc-dispatcher" (code)) (defun vc-cvs-print-log (files buffer &optional _shortlog _start-revision limit) "Print commit log associated with FILES into specified BUFFER. Remaining arguments are ignored." - (require 'vc-rcs) ;; It's just the catenation of the individual logs. (vc-cvs-command buffer diff --git a/lisp/vc/vc-rcs.el b/lisp/vc/vc-rcs.el index 6ffc1a8a2f..0b0c71b1ff 100644 --- a/lisp/vc/vc-rcs.el +++ b/lisp/vc/vc-rcs.el @@ -41,7 +41,6 @@ (require 'cl-lib) (require 'vc)) -(declare-function vc-branch-p "vc" (rev)) (declare-function vc-read-revision "vc" (prompt &optional files backend default initial-input)) (declare-function vc-buffer-context "vc-dispatcher" ()) @@ -173,6 +172,19 @@ For a description of possible values, see `vc-check-master-templates'." (defun vc-rcs-dir-extra-headers (&rest _ignore)) +;; functions that operate on RCS revision numbers. +(defun vc-rcs-branch-p (rev) + "Return t if REV is a branch revision." + (not (eq nil (string-match "\\`[0-9]+\\(\\.[0-9]+\\.[0-9]+\\)*\\'" rev)))) +(define-obsolete-function-alias 'vc-branch-p #'vc-rcs-branch-p "28.1") + +(defun vc-rcs-branch-part (rev) + "Return the branch part of a revision number REV." + (let ((index (string-match "\\.[0-9]+\\'" rev))) + (when index + (substring rev 0 index)))) +(define-obsolete-function-alias 'vc-branch-part #'vc-rcs-branch-part "28.1") + (defun vc-rcs-working-revision (file) "RCS-specific version of `vc-working-revision'." (or (and vc-consult-headers @@ -198,7 +210,7 @@ When VERSION is given, perform check for that version." ;; If we are not on the trunk, we need to examine the ;; whole current branch. (vc-insert-file (vc-master-name file) "^desc") - (vc-rcs-find-most-recent-rev (vc-branch-part version)))))) + (vc-rcs-find-most-recent-rev (vc-rcs-branch-part version)))))) (defun vc-rcs-workfile-unchanged-p (file) "Has FILE remained unchanged since last checkout?" @@ -326,7 +338,7 @@ whether to remove it." (setq rev default-branch) (setq switches (cons "-f" switches))) (if (and (not rev) old-version) - (setq rev (vc-branch-part old-version))) + (setq rev (vc-rcs-branch-part old-version))) (apply #'vc-do-command "*vc*" 0 "ci" (vc-master-name file) ;; if available, use the secure check-in option (and (vc-rcs-release-p "5.6.4") "-j") @@ -349,11 +361,11 @@ whether to remove it." ;; branch accordingly (cond ((and old-version new-version - (not (string= (vc-branch-part old-version) - (vc-branch-part new-version)))) + (not (string= (vc-rcs-branch-part old-version) + (vc-rcs-branch-part new-version)))) (vc-rcs-set-default-branch file (if (vc-rcs-trunk-p new-version) nil - (vc-branch-part new-version))) + (vc-rcs-branch-part new-version))) ;; If this is an old (pre-1992!) RCS release, we might have ;; to remove a remaining lock. (if (not (vc-rcs-release-p "5.6.2")) @@ -414,7 +426,7 @@ attempt the checkout for all registered files beneath it." ;; REV is t ... (if (not (vc-rcs-trunk-p workrev)) ;; ... go to head of current branch - (vc-branch-part workrev) + (vc-rcs-branch-part workrev) ;; ... go to head of trunk (vc-rcs-set-default-branch file nil) @@ -431,7 +443,7 @@ attempt the checkout for all registered files beneath it." file (if (vc-rcs-latest-on-branch-p file new-version) (if (vc-rcs-trunk-p new-version) nil - (vc-branch-part new-version)) + (vc-rcs-branch-part new-version)) new-version))))) (message "Checking out %s...done" file)))))) @@ -456,17 +468,17 @@ revert all registered files beneath it." ((string= first-revision "") (error "A starting RCS revision is required")) (t - (if (not (vc-branch-p first-revision)) + (if (not (vc-rcs-branch-p first-revision)) (setq second-revision (vc-read-revision "Second RCS revision: " (list file) 'RCS nil - (concat (vc-branch-part first-revision) "."))) + (concat (vc-rcs-branch-part first-revision) "."))) ;; We want to merge an entire branch. Set revisions ;; accordingly, so that vc-rcs-merge understands us. (setq second-revision first-revision) ;; first-revision must be the starting point of the branch - (setq first-revision (vc-branch-part first-revision))))) + (setq first-revision (vc-rcs-branch-part first-revision))))) (vc-rcs-merge file first-revision second-revision))) (defun vc-rcs-merge (file first-version &optional second-version) @@ -637,11 +649,11 @@ Optional arg REVISION is a revision to annotate from." ;; Find which branches (if any) must be included in the edits. (let ((par revision) bpt kids) - (while (setq bpt (vc-branch-part par) - par (vc-branch-part bpt)) + (while (setq bpt (vc-rcs-branch-part par) + par (vc-rcs-branch-part bpt)) (setq kids (cdr (assq 'branches (cdr (assoc par revisions))))) ;; A branchpoint may have multiple children. Find the right one. - (while (not (string= bpt (vc-branch-part (car kids)))) + (while (not (string= bpt (vc-rcs-branch-part (car kids)))) (setq kids (cdr kids))) (push (cons par (car kids)) nbls))) ;; Start with the full text. @@ -818,7 +830,7 @@ systime, or nil if there is none. Also, reposition point." or nil if there is no previous revision. This default implementation works for MAJOR.MINOR-style revision numbers as used by RCS and CVS." - (let ((branch (vc-branch-part rev)) + (let ((branch (vc-rcs-branch-part rev)) (minor-num (string-to-number (vc-rcs-minor-part rev)))) (when branch (if (> minor-num 1) @@ -830,7 +842,7 @@ used by RCS and CVS." nil ;; we are at the beginning of a branch -- ;; return revision of starting point - (vc-branch-part branch)))))) + (vc-rcs-branch-part branch)))))) (defun vc-rcs-next-revision (file rev) "Return the revision number immediately following REV for FILE, @@ -838,7 +850,7 @@ or nil if there is no next revision. This default implementation works for MAJOR.MINOR-style revision numbers as used by RCS and CVS." (when (not (string= rev (vc-working-revision file))) - (let ((branch (vc-branch-part rev)) + (let ((branch (vc-rcs-branch-part rev)) (minor-num (string-to-number (vc-rcs-minor-part rev)))) (concat branch "." (number-to-string (1+ minor-num)))))) @@ -965,7 +977,7 @@ to its master version." (setq latest-rev rev) (setq value (match-string 1))))) (or value - (vc-branch-part branch)))) + (vc-rcs-branch-part branch)))) (defun vc-rcs-fetch-master-state (file &optional working-revision) "Compute the master file's idea of the state of FILE. diff --git a/lisp/vc/vc.el b/lisp/vc/vc.el index b75862e8a5..38204ef91c 100644 --- a/lisp/vc/vc.el +++ b/lisp/vc/vc.el @@ -3072,20 +3072,6 @@ log entries should be gathered." (vc-call-backend (vc-responsible-backend default-directory) 'update-changelog args)) -;; functions that operate on RCS revision numbers. This code should -;; also be moved into the backends. It stays for now, however, since -;; it is used in code below. -(defun vc-branch-p (rev) - "Return t if REV is a branch revision." - (not (eq nil (string-match "\\`[0-9]+\\(\\.[0-9]+\\.[0-9]+\\)*\\'" rev)))) - -;;;###autoload -(defun vc-branch-part (rev) - "Return the branch part of a revision number REV." - (let ((index (string-match "\\.[0-9]+\\'" rev))) - (when index - (substring rev 0 index)))) - (defun vc-default-responsible-p (_backend _file) "Indicate whether BACKEND is responsible for FILE. The default is to return nil always." commit 7c7d58f45463edf13f97f6b2496c5edc901ede45 Author: Lars Ingebrigtsen Date: Sun Aug 29 21:56:22 2021 +0200 Fix vc test for RCS * test/lisp/vc/vc-tests.el (vc-test--rename-file): Fix test for RCS. diff --git a/test/lisp/vc/vc-tests.el b/test/lisp/vc/vc-tests.el index dbb8a9e3d1..f2807a3f06 100644 --- a/test/lisp/vc/vc-tests.el +++ b/test/lisp/vc/vc-tests.el @@ -588,7 +588,10 @@ This checks also `vc-backend' and `vc-responsible-backend'." (should (not (file-exists-p tmp-name))) (should (file-exists-p new-name)) - (should (equal (vc-state new-name) 'added)))) + (should (equal (vc-state new-name) + (if (eq backend 'RCS) + 'up-to-date + 'added))))) ;; Save exit. (ignore-errors commit 5bd23b0cd36bc1ea47313db15765fe0a1e6ea717 Author: Lars Ingebrigtsen Date: Sun Aug 29 21:31:57 2021 +0200 Mention `set-variable' in the Init Syntax Emacs manual node * doc/emacs/custom.texi (Init Syntax): Mention set-variable (bug#50248). (Init Examples): Add an example. diff --git a/doc/emacs/custom.texi b/doc/emacs/custom.texi index cdbb614b77..2ff6b8c762 100644 --- a/doc/emacs/custom.texi +++ b/doc/emacs/custom.texi @@ -2366,14 +2366,19 @@ function @code{setq} to set the variable @code{fill-column} (@pxref{Filling}) to 60. You can set any Lisp variable with @code{setq}, but with certain -variables @code{setq} won't do what you probably want in the -init file. Some variables automatically become buffer-local -when set with @code{setq}; what you want in the init file is to set -the default value, using @code{setq-default}. Some customizable minor -mode variables do special things to enable the mode when you set them -with Customize, but ordinary @code{setq} won't do that; to enable the -mode in your init file, call the minor mode command. The -following section has examples of both of these methods. +variables @code{setq} won't do what you probably want in the init +file. Some variables automatically become buffer-local when set with +@code{setq}; what you want in the init file is to set the default +value, using @code{setq-default}. (The following section has examples +of both of these methods.) + +Some customizable minor mode variables do special things to enable the +mode when you set them with Customize, but ordinary @code{setq} won't +do that; to enable the mode in your init file, call the minor mode +command. Finally, a few customizable user options are initialized in +complex ways, and these have to be set either via the customize +interface (@pxref{Customization}) or by using @code{set-variable} +(@pxref{Examining}). The second argument to @code{setq} is an expression for the new value of the variable. This can be a constant, a variable, or a @@ -2521,6 +2526,14 @@ Turn on Auto Fill mode automatically in Text mode and related modes (add-hook 'text-mode-hook 'auto-fill-mode) @end example +@item +Change the coding system used when using the clipboard +(@pxref{Communication Coding}). + +@example +(set-variable 'selection-coding-system 'utf-8) +@end example + @item Load the installed Lisp library named @file{foo} (actually a file @file{foo.elc} or @file{foo.el} in a standard Emacs directory). commit 9117a76b53d93fd200777c31c6d45302e900df89 Author: Clément Pit-Claudel Date: Sun Aug 29 21:15:06 2021 +0200 Change --with-nativecomp to --with-native-compilation in messages * configure.ac: * test/infra/Dockerfile.emba: * test/infra/gitlab-ci.yml: Fix mentions of --with-nativecomp (bug#50255). diff --git a/configure.ac b/configure.ac index 76f608ffb0..a1deb7b0dd 100644 --- a/configure.ac +++ b/configure.ac @@ -3795,7 +3795,7 @@ AC_DEFUN([libgccjit_dev_not_found], [ not found. Please try installing libgccjit-dev or a similar package. If you are sure you want Emacs be compiled without ELisp native compiler, -pass the --without-nativecomp option to configure.])]) +pass the --without-native-compilation option to configure.])]) AC_DEFUN([libgccjit_broken], [ AC_MSG_ERROR([The installed libgccjit failed to compile and run a test program using @@ -3814,10 +3814,10 @@ LIBGCCJIT_LIBS= LIBGCCJIT_CFLAGS= if test "${with_native_compilation}" != "no"; then if test "${HAVE_PDUMPER}" = no; then - AC_MSG_ERROR(['--with-nativecomp' requires '--with-dumping=pdumper']) + AC_MSG_ERROR(['--with-native-compilation' requires '--with-dumping=pdumper']) fi if test "${HAVE_ZLIB}" = no; then - AC_MSG_ERROR(['--with-nativecomp' requires zlib]) + AC_MSG_ERROR(['--with-native-compilation' requires zlib]) fi # Ensure libgccjit installed by Homebrew can be found. diff --git a/test/infra/Dockerfile.emba b/test/infra/Dockerfile.emba index 9f03482c3f..0b61c74aef 100644 --- a/test/infra/Dockerfile.emba +++ b/test/infra/Dockerfile.emba @@ -82,6 +82,6 @@ ARG make_bootstrap_params="" COPY . /checkout WORKDIR /checkout RUN ./autogen.sh autoconf -RUN ./configure --with-nativecomp +RUN ./configure --with-native-compilation RUN make bootstrap -j2 NATIVE_FULL_AOT=1 BYTE_COMPILE_EXTRA_FLAGS='--eval "(setq comp-speed 0)"' RUN make -j4 diff --git a/test/infra/gitlab-ci.yml b/test/infra/gitlab-ci.yml index 6876a8b11d..5082b08e01 100644 --- a/test/infra/gitlab-ci.yml +++ b/test/infra/gitlab-ci.yml @@ -291,7 +291,7 @@ build-native-bootstrap-speed0: # script: # - DEBIAN_FRONTEND=noninteractive apt install --no-install-recommends -y -qq -o=Dpkg::Use-Pty=0 libgccjit-6-dev # - ./autogen.sh autoconf -# - ./configure --with-nativecomp +# - ./configure --with-native-compilation # - make bootstrap NATIVE_FULL_AOT=1 BYTE_COMPILE_EXTRA_FLAGS='--eval "(setq comp-speed 0)"' -j2 # timeout: 8 hours @@ -300,7 +300,7 @@ build-native-bootstrap-speed0: # script: # - DEBIAN_FRONTEND=noninteractive apt install --no-install-recommends -y -qq -o=Dpkg::Use-Pty=0 libgccjit-6-dev # - ./autogen.sh autoconf -# - ./configure --with-nativecomp +# - ./configure --with-native-compilation # - make bootstrap BYTE_COMPILE_EXTRA_FLAGS='--eval "(setq comp-speed 1)"' # timeout: 8 hours @@ -309,7 +309,7 @@ build-native-bootstrap-speed0: # script: # - DEBIAN_FRONTEND=noninteractive apt install --no-install-recommends -y -qq -o=Dpkg::Use-Pty=0 libgccjit-6-dev # - ./autogen.sh autoconf -# - ./configure --with-nativecomp +# - ./configure --with-native-compilation # - make bootstrap # timeout: 8 hours commit dce5f7aed6047b56bcec83cca36ba94b23d8f558 Author: Augusto Stoffel Date: Sun Aug 29 20:56:11 2021 +0200 Add support for OSC 7 in comint (current directory tracking) * lisp/comint.el (comint-osc-directory-tracker, comint-osc-handlers): Define and register a handler for OSC 7. (comint-osc-process-output): Do fewer checks on 'comint-last-output-start'. diff --git a/etc/NEWS b/etc/NEWS index 3fa22fbb57..9651ce101b 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -3034,9 +3034,10 @@ mode. By default, these new options support 'view-mode'. Adding the new 'comint-osc-process-output' to 'comint-output-filter-functions' enables the interpretation of OSC ("Operating System Command") escape sequences in comint buffers. By -default, only OSC 8, for hyperlinks, is acted upon. Adding more -entries to `comint-osc-handlers' allows a customized treatment of -further escape sequences. +default, only OSC 8, for hyperlinks, and OSC 7, for directory +tracking, are acted upon. Adding more entries to +`comint-osc-handlers' allows a customized treatment of further escape +sequences. +++ *** 'comint-delete-output' can now save deleted text in the kill-ring. diff --git a/lisp/comint.el b/lisp/comint.el index b2557dd502..9e3042f597 100644 --- a/lisp/comint.el +++ b/lisp/comint.el @@ -3896,7 +3896,8 @@ REGEXP-GROUP is the regular expression group in REGEXP to use." ;; OSC 8, for hyperlinks, is acted upon. Adding more entries to ;; `comint-osc-handlers' allows a customized treatment of further sequences. -(defvar-local comint-osc-handlers '(("8" . comint-osc-hyperlink-handler)) +(defvar-local comint-osc-handlers '(("7" . comint-osc-directory-tracker) + ("8" . comint-osc-hyperlink-handler)) "Alist of handlers for OSC escape sequences. See `comint-osc-process-output' for details.") @@ -3918,12 +3919,8 @@ should be a function, is called with `command' and `text' as arguments, with point where the escape sequence was located." (let ((bound (process-mark (get-buffer-process (current-buffer))))) (save-excursion - (goto-char (or comint-osc--marker - (and (markerp comint-last-output-start) - (eq (marker-buffer comint-last-output-start) - (current-buffer)) - comint-last-output-start) - (point-min))) + ;; Start one char before last output to catch a possibly stray ESC + (goto-char (or comint-osc--marker (1- comint-last-output-start))) (when (eq (char-before) ?\e) (backward-char)) (while (re-search-forward "\e]" bound t) (let ((pos0 (match-beginning 0)) @@ -3940,6 +3937,30 @@ arguments, with point where the escape sequence was located." (put-text-property pos0 bound 'invisible t) (setq comint-osc--marker (copy-marker pos0)))))))) +;; Current directory tracking (OSC 7) + +(declare-function url-host "url-parse.el") +(declare-function url-type "url-parse.el") +(declare-function url-filename "url-parse.el") +(defun comint-osc-directory-tracker (_ text) + "Update `default-directory' from OSC 7 escape sequences. + +This function is intended to be included as an entry of +`comint-osc-handlers'. You should moreover arrange for your +shell to print the appropriate escape sequence at each prompt, +say with the following command: + + printf \"\\e]7;file://%s%s\\e\\\\\" \"$HOSTNAME\" \"$PWD\" + +This functionality serves as an alternative to `dirtrack-mode' +and `shell-dirtrack-mode'." + (let ((url (url-generic-parse-url text))) + (when (and (string= (url-type url) "file") + (or (null (url-host url)) + (string= (url-host url) (system-name)))) + (ignore-errors + (cd-absolute (url-unhex-string (url-filename url))))))) + ;; Hyperlink handling (OSC 8) (defvar comint-osc-hyperlink-map commit 6392bc37ab3b7eb83465d9b2248d21173373ae73 Author: Kévin Le Gouguec Date: Sun Aug 29 20:27:56 2021 +0200 Tweak sh-script-mode indentation further * lisp/progmodes/sh-script.el (sh-smie--default-backward-token): Allow more parentheses in a token (bug#44592). diff --git a/lisp/progmodes/sh-script.el b/lisp/progmodes/sh-script.el index 201d1fd164..7507579d16 100644 --- a/lisp/progmodes/sh-script.el +++ b/lisp/progmodes/sh-script.el @@ -1775,7 +1775,7 @@ Does not preserve point." (goto-char p) nil)))) (while - (progn (skip-syntax-backward ".w_'") + (progn (skip-syntax-backward ".w_'()") (or (not (zerop (skip-syntax-backward "\\"))) (when (eq ?\\ (char-before (1- (point)))) (let ((p (point))) diff --git a/test/lisp/progmodes/sh-script-tests.el b/test/lisp/progmodes/sh-script-tests.el index 5bdce6260a..82c2d5168c 100644 --- a/test/lisp/progmodes/sh-script-tests.el +++ b/test/lisp/progmodes/sh-script-tests.el @@ -35,6 +35,17 @@ (should (equal (buffer-substring-no-properties (point-min) (point-max)) "relative-path/to/configure --prefix=$prefix\\ - --with-x")))) + --with-x"))) + (with-temp-buffer + (insert "${path_to_root}/configure --prefix=$prefix\\ + --with-x") + (shell-script-mode) + (goto-char (point-min)) + (forward-line 1) + (indent-for-tab-command) + (should (equal + (buffer-substring-no-properties (point-min) (point-max)) + "${path_to_root}/configure --prefix=$prefix\\ + --with-x")))) ;;; sh-script-tests.el ends here commit 8fa624b39b39569d280b06811dd81f1253559e17 Author: Philipp Stephani Date: Sun Aug 29 20:51:39 2021 +0200 Improve compatibility with musl-libc (Bug#48789) * lib-src/seccomp-filter.c (export_filter): Remove use of nonstandard macro TEMP_FAILURE_RETRY. diff --git a/lib-src/seccomp-filter.c b/lib-src/seccomp-filter.c index dc568e035b..d378e0b027 100644 --- a/lib-src/seccomp-filter.c +++ b/lib-src/seccomp-filter.c @@ -131,9 +131,12 @@ export_filter (const char *file, int (*function) (const scmp_filter_ctx, int), const char *name) { - int fd = TEMP_FAILURE_RETRY ( - open (file, O_WRONLY | O_CREAT | O_TRUNC | O_BINARY | O_CLOEXEC, - 0644)); + int fd; + do + fd = open (file, + O_WRONLY | O_CREAT | O_TRUNC | O_BINARY | O_CLOEXEC, + 0644); + while (fd < 0 && errno == EINTR); if (fd < 0) fail (errno, "open %s", file); int status = function (ctx, fd); commit a2a0b70c8bf03ee0ad57f97b06b1d591dc8801f1 Author: Eli Zaretskii Date: Sun Aug 29 18:03:28 2021 +0300 ; * src/xfaces.c (gui_supports_face_attributes_p): Fix typo in comment. diff --git a/src/xfaces.c b/src/xfaces.c index 207f0d6a36..2273fb4fe4 100644 --- a/src/xfaces.c +++ b/src/xfaces.c @@ -5092,8 +5092,8 @@ gui_supports_face_attributes_p (struct frame *f, { Lisp_Object *def_attrs = def_face->lface; - /* Check that other specified attributes are different that the default - face. */ + /* Check that other specified attributes are different from the + default face. */ if ((!UNSPECIFIEDP (attrs[LFACE_UNDERLINE_INDEX]) && face_attr_equal_p (attrs[LFACE_UNDERLINE_INDEX], def_attrs[LFACE_UNDERLINE_INDEX])) commit 9a1d54814e7970638d8fed56c84389b6c49a55cb Author: Alan Mackenzie Date: Sun Aug 29 14:03:57 2021 +0000 C++ Mode: handle compound identifiers preceding brace lists correctly * lisp/progmodes/cc-engine.el (c-looking-at-or-maybe-in-bracelist): early in function, check alternatively for c-back-over-compound-identifier when doing c-backward-token-2. * bracelist-36.{cc,res}: New test files. diff --git a/lisp/progmodes/cc-engine.el b/lisp/progmodes/cc-engine.el index 5d2e41ae57..c305cae754 100644 --- a/lisp/progmodes/cc-engine.el +++ b/lisp/progmodes/cc-engine.el @@ -12288,12 +12288,15 @@ comment at the start of cc-engine.el for more info." pos2 in-paren parens-before-brace paren-state paren-pos) - (setq res (c-backward-token-2 1 t lim)) + (setq res + (or (progn (c-backward-syntactic-ws) + (c-back-over-compound-identifier)) + (c-backward-token-2 1 t lim))) ;; Checks to do only on the first sexp before the brace. ;; Have we a C++ initialization, without an "="? (if (and (c-major-mode-is 'c++-mode) (cond - ((and (or (not (eq res 0)) + ((and (or (not (memq res '(t 0))) (eq (char-after) ?,)) (setq paren-state (c-parse-state)) (setq paren-pos (c-pull-open-brace paren-state)) @@ -12317,7 +12320,7 @@ comment at the start of cc-engine.el for more info." (t nil)) (save-excursion (cond - ((or (not (eq res 0)) + ((or (not (memq res '(t 0))) (eq (char-after) ?,)) (and (setq paren-state (c-parse-state)) (setq paren-pos (c-pull-open-brace paren-state)) commit 3065b6b73b72f8661d87e3335b348b347a9eb58d Author: Alan Third Date: Sun Aug 29 13:07:54 2021 +0100 Fix libexec installation on NS (bug#50250) * lib-src/Makefile.in (ns_applibexecdir): New variable. diff --git a/lib-src/Makefile.in b/lib-src/Makefile.in index 7af89eb380..e6cda73367 100644 --- a/lib-src/Makefile.in +++ b/lib-src/Makefile.in @@ -52,6 +52,7 @@ top_builddir = @top_builddir@ # Location to install Emacs.app under GNUstep / macOS. # Later values may use this. ns_appbindir=@ns_appbindir@ +ns_applibexecdir=@ns_applibexecdir@ # The default location for installation. Everything is placed in # subdirectories of this directory. The default values for many of commit f1901fc3084e6bdd6c72f11dbae58ee2a0232224 Author: Eli Zaretskii Date: Sun Aug 29 14:47:02 2021 +0300 Better document obsolescence of 'values' * doc/lispref/eval.texi (Eval): Mention that 'values' is obsolete. * etc/NEWS: Add a rationale for obsoleting 'values'. diff --git a/doc/lispref/eval.texi b/doc/lispref/eval.texi index 7893895eee..e1998842cf 100644 --- a/doc/lispref/eval.texi +++ b/doc/lispref/eval.texi @@ -862,8 +862,13 @@ expressions that were read, evaluated, and printed from buffers (including the minibuffer) by the standard Emacs commands which do this. (Note that this does @emph{not} include evaluation in @file{*ielm*} buffers, nor evaluation using @kbd{C-j}, @kbd{C-x C-e}, -and similar evaluation commands in @code{lisp-interaction-mode}.) The -elements are ordered most recent first. +and similar evaluation commands in @code{lisp-interaction-mode}.) + +This variable is obsolete, and will be removed in a future version, +since it constantly enlarges the memory footprint of the Emacs +process. For that reason, we recommend against using it. + +The elements of @code{values} are ordered most recent first. @example @group @@ -880,8 +885,8 @@ values @end group @end example -This variable is useful for referring back to values of forms recently -evaluated. It is generally a bad idea to print the value of +This variable could be useful for referring back to values of forms +recently evaluated. It is generally a bad idea to print the value of @code{values} itself, since this may be very long. Instead, examine particular elements, like this: diff --git a/etc/NEWS b/etc/NEWS index 2adcc6f4a7..3fa22fbb57 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -3374,7 +3374,10 @@ back in Emacs 23.1. The affected functions are: 'make-obsolete', ** The variable 'keyboard-type' is obsolete and not dynamically scoped any more. ++++ ** The 'values' variable is now obsolete. +Using it just contributes to the growth of the Emacs memory +footprint. +++ ** The '&define' keyword in an Edebug specification now disables backtracking. commit dbec4ae06b36f2c86287f54e3417f4e5db6c7c01 Author: Eli Zaretskii Date: Sun Aug 29 14:28:36 2021 +0300 ; Copy contents of oldXMenu/copyright.h into oldXMenu/*.[ch] files diff --git a/oldXMenu/Activate.c b/oldXMenu/Activate.c index 91439eacc2..8ffa817f6c 100644 --- a/oldXMenu/Activate.c +++ b/oldXMenu/Activate.c @@ -1,6 +1,24 @@ /* Copyright Massachusetts Institute of Technology 1985 */ -#include "copyright.h" +/* + +Copyright 1985, 1986, 1987 by the Massachusetts Institute of Technology + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of M.I.T. not be used in +advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +M.I.T. makes no representations about the suitability of +this software for any purpose. It is provided "as is" +without express or implied warranty. + +*/ + + /* Copyright (C) 2001-2021 Free Software Foundation, Inc. diff --git a/oldXMenu/AddPane.c b/oldXMenu/AddPane.c index e7246f2faa..b14b3e82e4 100644 --- a/oldXMenu/AddPane.c +++ b/oldXMenu/AddPane.c @@ -1,6 +1,24 @@ /* Copyright Massachusetts Institute of Technology 1985 */ -#include "copyright.h" +/* + +Copyright 1985, 1986, 1987 by the Massachusetts Institute of Technology + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of M.I.T. not be used in +advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +M.I.T. makes no representations about the suitability of +this software for any purpose. It is provided "as is" +without express or implied warranty. + +*/ + + /* * XMenu: MIT Project Athena, X Window system menu package diff --git a/oldXMenu/AddSel.c b/oldXMenu/AddSel.c index 2a52a6a6c8..9596caed0e 100644 --- a/oldXMenu/AddSel.c +++ b/oldXMenu/AddSel.c @@ -1,6 +1,24 @@ /* Copyright Massachusetts Institute of Technology 1985 */ -#include "copyright.h" +/* + +Copyright 1985, 1986, 1987 by the Massachusetts Institute of Technology + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of M.I.T. not be used in +advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +M.I.T. makes no representations about the suitability of +this software for any purpose. It is provided "as is" +without express or implied warranty. + +*/ + + /* diff --git a/oldXMenu/ChgPane.c b/oldXMenu/ChgPane.c index 733f65950f..c9c4a5e8a4 100644 --- a/oldXMenu/ChgPane.c +++ b/oldXMenu/ChgPane.c @@ -1,6 +1,24 @@ /* Copyright Massachusetts Institute of Technology 1985 */ -#include "copyright.h" +/* + +Copyright 1985, 1986, 1987 by the Massachusetts Institute of Technology + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of M.I.T. not be used in +advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +M.I.T. makes no representations about the suitability of +this software for any purpose. It is provided "as is" +without express or implied warranty. + +*/ + + /* diff --git a/oldXMenu/ChgSel.c b/oldXMenu/ChgSel.c index 5a46b5cf58..c26781b014 100644 --- a/oldXMenu/ChgSel.c +++ b/oldXMenu/ChgSel.c @@ -1,6 +1,24 @@ /* Copyright Massachusetts Institute of Technology 1985 */ -#include "copyright.h" +/* + +Copyright 1985, 1986, 1987 by the Massachusetts Institute of Technology + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of M.I.T. not be used in +advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +M.I.T. makes no representations about the suitability of +this software for any purpose. It is provided "as is" +without express or implied warranty. + +*/ + + /* diff --git a/oldXMenu/Create.c b/oldXMenu/Create.c index e209bbecee..2077a71848 100644 --- a/oldXMenu/Create.c +++ b/oldXMenu/Create.c @@ -1,6 +1,24 @@ /* Copyright Massachusetts Institute of Technology 1985 */ -#include "copyright.h" +/* + +Copyright 1985, 1986, 1987 by the Massachusetts Institute of Technology + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of M.I.T. not be used in +advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +M.I.T. makes no representations about the suitability of +this software for any purpose. It is provided "as is" +without express or implied warranty. + +*/ + + /* Copyright (C) 1993-1994, 2001-2021 Free Software Foundation, Inc. diff --git a/oldXMenu/DelPane.c b/oldXMenu/DelPane.c index 10234e0290..37a2095c55 100644 --- a/oldXMenu/DelPane.c +++ b/oldXMenu/DelPane.c @@ -1,6 +1,24 @@ /* Copyright Massachusetts Institute of Technology 1985 */ -#include "copyright.h" +/* + +Copyright 1985, 1986, 1987 by the Massachusetts Institute of Technology + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of M.I.T. not be used in +advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +M.I.T. makes no representations about the suitability of +this software for any purpose. It is provided "as is" +without express or implied warranty. + +*/ + + /* diff --git a/oldXMenu/DelSel.c b/oldXMenu/DelSel.c index ca2ea28c4b..47cc1685f0 100644 --- a/oldXMenu/DelSel.c +++ b/oldXMenu/DelSel.c @@ -1,6 +1,24 @@ /* Copyright Massachusetts Institute of Technology 1985 */ -#include "copyright.h" +/* + +Copyright 1985, 1986, 1987 by the Massachusetts Institute of Technology + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of M.I.T. not be used in +advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +M.I.T. makes no representations about the suitability of +this software for any purpose. It is provided "as is" +without express or implied warranty. + +*/ + + /* diff --git a/oldXMenu/Destroy.c b/oldXMenu/Destroy.c index 7f0f614631..fdaa69b8d1 100644 --- a/oldXMenu/Destroy.c +++ b/oldXMenu/Destroy.c @@ -1,6 +1,24 @@ /* Copyright Massachusetts Institute of Technology 1985 */ -#include "copyright.h" +/* + +Copyright 1985, 1986, 1987 by the Massachusetts Institute of Technology + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of M.I.T. not be used in +advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +M.I.T. makes no representations about the suitability of +this software for any purpose. It is provided "as is" +without express or implied warranty. + +*/ + + /* diff --git a/oldXMenu/Error.c b/oldXMenu/Error.c index 01738458b6..b49e172f0e 100644 --- a/oldXMenu/Error.c +++ b/oldXMenu/Error.c @@ -1,6 +1,24 @@ /* Copyright Massachusetts Institute of Technology 1985 */ -#include "copyright.h" +/* + +Copyright 1985, 1986, 1987 by the Massachusetts Institute of Technology + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of M.I.T. not be used in +advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +M.I.T. makes no representations about the suitability of +this software for any purpose. It is provided "as is" +without express or implied warranty. + +*/ + + /* diff --git a/oldXMenu/EvHand.c b/oldXMenu/EvHand.c index bd15359d91..94789c296f 100644 --- a/oldXMenu/EvHand.c +++ b/oldXMenu/EvHand.c @@ -1,6 +1,24 @@ /* Copyright Massachusetts Institute of Technology 1985 */ -#include "copyright.h" +/* + +Copyright 1985, 1986, 1987 by the Massachusetts Institute of Technology + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of M.I.T. not be used in +advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +M.I.T. makes no representations about the suitability of +this software for any purpose. It is provided "as is" +without express or implied warranty. + +*/ + + /* diff --git a/oldXMenu/FindPane.c b/oldXMenu/FindPane.c index 8101d009a2..3e763215dd 100644 --- a/oldXMenu/FindPane.c +++ b/oldXMenu/FindPane.c @@ -1,6 +1,24 @@ /* Copyright Massachusetts Institute of Technology 1985 */ -#include "copyright.h" +/* + +Copyright 1985, 1986, 1987 by the Massachusetts Institute of Technology + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of M.I.T. not be used in +advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +M.I.T. makes no representations about the suitability of +this software for any purpose. It is provided "as is" +without express or implied warranty. + +*/ + + /* diff --git a/oldXMenu/FindSel.c b/oldXMenu/FindSel.c index e2a5dbbdcd..53d14053b3 100644 --- a/oldXMenu/FindSel.c +++ b/oldXMenu/FindSel.c @@ -1,6 +1,24 @@ /* Copyright Massachusetts Institute of Technology 1985 */ -#include "copyright.h" +/* + +Copyright 1985, 1986, 1987 by the Massachusetts Institute of Technology + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of M.I.T. not be used in +advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +M.I.T. makes no representations about the suitability of +this software for any purpose. It is provided "as is" +without express or implied warranty. + +*/ + + /* Copyright (C) 2001-2021 Free Software Foundation, Inc. diff --git a/oldXMenu/InsPane.c b/oldXMenu/InsPane.c index da92f49aa7..89253e1db0 100644 --- a/oldXMenu/InsPane.c +++ b/oldXMenu/InsPane.c @@ -1,6 +1,24 @@ /* Copyright Massachusetts Institute of Technology 1985 */ -#include "copyright.h" +/* + +Copyright 1985, 1986, 1987 by the Massachusetts Institute of Technology + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of M.I.T. not be used in +advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +M.I.T. makes no representations about the suitability of +this software for any purpose. It is provided "as is" +without express or implied warranty. + +*/ + + /* diff --git a/oldXMenu/InsSel.c b/oldXMenu/InsSel.c index f538043795..527a7a0da8 100644 --- a/oldXMenu/InsSel.c +++ b/oldXMenu/InsSel.c @@ -1,6 +1,24 @@ /* Copyright Massachusetts Institute of Technology 1985 */ -#include "copyright.h" +/* + +Copyright 1985, 1986, 1987 by the Massachusetts Institute of Technology + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of M.I.T. not be used in +advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +M.I.T. makes no representations about the suitability of +this software for any purpose. It is provided "as is" +without express or implied warranty. + +*/ + + /* diff --git a/oldXMenu/Internal.c b/oldXMenu/Internal.c index 3e97f9ab3f..476336ce49 100644 --- a/oldXMenu/Internal.c +++ b/oldXMenu/Internal.c @@ -1,6 +1,24 @@ /* Copyright Massachusetts Institute of Technology 1985 */ -#include "copyright.h" +/* + +Copyright 1985, 1986, 1987 by the Massachusetts Institute of Technology + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of M.I.T. not be used in +advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +M.I.T. makes no representations about the suitability of +this software for any purpose. It is provided "as is" +without express or implied warranty. + +*/ + + /* Copyright (C) 1993, 1996, 2001-2021 Free Software Foundation, Inc. diff --git a/oldXMenu/Locate.c b/oldXMenu/Locate.c index 1605b4bbb2..bd12666011 100644 --- a/oldXMenu/Locate.c +++ b/oldXMenu/Locate.c @@ -1,6 +1,24 @@ /* Copyright Massachusetts Institute of Technology 1985 */ -#include "copyright.h" +/* + +Copyright 1985, 1986, 1987 by the Massachusetts Institute of Technology + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of M.I.T. not be used in +advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +M.I.T. makes no representations about the suitability of +this software for any purpose. It is provided "as is" +without express or implied warranty. + +*/ + + /* diff --git a/oldXMenu/Post.c b/oldXMenu/Post.c index e78fedcf77..524773673b 100644 --- a/oldXMenu/Post.c +++ b/oldXMenu/Post.c @@ -1,6 +1,24 @@ /* Copyright Massachusetts Institute of Technology 1985 */ -#include "copyright.h" +/* + +Copyright 1985, 1986, 1987 by the Massachusetts Institute of Technology + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of M.I.T. not be used in +advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +M.I.T. makes no representations about the suitability of +this software for any purpose. It is provided "as is" +without express or implied warranty. + +*/ + + /* diff --git a/oldXMenu/Recomp.c b/oldXMenu/Recomp.c index 2aec87a51d..5c129fc543 100644 --- a/oldXMenu/Recomp.c +++ b/oldXMenu/Recomp.c @@ -1,6 +1,24 @@ /* Copyright Massachusetts Institute of Technology 1985 */ -#include "copyright.h" +/* + +Copyright 1985, 1986, 1987 by the Massachusetts Institute of Technology + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of M.I.T. not be used in +advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +M.I.T. makes no representations about the suitability of +this software for any purpose. It is provided "as is" +without express or implied warranty. + +*/ + + /* diff --git a/oldXMenu/SetAEQ.c b/oldXMenu/SetAEQ.c index ee2d64b880..57debf0dd7 100644 --- a/oldXMenu/SetAEQ.c +++ b/oldXMenu/SetAEQ.c @@ -1,6 +1,24 @@ /* Copyright Massachusetts Institute of Technology 1985 */ -#include "copyright.h" +/* + +Copyright 1985, 1986, 1987 by the Massachusetts Institute of Technology + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of M.I.T. not be used in +advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +M.I.T. makes no representations about the suitability of +this software for any purpose. It is provided "as is" +without express or implied warranty. + +*/ + + /* diff --git a/oldXMenu/SetFrz.c b/oldXMenu/SetFrz.c index c8998eeb66..eb54dd671e 100644 --- a/oldXMenu/SetFrz.c +++ b/oldXMenu/SetFrz.c @@ -1,6 +1,24 @@ /* Copyright Massachusetts Institute of Technology 1985 */ -#include "copyright.h" +/* + +Copyright 1985, 1986, 1987 by the Massachusetts Institute of Technology + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of M.I.T. not be used in +advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +M.I.T. makes no representations about the suitability of +this software for any purpose. It is provided "as is" +without express or implied warranty. + +*/ + + /* diff --git a/oldXMenu/SetPane.c b/oldXMenu/SetPane.c index f29a81c5ca..b43c777f27 100644 --- a/oldXMenu/SetPane.c +++ b/oldXMenu/SetPane.c @@ -1,6 +1,24 @@ /* Copyright Massachusetts Institute of Technology 1985 */ -#include "copyright.h" +/* + +Copyright 1985, 1986, 1987 by the Massachusetts Institute of Technology + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of M.I.T. not be used in +advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +M.I.T. makes no representations about the suitability of +this software for any purpose. It is provided "as is" +without express or implied warranty. + +*/ + + /* diff --git a/oldXMenu/SetSel.c b/oldXMenu/SetSel.c index 2f950d49fd..251b5f9515 100644 --- a/oldXMenu/SetSel.c +++ b/oldXMenu/SetSel.c @@ -1,6 +1,24 @@ /* Copyright Massachusetts Institute of Technology 1985 */ -#include "copyright.h" +/* + +Copyright 1985, 1986, 1987 by the Massachusetts Institute of Technology + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of M.I.T. not be used in +advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +M.I.T. makes no representations about the suitability of +this software for any purpose. It is provided "as is" +without express or implied warranty. + +*/ + + /* diff --git a/oldXMenu/XCrAssoc.c b/oldXMenu/XCrAssoc.c index 7150cbc53d..e017cbbbcc 100644 --- a/oldXMenu/XCrAssoc.c +++ b/oldXMenu/XCrAssoc.c @@ -1,5 +1,23 @@ /* Copyright Massachusetts Institute of Technology 1985 */ -#include "copyright.h" +/* + +Copyright 1985, 1986, 1987 by the Massachusetts Institute of Technology + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of M.I.T. not be used in +advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +M.I.T. makes no representations about the suitability of +this software for any purpose. It is provided "as is" +without express or implied warranty. + +*/ + + #include diff --git a/oldXMenu/XDelAssoc.c b/oldXMenu/XDelAssoc.c index ec1d09d46e..26a635eef5 100644 --- a/oldXMenu/XDelAssoc.c +++ b/oldXMenu/XDelAssoc.c @@ -1,6 +1,24 @@ /* Copyright Massachusetts Institute of Technology 1985 */ -#include "copyright.h" +/* + +Copyright 1985, 1986, 1987 by the Massachusetts Institute of Technology + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of M.I.T. not be used in +advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +M.I.T. makes no representations about the suitability of +this software for any purpose. It is provided "as is" +without express or implied warranty. + +*/ + + #include "XMenuInt.h" diff --git a/oldXMenu/XDestAssoc.c b/oldXMenu/XDestAssoc.c index 94c0454756..7306944434 100644 --- a/oldXMenu/XDestAssoc.c +++ b/oldXMenu/XDestAssoc.c @@ -1,6 +1,24 @@ /* Copyright Massachusetts Institute of Technology 1985 */ -#include "copyright.h" +/* + +Copyright 1985, 1986, 1987 by the Massachusetts Institute of Technology + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of M.I.T. not be used in +advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +M.I.T. makes no representations about the suitability of +this software for any purpose. It is provided "as is" +without express or implied warranty. + +*/ + + #include "XMenuInt.h" diff --git a/oldXMenu/XLookAssoc.c b/oldXMenu/XLookAssoc.c index fad960d7a4..577e63f42f 100644 --- a/oldXMenu/XLookAssoc.c +++ b/oldXMenu/XLookAssoc.c @@ -1,6 +1,24 @@ /* Copyright Massachusetts Institute of Technology 1985 */ -#include "copyright.h" +/* + +Copyright 1985, 1986, 1987 by the Massachusetts Institute of Technology + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of M.I.T. not be used in +advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +M.I.T. makes no representations about the suitability of +this software for any purpose. It is provided "as is" +without express or implied warranty. + +*/ + + #include #include diff --git a/oldXMenu/XMakeAssoc.c b/oldXMenu/XMakeAssoc.c index 2530e8e507..256d4ebb0e 100644 --- a/oldXMenu/XMakeAssoc.c +++ b/oldXMenu/XMakeAssoc.c @@ -1,6 +1,24 @@ /* Copyright Massachusetts Institute of Technology 1985 */ -#include "copyright.h" +/* + +Copyright 1985, 1986, 1987 by the Massachusetts Institute of Technology + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of M.I.T. not be used in +advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +M.I.T. makes no representations about the suitability of +this software for any purpose. It is provided "as is" +without express or implied warranty. + +*/ + + #include "XMenuInt.h" diff --git a/oldXMenu/XMenu.h b/oldXMenu/XMenu.h index 8e4292f508..50ea683409 100644 --- a/oldXMenu/XMenu.h +++ b/oldXMenu/XMenu.h @@ -1,6 +1,24 @@ /* Copyright Massachusetts Institute of Technology 1985 */ -#include "copyright.h" +/* + +Copyright 1985, 1986, 1987 by the Massachusetts Institute of Technology + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of M.I.T. not be used in +advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +M.I.T. makes no representations about the suitability of +this software for any purpose. It is provided "as is" +without express or implied warranty. + +*/ + + /* diff --git a/oldXMenu/XMenuInt.h b/oldXMenu/XMenuInt.h index 369b8c1a4a..86b8e057cd 100644 --- a/oldXMenu/XMenuInt.h +++ b/oldXMenu/XMenuInt.h @@ -1,6 +1,24 @@ /* Copyright Massachusetts Institute of Technology 1985 */ -#include "copyright.h" +/* + +Copyright 1985, 1986, 1987 by the Massachusetts Institute of Technology + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of M.I.T. not be used in +advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +M.I.T. makes no representations about the suitability of +this software for any purpose. It is provided "as is" +without express or implied warranty. + +*/ + + /* commit b0fe06e656209581466f60ac3b9ea98bb6acecbf Author: Alan Third Date: Wed Aug 25 21:00:07 2021 +0100 Disable the NS app when no frames are left (bug#14619, bug#21357, bug#23586) * src/nsfns.m (Fx_create_frame): Enable the app. * src/nsterm.m (ns_delete_terminal): Disable the app. diff --git a/src/nsfns.m b/src/nsfns.m index c40367703d..07bcab1816 100644 --- a/src/nsfns.m +++ b/src/nsfns.m @@ -1343,6 +1343,11 @@ Turn the input menu (an NSMenu) into a lisp list for tracking on lisp side. f->output_data.ns->in_animation = NO; +#ifdef NS_IMPL_COCOA + /* If the app has previously been disabled, start it up again. */ + [NSApp setActivationPolicy:NSApplicationActivationPolicyRegular]; +#endif + [[EmacsView alloc] initFrameFromEmacs: f]; ns_icon (f, parms); diff --git a/src/nsterm.m b/src/nsterm.m index 1c1f0c8f23..4bdc67c10b 100644 --- a/src/nsterm.m +++ b/src/nsterm.m @@ -5014,6 +5014,12 @@ static Lisp_Object ns_string_to_lispmod (const char *s) block_input (); +#ifdef NS_IMPL_COCOA + /* Rather than try to clean up the NS environment we can just + disable the app and leave it waiting for any new frames. */ + [NSApp setActivationPolicy:NSApplicationActivationPolicyProhibited]; +#endif + image_destroy_all_bitmaps (dpyinfo); ns_delete_display (dpyinfo); unblock_input (); commit 0aa0410372dc9dbd251fec0ec71a28e88b9697ec Author: Stephen Gildea Date: Wed Aug 25 17:39:26 2021 -0700 Fix "Finder" description for multi-file packages * lisp/finder.el (finder-compile-keywords): Now that 'version' is set for more files, it is no longer necessary to check that we have a version when picking the file from which to take the description. Doing so caused built-in packages (where the version is known) to have their package description taken from the last .el file that matched the file name pattern, usually the last source file in the sub-directory. This bug was introduced in July 2019 and first released in Emacs 27.1. Thanks to Michael Albinus for reviewing this patch. diff --git a/lisp/finder.el b/lisp/finder.el index d79b9c99f6..b8db62865d 100644 --- a/lisp/finder.el +++ b/lisp/finder.el @@ -253,7 +253,7 @@ from; the default is `load-path'." ;; The idea here is that eg calc.el gets to define ;; the description of the calc package. ;; This does not work for eg nxml-mode.el. - ((or (eq base-name package) version) + ((eq base-name package) (setq desc (cdr entry)) (aset desc 0 version) (aset desc 2 summary)))