From 67a27ff53bf0f8473cb6b58ad85298e066b8def4 Mon Sep 17 00:00:00 2001 From: Stefan Kangas Date: Sun, 27 Oct 2024 07:49:32 +0100 Subject: [PATCH 1/4] ; Fix typos --- ChangeLog.4 | 6 +++--- admin/codespell/codespell.exclude | 5 ++--- doc/emacs/emacs.texi | 2 +- doc/misc/eieio.texi | 2 +- etc/themes/adwaita-theme.el | 2 +- etc/themes/manoj-dark-theme.el | 4 ++-- etc/themes/misterioso-theme.el | 2 +- lisp/emacs-lisp/nadvice.el | 2 +- lisp/progmodes/c-ts-mode.el | 4 ++-- lisp/progmodes/etags.el | 2 +- lisp/progmodes/php-ts-mode.el | 2 +- lisp/treesit.el | 2 +- test/lisp/eshell/em-glob-tests.el | 2 +- test/lisp/progmodes/c-ts-mode-resources/indent.erts | 2 +- 14 files changed, 19 insertions(+), 20 deletions(-) diff --git a/ChangeLog.4 b/ChangeLog.4 index 282197eaeed..7cfdbd13184 100644 --- a/ChangeLog.4 +++ b/ChangeLog.4 @@ -219,7 +219,7 @@ Fix c-ts-mode indentation for initializer lists (bug#73661) - The intentation behavior differed between c-mode/c++-mode + The indentation behavior differed between c-mode/c++-mode and *-ts-mode for initializer lists where the first element was not at beginning-of-line. The anchor-prev-sibling function gave up and returned nil, but it should (probably) anchor on the @@ -547,7 +547,7 @@ Align columns in which-key with wide characters properly - In the case that a character takes up multple columns (such as + In the case that a character takes up multiple columns (such as `…' when used as a truncation character), make sure that the columns are still aligned properly. * lisp/which-key.el (which-key--pad-column): Use `string-width' @@ -1032,7 +1032,7 @@ * src/treesit.c (treesit_sync_visible_region): Minimally fix ranges so it doesn't exceed parser's visible range. - (treesit_call_after_change_functions): Update calling sigature to + (treesit_call_after_change_functions): Update calling signature to treesit_make_ranges. (treesit_ensure_parsed, make_treesit_parser): Use the new field within_reparse. diff --git a/admin/codespell/codespell.exclude b/admin/codespell/codespell.exclude index 1dc4fb8f014..f4c67ae83e8 100644 --- a/admin/codespell/codespell.exclude +++ b/admin/codespell/codespell.exclude @@ -1701,8 +1701,6 @@ Timo Savola, Jorgen Sch@"afer, Holger Schauer, William Schelter, Ralph 5b34fc07085 * lisp/treesit.el (treesit-node-at): Update docstring (bu... 5cf1de683b2 Fix python-fill-paragraph problems on filling strings (bu... 7678b7e46f2 Eglot: check server capability before sending didSave (bu... - 7678b7e46f2 Eglot: check server capability before sending didSave (bu... - 9ac12592781 Fix display of menu-bar bindings of commands in *Help* bu... 9ac12592781 Fix display of menu-bar bindings of commands in *Help* bu... 9e105d483fa Fix c-ts-mode indentation for statement after preproc (bu... When running emacs in a terminal (or at least, in iTerm), keys are not @@ -1736,7 +1734,6 @@ Timo Savola, Jorgen Sch@"afer, Holger Schauer, William Schelter, Ralph ed3bab3cc72 Revert 'forward-sentence-default-function' to return poin... b3e930d328e Revert inadvertent change to lisp/icomplete.el in previou... 973c1d24c6a ruby-ts-mode: Also don't reindent 'identifier' when insid... - 973c1d24c6a ruby-ts-mode: Also don't reindent 'identifier' when insid... e444115d026 Improve keymap-global-set and keymap-local-set interactiv... 8e9783b4ce4 Rebind in read-regexp-map ‘M-c’ to ‘M-s c’ compatible wit... f12f72b0e09 ; * lisp/simple.el (primitive-undo): Clarify error messag... @@ -1744,3 +1741,5 @@ Timo Savola, Jorgen Sch@"afer, Holger Schauer, William Schelter, Ralph b211a63455c Make tab-bar-tab-group-format-function also handle curren... a3c310c11a Create new "use-package" themse and use it for :custom wit... 2a85d81c47 Add support for gathering statistics on use-package declar... + (let* ((nam (buffer-substring (match-beginning 2) (match-end 2))) + (setq nmlst (cons nam nmlst) diff --git a/doc/emacs/emacs.texi b/doc/emacs/emacs.texi index 6df853f2a00..3dd0688d426 100644 --- a/doc/emacs/emacs.texi +++ b/doc/emacs/emacs.texi @@ -1432,7 +1432,7 @@ If you need to contact the Free Software Foundation, see @display Free Software Foundation -31 Milk Street # 960789 +31 Milk Street, # 960789 Boston, MA 02196 USA @end display diff --git a/doc/misc/eieio.texi b/doc/misc/eieio.texi index 039588b311d..ec1e6727ff8 100644 --- a/doc/misc/eieio.texi +++ b/doc/misc/eieio.texi @@ -812,7 +812,7 @@ You do it using Emacs Lisp's built-in support for CLOS-style generic functions via the @code{cl-defgeneric} and @code{cl-defmethod} macros (@pxref{Generic Functions,,,elisp,GNU Emacs Lisp Reference Manual}). -EIEIO provides one extension to @code{cl-defmethod} to allow mathods to +EIEIO provides one extension to @code{cl-defmethod} to allow methods to dispatch on a class argument: so-called ``static'' methods do not depend on an object instance, but instead operate on a class. You can create a static method by using the @code{subclass} specializer with diff --git a/etc/themes/adwaita-theme.el b/etc/themes/adwaita-theme.el index cea8f85c081..1c3c3b26752 100644 --- a/etc/themes/adwaita-theme.el +++ b/etc/themes/adwaita-theme.el @@ -105,4 +105,4 @@ default look of the Gnome 3 desktop." `(diff-added ((,class (:bold t :foreground "#4E9A06")))) `(diff-removed ((,class (:bold t :foreground "#F5666D")))))) -;;; adwaita-theme.el ends here +;;; adwaita-theme.el ends here diff --git a/etc/themes/manoj-dark-theme.el b/etc/themes/manoj-dark-theme.el index 81dac1902f0..1bee1e7faf8 100644 --- a/etc/themes/manoj-dark-theme.el +++ b/etc/themes/manoj-dark-theme.el @@ -37,7 +37,7 @@ ;; viewed, for example, the Gnus group buffer, consistent and logical ;; color choices are the only sane option. Gnus groups can be newa ;; (blueish) or mail (greenish), have states (large number of under -;; messages, normal, and empty). The large number unread groups have +;; messages, normal, and empty). The large number unread groups have ;; highest luminance (appear brighter), and the empty one have lower ;; luminance (appear grayer), but have the same chroma and saturation. ;; Sub states and group priorities are rendered using a color series @@ -704,4 +704,4 @@ jarring angry fruit salad look to reduce eye fatigue." (provide-theme 'manoj-dark) -;;; manoj-dark.el ends here +;;; manoj-dark-theme.el ends here diff --git a/etc/themes/misterioso-theme.el b/etc/themes/misterioso-theme.el index 75693b59016..6487356fbb1 100644 --- a/etc/themes/misterioso-theme.el +++ b/etc/themes/misterioso-theme.el @@ -134,4 +134,4 @@ (provide-theme 'misterioso) -;;; misterioso-theme.el ends here +;;; misterioso-theme.el ends here diff --git a/lisp/emacs-lisp/nadvice.el b/lisp/emacs-lisp/nadvice.el index 36df143a82a..ac9254c867a 100644 --- a/lisp/emacs-lisp/nadvice.el +++ b/lisp/emacs-lisp/nadvice.el @@ -584,7 +584,7 @@ of the piece of advice." ;;;###autoload (defmacro define-advice (symbol args &rest body) "Define an advice and add it to function named SYMBOL. -See `advice-add' and `add-function' for explanation on the +See `advice-add' and `add-function' for explanation of the arguments. If NAME is non-nil, the advice is named `SYMBOL@NAME' and installed with the name NAME; otherwise, the advice is anonymous. diff --git a/lisp/progmodes/c-ts-mode.el b/lisp/progmodes/c-ts-mode.el index 73ec3f2bb2d..2785e9a6e68 100644 --- a/lisp/progmodes/c-ts-mode.el +++ b/lisp/progmodes/c-ts-mode.el @@ -1437,9 +1437,9 @@ recommended to enable `electric-pair-mode' with this mode." :help "Toggle C/C++ comment style between block and line comments"]) "--" ("Toggle..." - ["SubWord Mode" subword-mode + ["Subword Mode" subword-mode :style toggle :selected subword-mode - :help "Toggle sub-word movement and editing mode"]))) + :help "Toggle subword movement and editing mode"]))) ;; We could alternatively use parsers, but if this works well, I don't ;; see the need to change. This is copied verbatim from cc-guess.el. diff --git a/lisp/progmodes/etags.el b/lisp/progmodes/etags.el index 35dc0215046..ca69817953e 100644 --- a/lisp/progmodes/etags.el +++ b/lisp/progmodes/etags.el @@ -1915,7 +1915,7 @@ If no file is associated with the current buffer, this function returns nil." (defun list-tags (file &optional _next-match) "Display list of tags in file FILE. Interactively, prompt for FILE, with completion, offering the current -buffer's file name as the defaul. +buffer's file name as the default. This command searches only the first table in the list of tags tables, and does not search included tables. FILE should be as it was submitted to the `etags' command, which usually diff --git a/lisp/progmodes/php-ts-mode.el b/lisp/progmodes/php-ts-mode.el index ce8cf8aa340..14a487d3f7a 100644 --- a/lisp/progmodes/php-ts-mode.el +++ b/lisp/progmodes/php-ts-mode.el @@ -437,7 +437,7 @@ Useful for debugging." Return `php-ts-mode-indent-offset' plus 1 when BOL is after `php-ts-mode--possibly-braceless-keyword-re', otherwise return 0. It's -usefull for matching incomplete compound_statement or colon_block. +useful for matching incomplete compound_statement or colon_block. PARENT is NODE's parent, BOL is the beginning of non-whitespace characters of the current line." (and (null node) diff --git a/lisp/treesit.el b/lisp/treesit.el index bedcc260750..9ac470691d6 100644 --- a/lisp/treesit.el +++ b/lisp/treesit.el @@ -3080,7 +3080,7 @@ If `treesit-defun-name-function' is non-nil, set up If `treesit-simple-imenu-settings' is non-nil, set up Imenu. If either `treesit-outline-predicate' or `treesit-simple-imenu-settings' -are non-nil, and Outline minor mode settings don't alreay exist, setup +are non-nil, and Outline minor mode settings don't already exist, setup Outline minor mode. If `sexp', `sentence' are defined in `treesit-thing-settings', diff --git a/test/lisp/eshell/em-glob-tests.el b/test/lisp/eshell/em-glob-tests.el index 88e9cc73bbd..4169ab7f339 100644 --- a/test/lisp/eshell/em-glob-tests.el +++ b/test/lisp/eshell/em-glob-tests.el @@ -74,7 +74,7 @@ component ending in \"symlink\" is treated as a symbolic link." ;; Ensure the default expansion splices the glob. (eshell-command-result-equal "funcall list *.el" '("a.el" "b.el")) (eshell-command-result-equal "funcall list *.txt" '("c.txt")) - ;; When spliting, no-matches cases also return a list containing + ;; When splitting, no-matches cases also return a list containing ;; the original non-matching glob. (eshell-command-result-equal "funcall list *.no" '("*.no")) (when (eshell-tests-remote-accessible-p) diff --git a/test/lisp/progmodes/c-ts-mode-resources/indent.erts b/test/lisp/progmodes/c-ts-mode-resources/indent.erts index f97ceac61f5..2f3540c3970 100644 --- a/test/lisp/progmodes/c-ts-mode-resources/indent.erts +++ b/test/lisp/progmodes/c-ts-mode-resources/indent.erts @@ -208,7 +208,7 @@ int main() } =-=-= -Name: Return Compund Literal +Name: Return Compound Literal =-= struct pair { int fst, snd; }; From 299a1f240750595d7b0132aec5eb3a2b58c9d943 Mon Sep 17 00:00:00 2001 From: Sean Whitton Date: Sun, 27 Oct 2024 18:56:31 +0800 Subject: [PATCH 2/4] ; * lisp/vc/log-edit.el (log-edit-diff-function): Grammar fix. --- lisp/vc/log-edit.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/vc/log-edit.el b/lisp/vc/log-edit.el index d61a108b195..3c4eadb59a1 100644 --- a/lisp/vc/log-edit.el +++ b/lisp/vc/log-edit.el @@ -246,7 +246,7 @@ when this variable is set to nil.") (defvar log-edit-initial-files nil) (defvar log-edit-callback nil) (defvar log-edit-diff-function - (lambda () (error "Diff functionality has not been setup"))) + (lambda () (error "Diff functionality has not been set up"))) (defvar log-edit-listfun nil) (defvar log-edit-parent-buffer nil) From b0aaee93fde245b972a0d69b60328550f53bc043 Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Sun, 27 Oct 2024 13:16:36 +0200 Subject: [PATCH 3/4] Update the documentation of void functions * doc/lispref/functions.texi (Function Cells): * src/data.c (Ffboundp, Ffmakunbound, Fsymbol_function): Update documentation to the changes of how void functions are represented since Emacs 24.5. (Bug#73886) --- doc/lispref/functions.texi | 24 ++++++++++++------------ src/data.c | 12 ++++++------ 2 files changed, 18 insertions(+), 18 deletions(-) diff --git a/doc/lispref/functions.texi b/doc/lispref/functions.texi index 0131305525c..bfb8789d05b 100644 --- a/doc/lispref/functions.texi +++ b/doc/lispref/functions.texi @@ -1511,9 +1511,9 @@ indirect-function}. This returns the object in the function cell of @var{symbol}. It does not check that the returned object is a legitimate function. -If the function cell is void, the return value is @code{nil}. To -distinguish between a function cell that is void and one set to -@code{nil}, use @code{fboundp} (see below). +If the function cell is void, the return value is @code{nil}. It is +impossible to distinguish between a function cell that is void and one +set to @code{nil}. @example @group @@ -1538,24 +1538,24 @@ that that symbol's function cell is @dfn{void}. In other words, the function cell does not have any Lisp object in it. If you try to call the symbol as a function, Emacs signals a @code{void-function} error. - Note that void is not the same as @code{nil} or the symbol -@code{void}. The symbols @code{nil} and @code{void} are Lisp objects, -and can be stored into a function cell just as any other object can be -(and @code{void} can be a valid function if you define it with -@code{defun}). A void function cell contains no object whatsoever. + Unlike with void variables (@pxref{Void Variables}), a symbol's +function cell that contains @code{nil} is indistinguishable from the +function's being void. Note that void is not the same as the symbol +@code{void}: @code{void} can be a valid function if you define it with +@code{defun}. You can test the voidness of a symbol's function definition with @code{fboundp}. After you have given a symbol a function definition, you can make it void once more using @code{fmakunbound}. @defun fboundp symbol -This function returns @code{t} if the symbol has an object in its -function cell, @code{nil} otherwise. It does not check that the object -is a legitimate function. +This function returns @code{t} if the symbol has a non-@code{nil} object +in its function cell, @code{nil} otherwise. It does not check that the +object is a legitimate function. @end defun @defun fmakunbound symbol -This function makes @var{symbol}'s function cell void, so that a +This function makes @var{symbol}'s function cell @code{nil}, so that a subsequent attempt to access this cell will cause a @code{void-function} error. It returns @var{symbol}. (See also @code{makunbound}, in @ref{Void Variables}.) diff --git a/src/data.c b/src/data.c index 13b4593e005..bf83755bff3 100644 --- a/src/data.c +++ b/src/data.c @@ -756,7 +756,7 @@ global value outside of any lexical scope. */) breaking backward compatibility, as some users of fboundp may expect t in particular, rather than any true value. */ DEFUN ("fboundp", Ffboundp, Sfboundp, 1, 1, 0, - doc: /* Return t if SYMBOL's function definition is not void. */) + doc: /* Return t if SYMBOL's function definition is neither void nor nil. */) (Lisp_Object symbol) { CHECK_SYMBOL (symbol); @@ -782,12 +782,12 @@ See also `fmakunbound'. */) } DEFUN ("fmakunbound", Ffmakunbound, Sfmakunbound, 1, 1, 0, - doc: /* Make SYMBOL's function definition be void. + doc: /* Make SYMBOL's function definition be nil. Return SYMBOL. -If a function definition is void, trying to call a function by that -name will cause a `void-function' error. For more details, see Info -node `(elisp) Function Cells'. +If a function definition is nil or void, trying to call a function by +that name will cause a `void-function' error. For more details, see +Info node `(elisp) Function Cells'. See also `makunbound'. */) (register Lisp_Object symbol) @@ -800,7 +800,7 @@ See also `makunbound'. */) } DEFUN ("symbol-function", Fsymbol_function, Ssymbol_function, 1, 1, 0, - doc: /* Return SYMBOL's function definition, or nil if that is void. */) + doc: /* Return SYMBOL's function definition, or nil if that is void or nil. */) (Lisp_Object symbol) { CHECK_SYMBOL (symbol); From c78b4d2b31d9b763aa506d8498f70b3e651bbbf5 Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Sun, 27 Oct 2024 13:41:24 +0200 Subject: [PATCH 4/4] Fix doc string of 'wdired-use-dired-vertical-movement' * lisp/wdired.el (wdired-use-dired-vertical-movement): Remove the incorrect reference to 'track-eol'. (Bug#73917) --- lisp/wdired.el | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/lisp/wdired.el b/lisp/wdired.el index 8ce115eb142..0a858864d2d 100644 --- a/lisp/wdired.el +++ b/lisp/wdired.el @@ -93,8 +93,7 @@ is not nil." That is, always move the point to the beginning of the filename at line. If `sometimes', only move to the beginning of filename if the point is -before it, and `track-eol' is non-nil. This behavior is very handy -when editing several filenames. +before it. This behavior is very handy when editing several filenames. If nil, \"up\" and \"down\" movement is done as in any other buffer." :type '(choice (const :tag "As in any other mode" nil)