* lisp/emacs-lisp/package.el (package--removable-packages):
Handle the fact that 'package--dependencies' doesn't return the
package itself as a dependency, so we have to check
'package-selected-packages' separately. Also fix the way we
check the return value of 'package--dependencies', keeping in
mind that the value is an alist. (Bug#80907)
This is a partial reversion of 931e04a34b.
* lisp/emacs-lisp/package.el (package--builtin-alist): Add a
function that loads 'finder-inf', which in turn will populate
'package--builtins', if necessary, caching the result.
(package--upgradeable-packages, describe-package-1)
(package-menu--refresh, package--mapc, package-get-descriptor):
Use the function instead of the variable.
If a host parser has some ranges, and an embedded parser also
has some ranges, the final range used by the embedded parser
should be an intersection of the two. This patch adds this
logic.
* lisp/treesit.el (treesit--range-verbose): New variable.
(treesit--intersect-ranges):
(treesit--set-embed-ranges): New function.
(treesit--update-ranges-non-local):
(treesit--update-ranges-local): Use the new functions.
* test/src/treesit-tests.el:
(treesit-intersect-ranges): New test.
* lisp/register.el (register--get-method-type): Refine the cl-generic hack
yet a but further.
* test/lisp/register-tests.el (register--jumpable-p): Fix the test.
* lisp/progmodes/compile.el (compilation-search-extra-path): New
option (bug#80279).
(compilation-start): Use it.
(compilation-search-path):
* doc/emacs/building.texi:
* etc/NEWS: Document it, and also compilation-search-path.
* lisp/vc/vc-rcs.el (vc-rcs-register): Filter out directories from
FILES.
(vc-rcs-rename-file): Support OLD being a directory.
* test/lisp/vc/vc-tests/vc-tests.el (vc-test--rename-file)
(vc-test--rename-directory): Re-enable these tests for RCS.
(vc-test--rename-directory): Disable 'yes-or-no-p' questions that
RCS asks when it needs to create the RCS/ subdirectory: this lets
the test run without user interaction.
* lisp/vc/vc.el (vc-delete-file): In the delete-file branch,
narrow the binding of default-directory to cover only the call
into the backend.
Suggested by Aaron L. Zeng <azeng@janestreet.com> in bug#80875.
* lisp/emacs-lisp/package.el (package-get-descriptor): Use
'assq' to look up element in package alists instead of iterative
over them manually. This was initially not possible, since we
merged all alists into one, which would require using a consing
function like 'map-merge-with' to look up all package descriptor
objects we want to consider in a single 'assq' call. As we
ended up not merging lists, we can assume that there are no
duplicate keys in the alists, making the efficient 'assq'
viable.
* lisp/emacs-lisp/package.el (package--compatible-packages):
Drop 'package-read-all-archive-contents' call, as
'package--build-compatibility-table' will load the archive
contents on demand via 'package--mapc' anyway. (Bug#80902)
* lisp/emacs-lisp/package.el (package--builtin-alist):
(package--upgradeable-packages, package--mapc)
(package-get-descriptor):
* lisp/emacs-lisp/package.el (package--builtin-alist): Replace
function with constant, as the result of the function is always
the same within an Emacs session, since the set of built-in
packages don't change during execution.
(package--upgradeable-packages, package--mapc)
(package-get-descriptor): Use variable instead of function.
(package-menu--refresh, describe-package-1): Lookup desc in
alist instead of calling 'package--from-builtin'.
(Bug#80902)
* lisp/treesit.el (treesit--range-start):
(treesit--range-end):
(treesit--flatten-ranges): New helpers.
(treesit-query-range):
(treesit-query-range-by-language): Don't flatten the ranges
returned by each range-fn.
(treesit--update-ranges-non-local):
(treesit--update-ranges-local): Handle the case where the range
is a complicated ((START . END)...).
* test/src/treesit-tests.el (treesit-range-helper): New test.
* src/term.c (append_glyph, append_composite_glyph)
(append_glyphless_glyph): Account for the right-border glyph
when computing the end glyph of TEXT_AREA. (Bug#80900)
This code may be called from within the loop in process_special_events
which assumed kbd_fetch_ptr remains unchanged. This caused a buffer
underflow which resulted in the entire kbd buffer being replayed.
* src/xterm.c (x_delete_selection_requests): Simply clear deleted
events rather than rotating the kbd buffer.
* lisp/emacs-lisp/subr-x.el (work-buffer--release): Make sure the
buffer is not left read-only. Clarify potential limitations to
the cleanup performed, especially w.r.t indirect buffers.
Don't bother binding `deactivate-mark` since that variable is buffer-local
nowadays anyway.
`syntax-propertize` currently doesn't support propertizing only
parts of a buffer. Maybe we should improve it, maybe via
something like `font-lock-dont-widen` or the `syntax-ppss` support for
narrowing, but in the mean time, teach comint to avoid holes in
the propertization.
* lisp/comint.el (comint--dummy-fontify-syntax): New function.
(comint--fontify-input-fontify-region): Use it to silence the
new "Cannot syntax-propertize" message in `syntax.el`.
Also, refine args to reflect the fact that it's an advice.
`overriding-text-conversion-style' isn't defined on all platforms, in
which case this is a no-op; there's nothing that has to be suspended.
Re <id:86zf2uc2ve.fsf@gnu.org>.
* lisp/vc/vc-hg.el (vc-hg-after-dir-status): Rewrite to handle
renames where the "R" line comes arbitrarily later in the
output.
* test/lisp/vc/vc-hg-tests.el
(vc-hg-test--after-dir-status-expect): New function.
(vc-hg-after-dir-status): New test.