The 'completion-regexp-list' optimization in
completion--flex-all-completions-1, a cheap pre-filter via a trivial
regexp, performs very poorly for longer patterns and strings, so drop
it. That alone recovers fairly decent performance for the flex
completion when compared to the 'hotfuzz' point of reference.
We then recover the cheap rejection with an O(N+M) pre-check in the
Fcompletion__flex_cost_gotoh C scorer. This kicks in the common case
(completion-ignore-case is nil) and pays off especially when the table
is already a list and 'all-completions' needn't cons.
See:
https://lists.gnu.org/archive/html/emacs-devel/2026-04/msg01081.htmlhttps://lists.gnu.org/archive/html/emacs-devel/2026-05/msg00519.html
* lisp/minibuffer.el (completion--flex-all-completions-1): Remove
regexp pre-filter.
* src/minibuf.c (Fcompletion__flex_cost_gotoh): Add subsequence
pre-check.
* lisp/progmodes/compile.el
(compilation-error-regexp-alist-alist): Put 'rust' before 'gnu'
to avoid a mismatch since the " |" has become optional (bug#81075).
Copyright-paperwork-exempt: yes
* lisp/textmodes/markdown-ts-mode.el (markdown-ts-mode-maybe):
New function.
(auto-mode-alist): Bind ".md", ".markdown", and ".mdx" to
'markdown-ts-mode-maybe' instead of 'markdown-ts-mode'.
* etc/NEWS: Update the 'markdown-ts-mode' entry.
* lisp/disp-table.el (prettify-special-glyphs-mode): New mode to
display nicer special glyphs.
(special-glyphs): New face for displaying special glyphs when
the minor mode is active.
(prettify-special-glyphs-saved-truncation)
(prettify-special-glyphs-saved-continuation): Internal variables
to save previous special glyphs.
* etc/NEWS: Announce the change. (Bug#80628)
More context in Bug#80786 and:
https://lists.gnu.org/archive/html/emacs-orgmode/2026-03/msg00286.html
`icalendar-recur' as a type name for RRULE values was confusing and made
the accessors for this type difficult to discover, because `icalendar-recur-'
is also used as a prefix in icalendar-recur.el. This change renames the
`icalendar-recur' type to `icalendar-rrule-value' and renames the
accessor functions for these values appropriately.
* lisp/calendar/icalendar-parser.el: Rename symbols as follows:
(icalendar-recur): `icalendar-rrule-value'
(icalendar-read-recur-rule-part): `icalendar-read-rrule-part'
(icalendar-print-recur-rule-part): `icalendar-print-rrule-part'
(icalendar-recur-rule-part): `icalendar-rrule-part'
(icalendar-read-recur): `icalendar-read-rrule-value'
(icalendar-print-recur): `icalendar-print-rrule-value'
(icalendar--recur-value-types): `icalendar--rrule-value-types'
(icalendar-recur-value-p): `icalendar-rrule-value-p'
(icalendar-recur-freq): `icalendar-rrule-freq'
(icalendar-recur-interval-size): `icalendar-rrule-interval-size'
(icalendar-recur-until): `icalendar-rrule-until'
(icalendar-recur-count): `icalendar-rrule-count'
(icalendar-recur-weekstart): `icalendar-rrule-weekstart'
(icalendar-recur-by*): `icalendar-rrule-by*'.
(icalendar-rrule):
(icalendar-index-insert):
(icalendar-index-get): Update references.
* lisp/calendar/icalendar-recur.el (icalendar-recur-find-interval):
(icalendar-recur-nth-interval):
(icalendar-recur-next-interval):
(icalendar-recur-previous-interval):
(icalendar-recur-refine-from-clauses):
(icalendar-recur-recurrences-in-interval):
(icalendar-recur-recurrences-in-window):
(icalendar-recur-recurrences-to-count):
(icalendar-recur-tz-observance-on): Update references.
* lisp/calendar/diary-icalendar.el: Update references.
* lisp/calendar/icalendar-shortdoc.el (icalendar): Update shortdoc examples.
* lisp/gnus/gnus-icalendar.el: Update references.
* test/lisp/calendar/diary-icalendar-tests.el:
* test/lisp/calendar/icalendar-parser-tests.el:
* test/lisp/calendar/icalendar-recur-tests.el: Update references in tests.
* lisp/gnus/gnus-msg.el (gnus-inews-make-draft-meta-information):
Escape the group name with prin1-to-string to prevent arbitrary
Lisp injection through crafted group names. The unescaped group
name was embedded into a Lisp-readable string, parsed back with
read-from-string in gnus-draft-setup, and eventually eval'd via
message-do-actions, allowing code execution when a draft was sent.
With Emacs 31 the old_buffer slot of a window gets overwritten
with the buffer unshown in that window when that window is
deleted. Fset_window_configuration triggers that when calling
delete_all_child_windows. If a window configuration gets saved
and restored in one and the same redisplay cycle, the change
time stamps of the window and its frame will be equal and
'window-buffer-change-functions' may wrongly decide that the
window's buffer has not changed because its buffer and
old_buffer slots refer to the same buffer (Bug#81097). Fix that
by saving and restoring the old_buffer slot.
* src/window.c (struct saved_window): Add 'old_buffer' slot.
(Fset_window_configuration): Restore old_buffer slot.
(save_window_save): Save old_buffer slot.
* lisp/isearch.el (lazy-highlight, lazy-highlight-initial-delay)
(lazy-highlight-buffer, isearch-lazy-highlight, isearch-forward):
* lisp/replace.el (query-replace, query-replace-lazy-highlight)
(query-replace, query-replace-regexp): Doc fixes.
* doc/emacs/search.texi (Search Customizations): Document
'lazy-highlight-buffer' and 'lazy-highlight-buffer-max-at-a-time'.
Use @vtable to avoid the need of indexing each variable
separately.
* src/gtkutil.c (xg_frame_set_size_and_position): Remove a
gtk_window_resize call which used a wrong value type
(GdkX11Window instead of GtkWindow). The original motivation
for that line seems to be fixed by later changes (bug#80662).
* lisp/net/shr.el (shr-outline-search):
Don't check for the beginning of the line.
Suggested by Omar Antolín Camarena <omar@im.unam.mx>.
Confirmed by Rahguzar <rahguzar@mailbox.org>.
* lisp/auth-source.el (auth-source-backend-parse): Use `run-hook-wrapped'.
Suggested by Augusto Stoffel <arstoffel@gmail.com>.
Transform a warning into a debug message.
No reason not to. Tested with gfm-view-mode and markdown-ts-mode
* lisp/progmodes/eglot.el (eglot-client-capabilities): Annouce
markdown support for completion docs.
* lisp/textmodes/markdown-ts-mode.el
(markdown-ts--fontify-delimiter): When `markdown-ts-hide-markup'
is enabled in `markdown-ts-view-mode', also hide the whole line
containing a `fenced_code_block_delimiter' (including its
terminating newline) so Eldoc/LSP markdown snippets render
without stray blank lines around the code block. Scoped to
view-mode and to fenced delimiters on purpose: the same handler
is shared by inline delimiters (emphasis, code span, link
brackets) where munching surrounding whitespace would collapse
word separators, and tuning rendering for
hide-markup-while-editing is not a goal.
The grammar reports leading spaces as part of the atx_heading "marker"
and we cannot use the length of the marker as a result. Instead, count
the number of consecutive # after any blanks to determine its "level."
* lisp/textmodes/markdown-ts-mode.el
(markdown-ts--fontify-atx-heading): Count the octothorpes rather
than using the length of the marker node's text.
Do not assume every command run in
'markdown-ts--run-command-in-code-block' produces output that needs to
be merged from the temp/work buffer into the source buffer. One example
is 'xref-find-definitions', the temp buffer of which is unrelated to the
source buffer.
* lisp/textmodes/markdown-ts-mode.el
(markdown-ts-code-block-commands): Add 'complete-symbol'.
(markdown-ts-code-block-ignore-output-commands): New defvar.
(markdown-ts--run-command-in-code-block): Ignore command output
when necessary.
* lisp/erc/erc-stamp.el (erc-insert-timestamp-right): Explicitly add
face to right-hand stamp's `display' margin string. Commit d24b10ca
"Introduce 'margin' face for window margin background" did away with the
"fall-through" behavior in which a margin spec's string that lacks its
own face property inherited whatever the associated `display' char
happened to have. (Bug#80693)
;; The old language in "(elisp) Display Margins" said "if the
;; string to be displayed in the margin doesn't specify a face, its
;; face is determined using the same rules and priorities as it is
;; for strings displayed in the text area (see Displaying Faces),"
;; and that "if this results in undesirable 'leaking' of faces into
;; the margin, make sure the string has an explicit face specified
;; for it." It seems ERC and likely more than a few other packages
;; never came to heed this guidance and have erroneously depended
;; on such behavior for years if not decades.
;;
;; * test/lisp/erc/resources/fill/snapshots/merge-01-start.eld:
;; * test/lisp/erc/resources/fill/snapshots/merge-02-right.eld:
;; * test/lisp/erc/resources/fill/snapshots/merge-wrap-01.eld:
;; * test/lisp/erc/resources/fill/snapshots/merge-wrap-indicator-pre-01.eld:
;; * test/lisp/erc/resources/fill/snapshots/monospace-01-start.eld:
;; * test/lisp/erc/resources/fill/snapshots/monospace-02-right.eld:
;; * test/lisp/erc/resources/fill/snapshots/monospace-03-left.eld:
;; * test/lisp/erc/resources/fill/snapshots/monospace-04-reset.eld:
;; * test/lisp/erc/resources/fill/snapshots/spacing-01-mono.eld: Update
;; snapshot.
I ran into the issue described in the comment with the current
code in project-find-file-in and project-find-dir, when using
'C-x p p' to switch between projects.
* lisp/vc/vc-hooks.el (vc-refresh-state): When calling into the
backend, override any let-bindings of default-directory.
* lisp/net/newst-treeview.el
(newsticker--treeview-get-selected-item): If an item is already
selected, use it. (Bug#80972)
Copyright-paperwork-exempt: yes
All tests now use 'jsonrpc--with-python-fixture' with a Python3
subprocess instead of the in-Emacs TCP server. Changed the "harakiri"
method to be a request instead of a notification for to reduce chance of
"Sentinel hasn't run" warning.
The two in-Emacs-RPC-specific error tests ('errors-with--32601' and
'signals-an--32603-JSONRPC-error') are dropped with the fixture itself,
as the error paths they exercise are internal to the Emacs Lisp
dispatcher and have no direct Python equivalent. They will have to be
re-done later on in other form.
* test/lisp/jsonrpc-resources/server-emacsrpc.py: New file.
* test/lisp/jsonrpc-resources/server-anxious-nested.py: Use new
harakiri.
* test/lisp/jsonrpc-resources/server-emacsrpc.py: Use new harakiri.
* test/lisp/jsonrpc-resources/server-harakiri.py: Use new harakiri.
* test/lisp/jsonrpc-resources/server-remote-during-sync-1.py: Use new
harakiri.
* test/lisp/jsonrpc-resources/server-remote-during-sync-2.py: Use new
harakiri.
* test/lisp/jsonrpc-resources/server-remote-error.py: Use new harakiri.
* test/lisp/jsonrpc-resources/common.py (harakiri): New definition.
* test/lisp/jsonrpc-tests.el
(jsonrpc--with-python-fixture): Rework, move up.
(jsonrpc-connection-ready-p): Move up.
(jsonrpc--call-with-emacsrpc-fixture)
(jsonrpc--with-emacsrpc-fixture)
(errors-with--32601)
(signals-an--32603-JSONRPC-error): Remove.
(returns-3, times-out, doesnt-time-out, stretching-it-but-works)
(deferred-action-toolate, deferred-action-intime)
(deferred-action-complex-tests): Migrate to Python fixture.
(scontrol-remote-during-sync-1, scontrol-remote-during-sync-2)
(scontrol-anxious-nested, scontrol-remote-error)
(shutdown-clean-after-notification): Tweak.
The fringe indicator uses a custom lightning-bolt bitmap, an alternative
to the margin indicator on GUI frames. It is non-interactive, however.
* lisp/progmodes/eglot.el (eglot--fringe-action): New fringe bitmap.
(eglot-code-action-indications): Add 'left-fringe' to default value
and to docstring. Update incompatibility note.
(eglot-code-action-suggestion): Handle 'left-fringe' indication.
* lisp/calc/calc-embed.el (calc-embedded-update): Use
'buffer-substring' to better track the string representation of
the formula when it is being edited. Suggested by
gnu@publik.slmail.me. Also, update commentary. (Bug#80901)