1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-01-17 16:41:17 -08:00
Commit graph

178432 commits

Author SHA1 Message Date
Eli Zaretskii
0203543fa6 ; Merge from origin/emacs-30
The following commit was skipped:

c526646d70 ; Sync with Tramp 2.7.3.30.2 (Do not merge to master)
2025-05-24 06:46:33 -04:00
Eli Zaretskii
ad217dcc46 Merge from origin/emacs-30
661fa578d5 Adapt Tramp version in customize-package-emacs-version-alist
0045a56d55 ; * ChangeLog.5: Delete entry for minor change.
1136aed6dc ; Update ChangeLog and AUTHORS for Emacs 30.2
2025-05-24 06:46:32 -04:00
Eli Zaretskii
77734d270b ; Merge from origin/emacs-30
The following commits were skipped:

dfcde786ad ; Update ldefs-boot.el.  Do not merge to master.
4c11021260 ; Bump Emacs version to 30.1.90
2025-05-24 06:46:32 -04:00
Roi Martin
9c00f55265 Add baseline pass/fail tests for `ert-test-erts-file'
* test/lisp/emacs-lisp/ert-tests.el (ert-test-erts-pass)
(ert-test-erts-fail): Add tests to verify that the
`ert-test-erts-file' function can detect both passing a failing
test cases.
* test/lisp/emacs-lisp/ert-resources/erts-fail.erts:
* test/lisp/emacs-lisp/ert-resources/erts-pass.erts:
Add test data.  (Bug#78552)
2025-05-24 13:08:21 +03:00
Lin Sun
9f1cec6297 Speed up loading modules
* src/lread.c (get-load-suffixes): Don't try loading modules with
suffixes from 'jka-compr-load-suffixes', since loading of
compressed shared libraries is not supported (so attempt to look
for them is just waste of cycles).  (Bug#78416.)
2025-05-24 12:43:25 +03:00
Eli Zaretskii
da174e4a15 ; Fix documentation of a recent commit
* etc/NEWS:
* doc/lispref/loading.texi (How Programs Do Loading): Document the
new variable and function.

* src/lread.c (load-path-filter-function):
* lisp/startup.el (load-path-filter-cache-directory-files)
(load-path-filter--cache): Doc fixes.
2025-05-24 10:23:11 +03:00
Spencer Baugh
e5218df144 Add load-path-filter-function and use it to optimize loading
When there are many directories on load-path, the part of load which
searches load-path can become very slow.  By filtering load-path up
front to only contain directories which are likely to contain the
searched-for file, load becomes much faster.

This can be set in early-init.el for maximum effect.

* lisp/startup.el (load-path-filter--cache)
(load-path-filter-cache-directory-files): Add.
* src/lread.c (Fload): Call load-path-filter-function.
(syms_of_lread): Add load-path-filter-function.
2025-05-23 21:41:14 -04:00
Michael Albinus
c879576729 * test/infra/Dockerfile.emba (emacs-tree-sitter): Cosmetic change. 2025-05-23 13:40:11 +02:00
Vincent Belaïche
9f80363f8c Minor fix.
* lisp/ses.el (ses--align): fix /Unused lexical variable 'half'/ warning.
2025-05-23 09:59:02 +02:00
Vincent Belaïche
ce08defd0a More SES printer functions.
* lisp/ses.el (ses-standard-printer-functions): add 'ses-left' &
'ses-left-span' to the list.
(ses--align): New helper function, takes most of the code
previously in 'ses-center'
(ses-center): Use 'ses--align'.
(ses--span):  New helper function, takes most of the code
previously in 'ses-center-span.
(ses-center-span): Use 'ses--span'.'
(ses-left): New function.
(ses-left-span): New function.
2025-05-23 09:41:17 +02:00
Eli Zaretskii
c9690f10fd ; * lisp/help-fns.el (help-fns-edit-variable): Fix typo (bug#78554). 2025-05-23 09:59:15 +03:00
Stefan Monnier
772c4f036c (perform-replace): Make it work with F-keys in TTYs (bug#78113)
* lisp/replace.el (perform-replace): Use `read-key`.
* test/lisp/replace-tests.el (replace-tests-with-undo): Adjust accordingly.
2025-05-22 09:33:14 -04:00
Mattias Engdegård
6e98316f04 Check diagnostic types in compile-tests
* test/lisp/progmodes/compile-tests.el
(compile-tests--test-regexps-data, compile--test-error-line)
(compile-test-functions): Check the types (error, warning or info) for
most patterns.  Use names instead of numbers in the reference.
2025-05-22 15:03:51 +02:00
Vincenzo Pupillo
676f12c65f Support Rust compiler messages in compile mode (bug#70794).
* etc/compilation.txt: Add examples of Rust compiler error, warning and
note messages.
* lisp/progmodes/compile.el
(compilation-error-regexp-alist-alist): Add Rust regexps for error,
warning and note messages.
* test/lisp/progmodes/compile-tests.el
(compile-tests--test-regexps-data): Add new test cases.
(compile-test-error-regexps): Increase expected errors.
2025-05-22 11:53:34 +02:00
Yuan Fu
0b2ba13c97
Eglot: always call ElDoc callbacks in correct buffer (bug#78530)
Some minor modes adds their own eldoc display function to
'eldoc-display-functions' hook buffer-locally.  So when eldoc
uses 'eldoc-display-functions' to display docs, it should use
the buffer-local value of the hook.

But that's not always the case. In 'eldoc--invoke-strategy', the
code that runs 'eldoc-display-functions' hook is wrapped in a
callback function that eventually gets passed to each
documentation function in 'eldoc-documentation-functions'. So
now it's the documentation functions' responsibility to call the
eldoc callback in the original buffer.

All the eglot documentation functions indeed do that, using
'eglot--when-buffer-window' to switch to the original buffer
when calling the eldoc callback. But
'eglot-code-action-suggestion' is the exception, the callback is
called outside of the 'eglot--when-buffer-window' form.

This patch fixes that.

This bug was originally reported on eldoc-box [1]. The user
found that eldoc-box's display function are rarely called, even
though the minor mode is turned on. This patch fixes the issue.

[1] https://github.com/casouri/eldoc-box/issues/126#issuecomment-2896611278

* lisp/progmodes/eglot.el (eglot-code-action-suggestion): Move
the funcall form into the eglot--when-buffer-window form.
2025-05-21 22:42:35 -07:00
Lin Sun
cb1b65f392 * lisp/emacs-lisp/find-func.el: Fix Eager macro-expansion failure
Bug#78446
2025-05-21 13:18:06 -04:00
Paul Eggert
9dfc605654 Work around GCC bug 117423
Problem reported by Oliver Reiter and Pip Cet (Emacs bug#78473).
It looks like GCC tree-sra is trouble in general with how Emacs
uses unions, so disable tree-sra until the GCC bug is fixed.
* configure.ac (C_SWITCH_MACHINE): Also work around GCC bug 117423.
2025-05-21 10:10:57 -07:00
Robert Pluim
8605221ef6 ; * lisp/disp-table.el (standard-display-unicode-special-glyphs): Fix typo. 2025-05-21 11:11:10 +02:00
Juri Linkov
822b6cca1e * lisp/treesit.el: New variables for 'down-list' and 'up-list'.
(treesit-sexp-type-down-list, treesit-sexp-type-up-list):
New buffer-local variables.
(treesit-down-list): Use 'treesit-sexp-type-down-list'.
(treesit-up-list): Use 'treesit-sexp-type-up-list'.

* lisp/progmodes/elixir-ts-mode.el (elixir-ts-mode):
Set 'treesit-sexp-type-down-list' and
'treesit-sexp-type-up-list' to 'list'.
2025-05-21 09:31:45 +03:00
Juri Linkov
87fa5f565d * lisp/tab-line.el (tab-line-move-tab-forward): New command.
(tab-line-move-tab-backward): New command.
(tab-line-mode-map): Bind 'C-x M-<left>' to
'tab-line-move-tab-backward' and 'C-x M-<right>' to
'tab-line-move-tab-forward'.
(tab-line-switch-repeat-map): Bind 'M-<left>' to
'tab-line-move-tab-backward' and 'M-<right>' to
'tab-line-move-tab-forward'.
Suggested by pinmacs <pinmacs@cas.cat>.
2025-05-20 21:30:38 +03:00
Elijah Gabe Pérez
d8bf84f7f4 lisp/progmodes/hideshow.el (hs--get-ellipsis): Simplify
Mostly using `truncate-string-ellipsis`.
2025-05-19 18:33:39 -04:00
Spencer Baugh
cd364a2119 Fix 'completion-ignore-case' with 'completion--file-name-table'
509cbe1c35 "Improve env var handling in read-file-name"
caused 'try-completion' and 'all-completion' operations with
'completion--file-name-table' to no longer update the case of
text which was already present in the input string.  That is,
completions would be returned ignoring case, but the completions
would have letter-casing which matched the input string rather
than matching the actual file names.
This was caused by unnecessarily replacing text in the returned
file name completions with text from the input string ORIG,
which in turn was caused by the desire to preserve text from
ORIG even after 'substitute-in-file-name' changed it.  Fix this
by detecting when ORIG was not substantially changed by
'substitute-in-file-name'; in that case, the returned file name
completions also don't need substantial changes.
* lisp/minibuffer.el (completion--file-name-table): Use text
from the completions, not the input string.  (Bug#78323)
* test/lisp/minibuffer-tests.el (completion-table-test-quoting):
Test with 'completion-ignore-case' as well.
2025-05-19 20:02:45 +03:00
Martin Rudalics
0de59ded25 Fix thinko in 'fit-frame-to-buffer-1' (Bug#78418)
* lisp/window.el (fit-frame-to-buffer-1): Don't add extra line
when character sizes evenly divide decorations sizes
(Bug#78418).
2025-05-19 09:14:15 +02:00
Michael Albinus
baa33c3806 ; Fix last change 2025-05-19 08:45:37 +02:00
Stefan Monnier
860a6c86c5 eww.el: Misc changes
* lisp/net/eww.el (eww--parse-html-region): Don't decode when it's a no-op.
(eww-display-raw): Simplify.
(eww-mode): Prefer #' to quote function names.
(eww-switch-to-buffer): Use `completion-table-with-metadata` instead of
`completion-extra-properties`.  Don't prompt the user when there's only
one choice.
(eww-buffer-list): Use `eww--buffer-p`.
2025-05-18 15:48:54 -04:00
Stefan Monnier
168b67b1ee eww.el: Use track-changes
* lisp/net/eww.el: Require `track-changes`.
(eww-display-document): Don't `inhibit-modification-hooks` any more.
Use `track-changes-register` *at the end* instead.
(eww-mode): Don't use `after-change-functions` any more.
(eww--track-changes): New function.
(eww--process-text-input): Rename from `eww-process-text-input`.
Try and be more careful: don't presume `point` is near
the modification.  Check for a form both at BEG and at END.
Don't rely on `:start/:end` pointing to the right places.
Use `:length` instead and shrink the field back to its original length
when possible.
(eww-size-text-inputs): Set `:length` rather than `:start/:end`.
2025-05-18 15:44:35 -04:00
Stefan Monnier
48c66f26c1 lisp/net/eww.el: Remove redundant :group arguments 2025-05-18 15:31:10 -04:00
Michael Albinus
c526646d70 ; Sync with Tramp 2.7.3.30.2 (Do not merge to master)
* doc/misc/trampver.texi:
* lisp/net/trampver.el (tramp-version): Adapt Tramp versions.
2025-05-18 21:20:41 +02:00
Michael Albinus
661fa578d5 Adapt Tramp version in customize-package-emacs-version-alist
* lisp/net/trampver.el (customize-package-emacs-version-alist):
Add Tramp version integrated in Emacs 30.1.
2025-05-18 21:12:41 +02:00
Sean Whitton
0045a56d55 ; * ChangeLog.5: Delete entry for minor change. 2025-05-18 20:00:07 +01:00
Michael Albinus
c8294f3a0f Generate tree-sitter compatibility report on emba
* test/infra/Dockerfile.emba (emacs-tree-sitter): Generate
compatibility report.

* test/infra/gitlab-ci.yml (.job-template): Modify artifacts preparation.
(build-tree-sitter): Add artifact.
2025-05-18 20:39:59 +02:00
Sean Whitton
a4424fb8cd Factor out vc-git--with-apply-temp-to-staging
* lisp/vc/vc-git.el (vc-git--with-apply-temp-to-staging): New macro.
(vc-git-checkin): Use it.
2025-05-18 12:35:13 +01:00
Eli Zaretskii
1136aed6dc ; Update ChangeLog and AUTHORS for Emacs 30.2
* etc/AUTHORS:
^ ChangeLog.5: Update.
2025-05-18 05:25:35 -04:00
Eli Zaretskii
dfcde786ad ; Update ldefs-boot.el. Do not merge to master. 2025-05-18 05:24:11 -04:00
Eli Zaretskii
4c11021260 ; Bump Emacs version to 30.1.90
* README:
* configure.ac:
* exec/configure.ac:
* java/AndroidManifest.xml.in (Version-code):
* nt/README.W32:
* msdos/sed2v2.inp: Bump Emacs version to 30.1.90.
2025-05-18 05:08:31 -04:00
Stephen Berman
913b4e1c97 Amend Electric Pair mode documentation
* doc/emacs/programs.texi (Matching): Restore to the documentation
of Electric Pair mode the description of the use of a prefix
argument, which was overwritten by merging changes from the
emacs-30 branch, and clarify the usage.
2025-05-18 09:39:02 +02:00
Eli Zaretskii
38789e9a28 Improve reporting of language-grammar library ABI version mismatch
* lisp/treesit.el (treesit-ready-p): More accurate wording of
message when grammar library fails to load.

* src/treesit.c (treesit_load_language): Improve message when
reporting library ABI version mismatch.  Suggested by Soham
Gumaste <sohamg2@gmail.com>.
2025-05-18 09:05:07 +03:00
Stefan Monnier
28a8bd6061 editorconfig.el: Fix bug#78097
When there is no `.editorconfig` variable, the
`file-name-directory` call can signal an error, but that can
happen only if `editorconfig-get-local-variables-functions`
added entries "out of thin air".  So just skip running that hook
to avoid this corner case.

* lisp/editorconfig.el (editorconfig--get-dir-local-variables):
Don't run `editorconfig-get-local-variables-functions` when we found no
EditorConfig settings.
2025-05-17 21:54:54 -04:00
Po Lu
b9b52f0092 Prevent double frees in closing fonts provided by the Haiku font driver
* src/haikufont.c (haikufont_close): Clear INFO->metrics,
glyphs, be_font after they are released and do not attempt to
access them if NULL.  (bug#77478)
2025-05-18 08:46:36 +08:00
Stefan Monnier
f77f464637 (eww-switch-to-buffer): Don't let-bind completion-extra-properties
* lisp/net/eww.el (eww--buffer-p): New function.
(eww-switch-to-buffer): Use it.  And set `completion-extra-properties`
buffer-locally rather than let-binding it.
2025-05-17 12:34:33 -04:00
Eli Zaretskii
e05f76667d Support 'dired-hide-details-mode' in find-lisp.el
* lisp/find-lisp.el (find-lisp-find-dired-insert-file): Call
'dired-insert-set-properties' to support 'dired-hide-details-mode'
in the resulting Dired display.  (Bug#78455)
2025-05-17 16:46:07 +03:00
Mattias Engdegård
2606e3dd99 * doc/lispref/searching.texi (Rx Notation): Fix example (bug#76731)
The example purporting to match C comments was wrong.
Reported by Yue Yi, whose proposed remedy is used here.
2025-05-17 14:20:51 +02:00
Mattias Engdegård
e888bd990d * src/lread.c (read0): Don't allow radix 0 or 1.
This was just a silly mistake introduced in Emacs 29.  Found by Pip Cet.
2025-05-17 14:20:51 +02:00
Eli Zaretskii
6571a2d70b ; Fix a recent change in hideshow.el
* lisp/progmodes/hideshow.el (hs--get-ellipsis): Don't assume
'standard-display-table' is defined.
2025-05-17 15:14:47 +03:00
Eli Zaretskii
bd57055a58 Merge from origin/emacs-30
299d3a4401 Fix saving abbrevs by 'abbrev-edit-save-buffer'
399d05332e ; Remove confusing text from ELisp manual
feecb1fbc6 ; * doc/emacs/cmdargs.texi (General Variables): More accu...
18e1aabbea ; Improve documentation of the -L command-line option
c80fbe3f23 typescript-ts-mode: align ternary-chain branches (bug#78187)
16bfbc6fe3 ; Tramp test fixes
f0ac271da3 ; Time Stamps doc: Clearer customize recipe
49c06df224 ; * doc/lispref/variables.texi (Default Value): Update.
cbea5997c0 ; * lisp/mh-e/mh-e.el: Commentary: link to The MH-E Manual
0bf956235e Improve Tramp test
eaf01d034c * lisp/autorevert.el (auto-revert-remote-files): Adapt do...
e32bb816ad ; Improve documentation of ls-lisp.el
2d5f243470 ; * lisp/emacs-lisp/comp.el (native-compile-prune-cache):...
bb73533165 Improve Electric Pair mode documentation (bug#78021)
2025-05-17 06:52:01 -04:00
Eli Zaretskii
299d3a4401 Fix saving abbrevs by 'abbrev-edit-save-buffer'
* lisp/abbrev.el (abbrev-edit-save-buffer): Reset
'abbrevs-changed'.  Suggested by Rick <rbielaws@gmail.com>.
(Bug#78435)
2025-05-17 13:00:13 +03:00
Eli Zaretskii
399d05332e ; Remove confusing text from ELisp manual
* doc/lispref/variables.texi (Defining Variables): Remove outdated
confusing warning.  For the details, see
https://lists.gnu.org/archive/html/emacs-devel/2025-05/msg00332.html.
2025-05-17 12:35:29 +03:00
Eli Zaretskii
214c0ba3c7 ; * lisp/progmodes/hideshow.el (hs--get-ellipsis): Doc fix (bug#78234). 2025-05-17 12:11:37 +03:00
Elías Gabriel Pérez
8b6e1d8435 Prettify and improve hideshow (bug#78234)
Buttonize the ellipsis and optionally display in the ellipsis
the total number of hidden lines.
* lisp/progmodes/hideshow.el (hs-display-lines-hidden): New
user option.
(hs-ellipsis): New face.
(hs-make-overlay): Tweak.
(hs--get-ellipsis): New function.
* doc/emacs/programs.texi (Hideshow): Update documentation.
* etc/NEWS: Announce changes.
2025-05-17 12:10:03 +03:00
Manuel Giraud
719b2fd580 Fix eww-switch-to-buffer' when resorting to eww'
* lisp/net/eww.el (eww-switch-to-buffer): Do not bind
`completion-extra-properties' before calling `eww'.
(bug#78372)
2025-05-17 12:05:30 +03:00