]> git.eshelyaron.com Git - emacs.git/log
emacs.git
18 months agoApply quote substitution to popup choice menus
Stephen Berman [Sat, 24 Jun 2023 08:45:10 +0000 (10:45 +0200)]
Apply quote substitution to popup choice menus

* lisp/wid-edit.el (widget-choose): Iteratively apply
substitute-command-keys to choice item text before building popup
or text buffer menu.  Also fix two unnecessary uses of let*.

18 months agoExtend Tramp kubernetes method
Michael Albinus [Fri, 23 Jun 2023 19:26:14 +0000 (21:26 +0200)]
Extend Tramp kubernetes method

* doc/misc/tramp.texi (Inline methods): Adapt kubernetes method.

* etc/NEWS: Describe changes in Tramp kubernetes method.

* lisp/net/tramp-container.el (tramp-kubernetes-context)
(tramp-kubernetes-namespace): New defcustoms.
(tramp-kubernetes--completion-function): Extend for CONTAINER.POD
syntax.
(tramp-kubernetes--host-name-regexp): New defconst.
(tramp-kubernetes--container, tramp-kubernetes--pod)
(tramp-kubernetes--current-context): New defuns.
(tramp-kubernetes--current-context-data): Simplify.
(tramp-kubernetes--context-namespace): New defun.
(tramp-methods) <kubernetes>: Respect container, context and
namespace.  (Bug#59797)
(tramp-container-connection-local-default-kubernetes-variables):
New defconst.  Set respective connection-local variables.

* lisp/net/tramp-sh.el (tramp-config-check): New variable.
(tramp-open-connection-setup-interactive-shell): Use it.

* lisp/net/tramp.el (tramp-methods): Adapt docstring.
(tramp-extra-expand-args): New defvar.
(tramp-expand-args): Use it.

18 months ago; * etc/NEWS: Fix typos.
Michael Albinus [Fri, 23 Jun 2023 19:15:13 +0000 (21:15 +0200)]
; * etc/NEWS: Fix typos.

18 months agocl-defsubst: Use static scoping for args
Stefan Monnier [Fri, 23 Jun 2023 15:37:12 +0000 (11:37 -0400)]
cl-defsubst: Use static scoping for args

* lisp/emacs-lisp/cl-macs.el (cl--slet): New function, partly extracted
from `cl--slet*`.
(cl--slet*): Use it.
(cl--defsubst-expand): Use it to fix bug#47552.

* test/lisp/emacs-lisp/cl-macs-tests.el (cl-defstruct-dynbound-label):
New test.

18 months agocl-defun/cl-struct: Use static scoping for function args
Stefan Monnier [Fri, 23 Jun 2023 14:45:49 +0000 (10:45 -0400)]
cl-defun/cl-struct: Use static scoping for function args

* lisp/emacs-lisp/cl-macs.el (cl--slet*): New function.
(cl--transform-lambda): Use it to fix bug#47552.

* test/lisp/emacs-lisp/cl-macs-tests.el (cl-&key-arguments): Add test.

18 months agoRevert "Avoid header line with some empty non-nil formats"
Eli Zaretskii [Fri, 23 Jun 2023 10:50:15 +0000 (13:50 +0300)]
Revert "Avoid header line with some empty non-nil formats"

This reverts commit 4f66cbbfe520ee31ef26676e09a926217d9736fe.
This is part of removing the recently-added feature whereby
certain non-nil values of 'header-line-format' could signal
that the header line shall not be displayed.  The feature is
being reverted because its advantages are very minor, whereas
the complications it causes are serious.

18 months agoRevert "; Fix last change"
Eli Zaretskii [Fri, 23 Jun 2023 10:47:53 +0000 (13:47 +0300)]
Revert "; Fix last change"

This reverts commit 05c2be28a3e97bd920d0bf8c8b59ec682a420cce.
This is part of removing the recently-added feature whereby
certain non-nil values of 'header-line-format' could signal
that the header line shall not be displayed.  The feature is
being reverted because its advantages are very minor, whereas
the complications it causes are serious.

18 months agoRevert "; Fix coding style in just installed change"
Eli Zaretskii [Fri, 23 Jun 2023 10:47:33 +0000 (13:47 +0300)]
Revert "; Fix coding style in just installed change"

This reverts commit 229f0b8dd3b92827b6e0c6fc105508e8b80858f5.
This is part of removing the recently-added feature whereby
certain non-nil values of 'header-line-format' could signal
that the header line shall not be displayed.  The feature is
being reverted because its advantages are very minor, whereas
the complications it causes are serious.

18 months agoRevert "; * src/window.c (window_wants_header_line): Shut up bogus GCC warning."
Eli Zaretskii [Fri, 23 Jun 2023 10:47:05 +0000 (13:47 +0300)]
Revert "; * src/window.c (window_wants_header_line): Shut up bogus GCC warning."

This reverts commit ef8485ad05dd9200b68ea8141fd44c7b976140cd.
This is part of removing the recently-added feature whereby
certain non-nil values of 'header-line-format' could signal
that the header line shall not be displayed.  The feature is
being reverted because its advantages are very minor, whereas
the complications it causes are serious.

18 months agoRevert "Avoid infinite recursion in 'window_wants_header_line'"
Eli Zaretskii [Fri, 23 Jun 2023 10:44:59 +0000 (13:44 +0300)]
Revert "Avoid infinite recursion in 'window_wants_header_line'"

This reverts commit 3de8ed09ab46b9922e15aaf0cc8884b41087c996.
This is part of removing the recently-added feature whereby
certain non-nil values of 'header-line-format' could signal
that the header line shall not be displayed.  The feature is
being reverted because its advantages are very minor, whereas
the complications it causes are serious.

18 months ago; * doc/lispref/frames.texi (Frame Layout): Fix typo.
Po Lu [Fri, 23 Jun 2023 00:24:45 +0000 (08:24 +0800)]
; * doc/lispref/frames.texi (Frame Layout): Fix typo.

18 months agolatin-ltx.el: Add \Phi; fix bug#64212
Stefan Monnier [Thu, 22 Jun 2023 17:11:03 +0000 (13:11 -0400)]
latin-ltx.el: Add \Phi; fix bug#64212

* lisp/leim/quail/latin-ltx.el (greek letters): Fix regexp which was
meant to avoid lowercase phi only.

18 months agoFix orgtbl-to-table.el function to include last cell border
Jakub Ječmínek [Wed, 21 Jun 2023 13:50:31 +0000 (15:50 +0200)]
Fix orgtbl-to-table.el function to include last cell border

* lisp/org/org-table.el (orgtbl-to-table.el): Perform character
replacement in the temp buffer and fix missing cell border.  (Bug#64205)

Copyright-paperwork-exempt: yes

18 months ago* etc/NEWS: Announce the fix for bug#44418 (,@ prefix syntax)
Mattias Engdegård [Thu, 22 Jun 2023 11:17:00 +0000 (13:17 +0200)]
* etc/NEWS: Announce the fix for bug#44418 (,@ prefix syntax)

18 months agoRearrange some Tramp declarations
Michael Albinus [Thu, 22 Jun 2023 09:07:10 +0000 (11:07 +0200)]
Rearrange some Tramp declarations

* lisp/net/tramp.el (tramp-prefix-format, tramp-prefix-regexp)
(tramp-method-regexp, tramp-postfix-method-format)
(tramp-postfix-method-regexp, tramp-prefix-ipv6-format)
(tramp-prefix-ipv6-regexp, tramp-postfix-ipv6-format)
(tramp-postfix-ipv6-regexp, tramp-postfix-host-format)
(tramp-postfix-host-regexp, tramp-remote-file-name-spec-regexp)
(tramp-file-name-structure, tramp-file-name-regexp)
(tramp-completion-method-regexp)
(tramp-completion-file-name-regexp):
* lisp/net/tramp-gvfs.el (tramp-gvfs-dbus-event-vector):
Rearrange declarations.

18 months agoMerge from origin/emacs-29
Michael Albinus [Thu, 22 Jun 2023 09:01:23 +0000 (11:01 +0200)]
Merge from origin/emacs-29

0154f5885e3 Merge branch 'emacs-29' of git.sv.gnu.org:/srv/git/emacs ...
111efb0dd7f Merge branch 'emacs-29' of git.sv.gnu.org:/srv/git/emacs ...
948b471756e Require ls-lisp in Tramp only when needed
90c03ffcd4b After minibuffer action, don't make the minibuffer current

18 months ago; Merge from origin/emacs-29
Michael Albinus [Thu, 22 Jun 2023 08:50:49 +0000 (10:50 +0200)]
; Merge from origin/emacs-29

The following commit was skipped:

95091b77f0b Fix some tree-sitter :match regexps

18 months agoMerge from origin/emacs-29
Michael Albinus [Thu, 22 Jun 2023 08:50:46 +0000 (10:50 +0200)]
Merge from origin/emacs-29

3d930b928fe Eglot: fix relative position of coinciding inlay hint ove...
aad7d68164c ; * doc/lispref/display.texi (Display Tables): Remove ext...

18 months ago; Minor fixes of recently-installed regexp documentation changes
Eli Zaretskii [Thu, 22 Jun 2023 05:32:16 +0000 (08:32 +0300)]
; Minor fixes of recently-installed regexp documentation changes

* doc/emacs/search.texi (Regexps):
* doc/lispref/searching.texi (Regexp Special): Keep the old
terminology as "a.k.a.".
(Char Classes, POSIX Regexps, POSIX Regexps): Add cross-references
to where "bracket expression" is defined.  (Bug#64128)

18 months agoAdd Tramp option showing ad-hoc multi-hops
Michael Albinus [Wed, 21 Jun 2023 16:25:32 +0000 (18:25 +0200)]
Add Tramp option showing ad-hoc multi-hops

* doc/misc/tramp.texi (Ad-hoc multi-hops):
Describe tramp-show-ad-hoc-proxies.

* lisp/net/tramp.el (tramp-show-ad-hoc-proxies): New defcustom.
(tramp-make-tramp-file-name): Use it.
(tramp-make-tramp-hop-name): Don't add hop twice.

* test/lisp/net/tramp-tests.el (tramp-test02-file-name-dissect)
(tramp-test02-file-name-dissect-simplified)
(tramp-test02-file-name-dissect-separate): Adapt tests.

18 months agoDon't compile (+ X 0) as (* X 1)
Mattias Engdegård [Wed, 21 Jun 2023 14:56:12 +0000 (16:56 +0200)]
Don't compile (+ X 0) as (* X 1)

Previously (+ X 0) was reduced to (+ X) which became (* X 1) in
codegen, but this is wrong for X = -0.0 and also slightly slower.

* lisp/emacs-lisp/byte-opt.el (byte-optimize-plus): Don't reduce an
addition to (+ X) by eliminating zeros; retain one 0 argument.
* test/lisp/emacs-lisp/bytecomp-tests.el (bytecomp-tests--test-cases):
Add test case.

18 months agoPrefix syntax for ,@ in elisp-mode (bug#44418)
Mattias Engdegård [Wed, 21 Jun 2023 09:03:14 +0000 (11:03 +0200)]
Prefix syntax for ,@ in elisp-mode (bug#44418)

* lisp/progmodes/elisp-mode.el (elisp-mode-syntax-propertize):
Use prefix syntax for ,@ to avoid the @ becoming part of a symbol
that follows.
* test/lisp/emacs-lisp/edebug-tests.el (edebug-tests-with-normal-env):
Propertise inserted Lisp code to keep the test working.

18 months agoStraighten regexp postfix operator after zero-width assertion parse
Mattias Engdegård [Tue, 20 Jun 2023 10:12:50 +0000 (12:12 +0200)]
Straighten regexp postfix operator after zero-width assertion parse

The zero-width assertions \` \' \b \B were parsed in a sloppy way so
that a following postfix repetition operator could yield surprising
results.  For instance, "\\b*" would act as "\\b\\*", and "xy\\b*"
would act as "\\(?:xy\\b\\)*".

Except for \` and ^, any following postfix operator now applies to the
zero-width assertion itself only, which is predictable and consistent
with other assertions, if useless in practice.
For historical compatibility, an operator character following \` and ^
always becomes a literal. (Bug#64128)

* src/regex-emacs.c (regex_compile):
Set `laststart` appropriately for each zero-width assertion instead
of leaving it with whatever value it had before.
Remove a redundant condition.
* test/src/regex-emacs-tests.el
(regexp-tests-zero-width-assertion-repetition): New test.
* doc/lispref/searching.texi (Regexp Special):
Say that repetition operators are not special after \`,
and that they work as expected after other backslash escapes.
* etc/NEWS: Announce.

18 months agoCorrect handling of template markers on deletion/insertion
Alan Mackenzie [Wed, 21 Jun 2023 15:36:56 +0000 (15:36 +0000)]
Correct handling of template markers on deletion/insertion

This fixes bug#62841.

In particular, correct the syntax-table text properties on the
remaining <...>s.

* lisp/progmodes/cc-align.el
(c-lineup-template-args-indented-from-margin): New lineup
function.

* lisp/progmodes/cc-defs.el (c-put-char-properties): New macro.
(c-search-forward-non-nil-char-property): Handle terminating
limit correctly.

* lisp/progmodes/cc-engine.el
(c-clear-<-pair-props-if-match-after)
(c-clear->-pair-props-if-match-before): Return the position
outside the matching < or >, not merely t.
(c-end-of-literal): New function.
(c-unmark-<>-around-region): New function.
(c-before-change-check-<>-operators): Refactor, calling
c-unmark-<>-around-region.
(c-<>-get-restricted): New function, extracted from
c-restore-<>-properties.
(c-restore-<>-properties): Handle ">" characters whose matching
"<" has not yet been encountered.
(c-ml-string-opener-at-or-around-point): Fix an off by one
error.
(c-backward-<>-arglist): New parameter restricted-function, a
function which calculates c-restricted-<>-arglists for the
current operation.

* lisp/progmodes/cc-fonts.el (c-font-lock-c++-using): Check
point is less than limit in the loop.

* lisp/progmodes/cc-langs.el
(c-get-state-before-change-functions)
(c-before-font-lock-functions): Add the new function
c-unmark-<>-around-region into the C++ and Java values of the
variable.

* lisp/progmodes/cc-mode.el (c-clear-string-fences)
(c-restore-string-fences): Neutralize and restore the
syntax-table properties between an unbalanced " and EOL.

* lisp/progmodes/cc-vars.el (c-offsets-alist): Put new lineup
function c-lineup-template-args-indented-from-margin into entry
for template-args-cont.

* doc/misc/cc-mode.texi (List Line-Up): Document
c-lineup-template-args-indented-from-margin.

18 months agoExtend handling of prefix arg in some kmacro.el commands
Eli Zaretskii [Wed, 21 Jun 2023 13:58:32 +0000 (16:58 +0300)]
Extend handling of prefix arg in some kmacro.el commands

* lisp/kmacro.el (kmacro-call-ring-2nd)
(kmacro-call-ring-2nd-repeat, kmacro-end-macro)
(kmacro-end-and-call-macro): Accept just "C-u" and interpret it as
a numeric argument of 4.  Suggested by Al Petrofsky
<al@petrofsky.org>.  (Bug#64138)

18 months agoPrevent crashes on macOS when fullscreen frame is deleted
Daniel Martín [Sun, 18 Jun 2023 22:23:03 +0000 (00:23 +0200)]
Prevent crashes on macOS when fullscreen frame is deleted

* src/nsterm.m (ns_free_frame_resources): Remove the frame's
window from the hierarchy.  (Bug#64147)

18 months agoAllow --debug-init to debug all errors in init files
Eli Zaretskii [Wed, 21 Jun 2023 13:27:42 +0000 (16:27 +0300)]
Allow --debug-init to debug all errors in init files

* lisp/startup.el (startup--load-user-init-file): Ignore the value
of 'debug-ignored-errors' when loading init files if we were
invoked interactively with --debug-init.  (Bug#64163)

18 months agoDelete eval-command-interactive-spec
Sean Whitton [Wed, 21 Jun 2023 12:26:09 +0000 (13:26 +0100)]
Delete eval-command-interactive-spec

* etc/NEWS: Delete announcement of eval-command-interactive-spec.
* lisp/emacs-lisp/subr-x.el (eval-command-interactive-spec): Delete.

18 months ago* configure.ac: Update GCC bug number in comment.
Paul Eggert [Wed, 21 Jun 2023 07:06:44 +0000 (00:06 -0700)]
* configure.ac: Update GCC bug number in comment.

18 months ago; * src/pgtkfns.c (frame_geometry): Fix typo in last change.
Po Lu [Wed, 21 Jun 2023 03:32:41 +0000 (11:32 +0800)]
; * src/pgtkfns.c (frame_geometry): Fix typo in last change.

18 months agoAllow displaying tool bar on the bottom of the frame
Po Lu [Wed, 21 Jun 2023 02:04:31 +0000 (10:04 +0800)]
Allow displaying tool bar on the bottom of the frame

* src/xterm.c (x_clear_under_internal_border): Subtract bottom
margins before clearing bottom border.
(XTflash): Subtract bottom margins before flashing mini window.

* src/xfns.c (x_set_tool_bar_position): Allow setting different
values outside of GTK+.
(frame_geometry): Adjust inner width and height for tool bars
placed on the bottom.

* src/xdisp.c (init_xdisp): Calculate using top margins only.

* src/window.c (resize_frame_windows): Fix commentary.

* src/w32fns.c (Fw32_frame_geometry): Report tool bar position
correctly.
(w32_clear_under_internal_border): Subtract bottom margins
prior to clearing bottom border.
(w32_set_tool_bar_position): New function.
(Fw32_frame_edges): Subtract bottom tool bar from inner width and
height.
(w32_frame_parm_handlers): Add `set_tool_bar_position' parameter
handler.

* src/pgtkterm.c (pgtk_flash): Subtract bottom
margins before clearing bottom border.
(XTflash): Subtract bottom margins before flashing mini window.

* src/pgtkfns.c (frame_geometry): Set `inner_top' correctly.
(Fpgtk_set_mouse_absolute_pixel_position):
(Fpgtk_mouse_absolute_pixel_position):
(Fpgtk_page_setup_dialog):
(Fpgtk_get_page_setup): Wrap lines which cause C Mode to hang.

* src/nsterm.m (ns_clear_under_internal_border): Subtract bottom
margins before clearing bottom border.

* src/nsfns.m (ns_set_tool_bar_position): New function.  Error if
arg is not top.
(ns_frame_parm_handlers): Add that as the handler for
`tool-bar-position', to prevent it from being set to an invalid
value.

* src/haikuterm.c (haiku_flash): Subtract bottom margins before
flashing mini window.
(haiku_clear_under_internal_border): Subtract bottom margins
before clearing bottom border.

* src/haikufns.c (haiku_set_tool_bar_position): Allow setting
values other than `top'.
(frame_geometry): Take bottom margin into account when calculating
inner dimensions.

* src/frame.h (struct frame): Always define `tool_bar_position'.
(fset_tool_bar_position): Define function everywhere.
(FRAME_TOOL_BAR_POSITION): Define correctly on all toolkits.
(FRAME_TOOL_BAR_TOP_HEIGHT):
(FRAME_TOOL_BAR_TOP_LINES):
(FRAME_TOOL_BAR_BOTTOM_HEIGHT):
(FRAME_TOOL_BAR_BOTTOM_LINES): New macros.  Each pair returns the
tool bar dimensions only if the tool bar position is set
appropriately.
(FRAME_TOP_MARGIN, FRAME_TOP_MARGIN_HEIGHT): Only add tool bar
height if it is placed at the top of the frame.
(FRAME_BOTTOM_MARGIN, FRAME_BOTTOM_MARGIN_HEIGHT): Add ``bottom
margins''.
(FRAME_MARGINS, FRAME_MARGIN_HEIGHT): Move original margin macro
here.
(FRAME_PIXEL_HEIGHT_TO_TEXT_LINES):
(FRAME_TEXT_TO_PIXEL_HEIGHT):
(FRAME_PIXEL_TO_TEXT_HEIGHT):
(FRAME_INNER_HEIGHT): Subtract both vertical margins.

* src/frame.c (adjust_frame_size): Subtract both top and bottom
margins to determine the inner height.
(make_frame): Initialize `f->tool_bar_position' unconditionally.

* src/dispnew.c (adjust_frame_glyphs_for_window_redisplay): Place
internal tool bar on bottom if requested.

* doc/lispref/frames.texi (Frame Layout): Describe the possibility
of the tool bar being placed below the inner area of the frame.
(Layout Parameters): Describe that `tool-bar-position' is now
supported almost everywhere.

18 months ago; cperl-mode.el: Eliminate cperl-font-lock-multiline
Harald Jörg [Tue, 20 Jun 2023 20:51:29 +0000 (22:51 +0200)]
; cperl-mode.el: Eliminate cperl-font-lock-multiline

This undocumented variable was always set to t.  There was no
function to change the variable.

* lisp/progmodes/cperl-mode.el: Eliminate top-level variables
cperl-font-lock-multiline and cperl-font-lock-multiline-start.
(cperl-mode): Don't set cperl-font-lock-multiline.
(cperl-windowed-init): Don't set cperl-font-lock-multiline.
(cperl-init-faces): Eliminate (if cperl-font-lock-multiline)
conditionals.

18 months agoFix ldap-search when WITHDN is non-nil (bug#64089)
Filipp Gunbin [Tue, 20 Jun 2023 17:43:32 +0000 (20:43 +0300)]
Fix ldap-search when WITHDN is non-nil (bug#64089)

* lisp/net/ldap.el (ldap-search): Apply ldap-decode-attribute only to
attribute pairs.
(ldap-search-internal): Parse dn with the same regexp as other attrs;
use its value instead of the whole line.  Include entry into result
only if valid dn is present, to avoid treating process sentinel
messages like an entry.  Fix accidental match data clobbering.
Document return value format.

18 months agoSignal error upon setting unsupported tool bar position
Po Lu [Tue, 20 Jun 2023 02:13:41 +0000 (02:13 +0000)]
Signal error upon setting unsupported tool bar position

* src/haikufns.c (haiku_set_tool_bar_position): New function.
Port non-GTK code from X.
(haiku_frame_parm_handlers): Add new function.

18 months agoDon't read all headers in gnus thread referral (bug#63842)
Andrew G Cohen [Mon, 19 Jun 2023 23:59:51 +0000 (07:59 +0800)]
Don't read all headers in gnus thread referral (bug#63842)

Gnus thread referral tries to add newly found articles to an existing
summary buffer. When the list of such articles is known from searching
we can speed things up by only entering these specific headers into
the dependencies table.

* lisp/gnus/gnus-sum.el (gnus-summary-refer-thread): Don't set
`gnus-read-all-available-headers' when finding articles by searching.

18 months ago; Improve 'rx' form from edb0862f5e69
Jim Porter [Mon, 19 Jun 2023 20:45:37 +0000 (13:45 -0700)]
; Improve 'rx' form from edb0862f5e69

Thanks to Michael Albinus for the suggestion.

* test/lisp/eshell/esh-util-tests.el
(esh-util-test/eshell-stringify/list): Use 'any' instead of 'or' in
'rx' form.

18 months agoCall them “bracket expressions” more consistently
Paul Eggert [Mon, 19 Jun 2023 18:09:00 +0000 (11:09 -0700)]
Call them “bracket expressions” more consistently

Emacs comments and doc were inconsistent about the name used for
regexps like [a-z].  Sometimes it called them “character
alternatives”, sometimes “character sets”, sometimes “bracket
expressions”.  Prefer “bracket expressions” as it is less confusing:
POSIX and most other programs’ doc uses “bracket expressions”,
“alternative” is also used in the Emacs documentation to talk about
...\|... in regexps, and “character set” normally has a different
meaning in Emacs.

18 months agoDocument Emacs vs POSIX REs
Paul Eggert [Mon, 19 Jun 2023 18:09:00 +0000 (11:09 -0700)]
Document Emacs vs POSIX REs

* doc/lispref/searching.texi (Longest Match):
Rename from POSIX Regexps, as this section
is about longest-match functions, not about POSIX regexps.
(POSIX Regexps): New section.

18 months agoDocument regular expression special cases better
Paul Eggert [Mon, 19 Jun 2023 18:09:00 +0000 (11:09 -0700)]
Document regular expression special cases better

In particular, document that escape sequences like \b*
are currently buggy.

18 months agoAdapt Tramp specific tests in eglot-tests.el
Michael Albinus [Tue, 13 Dec 2022 19:06:48 +0000 (20:06 +0100)]
Adapt Tramp specific tests in eglot-tests.el

* test/lisp/progmodes/eglot-tests.el (tramp): Move up.
(tramp-sh): Don't require.
(eglot--cleanup-after-test): Delete Tramp buffers if needed.
(eglot-tests-lsp-abiding-column): Rename from `eglot-lsp-abiding-column'.
(tramp-histfile-override): Declare.
(eglot--call-with-tramp-test):
Use `ert-remote-temporary-file-directory'.  Skip if needed.
(eglot--tramp-test, eglot--tramp-test-2): Don't skip.

18 months ago* src/regex-emacs.c (regex_compile): Remove useless condition
Mattias Engdegård [Mon, 19 Jun 2023 08:25:15 +0000 (10:25 +0200)]
* src/regex-emacs.c (regex_compile): Remove useless condition

This condition didn't have any visible effect (as ^ is not a
repetition operator); all it did was to generate slightly worse regexp
bytecode for out-of-place (literal) ^ in the midst of literal
characters (bug#64128).

18 months ago; Fix test failure from 2f181d60323 (new 'pp' implementation)
Jim Porter [Sun, 18 Jun 2023 21:35:01 +0000 (14:35 -0700)]
; Fix test failure from 2f181d60323 (new 'pp' implementation)

* test/lisp/eshell/esh-util-tests.el
(esh-util-test/eshell-stringify/list): Be more flexible when checking
stringification of nested lists.

18 months agoMake C-SPC work in "M-x term"
Al Petrofsky [Sat, 17 Jun 2023 00:06:57 +0000 (20:06 -0400)]
Make C-SPC work in "M-x term"

* lisp/term.el (term-raw-map): Add bindings for C-SPC, C-M-SPC,
and C-M-/.
(term-send-C-@, term-send-C-M-_, term-send-C-M-@): New commands.
(Bug#64121)

18 months agoMerge branch 'master' of git+ssh://git.sv.gnu.org/srv/git/emacs
Stefan Monnier [Sat, 17 Jun 2023 22:06:01 +0000 (18:06 -0400)]
Merge branch 'master' of git+ssh://git.sv.gnu.org/srv/git/emacs

18 months agopp-fill: Fix tests breakage
Stefan Monnier [Sat, 17 Jun 2023 22:05:33 +0000 (18:05 -0400)]
pp-fill: Fix tests breakage

* lisp/emacs-lisp/pp.el (pp-to-string, pp-buffer, pp): Preserve old
behavior of (almost always) returning a trailing newline.

* test/lisp/emacs-lisp/pp-tests.el (pp-print-quote): Adjust tests, now
that `pp-to-string` always returns a trailing newline, rather than only
most of the time.

* test/lisp/emacs-lisp/backtrace-tests.el
(backtrace-tests--single-and-multi-line): Make the test less sensitive
to the choice of what is "pretty".

18 months ago* doc/lispref/streams.texi (Output Variables): Document `pp-default-function`
Stefan Monnier [Fri, 16 Jun 2023 17:35:36 +0000 (13:35 -0400)]
* doc/lispref/streams.texi (Output Variables): Document `pp-default-function`

18 months agopp.el (pp-fill): New default pp function
Stefan Monnier [Fri, 16 Jun 2023 17:35:06 +0000 (13:35 -0400)]
pp.el (pp-fill): New default pp function

* lisp/emacs-lisp/pp.el (pp-default-function): Change default.
(pp--within-fill-column-p): New helper function.
(pp-fill): New function.

18 months agopp.el (pp-default-function): New custom var
Stefan Monnier [Fri, 16 Jun 2023 17:31:13 +0000 (13:31 -0400)]
pp.el (pp-default-function): New custom var

* lisp/emacs-lisp/pp.el (pp-use-max-width): Make obsolete.
(pp-default-function): New custom var.
(pp--object, pp--region): New helper functions.
(pp-29): New function, extracted from `pp-to-string`.
(pp-to-string): Add `pp-function` arg and obey `pp-default-function`.
(pp-28): New function, extracted from `pp-buffer`.
(pp-buffer): Rewrite, to obey `pp-default-function`.
(pp): Obey `pp-default-function`.
(pp-emacs-lisp-code): Add new calling convention to apply it to a region.

18 months ago* lisp/emacs-lisp/lisp-mode.el (lisp-ppss): Fix performance bug
Stefan Monnier [Fri, 16 Jun 2023 17:14:27 +0000 (13:14 -0400)]
* lisp/emacs-lisp/lisp-mode.el (lisp-ppss): Fix performance bug

(nth 2 ppss) can be absent but not incorrect, so don't recompute ppss
for (nth 2 ppss) when (nth 2 ppss) is already provided.
When calling `lisp-indent-line` on all the lines in a region, this
sometimes introduced a gratuitous O(N²) complexity.

18 months agoFix some tree-sitter :match regexps
Basil L. Contovounesios [Tue, 13 Jun 2023 12:53:31 +0000 (13:53 +0100)]
Fix some tree-sitter :match regexps

This was originally installed on 2023-06-17 in the emacs-29 release
branch and later reverted.  The intention is to backport it after
Emacs 29.1 is released.

The shy groups were caught by modified versions of the GNU ELPA
packages xr and relint:
- https://github.com/mattiase/xr/pull/6
- https://github.com/mattiase/relint/pull/14

* lisp/progmodes/ruby-ts-mode.el (ruby-ts--s-p-query): Quote special
character in regexp.
* lisp/progmodes/java-ts-mode.el (java-ts-mode--font-lock-settings):
* lisp/progmodes/js.el (js--plain-method-re):
(js--treesit-font-lock-settings):
* lisp/progmodes/rust-ts-mode.el (rust-ts-mode--font-lock-settings):
* lisp/progmodes/typescript-ts-mode.el
(typescript-ts-mode--font-lock-settings): Replace character
alternative [\\d], which matches '\' or 'd', with the most likely
intention [0-9].  Fix shy groups mistyped as optional colons.
Remove unneeded numbered :match group in rust-ts-mode (bug#64019).

18 months agoMerge branch 'emacs-29' of git.sv.gnu.org:/srv/git/emacs into emacs-29
Michael Albinus [Sat, 17 Jun 2023 16:16:24 +0000 (18:16 +0200)]
Merge branch 'emacs-29' of git.sv.gnu.org:/srv/git/emacs into emacs-29

18 months agoMerge branch 'emacs-29' of git.sv.gnu.org:/srv/git/emacs into emacs-29
Michael Albinus [Sat, 17 Jun 2023 16:15:47 +0000 (18:15 +0200)]
Merge branch 'emacs-29' of git.sv.gnu.org:/srv/git/emacs into emacs-29

18 months agoRequire ls-lisp in Tramp only when needed
Michael Albinus [Sat, 17 Jun 2023 16:15:09 +0000 (18:15 +0200)]
Require ls-lisp in Tramp only when needed

* lisp/net/tramp-compat.el (ls-lisp): Require only on MS Windows.
(Bug#64124)

* lisp/net/tramp-sh.el (ls-lisp-use-insert-directory-program): Declare.
(tramp-sh-handle-insert-directory): Simplify.

* lisp/net/tramp.el (ls-lisp-use-insert-directory-program): Declare.
(tramp-handle-insert-directory): Require ls-lisp.  Simplify.

18 months agoAfter minibuffer action, don't make the minibuffer current
Alan Mackenzie [Sat, 17 Jun 2023 16:14:14 +0000 (16:14 +0000)]
After minibuffer action, don't make the minibuffer current

This fixes bug#63967.

* src/minibuf.c (minibuffer_unwind): After restoring the next
minibuffer outwards to the mini window (when
enable-recursive-minibuffers is non-nil), don't call
Fset_frame_selected_window, which used to set the current
window to be the mini window.

18 months agoFix some tree-sitter :match regexps
Basil L. Contovounesios [Tue, 13 Jun 2023 12:53:31 +0000 (13:53 +0100)]
Fix some tree-sitter :match regexps

The shy groups were caught by modified versions of the GNU ELPA
packages xr and relint:
- https://github.com/mattiase/xr/pull/6
- https://github.com/mattiase/relint/pull/14

* lisp/progmodes/ruby-ts-mode.el (ruby-ts--s-p-query): Quote special
character in regexp.
* lisp/progmodes/java-ts-mode.el (java-ts-mode--font-lock-settings):
* lisp/progmodes/js.el (js--plain-method-re):
(js--treesit-font-lock-settings):
* lisp/progmodes/rust-ts-mode.el (rust-ts-mode--font-lock-settings):
* lisp/progmodes/typescript-ts-mode.el
(typescript-ts-mode--font-lock-settings): Replace character
alternative [\\d], which matches '\' or 'd', with the most likely
intention [0-9].  Fix shy groups mistyped as optional colons.
Remove unneeded numbered :match group in rust-ts-mode (bug#64019).

18 months agoFix more shy group regexps
Basil L. Contovounesios [Sun, 11 Jun 2023 23:23:56 +0000 (00:23 +0100)]
Fix more shy group regexps

These issues were caught by modified versions of the GNU ELPA
packages xr and relint:
- https://github.com/mattiase/xr/pull/6
- https://github.com/mattiase/relint/pull/14

* lisp/gnus/gnus-art.el (gnus-parse-news-url): Remove redundant
numbered group and calls to match-string.
* lisp/progmodes/c-ts-mode.el (c-ts-mode--c-or-c++-regexp): Fix shy
group mistyped as optional colon (bug#64019#29).
* lisp/vc/vc-git.el (vc-git-annotate-time): Ditto.  Also fix
timezone parsing by using iso8601-parse (bug#64069).
* test/lisp/vc/vc-git-tests.el (vc-git-test-annotate-time): New
test.

18 months agoEglot: fix relative position of coinciding inlay hint overlays (bug#64101)
João Távora [Sat, 17 Jun 2023 14:25:30 +0000 (15:25 +0100)]
Eglot: fix relative position of coinciding inlay hint overlays (bug#64101)

Only seems to happen on certain platforms, like Mac OS.  Reason
unknown reason so far, but this defensive fix seems safe.

* lisp/progmodes/eglot.el (eglot--update-hints-1): Explicitly put
priority in inlay hint overalys.

18 months agoCC Mode: Correct some regexp typos, \\(:? -> \\(?:
Alan Mackenzie [Sat, 17 Jun 2023 13:19:18 +0000 (13:19 +0000)]
CC Mode: Correct some regexp typos, \\(:? -> \\(?:

This partly corrects bug#64069.

* lisp/progmodes/cc-langs.el (c-ml-string-back-closer-re): Fix
four occurrences, one of which was in a comment, one in a doc
string.

* lisp/progmodes/cc-mode.el (c-or-c++-mode--regexp.): Fix one
occurrence.

18 months ago; * doc/lispref/display.texi (Display Tables): Remove extra parens.
Eli Zaretskii [Sat, 17 Jun 2023 13:13:38 +0000 (16:13 +0300)]
; * doc/lispref/display.texi (Display Tables): Remove extra parens.

18 months ago; * src/treesit.c (treesit_query_string_string): fix last change
Mattias Engdegård [Sat, 17 Jun 2023 09:55:12 +0000 (11:55 +0200)]
; * src/treesit.c (treesit_query_string_string): fix last change

Escape the backslash character itself.

18 months ago; Auto-commit of loaddefs files.
Eli Zaretskii [Sat, 17 Jun 2023 09:27:03 +0000 (05:27 -0400)]
; Auto-commit of loaddefs files.

18 months agoMerge from origin/emacs-29
Eli Zaretskii [Sat, 17 Jun 2023 09:02:56 +0000 (05:02 -0400)]
Merge from origin/emacs-29

3b0bf359e9a Fix documentation of comment-dwim (bug#64104)

18 months ago; Merge from origin/emacs-29
Eli Zaretskii [Sat, 17 Jun 2023 09:02:56 +0000 (05:02 -0400)]
; Merge from origin/emacs-29

The following commits were skipped:

71b27779a9a ; * lisp/net/ldap.el (ldap-search-internal): Fix last cha...
d2246b26275 Fix parsing of dn line if WITHDN is non-nil

18 months agoMerge from origin/emacs-29
Eli Zaretskii [Sat, 17 Jun 2023 09:02:55 +0000 (05:02 -0400)]
Merge from origin/emacs-29

84d2da003e1 ; Fix example in the Flymake manual
0a1459f1d9b * doc/misc/calc.texi (Advanced Math Functions): Correct c...
92faf1f5645 Consider 'dired-kill-when-opening-new-dired-buffer' in mo...
bafe71a69fc ; Fix use-package.texi markup
018e4ca6c5d ; * doc/misc/calc.texi (Advanced Math Functions): Fix las...
1952dbd4c5f Fix Gamma function definition in calc.texi
f73f82d7e89 Fix subscripts in the Calc manual
70fc7c41ef3 Improve documentation of 'declare' forms
c8357582389 ; * src/lread.c (bytecode_from_rev_list): Avoid C++ comment.
28478574961 Improve tree-sitter docs
0e9307eb2b8 Fix some Texinfo markup in manuals
8dc08333eea Fix bol/bos anchors in tree-sitter :match regexps
8225ade6151 ; * src/xdisp.c (syms_of_xdisp) <display-line-numbers>: F...
1f0527a312a ; Fix last change in tex-mode.el
4da479920e6 * lisp/subr.el (with-restriction): Tweak indent rule
36aa9bd8183 ; Fix previous change
aaeaf608d89 Fix setting region in the minibuffer
1383efe01d0 Fix setting $DBUS_SESSION_BUS_ADDRESS after Emacs has sta...
bdb0bc2b4e4 Fix tex-mode display-buffer issues
90047c38ce9 Add test for when 'completion-auto-help' is 'visible'
2c623e4feb9 Avoid errors in 'apropos-documentation' after 'eval-buffer'
dd3b98121cc ; * doc/emacs/indent.texi (Indentation Commands): Fix las...
904edf1f076 Mention indent-rigidly in the Emacs manual

18 months agoFix documentation of comment-dwim (bug#64104)
Eli Zaretskii [Sat, 17 Jun 2023 08:37:19 +0000 (11:37 +0300)]
Fix documentation of comment-dwim (bug#64104)

* lisp/newcomment.el (comment-dwim): Doc fix.

* doc/emacs/programs.texi (Comment Commands): More accurate
description of what 'M-;' does when there's no active region.

18 months ago; * lisp/net/ldap.el (ldap-search-internal): Fix last change. (Bug#64089)
Eli Zaretskii [Sat, 17 Jun 2023 07:59:44 +0000 (10:59 +0300)]
; * lisp/net/ldap.el (ldap-search-internal): Fix last change.  (Bug#64089)

18 months agoFix parsing of dn line if WITHDN is non-nil
Jens Schmidt [Thu, 15 Jun 2023 22:04:04 +0000 (00:04 +0200)]
Fix parsing of dn line if WITHDN is non-nil

Function `ldap-search' errors out with `wrong-type-argument listp'
when called with WITHDN non-nil.
* lisp/net/ldap.el (ldap-search-internal): Parse the dn line
correctly so that `ldap-search' can grok it.  (Bug#64089)

18 months ago; Fix example in the Flymake manual
Eli Zaretskii [Sat, 17 Jun 2023 07:49:45 +0000 (10:49 +0300)]
; Fix example in the Flymake manual

* doc/misc/flymake.texi (An annotated example backend): Fix the
example.  (Bug#64070)

18 months agoCorrect conversion of strings to tree-sitter query syntax
Mattias Engdegård [Fri, 16 Jun 2023 10:37:07 +0000 (12:37 +0200)]
Correct conversion of strings to tree-sitter query syntax

The treesitter query syntax for string literals differs from that of
Elisp so we cannot just use the Lisp printer (bug#64017).

* src/treesit.c (treesit_query_string_string): New function.
(Ftreesit_pattern_expand): Use it.
* test/src/treesit-tests.el (treesit-query-api): Add test case.

18 months agoeshell-next-prompt: More precisely navigate to the prompt (bug#63748)
Tony Zorman [Sat, 3 Jun 2023 12:23:19 +0000 (14:23 +0200)]
eshell-next-prompt: More precisely navigate to the prompt (bug#63748)

* lisp/eshell/em-prompt.el (eshell-next-prompt): Navigate to the
current prompt more accurately by using text properties instead of
going to the beginning of the line.  This is important for multiline
prompts, as they don't necessarily start at the beginning of the
current line.

* test/lisp/eshell/em-prompt-tests.el
(em-prompt-test--with-multiline):
Execute a given body with a multiline prompt.

(em-prompt-test/next-previous-prompt-with):
(em-prompt-test/forward-backward-matching-input-with):
Helper functions for code reuse.

(em-prompt-test/forward-backward-matching-input):
(em-prompt-test/next-previous-prompt):
Rewrite in terms of the appropriate helper functions.

(em-prompt-test/next-previous-prompt-multiline):
(em-prompt-test/forward-backward-matching-input-multiline):
Add multiline variants of existing tests.

18 months ago; cperl-mode.el: Fix font-lock after yanking into POD
Harald Jörg [Thu, 15 Jun 2023 15:08:07 +0000 (17:08 +0200)]
; cperl-mode.el: Fix font-lock after yanking into POD

When extending the region to fontify for jit-lock-mode, make
sure we start fontifying at the beginning of a POD section
(Bug#64056).

18 months ago* doc/misc/calc.texi (Advanced Math Functions): Correct calc
Andreas Schwab [Thu, 15 Jun 2023 14:18:58 +0000 (16:18 +0200)]
* doc/misc/calc.texi (Advanced Math Functions): Correct calc
algebraic syntax.

18 months agoConsider 'dired-kill-when-opening-new-dired-buffer' in mouse clicks
Eli Zaretskii [Thu, 15 Jun 2023 13:12:24 +0000 (16:12 +0300)]
Consider 'dired-kill-when-opening-new-dired-buffer' in mouse clicks

* lisp/dired.el (dired-mouse-find-file): Honor the value of
'dired-kill-when-opening-new-dired-buffer'.  (Bug#64079)

18 months ago; Fix use-package.texi markup
Robert Pluim [Thu, 15 Jun 2023 10:23:29 +0000 (12:23 +0200)]
; Fix use-package.texi markup

* doc/misc/use-package.texi (Best practices): It's a subsection, not a
subheading.

18 months ago; * doc/misc/calc.texi (Advanced Math Functions): Fix last change.
Eli Zaretskii [Thu, 15 Jun 2023 08:38:32 +0000 (11:38 +0300)]
; * doc/misc/calc.texi (Advanced Math Functions): Fix last change.

18 months agoFix treesit-install-language-grammar (bug#63990)
Yuan Fu [Thu, 15 Jun 2023 08:22:53 +0000 (01:22 -0700)]
Fix treesit-install-language-grammar (bug#63990)

* lisp/treesit.el:
(treesit-install-language-grammar): When called non-interactively,
out-dir should default to default-out-dir.

18 months agoFix Gamma function definition in calc.texi
Eli Zaretskii [Thu, 15 Jun 2023 07:39:55 +0000 (10:39 +0300)]
Fix Gamma function definition in calc.texi

* doc/misc/calc.texi (Advanced Math Functions): Fix definition
of Gamma function.  Use @sup in @infoline lines.  (Bug#64077)

18 months agoFix subscripts in the Calc manual
Eli Zaretskii [Thu, 15 Jun 2023 07:08:55 +0000 (10:08 +0300)]
Fix subscripts in the Calc manual

* doc/misc/calc.texi (Musical Notes): Use @sub instead of TeX-only
'_' notation.  For the details, see the discussion in
https://lists.gnu.org/archive/html/emacs-devel/2023-06/msg00096.html.

18 months agoImprove documentation of 'declare' forms
Eli Zaretskii [Thu, 15 Jun 2023 06:28:26 +0000 (09:28 +0300)]
Improve documentation of 'declare' forms

* lisp/simple.el (read-extended-command-predicate): Mention the
'(declare completion ...' form in the doc string.

* doc/lispref/functions.texi (Declare Form): Clarify
'completion-predicate' and 'modes'; add cross-references.
(Bug#64045)

18 months agoAvoid using `(lambda ...) to build function values
Stefan Monnier [Wed, 14 Jun 2023 21:06:37 +0000 (17:06 -0400)]
Avoid using `(lambda ...) to build function values

* lisp/emacs-lisp/nadvice.el (advice-eval-interactive-spec): Avoid
`(lambda ...).

18 months agoHandle point not at EOB in minibuffer-choose-completion
Spencer Baugh [Mon, 24 Apr 2023 14:05:24 +0000 (10:05 -0400)]
Handle point not at EOB in minibuffer-choose-completion

Without this change, only the minibuffer contents before point are
cleared when a completion is chosen, which results in stray text when
point is in the middle of the minibuffer.

After this change, we heuristically decide either to clear the whole
buffer or only part of it, taking into account the location of point.

* lisp/minibuffer.el (minibuffer-completion-help): Use point when
calculating completion-base-affixes. (Bug#62700)

18 months ago; * src/lread.c (bytecode_from_rev_list): Avoid C++ comment.
Po Lu [Wed, 14 Jun 2023 05:54:53 +0000 (13:54 +0800)]
; * src/lread.c (bytecode_from_rev_list): Avoid C++ comment.

18 months agoImprove tree-sitter docs
Basil L. Contovounesios [Sun, 11 Jun 2023 14:19:28 +0000 (15:19 +0100)]
Improve tree-sitter docs

* doc/lispref/positions.texi (List Motion): Incorporate more
accurate description of treesit-defun-type-regexp from
'(elisp) Tree-sitter Major Modes', replacing that duplicate
entry (bug#64018).

* doc/lispref/parsing.texi (Parsing Program Source)
(Language Grammar, Using Parser, Retrieving Nodes)
(Accessing Node Information, Pattern Matching, Multiple Languages):
(Tree-sitter Major Modes):
* doc/lispref/modes.texi (Parser-based Font Lock): Improve wording,
grammar, punctuation, and markup.  Fix typos.
(Parser-based Indentation): Ditto.  Document indent rule presets
field-is, catch-all, nth-sibling, grand-parent, and
great-grand-parent.

* lisp/treesit.el (treesit-simple-indent-presets): Mention field-is,
catch-all, nth-sibling, grand-parent, great-grand-parent in
docstring.
(treesit-major-mode-setup, treesit-explore-mode): Improve
docstring/commentary grammar.

18 months agoFix some Texinfo markup in manuals
Basil L. Contovounesios [Mon, 12 Jun 2023 13:42:31 +0000 (14:42 +0100)]
Fix some Texinfo markup in manuals

* doc/emacs/macos.texi (Mac / GNUstep Customization):
* doc/lispintro/emacs-lisp-intro.texi (condition-case):
* doc/lispref/control.texi (pcase Macro):
* doc/lispref/debugging.texi (Internals of Debugger):
* doc/lispref/internals.texi (Building Emacs):
* doc/lispref/modes.texi (Imenu):
(Parser-based Font Lock, Parser-based Indentation):
* doc/lispref/parsing.texi (Retrieving Nodes, Tree-sitter C API):
* doc/lispref/processes.texi (Network, Bindat Types):
* doc/lispref/searching.texi (Rx Functions):
* doc/lispref/text.texi (Replacing):
* doc/lispref/windows.texi (Textual Scrolling):
* doc/misc/calc.texi (Killing From Stack, Customizing Calc):
* doc/misc/cc-mode.texi (Misc Font Locking, List Line-Up):
* doc/misc/ede.texi (ede-cpp-root-project)
(ede-proj-target-makefile, ede-sourcecode):
* doc/misc/ert.texi (Running Tests in Batch Mode):
* doc/misc/eudc.texi (Emacs-only Configuration, The Server Hotlist):
* doc/misc/eww.texi (Advanced):
* doc/misc/flymake.texi (Starting Flymake)
(Proc customization variables):
* doc/misc/tramp.texi (File name completion):
* doc/misc/gnus.texi (Summary Buffer Lines, Gnus Registry Setup)
(Fancy splitting to parent, Customizing the IMAP Connection)
(Mail Source Specifiers, Agent as Cache): Consistently mark up nil
and t as @code.  Also fix the markup and wording of some surrounding
text (bug#64016).

* doc/lispref/display.texi (SVG Images, Icons):
* doc/lispref/modes.texi (Customizing Keywords): Prefer ASCII
apostrophe over Unicode right single quotation mark.

18 months ago; * etc/NEWS: Backward compatibility with 'doc-view-svg-face'.
Eli Zaretskii [Tue, 13 Jun 2023 13:42:38 +0000 (16:42 +0300)]
; * etc/NEWS: Backward compatibility with 'doc-view-svg-face'.

18 months agoFix bol/bos anchors in tree-sitter :match regexps
Basil L. Contovounesios [Tue, 13 Jun 2023 12:45:08 +0000 (13:45 +0100)]
Fix bol/bos anchors in tree-sitter :match regexps

Further regexp fixes to follow separately (bug#64019#29).

* lisp/progmodes/c-ts-mode.el (c-ts-mode--font-lock-settings):
* lisp/progmodes/cmake-ts-mode.el
(cmake-ts-mode--font-lock-settings):
* lisp/progmodes/java-ts-mode.el (java-ts-mode--font-lock-settings):
* lisp/progmodes/js.el (js--treesit-font-lock-settings):
* lisp/progmodes/python.el (python--treesit-settings):
* lisp/progmodes/rust-ts-mode.el (rust-ts-mode--font-lock-settings):
* lisp/progmodes/sh-script.el (sh-mode--treesit-settings):
* lisp/progmodes/typescript-ts-mode.el
(typescript-ts-mode--font-lock-settings):
* test/src/treesit-tests.el (treesit-query-api): Anchor :match
regexps at beginning/end of string, not line.

18 months ago; * src/xdisp.c (syms_of_xdisp) <display-line-numbers>: Fix typo
Gregory Heytings [Tue, 13 Jun 2023 13:12:55 +0000 (13:12 +0000)]
; * src/xdisp.c (syms_of_xdisp) <display-line-numbers>: Fix typo

18 months agoReplace unneeded sprintfs with print
Robert Pluim [Mon, 5 Jun 2023 11:12:08 +0000 (13:12 +0200)]
Replace unneeded sprintfs with print

* admin/unidata/emoji-zwj.awk: Printing strings doesn't need sprintf,
so just use print and string concatenation.

18 months agoInsert timestamp when converting icalendar to org event
Robert Pluim [Tue, 13 Jun 2023 12:37:53 +0000 (14:37 +0200)]
Insert timestamp when converting icalendar to org event

* lisp/gnus/gnus-icalendar.el (gnus-icalendar--update-org-event):
Insert the timestamp even if the description is empty.  (Bug#64023)

18 months agoMove quoted lambda funarg check and expand coverage
Mattias Engdegård [Tue, 13 Jun 2023 12:08:11 +0000 (14:08 +0200)]
Move quoted lambda funarg check and expand coverage

* lisp/emacs-lisp/macroexp.el (macroexp--expand-all):
Move check for incorrectly quoted lambda arguments from here...
* lisp/emacs-lisp/bytecomp.el (byte-compile-form):
... to here, which should provide more detection opportunities.
Expand the set of functions for which this check is performed, now
also for some keyword arguments.

18 months ago; Fix last change in tex-mode.el
Eli Zaretskii [Tue, 13 Jun 2023 11:11:41 +0000 (14:11 +0300)]
; Fix last change in tex-mode.el

* lisp/textmodes/tex-mode.el (tex-cmd-doc-view): Remove the second
argument.  (Bug#63956)

18 months agoDon't feed the awk scripts into themselves
Robert Pluim [Mon, 5 Jun 2023 09:57:03 +0000 (11:57 +0200)]
Don't feed the awk scripts into themselves

* admin/unidata/Makefile.in (${unidir}/charscript.el,
${unidir}/emoji-zwj.el): Define variables for the required sources and
pass those to awk instead of $^, since the latter includes the awk
script itself.

18 months ago* lisp/subr.el (with-restriction): Tweak indent rule
Stefan Monnier [Tue, 13 Jun 2023 02:43:44 +0000 (22:43 -0400)]
* lisp/subr.el (with-restriction): Tweak indent rule

18 months ago* lisp/transient.el (transient--wrap-command): Use `letrec` and a closure
Stefan Monnier [Mon, 12 Jun 2023 17:25:08 +0000 (13:25 -0400)]
* lisp/transient.el (transient--wrap-command): Use `letrec` and a closure

18 months ago; Fix previous change
Robert Pluim [Mon, 12 Jun 2023 17:02:29 +0000 (19:02 +0200)]
; Fix previous change

* lisp/window.el (display-tex-shell-buffer-action): Fix default
value's type.  (Bug#63956)

18 months agoFix setting region in the minibuffer
Eli Zaretskii [Mon, 12 Jun 2023 15:47:04 +0000 (18:47 +0300)]
Fix setting region in the minibuffer

* lisp/minibuffer.el (minibuffer-beginning-of-buffer): Fix setting
region.  (Bug#64022)

18 months agoFix setting $DBUS_SESSION_BUS_ADDRESS after Emacs has started
Michael Albinus [Mon, 12 Jun 2023 10:45:38 +0000 (12:45 +0200)]
Fix setting $DBUS_SESSION_BUS_ADDRESS after Emacs has started

* doc/misc/dbus.texi (Alternative Buses): Explain using
$DBUS_SESSION_BUS_ADDRESS after Emacs has started.

* src/dbusbind.c (XD_DBUS_VALIDATE_BUS_ADDRESS): Use egetenv.

18 months ago; * lisp/emacs-lisp/macroexp.el (macroexp--expand-all): minor tweaks
Mattias Engdegård [Fri, 9 Jun 2023 08:10:49 +0000 (10:10 +0200)]
; * lisp/emacs-lisp/macroexp.el (macroexp--expand-all): minor tweaks

Don't lose `funcall` symbol position.  Remove outdated comment.

18 months agoDefine missing groups for ERC modules
F. Jason Park [Sat, 10 Jun 2023 06:34:58 +0000 (23:34 -0700)]
Define missing groups for ERC modules

* lisp/erc/erc-imenu.el (erc-imenu): Define group even though there
aren't any associated faces or user options because `imenu' is a
global module, and `define-erc-module' calls `define-minor-mode',
which needs a group for its mode variable.  This should have been
handled by bug#60954 but wasn't.
* lisp/erc/erc-sound.el (erc-sound): Move group definition above
module definition.
* lisp/erc/erc-spelling.el (erc-spelling): Define group.

18 months agoRevert "Add hook to regain nickname in ERC"
F. Jason Park [Fri, 9 Jun 2023 06:38:05 +0000 (23:38 -0700)]
Revert "Add hook to regain nickname in ERC"

This reverts commit 8c0c98268440b27a77faf30738dfd72c909bb33f.  The
functionality it introduced is likely being migrated to a
"regain"-specific local module to live in the library erc-services.el
alongside the existing `services' module.  Its scope will be expanded
to address common "regain" cases requiring NickServ.  This commit is
being reverted to prevent any confusion that might arise from users
encountering the old interface while the new one is being hashed out
on the tracker.