Commit graph

95391 commits

Author SHA1 Message Date
Eli Zaretskii
ae75ea6232 ; * src/fileio.c (Ffile_newer_than_file_p): Fix wording (bug#73709). 2024-10-13 18:29:34 +03:00
Eli Zaretskii
fb155bcfb6 ; * lisp/emacs-lisp/chart.el (chart-bar-quickie): Doc fix. 2024-10-12 08:44:28 +03:00
Andrea Corallo
6dbe4e99ac ; * lisp/emacs-lisp/chart.el (chart-bar-quickie): Improve documentation. 2024-10-11 22:42:25 +02:00
Jørgen Kvalsvik
e49b479f86
Fix c-ts-mode indentation for initializer lists (bug#73661)
The intentation 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
first element in the initializer list, such as this:

return { v1, v2, ...,
         y1, y2, ... };

c-ts-mode behaved better and figured out how to align, but I
added a test for a similar compound literal to prevent
regressions.

* lisp/progmodes/c-ts-mode.el (c-ts-mode--anchor-prev-sibling):
Anchor at first sibling unless bol is found.

* test/lisp/progmodes/c-ts-mode-resources/indent.erts: New
initializer list and compound literal test.

Copyright-paperwork-exempt: yes
2024-10-10 00:05:42 -07:00
Eli Zaretskii
f520008744 Avoid segfaults in Rmail-MIME
Rmail-MIME decodes text of email, including removal of
CR characters, but that can segfault if the text of some
MIME part is empty.
* src/coding.c (decode_coding_raw_text):
* lisp/mail/rmailmm.el (rmail-mime-insert-decoded-text): Don't
attempt to decode empty text region.
2024-10-09 16:22:52 +03:00
Brennan Vincent
6a5c2edd84 Eglot: use :immediate t when resolving completions (bug#73279)
Copyright-paperwork-exempt: Yes

* lisp/progmodes/eglot.el (eglot-completion-at-point): Tweak
eglot--request call.
2024-10-09 06:30:30 -05:00
João Távora
cd36e070c2 Eglot: minor changes to doc and docstrings
* doc/misc/eglot.texi (Quick Start): Tweak.
(Setting Up LSP Servers): Tweak.
(Customizing Eglot): Clarify eglot-connect-hook and
eglot-initialized-hook.

* lisp/progmodes/eglot.el (eglot-connect-hook)
(eglot-server-initialized-hook): Rework docstring.
2024-10-09 06:26:27 -05:00
Yuan Fu
1ea0d9b891
Revert "Set treesit-primary-parser for tree-sitter modes"
This reverts commit ed57faafc7.
2024-10-08 17:33:11 -07:00
Yuan Fu
52746ceb62
Remove duplicate indent rules in elixir-ts-mode
* lisp/progmodes/elixir-ts-mode.el (elixir-ts-mode): There are
two forms adding heex-ts--indent-rules, remove one of them.
2024-10-07 17:27:13 -07:00
Yuan Fu
ed57faafc7
Set treesit-primary-parser for tree-sitter modes
I debated whether to do this, since technically speaking it's
not needed for single-language modes.  But ultimately it's
better to be explicit and set a good example with builtin modes.

* lisp/progmodes/cmake-ts-mode.el (cmake-ts-mode):
* lisp/progmodes/csharp-mode.el (csharp-ts-mode):
* lisp/progmodes/dockerfile-ts-mode.el (dockerfile-ts-mode):
* lisp/progmodes/go-ts-mode.el (go-ts-mode):
(go-mod-ts-mode):
* lisp/progmodes/heex-ts-mode.el (heex-ts-mode):
* lisp/progmodes/java-ts-mode.el (java-ts-mode):
* lisp/progmodes/json-ts-mode.el (json-ts-mode):
* lisp/progmodes/lua-ts-mode.el (lua-ts-mode):
* lisp/progmodes/python.el (python-ts-mode):
* lisp/progmodes/ruby-ts-mode.el (ruby-ts-mode):
* lisp/progmodes/rust-ts-mode.el (rust-ts-mode):
* lisp/progmodes/sh-script.el:
* lisp/progmodes/typescript-ts-mode.el (typescript-ts-mode):
(tsx-ts-mode):
* lisp/textmodes/css-mode.el (css-ts-mode):
* lisp/textmodes/html-ts-mode.el (html-ts-mode):
* lisp/textmodes/toml-ts-mode.el (toml-ts-mode):
* lisp/textmodes/yaml-ts-mode.el (yaml-ts-mode): Set
treesit-primary-parser.
2024-10-07 17:24:32 -07:00
Sean Whitton
37a6c859b0 ; * lisp/emacs-lisp/cl-macs.el (cl-once-only): Fix capitalisation. 2024-10-06 13:38:57 +08:00
Eli Zaretskii
b68b9f291c ; * lisp/progmodes/csharp-mode.el (treesit-query-compile): Declare. 2024-10-05 14:38:48 +03:00
Eli Zaretskii
688201ef18 ; * lisp/window.el (switch-to-prev-buffer-skip-regexp): Doc fix (bug#73545). 2024-10-05 13:30:30 +03:00
Morgan Willcock
ba44fc9a44 Restore comment/string check for 'electric-layout-mode'
This reverts an accidental change which allowed
'electric-layout-mode' to insert newlines inside strings and
comments.  The new behavior can be obtained by setting the
new variable 'electric-layout-allow-in-comment-or-string' to a
non-nil value.
* lisp/electric.el (electric-layout-allow-in-comment-or-string):
New variable to determine whether inserting newlines is
permitted within comments or strings.
(electric-layout-post-self-insert-function-1): Restore the
previous default behavior of not inserting newlines within
comments or strings.
2024-10-05 13:11:04 +03:00
Stefan Kangas
5a462948e1 Update Arni Magnusson's email address
* .mailmap:
* doc/lispref/ChangeLog.1:
* doc/misc/ChangeLog.1:
* lisp/ChangeLog.16:
* lisp/ChangeLog.17:
* lisp/progmodes/bat-mode.el: Update email address of
Arni Magnusson.  (Bug#73631)
2024-10-05 02:30:41 +02:00
Stefan Kangas
6b1271b169 Fix python-ts-mode-map docstring
* lisp/progmodes/python.el (python-ts-mode-map): Fix docstring.
2024-10-05 01:58:50 +02:00
Stefan Kangas
aaaafddc94 Normalize "Commentary" section in eudc.el
* lisp/net/eudc.el: Normalize "Commentary" section to make
'M-x describe-package RET eudc RET' more useful.
2024-10-05 00:45:54 +02:00
Eli Zaretskii
d656be9794 Expand email abbrevs in X-Debbugs-Cc header.
* lisp/mail/mailabbrev.el (mail-abbrev-mode-regexp):
* lisp/mail/mailalias.el (mail-address-field-regexp)
(mail-complete-alist): Add "X-Debbugs-Cc" to headers where email
aliases should be expanded, for compatibility with emacsbug.el.
2024-10-04 16:32:13 +03:00
Eli Zaretskii
e9dcf0c57d Fix 'list-tags' when invoked from a non-file buffer
This use case was broken by the improvement that attempts to
offer the current buffer's file name as the default file whose
tags to list.
* lisp/progmodes/etags.el
(tags--get-current-buffer-name-in-tags-file): Doc fix.  Return nil
if no file is associated with the current buffer, and avoid
signaling an error if 'buffer-file-name' returns nil.  (Bug#37611)
(list-tags): Doc fix.  Signal an error if the user specifies no
file name at the prompt.

* doc/emacs/maintaining.texi (List Identifiers): Fix wording of
the documentation of 'list-tags'.
2024-10-04 14:39:50 +03:00
Sean Whitton
51ef05f684 count-windows: Fix reference to walk-windows
* lisp/window.el (count-windows): Refer to walk-windows for the
precise meaning of both the MINIBUF and ALL-FRAMES arguments,
not just the ALL-FRAMES argument.  In both functions, these
arguments are both passed through to window-list-1.
2024-10-04 17:28:59 +08:00
Stefan Kangas
5eaf0c784b * lisp/info-look.el (mapc): Add use-package manual's index. 2024-10-03 23:53:10 +02:00
Yuan Fu
bf26ff0dc8
Update csharp-ts-mode font-lock (bug#73369)
Adapt to the latest c-sharp grammar.

* lisp/progmodes/csharp-mode.el:
(csharp-ts-mode--test-this-expression):
(csharp-ts-mode--test-interpolated-string-text):
(csharp-ts-mode--test-type-constraint):
(csharp-ts-mode--test-type-of-expression):
(csharp-ts-mode--test-name-equals):
(csharp-ts-mode--test-if-directive):
(csharp-ts-mode--test-method-declaration-type-field): New
functions.
(csharp-ts-mode--type-field): New variable.
(csharp-ts-mode--font-lock-settings): Fix font-lock rules.
2024-10-02 22:22:28 -07:00
Sean Whitton
d42d7d474f ; * lisp/doc-view.el (doc-view-svg-face): Copy-edit docstring. 2024-10-02 12:07:32 +08:00
Sean Whitton
d68e6d2689 ; rcirc-update-activity-string: Justify some existing behaviour 2024-10-02 09:19:31 +08:00
Sean Whitton
e6a37869c8 Fix inconsistency in value of rcirc-activity-string
* lisp/net/rcirc.el (rcirc-update-activity-string): Consistently
don't display anything if there aren't any IRC connections.
2024-10-02 09:15:46 +08:00
john muhl
63058e1153 Tag interactive commands in 'lua-ts-mode'
* lisp/progmodes/lua-ts-mode.el (lua-ts-send-buffer)
(lua-ts-send-file, lua-ts-send-region): Mark inferior interaction
commands that are only relevant in Lua buffers.  (Bug#73586)
2024-10-01 21:35:24 +02:00
Stefan Kangas
84bea20eba ; * lisp/info-look.el: Add two more links. 2024-10-01 21:24:09 +02:00
Stefan Kangas
96b87ad536 Mention LSP acronym in eglot defgroup docstring
* lisp/progmodes/eglot.el (eglot): Improve defgroup description by
mentioning the LSP acronym, for users that might be searching for that.
2024-10-01 00:24:23 +02:00
Stefan Kangas
9c904e8cea Change :group of 'eglot' defgroup to 'tools'
In 'M-x customize', Eglot fits in better in "Programming -> Tools", with
the likes of Flymake and Gud, than it does in "Applications", with ERC
and Newsticker.

* lisp/progmodes/eglot.el (eglot): Change :group of defgroup to 'tools'.
2024-10-01 00:16:01 +02:00
Stefan Kangas
fd1a1b0780 Remove out-of-date documentation from python.el
* lisp/progmodes/python.el: Remove out-of-date documentation about
automatic indentation; 'electric-indent-mode' is enabled by default in
Emacs 24.4 or later, so this is no longer an issue.
2024-09-30 20:38:01 +02:00
Jim Porter
11e3e0cadd Fix executing commands in Eshell using "env" with no local variables
* lisp/eshell/esh-var.el (eshell/env): Throw 'eshell-replace-command' as
needed.

* test/lisp/eshell/esh-var-tests.el
(esh-var-test/local-variables/env/no-locals): New test (bug#73479).
2024-09-29 18:22:45 -07:00
Eli Zaretskii
36ff7138fe ; Fix a thinko in sieve-manage.el
* lisp/net/sieve-manage.el (sieve-manage--append-to-log): Fix
thinko.  (Bug#54154)
2024-09-29 15:42:21 +03:00
Eli Zaretskii
e2b01d164c ; Fix last changes in php-ts-mode.el
* lisp/progmodes/php-ts-mode.el
(php-ts-mode--test-namespace-name-as-prefix-p)
(php-ts-mode--test-namespace-aliasing-clause-p)
(php-ts-mode--test-namespace-use-group-clause-p): Doc fixes.
(treesit-query-compile): Declare.
2024-09-28 15:06:44 +03:00
Morgan Willcock
e8830015b0 Require ert-x for use by 'ert-font-lock-deftest-file'
This fixes a void-function error when 'ert-font-lock-deftest-file'
is called when ert-x has not already been loaded.
* lisp/emacs-lisp/ert-font-lock.el (ert): Require ert-x so that
'ert-resource-file' is available for use within
'ert-font-lock-deftest-file'.  (Bug#73254)
2024-09-28 14:10:00 +03:00
Vincenzo Pupillo
69d8f9d1b7
Fix php-ts-mode font-lock for latest PHP grammar (bug#73516)
Version 0.23 of the PHP grammar introduced some changes that
affect the font lock.

* lisp/progmodes/php-ts-mode.el
(php-ts-mode--language-source-alist): Update php, html, js and css
grammars version.
(php-ts-mode--parent-html-heuristic): Fix docstring
(php-ts-mode--test-namespace-name-as-prefix-p): New function.
(php-ts-mode--test-namespace-aliasing-clause-p): New function.
(php-ts-mode--test-namespace-use-group-clause-p): New function.
(php-ts-mode--font-lock-settings): Use the new functions.
2024-09-28 01:06:41 -07:00
Harald Jörg
53c887fdf6 ; cperl-mode.el: Fix an invalid face specification
* lisp/progmodes/cperl-mode.el (cperl-method-call): Avoid doubly
quoting the parent face.  This made htmlize-buffer fail.
2024-09-26 15:20:01 +02:00
Eli Zaretskii
f5cd5585f4 ; Recommend GNU Find for 'find-dired'
* lisp/find-dired.el (find-dired): Doc fix (bug#73455).
2024-09-26 10:30:56 +03:00
Stefan Kangas
65e589698e ; * lisp/filesets.el (filesets-homepage): Fix URL. 2024-09-26 02:10:16 +02:00
Michael Albinus
d63bff4d88 Fix Tramp shortdoc integration
* lisp/net/tramp-integration.el (tramp-syntax): Declare.
(shortdoc): Check, that Tramp has `default' syntax.
2024-09-25 19:43:07 +02:00
Juri Linkov
759b18a33c * lisp/imenu.el (imenu-flatten): More limitations in docstring (bug#73117) 2024-09-25 20:14:12 +03:00
Sean Whitton
794bb2a2e3 remember-data-file: Don't unconditionally call set-visited-file-name
* lisp/textmodes/remember.el (remember-data-file): Don't
unconditionally call set-visited-file-name.
2024-09-25 16:02:53 +01:00
Thomas Voss
7766ba8419 Align columns in which-key with wide characters properly
In the case that a character takes up multple 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'
instead of `length'.  (Bug#73463)

Copyright-paperwork-exempt: yes
2024-09-25 14:55:25 +03:00
Roland Winkler
bd25a98b4e bibtex-mode: fix patch bibtex validation for non-file buffers 2024-09-24 23:14:27 -05:00
Robert Pluim
f189457e5a ; * lisp/yank-media.el (yank-media-handler): Fix docstring typo. 2024-09-24 17:02:21 +02:00
Tassilo Horn
2b53e11a08 Use black-on-white by default for doc-view-svg-face.
* lisp/doc-view.el (doc-view-svg-face): Define black on white as
default value instead of using the current theme's values.
* etc/NEWS: Adjust entry for doc-view-svg-face.
2024-09-24 13:20:45 +02:00
Dmitry Gutov
32d0c8f6af etags-regen-file-extensions: Enable for more extensions
* lisp/progmodes/etags-regen.el (etags-regen-file-extensions):
Add more extensions, but remove "a".  From the ones recognized by
etags, also omit "t", "ml", "l", "def" and "inc", see
https://lists.gnu.org/archive/html/emacs-devel/2024-09/msg00735.html.
(etags-regen--all-files): Use 'string-match-p' for performance.
Bind 'case-fold-search' to t to match extensions in any case.
2024-09-23 21:35:19 +03:00
Stephen Berman
c1f2501f55 Update and improve UI of sql-read-product (bug#73412)
* lisp/progmodes/sql.el (sql-read-product): In invocation of
completing-read use format-prompt and make deprecated argument
INITIAL-INPUT nil.
(sql-set-product, sql-product-interactive): In invocation of
sql-read-product adjust prompt to use of format-prompt.
2024-09-21 22:23:11 +02:00
Philip Kaludercic
4f5fc519f0
Insert correct commit data into VC package descriptions
* lisp/emacs-lisp/package-vc.el (package-vc-commit): Rename
argument from PKG to PKG-DESC.
(package-vc--generate-description-file): Update the "extras"
section of the package description with the revision string at
generation time.
2024-09-21 17:44:26 +02:00
Scott Bell
ecfebb5abb ; Always set 'emoji--insert-buffer'
* lisp/international/emoji.el (emoji-list): Always set insert buffer.
(Bug#73390)

Copyright-paperwork-exempt: yes
2024-09-21 14:01:41 +03:00
Stefan Monnier
35e356f958 Fix font-lock of last character before EOB under 'whitespace-mode'
* lisp/whitespace.el (whitespace-color-on): Don't use OVERRIDE in
font-lock-keywords; instead, use 'prepend' in the call to
'font-lock-add-keywords'.  (Bug#73332)
2024-09-21 13:46:54 +03:00