]> git.eshelyaron.com Git - emacs.git/log
emacs.git
20 months agoMerge from origin/emacs-29
Eli Zaretskii [Thu, 6 Apr 2023 18:38:13 +0000 (14:38 -0400)]
Merge from origin/emacs-29

b39c3cd1125 ; * etc/NEWS: Fix typos.
89ac5ba11c7 Fix ModelSim error regexp in vhdl-mode
24ed9c7ae78 ; * doc/emacs/trouble.texi (Checklist): Minor copyedits (...
d1d39a0f09c Document enhancements in handling of echo-area messages

# Conflicts:
# etc/NEWS

20 months ago; Merge from origin/emacs-29
Eli Zaretskii [Thu, 6 Apr 2023 18:38:04 +0000 (14:38 -0400)]
; Merge from origin/emacs-29

The following commits were skipped:

46209b2453b ; Fix last change
21a4ee209c1 Fix new Eshell tests on MS-Windows
e2ebf3995d0 ; Auto-commit of loaddefs files.
6419d78fa6f Fix using background commands in 'eshell-command'

20 months agoDescribe how to run Emba tests locally
Michael Albinus [Thu, 6 Apr 2023 14:31:49 +0000 (16:31 +0200)]
Describe how to run Emba tests locally

* admin/notes/emba: Describe how to run Emba tests locally.

* test/infra/Dockerfile.emba (emacs-eglot):  Adapt software selection.

20 months agoRestore positions reliably for abbreviated file names in saveplace.el
Liu Hui [Tue, 4 Apr 2023 01:13:32 +0000 (09:13 +0800)]
Restore positions reliably for abbreviated file names in saveplace.el

* lisp/saveplace.el (save-place-abbreviate-file-names): Add setter
function for rewriting `save-place-alist'.  Update docstring.
(save-place-to-alist): Save Abbreviated dired-filename.
(save-place-load-alist-from-file): Move this function above
`save-place-abbreviate-file-names' since it is used in the :set
function.
(save-place-find-file-hook):
(save-place-dired-hook): Use abbreviated file name when
`save-place-abbreviate-file-names' is non-nil.
(Bug#62413)

20 months agoHandle electric heredocs pairs in elixir-ts-mode
Wilhelm H Kirschbaum [Sun, 2 Apr 2023 07:43:20 +0000 (09:43 +0200)]
Handle electric heredocs pairs in elixir-ts-mode

* lisp/progmodes/elixir-ts-mode.el
(elixir-ts--electric-pair-string-delimiter): New helper.
(elixir-ts-mode): Add post-self-insert-hook.  (Bug#62536)

20 months agoPropertize heredocs in elixir-ts-mode
Wilhelm H Kirschbaum [Tue, 21 Mar 2023 14:34:48 +0000 (16:34 +0200)]
Propertize heredocs in elixir-ts-mode

* lisp/progmodes/elixir-ts-mode.el
(elixir-ts--syntax-propertize-query): New variable.
(elixir-ts--syntax-propertize): New helper.
(elixir-ts-mode): Set syntax-propertize-function.  (Bug#62536)

20 months agoCC Mode: Miscellaneous coding fixes in c-forward-type
Alan Mackenzie [Thu, 6 Apr 2023 09:14:56 +0000 (09:14 +0000)]
CC Mode: Miscellaneous coding fixes in c-forward-type

This fixes bug #62339.

* lisp/progmodes/cc-engine.el (c-forward-type): In the implicit int handling,
respect the setting of the parameter stop-at-end.  In the case "normal
identifier", insert a missing (c-forward-syntactic-ws); this fixes the bug.
Here, correct the wrong return value `prefix' to t.

20 months ago; Fix compiler warning
Po Lu [Thu, 6 Apr 2023 02:06:28 +0000 (10:06 +0800)]
; Fix compiler warning

* src/xterm.c (x_term_init): Fix:

"xterm.c", line 30759: warning: improper pointer/integer
combination: op "="

20 months agoComp: Fix limplification pass (bug#62537)
Andrea Corallo [Wed, 5 Apr 2023 16:17:58 +0000 (18:17 +0200)]
Comp: Fix limplification pass (bug#62537)

* test/src/comp-resources/comp-test-funcs.el (comp-test-62537-1-f)
(comp-test-62537-2-f): New functions.

* lisp/emacs-lisp/comp.el (comp-jump-table-optimizable): Make it
stricter add a comment.

20 months agoCC Mode: Fix fontification problems shown by test file templates-20.cc
Alan Mackenzie [Wed, 5 Apr 2023 13:02:12 +0000 (13:02 +0000)]
CC Mode: Fix fontification problems shown by test file templates-20.cc

Also fix one problem evident in test file decls-10.cc.

* lisp/progmodes/cc-engine.el (c-brace-stack-at): Bind
c-record-type-identifiers to nil to prevent called functions recording
identifiers spuriously.
(c-forward-<>-arglist-recur): Revert the ill-advised optimization from autumn
2022 which attempted to avoid re-marking c-type text properties inside angle
bracket arglists.
(c-forward-decl-or-cast-1): Accept the semicolon at the end of "t8 * id;" as
sufficient evidence to fontify as a declaration (not a multiplication).

* lisp/progmodes/cc-fonts.el (c-font-lock-c++-using): No longer fontify the
last component of foo::bar with c-reference-face-name.

20 months agoImprove sigil fontification for elixir-ts-mode
Wilhelm H Kirschbaum [Sun, 2 Apr 2023 09:28:27 +0000 (11:28 +0200)]
Improve sigil fontification for elixir-ts-mode

* lisp/progmodes/elixir-ts-mode.el:
(elixir-ts--font-lock-settings): Update sigil queries.

20 months agoImprove list indentation for elixir-ts-mode
Wilhelm H Kirschbaum [Sun, 2 Apr 2023 09:26:02 +0000 (11:26 +0200)]
Improve list indentation for elixir-ts-mode

* lisp/progmodes/elixir-ts-mode.el:
(elixir-ts--argument-indent-offset): Add empty line check.
(elixir-ts--argument-indent-anchor): Change ERROR offset.
* test/lisp/progmodes/elixir-ts-mode-resources/indent.erts:
Add test.

20 months agoruby-ts-mode: Add more constructs to treesit-sexp-type-regexp
Dmitry Gutov [Wed, 5 Apr 2023 00:00:57 +0000 (03:00 +0300)]
ruby-ts-mode: Add more constructs to treesit-sexp-type-regexp

* lisp/progmodes/ruby-ts-mode.el (ruby-ts-mode): Add more
constructs to treesit-sexp-type-regexp (bug#62086).

20 months agoImprove Tramp robustness
Michael Albinus [Tue, 4 Apr 2023 11:37:18 +0000 (13:37 +0200)]
Improve Tramp robustness

* lisp/net/tramp-sh.el (tramp-open-connection-setup-interactive-shell):
Check for `tramp-string-empty-or-nil-p'.

20 months agoDisplay unlock-file warning only when file locks are enabled
Michael Albinus [Tue, 4 Apr 2023 07:43:09 +0000 (09:43 +0200)]
Display unlock-file warning only when file locks are enabled

* lisp/files.el (remote-file-name-inhibit-locks): Fix docstring.

* lisp/userlock.el (userlock--handle-unlock-error):
Display warning only when `create-lockfiles' is non-nil.  (Bug#62614)

* lisp/net/tramp.el (tramp-handle-unlock-file): Raise a warning
only when `create-lockfiles' is non-nil or
`remote-file-name-inhibit-locks' is nil.

20 months agoruby-ts-mode: Recognize more nodes as sexps
Juri Linkov [Tue, 4 Apr 2023 06:42:10 +0000 (09:42 +0300)]
ruby-ts-mode: Recognize more nodes as sexps

* lisp/progmodes/ruby-ts-mode.el (ruby-ts-mode):
Add "unless" to 'treesit-sexp-type-regexp'.

20 months agoruby-ts-mode: Recognize more nodes as sexps
Dmitry Gutov [Mon, 3 Apr 2023 20:39:41 +0000 (23:39 +0300)]
ruby-ts-mode: Recognize more nodes as sexps

* lisp/progmodes/ruby-ts-mode.el (ruby-ts-mode): Argument
treesit-sexp-type-regexp with interpolation, instance_variable,
global_variable (bug#62086, bug#62416).

20 months ago; Fix last change
Michael Albinus [Mon, 3 Apr 2023 14:00:11 +0000 (16:00 +0200)]
; Fix last change

20 months ago; * lisp/gnus/gnus-sum.el (gnus-summary-move-article): Just setq
Andrew G Cohen [Mon, 3 Apr 2023 13:49:55 +0000 (21:49 +0800)]
; * lisp/gnus/gnus-sum.el (gnus-summary-move-article): Just setq

20 months agoFix some `unwind-protect' forms
Michael Albinus [Mon, 3 Apr 2023 11:18:55 +0000 (13:18 +0200)]
Fix some `unwind-protect' forms

* lisp/net/tramp-smb.el (tramp-smb-handle-file-acl)
(tramp-smb-handle-set-file-acl): Remove superfluous `unwind-protect'.

* test/lisp/auth-source-tests.el
(auth-source-test-secrets-create-secret): Fix `unwind-protect' handler.

* test/lisp/net/tramp-tests.el (tramp-test38-find-backup-file-name):
Add dummy cleanup form.

20 months agoImprove portability of newly added icons
Po Lu [Mon, 3 Apr 2023 08:15:54 +0000 (16:15 +0800)]
Improve portability of newly added icons

* etc/images/symbols/README: Document what to do with changed icons.
* etc/images/symbols: Add portable variants of SVG icons.

20 months agoModify chevron icons and add some more
Yuan Fu [Sat, 1 Apr 2023 23:22:50 +0000 (16:22 -0700)]
Modify chevron icons and add some more

* etc/images/symbols/chevron_left_16.svg:
* etc/images/symbols/chevron_right_16.svg: Make them shorter so that
they appear roughly the same size as up and down chevrons.
* etc/images/symbols/cross_circle_fill_16.svg:
* etc/images/symbols/heart_16.svg:
* etc/images/symbols/heart_fill_16.svg:
* etc/images/symbols/heart_half_16.svg:
* etc/images/symbols/minus_circle_fill_16.svg:
* etc/images/symbols/plus_circle_fill_16.svg: New icons.

20 months agoEglot: Bump to 1.14
João Távora [Mon, 3 Apr 2023 00:40:30 +0000 (01:40 +0100)]
Eglot: Bump to 1.14

* lisp/progmodes/eglot.el (Version): Bump to 1.14
(Package-Requires): Require ElDoc 1.14.0

* etc/EGLOT-NEWS: Update.

20 months agoMerge from origin/emacs-29
João Távora [Sun, 2 Apr 2023 23:33:03 +0000 (00:33 +0100)]
Merge from origin/emacs-29

3bdbb66efb9 ; CONTRIBUTE: Minor stylistic changes.
d0eb12e8d3c Fix typo in section 14.1 of Emacs Manual
b2fbec37f39 ; * etc/EGLOT-NEWS: Clarify scope of topmost section
131ec049db0 Eglot: unbreak eglot-extend-to-xref on w32
0622e1f29f6 Eglot: ensure server shutdown turns off eglot-inlay-hints...
59f66ea3027 ; * lisp/emacs-lisp/package-vc.el: Remove completed item ...
d23dc3dd7e3 ; * lisp/emacs-lisp/package-vc.el (package-vc): Fix manua...
4508a024e81 ; Clarify documentation of 'cursor' text property
d2e82817a3f Add two typescript-ts-mode faces (bug#62429)
10918fc9d24 Fix scrolling window when point moves up
9b32bc134c4 Improve documentation of 'defcustom's :set keyword
ab4273056e0 Comp fix calls to redefined primtives with op-bytecode (b...
c98929c7e18 ; Fix last change
a14c3f62a67 ; Fix last change
09fece5722f Fix duplicate defcustom in eww.el
e45bd10a3d9 Fix indentation regression in 'C-h l'
46fd10a7600 * doc/misc/tramp.texi (Remote shell setup): Clarify use o...

20 months ago; * etc/EGLOT-NEWS (Upcoming 1.14): Update.
João Távora [Sun, 2 Apr 2023 23:00:18 +0000 (00:00 +0100)]
; * etc/EGLOT-NEWS (Upcoming 1.14): Update.

20 months agoEldoc: bump package version to 1.14.0
João Távora [Sun, 2 Apr 2023 22:40:31 +0000 (23:40 +0100)]
Eldoc: bump package version to 1.14.0

* lisp/emacs-lisp/eldoc.el (Version): Bump to 1.14.0

20 months ago; Eldoc: fix doc of e-d-functions w.r.t. :origin keyword
João Távora [Sun, 2 Apr 2023 22:38:37 +0000 (23:38 +0100)]
; Eldoc: fix doc of e-d-functions w.r.t. :origin keyword

* lisp/emacs-lisp/eldoc.el (eldoc-documentation-functions): Fix.

20 months ago; Eglot: removed unused dependency on 'array.el'
João Távora [Sun, 2 Apr 2023 22:33:23 +0000 (23:33 +0100)]
; Eglot: removed unused dependency on 'array.el'

* lisp/progmodes/eglot.el (array): Don't require

20 months agoEglot: load built-in GNU ELPA dependencies explicitly
João Távora [Sun, 2 Apr 2023 22:31:10 +0000 (23:31 +0100)]
Eglot: load built-in GNU ELPA dependencies explicitly

Because of outstanding bug#62576, it's way to easy for users to get
confused by the M-x package-install process for Eglot.

Whenever an Eglot release depends on a new version of a GNU ELPA :core
package which is _also_ provided built-in, M-x package-install will
install that dependency, but will not always load it on top of the
built-in one.

The solution is to not use "require" for now.  This may potentially
lead to double "loads", but that should in principle be idempotent.

* lisp/progmodes/eglot.el (project, eldoc, seq, flymake, xref, jsonrpc)
(external-completion): Load, don't require.

20 months agoEglot: improve caching in eglot-completion-at-point
João Távora [Wed, 29 Mar 2023 18:30:04 +0000 (19:30 +0100)]
Eglot: improve caching in eglot-completion-at-point

When answering the :textDocument/completion request, LSP servers
provide a :isIncomplete flag in the response, which allows Eglot to
know if "further typing should result in recomputing [the completions]
list.

If :isIncomplete is false (i.e. the full set was returned), Eglot
caches the response in a global variable eglot--capf-cache that
persists for the duration of the "completion session", taken to be the
interval between two calls to completion-in-region-mode.

If the cache has been set, and Eglot detects that "further typing" has
happened, it is safe to use the cache instead of making a request to
the server.

Thus eglot--capf-cache-flush, added to completion-in-region-mode-hook,
is used to flush this cache.  Since the popular Company completion
package doesn't use completion-in-region-mode, eglot--capf-cache-flush
is also added to its company-after-completion-hook.

* lisp/progmodes/eglot.el (eglot--managed-mode): Set
'completion-in-region-mode-hook and company-after-completion-hook.
(eglot--capf-cache): New variable.
(eglot--capf-cache-flush): New function.
(eglot-completion-at-point): Rework.

* etc/EGLOT-NEWS: Update.

20 months agoEglot: take advantage of new Eldoc options for signature doc
João Távora [Sat, 25 Mar 2023 19:53:14 +0000 (19:53 +0000)]
Eglot: take advantage of new Eldoc options for signature doc

Only echo the "active signature", send all the other signatures for
the *eldoc* buffer.

* lisp/progmodes/eglot.el (eglot--sig-info): Rework protocol.
(eglot-signature-eldoc-function): Rework.

20 months agoEglot: declare support for markdown also for signatures
João Távora [Fri, 24 Mar 2023 22:17:44 +0000 (22:17 +0000)]
Eglot: declare support for markdown also for signatures

* lisp/progmodes/eglot.el
(eglot--accepted-formats): new helper.
(eglot-client-capabilities): use it.

20 months agoEglot: define eglot--ensure-list with defalias
João Távora [Fri, 24 Mar 2023 22:16:49 +0000 (22:16 +0000)]
Eglot: define eglot--ensure-list with defalias

This avoids annoying obsoletion warnings when compiling the whole buffer.

* lisp/progmodes/eglot.el (eglot--ensure-list): define with defalias.

20 months agoEglot: remove hacky advice of jsonrpc-request
João Távora [Wed, 29 Mar 2023 21:48:54 +0000 (22:48 +0100)]
Eglot: remove hacky advice of jsonrpc-request

The vast majority of Eglot sync requests to the server need to inform
the server of any pending changes to the buffer beforehand, so that
the server has up-to-date information to do its job.

But doing so at the expense of ugly advice of jsonrpc-request is ill
advised.  Introduce eglot--request helper instead and use that.

Use this opportunity to conduct a review of Eglot sync requests and
come to the conclusion that all need to send any changes beforehand.
Nevertheless, an IMMEDIATE kwarg to eglot--request was added to
bypassing this.

* lisp/progmodes/eglot.el
(eglot--request): New helper.
(eglot-shutdown)
(eglot-execute-command)
(eglot-workspace-configuration)
(eglot--signal-textDocument/willSave)
(eglot--workspace-symbols)
(eglot--lsp-xrefs-for-method)
(xref-backend-apropos)
(eglot-format)
(eglot-completion-at-point)
(eglot-imenu)
(eglot-rename)
(eglot-code-actions): Use eglot--request.

20 months agoUse the 'interactive' spec to set arguments for 'eshell-command'
Jim Porter [Fri, 31 Mar 2023 02:38:30 +0000 (19:38 -0700)]
Use the 'interactive' spec to set arguments for 'eshell-command'

* lisp/eshell/eshell.el (eshell-read-command): New function...
(eshell-command): ... use it.  Additionally, require the COMMAND
argument, and rename ARG to TO-CURRENT-BUFFER.

20 months agoFix using background commands in 'eshell-command'
Jim Porter [Fri, 31 Mar 2023 02:31:30 +0000 (19:31 -0700)]
Fix using background commands in 'eshell-command'

This regressed due to the patch for bug#53715, which changed how
Eshell pipelines return the processes in the pipeline (bug#62556).

* lisp/eshell/esh-cmd.el (eshell-parse-command): When creating
background commands, wrap the process(es) in a cons cell whose CAR is
':eshell-background'.  This lets us use fewer heuristics...
(eshell-eval-command): ... here.  Additionally, keep the result and
the incomplete delimiter separate.

* lisp/eshell/eshell.el (eshell-command): Check ':eshell-background'
and use a more-robust method for setting the output target.

* test/lisp/eshell/eshell-tests.el (eshell-test/eshell-command/simple)
(eshell-test/eshell-command/pipeline)
(eshell-test/eshell-command/background)
(eshell-test/eshell-command/background-pipeline): New tests.

20 months agolisp/simple.el (inhibit-auto-fill): New var
Stefan Monnier [Sun, 2 Apr 2023 21:54:02 +0000 (17:54 -0400)]
lisp/simple.el (inhibit-auto-fill): New var

* lisp/simple.el (inhibit-auto-fill): New var.
(internal-auto-fill): Obey it.
(newline): Use it instead of binding `auto-fill-function`, so
as to avoid messing up the state if something wants to enable/disable
`auto-fill-mode` during the course of the let binding (bug#62419).

20 months agosrc/eval.c: Fix bug#62419
Stefan Monnier [Sun, 2 Apr 2023 21:45:58 +0000 (17:45 -0400)]
src/eval.c: Fix bug#62419

Yup, almost 40 years after ELisp first combined them, buffer-local
and let bindings still don't work quite right :-(

The "automatically buffer-local if set" semantics should follow the
principle that it becomes buffer-local iff the var's current binding
refers to the top-level/global/non-let binding.

* src/eval.c (let_shadows_buffer_binding_p): Disregard non-global
let-bindings.

* test/src/eval-tests.el (eval-test--bug62419): New test.

20 months ago; Add tests for synchronous processes in Eshell
Jim Porter [Sat, 1 Apr 2023 04:32:44 +0000 (21:32 -0700)]
; Add tests for synchronous processes in Eshell

Normally, Eshell only uses synchronous processes on MS-DOS, so this is
hard to test.  To get around this, let the tests explicitly request
synchronous processes.

* lisp/eshell/esh-proc.el (eshell-supports-asynchronous-processes):
New variable...
(eshell-gather-process-output): ... use it, and remove some incorrect
code updating Eshell's internal markers (the async code path doesn't
do this, so neither should the sync path).

* lisp/eshell/esh-cmd.el (eshell-execute-pipeline): Use
'eshell-supports-asynchronous-processes'.

* test/lisp/eshell/esh-proc-tests.el
(esh-proc-test/emacs-command): New function.
(esh-proc-test/emacs-echo, esh-proc-test/emacs-upcase): New variables.
(esh-proc-test/synchronous-proc/simple/interactive)
(esh-proc-test/synchronous-proc/simple/command-result)
(esh-proc-test/synchronous-proc/pipeline/interactive)
(esh-proc-test/synchronous-proc/pipeline/command-result): New tests.

20 months agoAvoid shadowing variables in some Eshell command forms
Jim Porter [Sun, 19 Mar 2023 02:18:28 +0000 (19:18 -0700)]
Avoid shadowing variables in some Eshell command forms

* lisp/eshell/esh-cmd.el (eshell-rewrite-for-command): Make
'for-items' an uninterned symbol.
(eshell-as-subcommand): Correct docstring.
(eshell-do-command-to-value): Mark obsolete.
(eshell-command-to-value): Move binding of 'value' outside of the
macro's result, and remove call to 'eshell-do-command-to-value'.

* test/lisp/eshell/esh-cmd-tests.el
(esh-cmd-test/subcommand-shadow-value)
(esh-cmd-test/for-loop-for-items-shadow): New tests.
(esh-cmd-test/for-name-loop, esh-cmd-test/for-name-shadow-loop):
Rename to...
(esh-cmd-test/for-loop-name, esh-cmd-test/for-loop-name-shadow):
... these.

20 months agoAdd some icons (bug#62562)
Yuan Fu [Fri, 31 Mar 2023 04:58:05 +0000 (21:58 -0700)]
Add some icons (bug#62562)

* etc/images/symbols/README: New file.
* etc/images/symbols/*.svg: New icons.

20 months ago; * etc/NEWS: Fix typos.
Michael Albinus [Sat, 1 Apr 2023 15:04:50 +0000 (17:04 +0200)]
; * etc/NEWS: Fix typos.

20 months agoFix ModelSim error regexp in vhdl-mode
Eli Zaretskii [Sat, 1 Apr 2023 10:07:42 +0000 (13:07 +0300)]
Fix ModelSim error regexp in vhdl-mode

* lisp/progmodes/vhdl-mode.el (vhdl-compiler-alist): Fix ModelSim
error regexp.  Suggested by Reto Zimmermann <reto@gnu.org>.
(Bug#62508)

20 months ago; * doc/emacs/trouble.texi (Checklist): Minor copyedits (bug#62320).
Eli Zaretskii [Sat, 1 Apr 2023 10:00:36 +0000 (13:00 +0300)]
; * doc/emacs/trouble.texi (Checklist): Minor copyedits (bug#62320).

20 months agoDocument enhancements in handling of echo-area messages
Eli Zaretskii [Sat, 1 Apr 2023 09:49:18 +0000 (12:49 +0300)]
Document enhancements in handling of echo-area messages

* etc/NEWS:
* doc/lispref/display.texi (Displaying Messages):
* lisp/minibuffer.el (inhibit-message-regexps)
(set-message-functions, inhibit-message, set-multi-message):
Improve the documentation of functions dealing with display of
echo-area messages.

20 months ago; * src/fns.c: Use if instead of #ifdef
Mattias Engdegård [Sat, 1 Apr 2023 08:53:50 +0000 (10:53 +0200)]
; * src/fns.c: Use if instead of #ifdef

* src/fns.c (HAVE_FAST_UNALIGNED_ACCESS, load_unaligned_size_t):
Always define these.
(Fstring_lessp): Use if instead of #ifdef.

20 months ago; Fix last change
Eli Zaretskii [Sat, 1 Apr 2023 06:55:29 +0000 (09:55 +0300)]
; Fix last change

* test/lisp/eshell/eshell-tests.el
(eshell-test/eshell-command/background-pipeline): Fix last change.

20 months ago; * src/fns.c (HAVE_FAST_UNALIGNED_ACCESS): Check in missing edit.
Po Lu [Sat, 1 Apr 2023 06:25:47 +0000 (14:25 +0800)]
; * src/fns.c (HAVE_FAST_UNALIGNED_ACCESS): Check in missing edit.

20 months agoFix new Eshell tests on MS-Windows
Eli Zaretskii [Sat, 1 Apr 2023 06:24:38 +0000 (09:24 +0300)]
Fix new Eshell tests on MS-Windows

* test/lisp/eshell/eshell-tests.el (eshell-test/eshell-command/background)
(eshell-test/eshell-command/background-pipeline): Allow for ".exe"
in the program's name.  This fixes these tests on MS-Windows.

20 months ago; * src/fns.c (Fstring_lessp): Fix coding style.
Po Lu [Sat, 1 Apr 2023 06:24:22 +0000 (14:24 +0800)]
; * src/fns.c (Fstring_lessp): Fix coding style.

20 months ago; * src/fns.c (Fstring_lessp): Port to RISCs.
Po Lu [Sat, 1 Apr 2023 06:23:32 +0000 (14:23 +0800)]
; * src/fns.c (Fstring_lessp): Port to RISCs.

20 months agoUpdate publicsuffix.txt from upstream
Stefan Kangas [Sat, 1 Apr 2023 04:00:47 +0000 (06:00 +0200)]
Update publicsuffix.txt from upstream

* etc/publicsuffix.txt: Update from
https://publicsuffix.org/list/public_suffix_list.dat
dated 2023-03-18 16:17:52 UTC.

20 months ago; Auto-commit of loaddefs files.
Stefan Kangas [Sat, 1 Apr 2023 03:10:48 +0000 (05:10 +0200)]
; Auto-commit of loaddefs files.

20 months ago; Auto-commit of loaddefs files.
Stefan Kangas [Sat, 1 Apr 2023 03:10:47 +0000 (05:10 +0200)]
; Auto-commit of loaddefs files.

20 months agoAllow null date in gnus-icalendar-event--decode-datefield
Andrew G Cohen [Thu, 16 Mar 2023 10:43:35 +0000 (18:43 +0800)]
Allow null date in gnus-icalendar-event--decode-datefield

* lisp/gnus/gnus-icalendar.el:
(gnus-icalendar-event--decode-datefield): Don't throw an error if the
event date is missing.

20 months agoReset 'gnus-current-window-configuration' on edit-form exit.
Andrew G Cohen [Thu, 9 Mar 2023 08:05:31 +0000 (16:05 +0800)]
Reset 'gnus-current-window-configuration' on edit-form exit.

* lisp/gnus/gnus.el: New variable gnus-prev-cwc.
* lisp/gnus/gnus-art.el (gnus-article-edit-mode):
New local variable gnus-prev-cwc.
(gnus-article-edit-article):  Store original
gnus-current-window-configuration as gnus-prev-cwc.
(gnus-article-edit-done, gnus-article-edit-exit): Restore
gnus-current-window-configuration from gnus-prev-cwc.
* lisp/gnus/gnus-eform.el (gnus-edit-form-mode):
New local variable gnus-prev-cwc.
(gnus-edit-form):  Store original
gnus-current-window-configuration as gnus-prev-cwc.
(gnus-edit-form-done, gnus-edit-form-exit): Restore
gnus-current-window-configuration from gnus-prev-cwc.

20 months agoUse completion when mark limiting in gnus summary buffers
Andrew G Cohen [Sun, 13 Mar 2022 23:59:25 +0000 (07:59 +0800)]
Use completion when mark limiting in gnus summary buffers

* lisp/gnus/gnus-sum.el (gnus-summary-limit-to-marks)
(gnus-summary-limit-exclude-marks): Use completing-read to complete on
marks in the current summary buffer.

20 months agoTrack article while moving between gnus groups
Andrew G Cohen [Sun, 13 Mar 2022 23:47:39 +0000 (07:47 +0800)]
Track article while moving between gnus groups

* lisp/gnus/gnus-sum.el (gnus-current-move-article): New variable to
track article while moving.
(gnus-summary-move-article): Set gnus-current-move-article when
moving/copying/crossposting or respooling.

20 months agoFix using background commands in 'eshell-command'
Jim Porter [Fri, 31 Mar 2023 00:39:24 +0000 (17:39 -0700)]
Fix using background commands in 'eshell-command'

Do not merge to master.

This regressed due to the patch for bug#53715, which changed how
Eshell pipelines return the processes in the pipeline (bug#62556).

* lisp/eshell/esh-cmd.el (eshell-eval-command): Allow process-pairs.

* test/lisp/eshell/eshell-tests.el (eshell-test/eshell-command/simple)
(eshell-test/eshell-command/pipeline)
(eshell-test/eshell-command/background)
(eshell-test/eshell-command/background-pipeline): New tests.

20 months agoMake string-lessp vectorisation safer
Mattias Engdegård [Fri, 31 Mar 2023 18:13:18 +0000 (20:13 +0200)]
Make string-lessp vectorisation safer

Use memcpy for loading unaligned words on platforms where this can be
done efficiently.  This guards against problems arising from future
compiler autovectorisation improvements that might cause instructions
that require aligned addresses to be emitted, and should also work
with an address sanitiser enabled.

* src/fns.c (HAVE_FAST_UNALIGNED_ACCESS): Only define when optimising.
(load_unaligned_size_t): New.
(Fstring_lessp): Use load_unaligned_size_t.
* src/lisp.h (UNALIGNED_LOAD_SIZE): Remove now unused macro.

20 months ago; CONTRIBUTE: Minor stylistic changes.
Eli Zaretskii [Fri, 31 Mar 2023 13:18:09 +0000 (16:18 +0300)]
; CONTRIBUTE: Minor stylistic changes.

20 months agoAllow old input to include continuation lines in shell-mode
Bob Rogers [Fri, 31 Mar 2023 07:57:32 +0000 (09:57 +0200)]
Allow old input to include continuation lines in shell-mode

* lisp/shell.el (shell-get-old-input-include-continuation-lines): New
defcustom (default nil).
(shell-get-old-input): New function.  Like
'comint-get-old-input-default' but include all continuation lines if
'shell-get-old-input-include-continuation-lines' is non-nil.
(shell-mode): Install shell-get-old-input.  (Bug#61069)

* etc/NEWS: Advertise the new defcustom.

20 months agoFix typo in section 14.1 of Emacs Manual
Shynur [Fri, 31 Mar 2023 11:49:39 +0000 (19:49 +0800)]
Fix typo in section 14.1 of Emacs Manual

* doc/emacs/display.texi (Scrolling): Fix typo.  (Bug#62569)

Copyright-paperwork-exempt: yes

20 months ago* test/infra/Dockerfile.emba (emacs-eglot): Adapt software selection.
Michael Albinus [Fri, 31 Mar 2023 12:17:54 +0000 (14:17 +0200)]
* test/infra/Dockerfile.emba (emacs-eglot): Adapt software selection.

20 months ago* lisp/net/tramp.el (tramp-accept-process-output): Use `with-local-quit'.
Michael Albinus [Fri, 31 Mar 2023 07:45:23 +0000 (09:45 +0200)]
* lisp/net/tramp.el (tramp-accept-process-output): Use `with-local-quit'.

20 months agoAdd treesit-node-get
Yuan Fu [Fri, 24 Mar 2023 20:13:05 +0000 (13:13 -0700)]
Add treesit-node-get

* doc/lispref/parsing.texi (Retrieving Nodes): Add manual entry.
* lisp/treesit.el (treesit-node--get): New function.

20 months ago; * etc/EGLOT-NEWS: Clarify scope of topmost section
João Távora [Thu, 30 Mar 2023 22:55:57 +0000 (23:55 +0100)]
; * etc/EGLOT-NEWS: Clarify scope of topmost section

20 months agoEglot: unbreak eglot-extend-to-xref on w32
João Távora [Thu, 30 Mar 2023 22:52:27 +0000 (23:52 +0100)]
Eglot: unbreak eglot-extend-to-xref on w32

Because of a drive-letter casing mismatch between 'buffer-file-name'
and the return value of 'url-generic-parse-url', the hash-table test
'equal' in 'eglot-current-server' failed.

This failed to recognize that the file xref landed us on really is
managed by the language server that facilitated that jump.

The function w32-long-file-name seems to convert "C:/Users/" to
"c:/Users" consistently and so is a good addition to
eglot--uri-to-path.

* lisp/progmodes/eglot.el (eglot--uri-to-path): Use
w32-long-file-name.

20 months agoEglot: ensure server shutdown turns off eglot-inlay-hints-mode
João Távora [Thu, 30 Mar 2023 18:47:00 +0000 (19:47 +0100)]
Eglot: ensure server shutdown turns off eglot-inlay-hints-mode

* lisp/progmodes/eglot.el (eglot--managed-mode-off): Turn off
eglot-inlay-hints-mode.

20 months ago; * lisp/emacs-lisp/package-vc.el: Remove completed item from TODO
Philip Kaludercic [Thu, 30 Mar 2023 21:25:20 +0000 (23:25 +0200)]
; * lisp/emacs-lisp/package-vc.el: Remove completed item from TODO

20 months ago; * lisp/emacs-lisp/package-vc.el (package-vc): Fix manual reference
Philip Kaludercic [Thu, 30 Mar 2023 21:24:08 +0000 (23:24 +0200)]
; * lisp/emacs-lisp/package-vc.el (package-vc): Fix manual reference

20 months ago; Clarify documentation of 'cursor' text property
Eli Zaretskii [Thu, 30 Mar 2023 13:34:41 +0000 (16:34 +0300)]
; Clarify documentation of 'cursor' text property

* doc/lispref/text.texi (Special Properties): Clarify that
'cursor' property is only considered when the overlay hides buffer
text on display.  (Bug#62540)

20 months agoAdd two typescript-ts-mode faces (bug#62429)
Yuan Fu [Fri, 24 Mar 2023 23:45:15 +0000 (16:45 -0700)]
Add two typescript-ts-mode faces (bug#62429)

* lisp/progmodes/typescript-ts-mode.el:
(typescript-ts-mode-jsx-tag-face)
(typescript-ts-mode-jsx-attribute-face): New faces.
(typescript-ts-mode--font-lock-settings): Use new faces.
(tsx-ts-mode): Mention the new faces in the docstring.

20 months agoFix scrolling window when point moves up
Shynur [Wed, 29 Mar 2023 17:29:17 +0000 (01:29 +0800)]
Fix scrolling window when point moves up

This fixes the case when both 'scroll-conservatively' and
'scroll-step' are customized to non-default values.
* src/xdisp.c (try_scrolling): Fix precedence between
'scroll-step' and 'scroll-conservatively' when scrolling with
'previous-line'.  (Bug#62530)

Copyright-paperwork-exempt: yes

20 months agoImprove documentation of 'defcustom's :set keyword
Eli Zaretskii [Thu, 30 Mar 2023 06:09:43 +0000 (09:09 +0300)]
Improve documentation of 'defcustom's :set keyword

* lisp/custom.el (defcustom):
* doc/lispref/customize.texi (Variable Definitions): Improve the
documentation of the :set keyword in 'defcustom'.

20 months agoComp fix calls to redefined primtives with op-bytecode (bug#61917)
Andrea Corallo [Wed, 29 Mar 2023 16:02:30 +0000 (18:02 +0200)]
Comp fix calls to redefined primtives with op-bytecode (bug#61917)

* test/src/comp-tests.el (61917-1): New test.
* src/comp.c (syms_of_comp): New variable.
* lisp/loadup.el: Store primitive arities before dumping.
* lisp/emacs-lisp/comp.el (comp--func-arity): New function.
(comp-emit-set-call-subr): Make use of `comp--func-arity'.

20 months ago; * test/lisp/dired-aux-tests.el: remove mistaken unwind-protect
Mattias Engdegård [Wed, 29 Mar 2023 20:16:37 +0000 (22:16 +0200)]
; * test/lisp/dired-aux-tests.el: remove mistaken unwind-protect

20 months ago; Fix last change
Eli Zaretskii [Wed, 29 Mar 2023 18:28:53 +0000 (21:28 +0300)]
; Fix last change

20 months ago; Fix last change
Eli Zaretskii [Wed, 29 Mar 2023 18:28:02 +0000 (21:28 +0300)]
; Fix last change

20 months agoFix duplicate defcustom in eww.el
Eli Zaretskii [Wed, 29 Mar 2023 18:27:09 +0000 (21:27 +0300)]
Fix duplicate defcustom in eww.el

* lisp/net/eww.el (eww-default-download-directory): Renamed back
from 'eww-download-directory'; all users changed.  Doc fix.
(Bug#62531)

20 months agoRework zeroconf integration into tramp-gvfs.el
Michael Albinus [Wed, 29 Mar 2023 18:22:04 +0000 (20:22 +0200)]
Rework zeroconf integration into tramp-gvfs.el

* lisp/net/tramp-gvfs.el (tramp-gvfs-enabled): Do not check for
:system bus.
(tramp-gvfs-mounttypes): New defconst.
(tramp-gvfs-maybe-open-connection): Use it.
(top): Call zeroconf only when :system bus is available.

20 months agoAvoid unwind-protect without unwind forms in cl-letf
Mattias Engdegård [Wed, 29 Mar 2023 15:03:31 +0000 (17:03 +0200)]
Avoid unwind-protect without unwind forms in cl-letf

* lisp/emacs-lisp/cl-macs.el (cl--letf): Use unwind-protect only if
necessary, avoiding a warning.

20 months agoWarn about unwind-protect without unwind forms
Mattias Engdegård [Wed, 29 Mar 2023 11:21:26 +0000 (13:21 +0200)]
Warn about unwind-protect without unwind forms

`unwind-protect` without unwind forms is not just pointless but often
indicates a mistake where the intended unwind part is misplaced, as in

    (unwind-protect (progn PROT-FORMS UNWIND-FORMS))   ; oops

or

    (unwind-protect PROT-FORM) UNWIND-FORMS            ; also oops

or entirely forgotten for that matter.  Warning about this makes
sense, and the warning can always be silenced by removing the
`unwind-protect` altogether if it shouldn't be there in the first
place.

* lisp/emacs-lisp/macroexp.el (macroexp--expand-all): Implement
warning.
* etc/NEWS: Announce.
* test/lisp/emacs-lisp/bytecomp-tests.el
(bytecomp-test--with-suppressed-warnings): Add test case.

20 months agoFix D-Bus event loop when executing a keyboard macro
Michael Albinus [Wed, 29 Mar 2023 14:10:29 +0000 (16:10 +0200)]
Fix D-Bus event loop when executing a keyboard macro

* lisp/net/dbus.el (dbus-call-method): Don't loop for events when
`executing-kbd-macro' is non-nil.  (Bug#62018)

20 months agoAdd clojure-ts-mode to eglot-server-programs
dannyfreeman [Sat, 25 Mar 2023 19:13:41 +0000 (15:13 -0400)]
Add clojure-ts-mode to eglot-server-programs

* lisp/progmodes/eglot.el (eglot-server-programs): Add
clojure-ts-mode.  (Bug#62449)

20 months agoFix indentation regression in 'C-h l'
Eli Zaretskii [Wed, 29 Mar 2023 11:56:20 +0000 (14:56 +0300)]
Fix indentation regression in 'C-h l'

* lisp/help.el (view-lossage): Fix indentation of commands
when the key sequence includes a semicolon.  (Bug#62453)

20 months ago* test/infra/Dockerfile.emba (emacs-eglot): Adapt software selection.
Michael Albinus [Wed, 29 Mar 2023 11:18:15 +0000 (13:18 +0200)]
* test/infra/Dockerfile.emba (emacs-eglot): Adapt software selection.

20 months ago* doc/misc/tramp.texi (Remote shell setup): Clarify use of ssh RemoteCommand.
Michael Albinus [Wed, 29 Mar 2023 08:55:18 +0000 (10:55 +0200)]
* doc/misc/tramp.texi (Remote shell setup): Clarify use of ssh RemoteCommand.

20 months agoMerge from origin/emacs-29
Stefan Kangas [Wed, 29 Mar 2023 04:30:09 +0000 (06:30 +0200)]
Merge from origin/emacs-29

3965c65d5e2 ; * lisp/subr.el (read-char-choice): Fix last change.
c1eac5b6586 Improve documentation of 'read-choice' and related symbols
a8c9283e170 Revert "Comp fix calls to redefined primtives with op-byt...
8b66d8abd01 Revert "* lisp/emacs-lisp/comp.el (comp-emit-set-call-sub...
4ec4f614c71 ; Fix incompatibility in 'display-buffer-assq-regexp'
ba3ade58f3b Skip ruby-ts-imenu-index test if needed
9133446db87 Fix Eglot Tramp tests on EMBA
5b351bc7fa9 * test/infra/Dockerfile.emba (emacs-gnustep): Instrument ...

20 months agoruby-ts-mode: Rehash which nodes should be treated as sexps
Dmitry Gutov [Tue, 28 Mar 2023 22:08:55 +0000 (01:08 +0300)]
ruby-ts-mode: Rehash which nodes should be treated as sexps

* lisp/progmodes/ruby-ts-mode.el (ruby-ts-mode): Recognize smaller
syntactic elements as sexps too (bug#62416).  Also do that for
heredocs, regexps and symbol arrays.  But drop binary expressions
(including assignments) since they led to non-intuitive behavior.

20 months agoAvoid parsing some Eshell forms when performing completion
Jim Porter [Tue, 21 Mar 2023 00:25:54 +0000 (17:25 -0700)]
Avoid parsing some Eshell forms when performing completion

During completion, we want to evaluate most Eshell forms
(e.g. variable references), but skip others (e.g. globbing,
subcommands).  For globbing, we want to pass the literal glob to
Pcomplete so it can use the glob for selecting completion candidates.
For subcommands (including Lisp forms), we especially want to avoid
evaluation, since they can produce arbitary side effects!  (Bug#50470)

* lisp/eshell/esh-cmd.el (eshell-allow-commands): New variable...
(eshell-commands-forbidden): New error...
(eshell-named-command, eshell-lisp-command): ... use them.

* lisp/eshell/em-cmpl.el (eshell-complete--eval-argument-form):
Disallow command forms and handle errors ourselves.
(eshell-complete-parse-arguments): Don't parse glob characters.

* test/lisp/eshell/em-cmpl-tests.el
(em-cmpl-test/parse-arguments/unevaluated-subcommand)
(em-cmpl-test/parse-arguments/unevaluated-lisp-form)
(em-cmpl-test/parse-arguments/unevaluated-inner-subcommand)
(em-cmpl-test/file-completion/glob, em-cmpl-test/command-completion)
(em-cmpl-test/subcommand-completion): New tests.
(em-cmpl-test/parse-arguments/pipeline): Remove superfluous
let-binding.
(em-cmpl-test/file-completion/after-list): Use a list variable rather
than a subexpression; the latter is no longer evaluated during
completion.
(em-cmpl-test/lisp-function-completion): Check "$(func)" syntax.

20 months agoSimplify parsing subcommands slightly
Jim Porter [Tue, 21 Mar 2023 00:25:24 +0000 (17:25 -0700)]
Simplify parsing subcommands slightly

This mainly reduces some overly-deep indentation, but also fixes some
minor issues with the "$<subcmd>" form: it unnecessarily added " >
TEMP" (we already set this later via 'eshell-create-handles'), and it
didn't properly unescape inner double quotes.

* lisp/eshell/esh-cmd.el (eshell-parse-subcommand-argument): Simplify.

* lisp/eshell/esh-var.el (eshell-parse-variable-ref): Simplify and
fix edge cases in "$<subcmd>".

* test/lisp/eshell/esh-var-tests.el
(esh-var-test/quoted-interp-temp-cmd): Adjust test to check behavior
of inner double quotes.

20 months ago; Fix an edge case in how 'eshell-do-eval' handles 'let' bodies
Jim Porter [Tue, 21 Mar 2023 00:24:28 +0000 (17:24 -0700)]
; Fix an edge case in how 'eshell-do-eval' handles 'let' bodies

* lisp/eshell/esh-cmd.el (ehell-do-eval): Use 'car-safe'; the object
in question might not be a cons cell.

20 months ago; * lisp/subr.el (read-char-choice): Fix last change.
Eli Zaretskii [Tue, 28 Mar 2023 18:31:51 +0000 (21:31 +0300)]
; * lisp/subr.el (read-char-choice): Fix last change.

20 months agoImprove documentation of 'read-choice' and related symbols
Eli Zaretskii [Tue, 28 Mar 2023 18:08:12 +0000 (21:08 +0300)]
Improve documentation of 'read-choice' and related symbols

* doc/lispref/commands.texi (Reading One Event):
* lisp/subr.el (read-char-choice-use-read-key, read-char-choice)
(read-char-choice-with-read-key, y-or-n-p-use-read-key): Improve
documentation of these functions and variables.

20 months agoRevert "Comp fix calls to redefined primtives with op-bytecode (bug#61917)"
Andrea Corallo [Tue, 28 Mar 2023 12:56:47 +0000 (14:56 +0200)]
Revert "Comp fix calls to redefined primtives with op-bytecode (bug#61917)"

This reverts commit 263d6c38539691c954f4c3057cbe8d5468499b91.

These patch series caused a number of regression and more analysis is
required.

20 months agoRevert "* lisp/emacs-lisp/comp.el (comp-emit-set-call-subr): Improve..."
Andrea Corallo [Tue, 28 Mar 2023 12:56:37 +0000 (14:56 +0200)]
Revert "* lisp/emacs-lisp/comp.el (comp-emit-set-call-subr): Improve..."

This reverts commit 4a7a0c9a9f521b04b23580901e9c0a662b504e32.

These patch series caused a number of regression and more analysis is
required.

20 months ago; Fix incompatibility in 'display-buffer-assq-regexp'
Eli Zaretskii [Tue, 28 Mar 2023 11:08:29 +0000 (14:08 +0300)]
; Fix incompatibility in 'display-buffer-assq-regexp'

* lisp/window.el (display-buffer-assq-regexp): Make it accept a
buffer's name again, as it did in Emacs 28.  This makes computing
the buffer's name inside the function unnecessary.
(display-buffer): Always pass the buffer's name to
'display-buffer-assq-regexp'.  (Bug#62417)

20 months agoSkip ruby-ts-imenu-index test if needed
Michael Albinus [Tue, 28 Mar 2023 11:04:09 +0000 (13:04 +0200)]
Skip ruby-ts-imenu-index test if needed

* test/lisp/progmodes/ruby-ts-mode-tests.el (ruby-ts-imenu-index):
Add check for treesitter.

20 months agoFix Eglot Tramp tests on EMBA
Michael Albinus [Tue, 28 Mar 2023 10:43:01 +0000 (12:43 +0200)]
Fix Eglot Tramp tests on EMBA

* test/lisp/progmodes/eglot-tests.el (eglot--call-with-tramp-test):
Bind `tramp-allow-unsafe-temporary-files' with t.  (Bug#62289)