1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2025-12-15 10:30:25 -08:00
Commit graph

179430 commits

Author SHA1 Message Date
Mattias Engdegård
b52ccb997d ; * lisp/emacs-lisp/bytecomp.el (featurep): mistake in last change 2025-09-01 16:50:10 +02:00
Eli Zaretskii
9c21c11277 ; Improve documentation of 'treesit-enabled-modes'
* lisp/treesit.el (treesit-enabled-modes): Doc fix.

* doc/emacs/modes.texi (Choosing Modes): Extend and improve
wording of a recently-added text.
2025-09-01 17:35:38 +03:00
Sean Whitton
838e8e4140 New project-find-matching-buffer-function for diff-mode
* lisp/vc/diff-mode.el (project-root): Declare.
(diff-find-matching-buffer): New function.
(diff-mode): Use it.
* doc/emacs/vc1-xtra.texi (Other Working Trees): Document
'C-x v w w' in diff-mode buffers.
2025-09-01 15:27:57 +01:00
Mattias Engdegård
985657e515 ; * src/data.c (Fash): GCC argument signedness quibble 2025-09-01 15:13:58 +02:00
Mattias Engdegård
bbc9ed3871 * src/data.c (Fash): Speed up when argument and result are fixnums. 2025-09-01 14:20:04 +02:00
Mattias Engdegård
7c6de4fe73 * lisp/emacs-lisp/bytecomp.el (featurep): Safer comp-time evaluation 2025-09-01 12:09:50 +02:00
Sean Whitton
66ef930ebe Rename arg REMOTE-LOCATION -> UPSTREAM-LOCATION
* lisp/vc/vc-bzr.el (vc-bzr-log-incoming)
(vc-bzr-incoming-revision, vc-bzr-log-outgoing):
* lisp/vc/vc-git.el (vc-git-incoming-revision):
* lisp/vc/vc-hg.el (vc-hg-incoming-revision):
* lisp/vc/vc.el (vc-root-diff-incoming, vc-diff-incoming)
(vc-root-diff-outgoing, vc-diff-outgoing)
(vc-root-diff-outgoing-base, vc-diff-outgoing-base)
(vc-incoming-outgoing-internal, vc-remote-location-history)
(vc--incoming-revision, vc-log-incoming, vc-default-log-incoming)
(vc-log-outgoing, vc-default-log-outgoing): Rename arguments
REMOTE-LOCATION -> UPSTREAM-LOCATION.  Adjust strings.
(vc--maybe-read-remote-location): Rename ...
(vc--maybe-read-upstream-location): ... to this.
2025-09-01 09:41:40 +01:00
Sean Whitton
fa256f11ed VC outgoing commands for Git: Don't unconditionally fetch
* lisp/vc/vc-bzr.el (vc-bzr-incoming-revision):
* lisp/vc/vc-hg.el (vc-hg-incoming-revision):
* lisp/vc/vc.el (vc-diff-incoming, vc--incoming-revision): New
REFRESH optional argument.
(vc-default-log-incoming): Pass it.
* lisp/vc/vc-git.el (vc-git-incoming-revision): New REFRESH
optional argument.  When nil, use cached info (bug#62940).
2025-09-01 09:32:40 +01:00
Stefan Monnier
3c94ae5a37 (completion-file-name-table): Refine last fix
* lisp/minibuffer.el (completion-file-name-table): Don't
hardcode Tramp knowledge here.
2025-09-01 00:57:44 -04:00
Juri Linkov
1ba75cc6fc New user option 'tab-line-define-keys'
* lisp/tab-line.el (tab-line-define-keys): New defcustom.
(tab-line--define-keys, tab-line--undefine-keys):
New functions that explicitly bind commands from
'tab-line-mode-map' to 'ctl-x-map'.
(tab-line-mode-map): Leave this keymap empty by default
to avoid breaking 'ctl-x-map' (bug#79323).
(global-tab-line-mode): Call either 'tab-line--define-keys'
or 'tab-line--undefine-keys'.
2025-08-31 21:23:05 +03:00
Juri Linkov
07adb8b59d * doc/emacs/modes.texi (Choosing Modes): Document 'treesit-enabled-modes'. 2025-08-31 20:30:18 +03:00
Sean Whitton
0cd0aaa14f vc-revert: Fix calling vc-buffer-sync (bug#79319)
* lisp/vc/vc.el (vc-revert): Don't call vc-buffer-sync on a
non-file-visiting buffer (bug#79319).  Don't try to use memq to
compare strings.
2025-08-31 16:37:11 +01:00
Sean Whitton
11dc1420e4 * lisp/vc/vc.el (vc-revert): Tighten up save-some-buffers predicate. 2025-08-31 16:32:48 +01:00
Eli Zaretskii
8c663618ce ; * etc/NEWS: Document the change that fixed bug#65897. 2025-08-31 09:54:17 +03:00
Spencer Baugh
98fbaacac2 Allow entering the debugger on error in emacsclient connections
* lisp/server.el (server--process-filter-1): Use
'condition-case-unless-debug'.  (Bug#65897)
2025-08-31 09:44:53 +03:00
Eli Zaretskii
32d3c859f0 Fix EOL decoding in files extracted from ZIP archives
* lisp/arc-mode.el (archive-set-buffer-as-visiting-file): Don't
lose EOL conversion determined by 'decode-coding-region' from the
extracted file's data.  (Bug#79316)
2025-08-30 19:50:22 +03:00
Jeremy Bryant
b73d92c8b1 * lisp/saveplace.el (save-places-to-alist): Add doc string.
Replace previous comment and simplify wording by refering to
the function 'save-place-to-alist' being called on all
buffers.  (Bug#79340)
2025-08-30 19:14:58 +03:00
Sean Whitton
8a284cbbc5 ; Fix `(emacs)Merge Bases'
Intended to be included in previous commit.
2025-08-30 15:54:32 +01:00
Eli Zaretskii
af4a5e2b4a Merge from origin/emacs-30
3d2a818679 * doc/misc/efaq-w32.texi (UTF-8 encoding): New section (b...
ec50d775ac ; * doc/misc/flymake.texi (Finding diagnostics): Fix a ty...
293e258a1b * doc/emacs/screen.texi (Mode Line): Fix reference.
8eb192c23d ; * admin/make-tarball.txt: Update the "Web pages" sectio...
2025-08-30 07:18:37 -04:00
Eli Zaretskii
e1af5d70e2 ; Merge from origin/emacs-30
The following commit was skipped:

eabb5f450c Improve and clarify documentation of 'dired-click-to-sele...
2025-08-30 07:18:36 -04:00
Spencer Baugh
b610f36d44 Document and test 'let-alist' support for indexing
* etc/NEWS: Announce 'let-alist' support for indexing.
* test/lisp/emacs-lisp/let-alist-tests.el (let-alist-numbers):
Add a test for 'let-alist's support for indexing.
* doc/lispref/lists.texi (Association Lists): Document indexing
with 'let-alist'.  (Bug#66509)
2025-08-30 13:59:18 +03:00
Eli Zaretskii
7efaa4657a Merge branch 'master' of git.savannah.gnu.org:/srv/git/emacs 2025-08-30 13:46:34 +03:00
Eli Zaretskii
73aac05cfd Fix "C-u C-h C-n"
* lisp/help.el (view-emacs-news): Widen the buffer before
re-narrowing it again to a different version.  (Bug#79324)
2025-08-30 13:45:07 +03:00
Sean Whitton
29e673a77b New commands for outgoing diffs including uncommitted changes
* lisp/vc/vc.el (vc-root-diff-outgoing-base)
(vc-diff-outgoing-base): New commands (bug#62940).
* lisp/vc/vc-hooks.el (vc-prefix-map): Bind them.
* doc/emacs/vc1-xtra.texi (Outgoing Base Diffs):
* etc/NEWS: Document them.
* doc/emacs/emacs.texi (Outgoing Base Diffs): New node.
2025-08-30 11:44:53 +01:00
Sean Whitton
14d20bff06 Document C-x v M D and C-x v M L in the manual
* doc/emacs/emacs.texi (Merge Bases):
* doc/emacs/vc1-xtra.texi (Merge Bases): New node.
2025-08-30 11:44:53 +01:00
João Távora
53f5a07beb Eglot: fix likely off-by-1 in LabelOffsetSupport feature (bug#79259)
This feature was tweaked and last tested with a 2019 edition of
the 'ccls' LSP.  The spec does not clearly specify this number
to be 0-indexed, but it would make sense that it would be so.
So there's not need to 1+ - correct the numbers at all before
using them in substring.  This would fix the Haskell server use
of this feature (which is bug#79259)

* lisp/progmodes/eglot.el (eglot--sig-info): Fix likely off-by-1.
2025-08-30 11:44:56 +01:00
Eli Zaretskii
467c75893c ; Fix defcustom type
* lisp/files.el (lock-file-name-transforms): Fix the 'defcustom'
type.  (Bug#79322)
2025-08-30 13:22:05 +03:00
Steven Allen
4ab16d701e Eglot: escape literal % characters in URIs
Escape literal % characters in Eglot URIs

Otherwise, a literal % in a file-name will be interpreted (by the
language server) as if it were a part of a percent-encoded sequence.

See Bug#78984 for context on why `url-path-allowed-chars' cannot be
changed to escape literal % characters.

* lisp/progmodes/eglot.el (eglot--uri-path-allowed-chars): Escape %,
remove the redundant variable definition.
* test/lisp/progmodes/eglot-tests.el (eglot-test-path-to-uri-escape):
test it.
2025-08-30 11:19:19 +01:00
Sergio Pastor Pérez
8d301906e1 bug#79241: Fix incorrect handling of overlays in `vertical-motion'
* src/indent.c (vertical-motion): If iterator is inside an overlay,
reset it to the beginning of line before trying to reach goal
column.  This prevents point from being stuck at the beginning
of overlay strings during upward motions.

Copyright-paperwork-exempt: yes
2025-08-30 12:39:35 +03:00
Eli Zaretskii
98cd122776 ; * doc/lispref/edebug.texi (Edebug Views): Fix wording of last change. 2025-08-30 12:35:18 +03:00
Jens Schmidt
fdc6bb2caf Add edebug-bounce-to-previous-value
Command edebug-bounce-to-previous-value uses the previous value
observed while single-stepping or evaluating an expression to
bounce point in the outside current buffer to the buffer
position corresponding to that value.

* lisp/emacs-lisp/edebug.el (edebug-previous-value): Add
variable.
(edebug-compute-previous-result, edebug-eval-expression): Update
it.
(edebug-bounce-to-previous-value): Add command.
(edebug-mode-map): Add keybinding for the new command, replacing
the binding of "P" to edebug-view-outside.
(edebug-mode-menus): Add menu entry for the new command.
* doc/lispref/edebug.texi (Edebug Views): Add documentation.
* test/lisp/emacs-lisp/edebug-resources/edebug-test-code.el
(edebug-test-code-bounce-point): Add test code.
* test/lisp/emacs-lisp/edebug-tests.el
(edebug-tests-bounce-outside-buffer)
(edebug-tests-bounce-outside-point)
(edebug-tests-bounce-outside-mark)
(edebug-tests-bounce-record-outside-environment)
(edebug-tests-should-have-bounced-to): Add infrastructure to
test bounces.
(edebug-tests-check-keymap): Update tests to new key bindings.
(edebug-tests-bounce-point)
(edebug-tests-bounce-to-previous-value)
(edebug-tests-bounce-to-previous-non-position): Add tests.
(edebug-tests-evaluation-of-current-buffer-bug-19611): Clean up
side effects.  (Bug#79288)
2025-08-30 12:30:21 +03:00
Eli Zaretskii
3d2a818679 * doc/misc/efaq-w32.texi (UTF-8 encoding): New section (bug#79296). 2025-08-30 12:23:42 +03:00
john muhl
34f3ac6c5b Fontify all comment delimiters in 'lua-ts-mode'
* lisp/progmodes/lua-ts-mode.el (lua-ts--comment-font-lock):
Apply 'font-lock-comment-delimiter-face' to the entire span of
initial dashes.  In particular, this improves the appearance of
LuaCATS and EmmyLua style annotations which use "---".
* test/lisp/progmodes/lua-ts-mode-resources/font-lock.lua:
Add tests.  (Bug#79258)
2025-08-30 11:31:34 +03:00
Eli Zaretskii
b0efe06551 ; * lisp/ehelp.el (ehelp-command): Fix the autoload form (bug#79289). 2025-08-30 11:24:51 +03:00
Sean Devlin
b85f9d6a97 Fix recursive load when 'calc-always-load-extensions' is set
* lisp/calc/calc.el (calc-create-buffer): Call 'calc-load-everything'.
(calc-always-load-extensions): Delete erroneous stanza.  (Bug#79157)
2025-08-30 10:26:20 +03:00
Sean Devlin
aa60f16e66 Add user option to inhibit Calc startup message (bug#79143)
* doc/misc/calc.texi (Customizing Calc): Document the new option.
* etc/NEWS: Document the new option.
* lisp/calc/calc.el (calc-inhibit-startup-message): New option to
inhibit Calc’s startup message.
(calc): Respect the option in Calc’s startup code.
* test/lisp/calc/calc-tests.el (ert): Require ert-x for
'ert-with-message-capture'.
(calc-inhibit-startup-message): Test the new user option.
2025-08-30 10:22:06 +03:00
Mattias Engdegård
8c71ef0f8e ; use modern sort calls in more places
* lisp/emacs-lisp/regexp-opt.el (regexp-opt, regexp-opt-group):
* lisp/emacs-lisp/rx.el (rx--parse-any): New-style calls, also faster.
2025-08-29 19:24:50 +02:00
Juri Linkov
8d3554683f * lisp/treesit-x.el (treesit-generic-mode-font-lock-map): Extend.
Add more font-lock mappings based on existing settings in ts-modes.
2025-08-29 19:35:58 +03:00
Juri Linkov
35f8ce7835 * lisp/textmodes/markdown-ts-mode.el: Fix embed settings.
(markdown-ts--range-settings): Move embed settings
for html/toml/yaml to 'markdown-ts-setup'.
(markdown-ts-setup): Append range rules to 'treesit-range-settings'
only when grammars for html/toml/yaml are installed.
2025-08-29 19:32:22 +03:00
Juri Linkov
b8ad7c38ae * lisp/progmodes/python.el: Use 'treesit-major-mode-remap-alist'.
(python-ts-mode): Don't duplicate 'auto-mode-alist' and
'interpreter-mode-alist' settings in Emacs 31 (bug#79180).
Add ts-mode mapping to 'treesit-major-mode-remap-alist'.
2025-08-29 19:27:32 +03:00
Michael Albinus
f7188ed77f ; Fix last commit
* lisp/net/tramp.el (tramp-parse-default-user-host): Fix thinko.
(tramp-handle-file-directory-p): Extend simple check.
2025-08-29 17:29:54 +02:00
Michael Albinus
4e44c149a6 Merge branch 'master' of git.sv.gnu.org:/srv/git/emacs 2025-08-29 13:48:10 +02:00
Michael Albinus
95232f556e `Fix read-directory-name' for Tramp files
* lisp/minibuffer.el (completion-file-name-table): Improve bypass
for directory checking.  (Bug#79236)

* lisp/net/tramp.el (tramp-user-regexp): Exclude "[" and "]".
(tramp-completion-make-tramp-file-name): Handle port for IPv6 hosts.
(tramp-completion-handle-file-directory-p)
(tramp-completion-handle-file-exists-p): Simplify.
(tramp-completion-handle-file-name-completion): Ignore PREDICATE.
(tramp-completion-dissect-file-name): Handle ports.
(tramp-parse-default-user-host): Suppress '(nil nil) result.
(tramp-parse-file): Delete duplicates.
(tramp-parse-shosts-group): Accept also IPv6 addresses.
(tramp-handle-file-directory-p): Return t for filenames
"/method:foo:".
(tramp-parse-auth-sources, tramp-parse-netrc):
* lisp/net/tramp-cache.el (tramp-parse-connection-properties):
* lisp/net/tramp-gvfs.el (tramp-gvfs-parse-device-names):
Use `tramp-compat-seq-keep'.

* test/lisp/net/tramp-tests.el (edebug-mode): Declare.
(tramp--test-message): Write also trace value.
(tramp-test26-file-name-completion):
(tramp-test26-interactive-file-name-completion): Extend tests.
2025-08-29 13:47:51 +02:00
Mattias Engdegård
bebba6be3d Fix org-habit bug related to string mutation
* lisp/org/org-habit.el (org-habit-build-graph): Rewrite without using
string mutation (using vectors instead), fixing a bug where
org-habit-completed-glyph and org-habit-today-glyph wouldn't display
properly if in the U+0080..00FF range, discovered by the more restricted
string mutation.

Reported by Daniel Mendler in
 https://lists.gnu.org/archive/html/emacs-orgmode/2025-08/msg00224.html
2025-08-29 10:55:21 +02:00
john muhl
bba28b744c Make 'lua-prefix-key' option a 'key-sequence'
This fixes a failure in 'test-custom-opts' caused by both strings
and integers being used for 'lua-prefix-key'.

* lisp/progmodes/lua-mode.el (lua-prefix-key): Convert option to
'key-sequence' type.
(lua-mode-map, lua-prefix-key-update-bindings, lua-set-prefix-key)
(lua--customize-set-prefix-key): Adjust to the change of type for
'lua-prefix-key'.
(lua-prefix-mode-map): Use 'defvar-keymap'.  (Bug#79335)
2025-08-29 09:47:24 +02:00
Robert Pluim
972e4f4a7f Prefer tls to ssl in nnimap and smtpmail code
* lisp/gnus/nnimap.el (nnimap-open-connection): Use 'tls.
(nnimap-open-connection-1): Check 'tls before 'ssl.
* lisp/mail/smtpmail.el (smtpmail-stream-type): Add 'ssl to
allowed values, state 'tls is preferred.
2025-08-28 17:11:56 +02:00
Arash Esbati
62e0cde967 ; Delete unnecessary backslashes
* doc/misc/reftex.texi (Options - Creating Citations): Delete
unnecessary backslashes.
2025-08-28 11:50:26 +02:00
Spencer Baugh
81267db01d Pass dired default filenames via defaults argument
Rather than using minibuffer-with-setup-hook, just pass the list
of default file names as a regular argument to read-file-name.
This allows read-file-name to run abbreviate-file-name on the
defaults as it normally does, instead of the defaults appearing
in expanded form.

dired-dwim-target-defaults changes slightly to return the
correct default at the start of the list.

* lisp/dired-aux.el (dired-do-create-files)
(dired-compare-directories): Pass default file names as an
argument. (bug#79293)
(dired-dwim-target-defaults): Return the correct default at the
start of the list.
2025-08-28 09:21:18 +03:00
Juri Linkov
b5ec833bc8 * lisp/tab-bar.el (frameset-session-filter-tabs): New function.
Push new function to 'frameset-session-filter-alist'
with 'tabs' key (bug#79291).
2025-08-28 09:09:18 +03:00
Eli Zaretskii
ec50d775ac ; * doc/misc/flymake.texi (Finding diagnostics): Fix a typo (bug#79325). 2025-08-28 08:58:17 +03:00