Michael Albinus [Sun, 13 Oct 2024 14:01:38 +0000 (16:01 +0200)]
* doc/emacs/mini.texi (Passwords): Mention password visibility.
Michael Albinus [Wed, 25 Sep 2024 17:43:07 +0000 (19:43 +0200)]
Fix Tramp shortdoc integration
* lisp/net/tramp-integration.el (tramp-syntax): Declare.
(shortdoc): Check, that Tramp has `default' syntax.
Juri Linkov [Wed, 25 Sep 2024 17:14:12 +0000 (20:14 +0300)]
* lisp/imenu.el (imenu-flatten): More limitations in docstring (bug#73117)
Sean Whitton [Wed, 25 Sep 2024 15:02:53 +0000 (16:02 +0100)]
remember-data-file: Don't unconditionally call set-visited-file-name
* lisp/textmodes/remember.el (remember-data-file): Don't
unconditionally call set-visited-file-name.
Thomas Voss [Wed, 25 Sep 2024 00:17:49 +0000 (02:17 +0200)]
Align columns in which-key with wide characters properly
In the case that a character takes up multple columns (such as
`…' when used as a truncation character), make sure that the
columns are still aligned properly.
* lisp/which-key.el (which-key--pad-column): Use `string-width'
instead of `length'. (Bug#73463)
Copyright-paperwork-exempt: yes
Roland Winkler [Wed, 25 Sep 2024 04:14:27 +0000 (23:14 -0500)]
bibtex-mode: fix patch bibtex validation for non-file buffers
Robert Pluim [Tue, 24 Sep 2024 15:03:49 +0000 (17:03 +0200)]
Document 'buttonize-region' in manual
It was added in emacs-29, but never added to the lisp reference
manual.
* doc/lispref/display.texi (Making Buttons): Document
'buttonize-region'.
Robert Pluim [Tue, 24 Sep 2024 15:02:21 +0000 (17:02 +0200)]
; * lisp/yank-media.el (yank-media-handler): Fix docstring typo.
Tassilo Horn [Mon, 23 Sep 2024 16:50:29 +0000 (18:50 +0200)]
Use black-on-white by default for doc-view-svg-face.
* lisp/doc-view.el (doc-view-svg-face): Define black on white as
default value instead of using the current theme's values.
* etc/NEWS: Adjust entry for doc-view-svg-face.
Dmitry Gutov [Mon, 23 Sep 2024 18:35:00 +0000 (21:35 +0300)]
etags-regen-file-extensions: Enable for more extensions
* lisp/progmodes/etags-regen.el (etags-regen-file-extensions):
Add more extensions, but remove "a". From the ones recognized by
etags, also omit "t", "ml", "l", "def" and "inc", see
https://lists.gnu.org/archive/html/emacs-devel/2024-09/msg00735.html.
(etags-regen--all-files): Use 'string-match-p' for performance.
Bind 'case-fold-search' to t to match extensions in any case.
Eli Zaretskii [Mon, 23 Sep 2024 14:13:31 +0000 (17:13 +0300)]
; Fix last change
* doc/lispref/lists.texi (Building Lists):
* src/fns.c (Fappend): Fix last change (bug#73427). Suggested by
Mattias Engdegård <mattias.engdegard@gmail.com>.
Eli Zaretskii [Mon, 23 Sep 2024 11:41:34 +0000 (14:41 +0300)]
; Improve documentation of 'append'
* doc/lispref/lists.texi (Building Lists):
* src/fns.c (Fappend): Improve documentation of 'append'. (Bug#73427)
Stephen Berman [Sat, 21 Sep 2024 20:23:11 +0000 (22:23 +0200)]
Update and improve UI of sql-read-product (bug#73412)
* lisp/progmodes/sql.el (sql-read-product): In invocation of
completing-read use format-prompt and make deprecated argument
INITIAL-INPUT nil.
(sql-set-product, sql-product-interactive): In invocation of
sql-read-product adjust prompt to use of format-prompt.
Philip Kaludercic [Thu, 19 Sep 2024 20:27:26 +0000 (22:27 +0200)]
Insert correct commit data into VC package descriptions
* lisp/emacs-lisp/package-vc.el (package-vc-commit): Rename
argument from PKG to PKG-DESC.
(package-vc--generate-description-file): Update the "extras"
section of the package description with the revision string at
generation time.
Stefan Kangas [Sat, 21 Sep 2024 11:25:00 +0000 (13:25 +0200)]
Document reporting security issues in user manual
* doc/emacs/trouble.texi (Bugs): Document how to report important
security issues.
Stefan Kangas [Sat, 21 Sep 2024 11:23:35 +0000 (13:23 +0200)]
* BUGS: Minor copy edit.
Scott Bell [Fri, 20 Sep 2024 21:16:52 +0000 (14:16 -0700)]
; Always set 'emoji--insert-buffer'
* lisp/international/emoji.el (emoji-list): Always set insert buffer.
(Bug#73390)
Copyright-paperwork-exempt: yes
Stefan Monnier [Thu, 19 Sep 2024 15:50:26 +0000 (11:50 -0400)]
Fix font-lock of last character before EOB under 'whitespace-mode'
* lisp/whitespace.el (whitespace-color-on): Don't use OVERRIDE in
font-lock-keywords; instead, use 'prepend' in the call to
'font-lock-add-keywords'. (Bug#73332)
Eli Zaretskii [Sat, 21 Sep 2024 10:41:21 +0000 (13:41 +0300)]
Fix 'whitespace-mode' with 'missing-newline-at-eof'
* lisp/whitespace.el (whitespace-post-command-hook): Refontify
when point moves if 'missing-newline-at-eof' is in
'whitespace-active-style'. (Bug#73332)
Eli Zaretskii [Sat, 21 Sep 2024 09:26:24 +0000 (12:26 +0300)]
Fix 'replace-regexp' in WDired
* src/search.c (Freplace_match): Revert the search.c part of the
change from Apr 7, 2024, which aims to fix bug#65451, but causes
bug#73018. Do not merge to master.
* test/src/editfns-tests.el
(editfns-tests--before/after-change-functions): Expect this test
to fail.
Peter Oliver [Wed, 4 Sep 2024 11:12:50 +0000 (12:12 +0100)]
Disable xwidgets with recent webkitgtk versions (Bug#66068)
* configure.ac: Accept only webkit2gtk-4.* versions less than 2.41.92.
Eli Zaretskii [Sat, 21 Sep 2024 07:21:21 +0000 (10:21 +0300)]
; * lisp/editorconfig.el (editorconfig-indentation-alist): Doc fix.
Yuan Fu [Sat, 21 Sep 2024 03:40:26 +0000 (20:40 -0700)]
Fix treesit--merge-ranges (bug#73324)
* lisp/treesit.el (treesit--merge-ranges): Make sure that old
ranges that intersects with START-END are actually discarded.
* test/src/treesit-tests.el (treesit-range-merge): New test.
Stefan Kangas [Sat, 21 Sep 2024 00:19:53 +0000 (02:19 +0200)]
Fix midnight-mode documentation
* lisp/midnight.el (Commentary): Document that 'midnight-mode' should be
enabled using the function, instead of by merely loading the library.
In Emacs 31, doing the latter will no longer work. (Bug#73291)
Stefan Kangas [Sat, 21 Sep 2024 00:16:40 +0000 (02:16 +0200)]
; Fix my email address
Stefan Monnier [Fri, 20 Sep 2024 18:58:45 +0000 (14:58 -0400)]
editorconfig.el: Fix too naive sync from upstream
* lisp/editorconfig.el (editorconfig--get-indentation-nxml-mode):
New function.
(editorconfig-indentation-alist): Use it to fix bug#73359.
Eli Zaretskii [Fri, 20 Sep 2024 18:50:12 +0000 (21:50 +0300)]
; * etc/NEWS: Announce 'doc-view-mpdf--use-svg'.
Stefan Monnier [Fri, 20 Sep 2024 18:42:22 +0000 (14:42 -0400)]
* lisp/progmodes/eglot.el (eglot--signal-textDocument/didOpen): Fix bug#72696
Po Lu [Fri, 20 Sep 2024 14:29:53 +0000 (22:29 +0800)]
Disable fontset-related workaround on non-Android systems
* src/fontset.c (fontset_find_font) [!HAVE_ANDROID]: Don't
refuse to cache font objects whose registries do not agree with
the font specs. (bug#73363)
Do not merge to master.
Sean Whitton [Fri, 20 Sep 2024 13:39:53 +0000 (14:39 +0100)]
etags-regen-file-extensions: Add .pm
* lisp/progmodes/etags-regen.el (etags-regen-file-extensions):
Add .pm.
Andrea Corallo [Thu, 19 Sep 2024 08:27:21 +0000 (10:27 +0200)]
* src/treesit.c (treesit_debug_print_parser_list): Fix compiler warning.
Robert Pluim [Wed, 18 Sep 2024 15:19:28 +0000 (17:19 +0200)]
Type-check argument to network-lookup-address-info
* src/process.c (Fnetwork_lookup_address_info): Check that the
"name" argument is a string, and mention 'puny-encode-domain'.
(Bug#73337)
Eli Zaretskii [Thu, 19 Sep 2024 05:20:04 +0000 (08:20 +0300)]
; Improve doc strings of options related to numbered backups
* lisp/files.el (version-control, dired-kept-versions)
(delete-old-versions, kept-old-versions, kept-new-versions): Doc
fixes.
Yuan Fu [Wed, 18 Sep 2024 04:17:13 +0000 (21:17 -0700)]
Conservative heuristic for tree-sitter parser ranges (bug#73324)
* src/treesit.c (treesit_sync_visible_region): If the parser's original
ranges don't overlap with visible region, give it a zero range, rather
than don't set any range.
* test/src/treesit-tests.el (treesit-range-fixup-after-edit): Test new
behavior.
Yuan Fu [Wed, 18 Sep 2024 03:53:36 +0000 (20:53 -0700)]
; Fix treesit.c printing
* src/treesit.c (treesit_debug_print_parser_list): Use PRIuPTR so 32bit
systems compile without warnings.
Eli Zaretskii [Tue, 17 Sep 2024 13:18:08 +0000 (16:18 +0300)]
; * admin/notes/unicode: Need to run textsec-tests (bug#73312).
Mattias Engdegård [Tue, 17 Sep 2024 11:07:01 +0000 (13:07 +0200)]
Re-enable GC mark trace buffer by default
Enable GC_REMEMBER_LAST_MARKED by default (it was disabled in Emacs 29)
to make it easier to debug difficult-to-reproduce GC problems
encountered by users. This increases GC costs by about 5 %, which can
be avoided by turning the mark trace buffer back off using the new
--disable-gc-mark-trace option.
See discussion at
https://lists.gnu.org/archive/html/emacs-devel/2024-09/msg00240.html
* configure.ac (--disable-gc-mark-trace): New config option.
* etc/NEWS: Mention it.
* src/alloc.c: Enable it by default and avoid a compiler warning.
Po Lu [Sun, 15 Sep 2024 08:28:38 +0000 (16:28 +0800)]
; * src/haiku_support.cc: Correct last change.
Yuan Fu [Sun, 15 Sep 2024 07:42:41 +0000 (00:42 -0700)]
; Add even more tests for previous commit
* test/src/treesit-tests.el:
(treesit-range-fixup-after-edit): Make the tests trickier.
Yuan Fu [Sun, 15 Sep 2024 07:24:03 +0000 (00:24 -0700)]
Fix treesit_sync_visible_region's range fixup code (bug#73264)
new_ranges_head
|
v
( )->( )->( )->( )->( )
^ ^
| |
| lisp_ranges (loop head)
|
prev_cons -> set cdr to nil to cut of the rest
result:
( )->( )
* src/treesit.c (treesit_sync_visible_region): Cut off this cons and the
rest, not set the current range's end to nil.
* test/src/treesit-tests.el:
(treesit-range-fixup-after-edit): Add tests for all cases.
Eli Zaretskii [Sun, 15 Sep 2024 04:55:20 +0000 (07:55 +0300)]
; * etc/PROBLEMS: Fix last change (bug#73207).
Po Lu [Sun, 15 Sep 2024 01:01:25 +0000 (09:01 +0800)]
Document unavailability of frame geometry on Wayland
* etc/PROBLEMS (Runtime problems specific to PGTK build):
Document that frame-edges and company are liable not to return
valid coordinates. (bug#73207)
Po Lu [Sun, 15 Sep 2024 00:52:46 +0000 (08:52 +0800)]
Port to Haiku R1/beta5
* src/haiku_support.cc (keysym_from_raw_char): Use revised names
for B_HANGUL and B_HANGUL_HANJA.
Yuan Fu [Sat, 14 Sep 2024 18:07:28 +0000 (11:07 -0700)]
Fix c++-ts-mode font-lock for latest c++ grammar (bug#73191)
* lisp/progmodes/c-ts-mode.el:
(c-ts-mode--keywords): Add "thread_local" keyword.
(c-ts-mode--test-virtual-named-p): New function.
(c-ts-mode--font-lock-settings): Use named/anonymous "virtual" depending
on the grammar.
Jonas Bernoulli [Sat, 14 Sep 2024 17:23:40 +0000 (19:23 +0200)]
; Set Transient's version and add admin/MAINTAINERS entry
* admin/MAINTAINERS: Add entry for externally maintained Transient
package.
* doc/misc/transient.texi: Bump version strings.
* lisp/transient.el: Bump version in Version header.
* lisp/transient.el (transient-version): New constant.
Stefan Kangas [Sat, 14 Sep 2024 15:34:09 +0000 (17:34 +0200)]
* admin/update-copyright: Print reminder to do manual updates.
Stefan Kangas [Sat, 14 Sep 2024 15:19:23 +0000 (17:19 +0200)]
* admin/notes/years: Update.
Stefan Kangas [Sat, 14 Sep 2024 14:34:11 +0000 (16:34 +0200)]
* etc/TODO: New item "support indentation guides".
Ref:
https://lists.gnu.org/r/emacs-devel/2024-07/msg01062.html
Stephen Berman [Sat, 14 Sep 2024 10:42:49 +0000 (12:42 +0200)]
Fix regression in widget-move (bug#72995)
* lisp/wid-edit.el (widget-move): Avoid advancing point only if it
is at the start of a widget at BOB.
* test/lisp/wid-edit-tests.el (widget-test-widget-move-bug72995): New test.
Eli Zaretskii [Sat, 14 Sep 2024 09:33:36 +0000 (12:33 +0300)]
; * lisp/cus-edit.el (setopt): Doc fix. (Bug#73098)
Eli Zaretskii [Sat, 14 Sep 2024 09:26:54 +0000 (12:26 +0300)]
; * lisp/minibuffer.el (completion-pcm--merge-completions): Fix comments.
Spencer Baugh [Mon, 26 Aug 2024 14:12:51 +0000 (10:12 -0400)]
Correctly include fixed strings before a prefix wildcard in PCM
In
03ac16ece40ba3e3ba805d6a61cc457d84bf3792 I fixed a bug with the
PCM implementation of substring completion, relating to the handling
of PCM wildcards.
However, this fix was incomplete. This change completes the fix by
also including a fixed string if it appears before a 'prefix'
wildcard, even if 'try-completion' doesn't discover that fixed
string grows to a unique completion.
I discovered this bug while working on enhancements to PCM
completion related to 'completion-pcm-leading-wildcard'.
* lisp/minibuffer.el (completion-pcm--merge-completions): Include
fixed strings before 'prefix wildcard. (Bug#72819)
* test/lisp/minibuffer-tests.el (completion-substring-test-5): Add a
test for this behavior.
Eli Zaretskii [Sat, 14 Sep 2024 09:02:56 +0000 (12:02 +0300)]
; * lisp/treesit.el (treesit-major-mode-setup): Doc fix.
Eli Zaretskii [Sat, 14 Sep 2024 08:55:08 +0000 (11:55 +0300)]
; Improve documentation of 'easy-menu-define'
* doc/lispref/keymaps.texi (Easy Menu):
* lisp/emacs-lisp/easymenu.el (easy-menu-define): Document that
SYMBOL is also defined as a variable. (Bug#73108)
Yuan Fu [Sat, 14 Sep 2024 07:46:05 +0000 (00:46 -0700)]
Set treesit-primary-parser for c and elixir ts mode
For buffers with multiple parsers, it's important to set this variable
so font-lock invalidation works smoothly.
* lisp/progmodes/c-ts-mode.el (c-ts-mode): Set treesit-primary-parser.
* lisp/progmodes/elixir-ts-mode.el (elixir-ts-mode): Set
treesit-primary-parser.
Yuan Fu [Sat, 14 Sep 2024 07:19:47 +0000 (00:19 -0700)]
; Minor doc fix in treesit.el
* lisp/treesit.el (treesit-outline-search): Mention parameters.
(treesit-major-mode-setup): Mention outline setup.
Yuan Fu [Sat, 14 Sep 2024 04:42:17 +0000 (21:42 -0700)]
Fix range handling so it works for multibyte buffer (bug#73204)
Here by multibyte buffer I mean buffer that includes non-ASCII
characters.
The problem is illustrated by this comment, which I copied from the
source:
======================================================================
(ref:bytepos-range-pitfall) Suppose we have the following buffer
content ([ ] is a unibyte char, [ ] is a multibyte char):
[a][b][c][d][e][ f ]
and the following ranges (denoted by braces):
[a][b][c][d][e][ f ]
{ }{ }
So far so good, now user deletes a unibyte char at the beginning:
[b][c][d][e][ f ]
{ }{ }
Oops, now our range cuts into the multibyte char, bad!
======================================================================
* src/treesit.c (treesit_debug_print_parser_list): Minor fix.
(treesit_sync_visible_region): Change the way we fixup ranges, instead
of using the bytepos ranges from tree-sitter, we use the cached lisp
charpos ranges.
(treesit_make_ts_ranges): New function.
(Ftreesit_parser_set_included_ranges): Refactor out the new function
treesit_make_ts_ranges.
(Ftreesit_parser_included_ranges): Rather than getting the ranges from
tree-sitter, just return the cached lisp ranges.
* src/treesit.h (Lisp_TS_Parser): Add some comment.
* test/src/treesit-tests.el (treesit-range-fixup-after-edit): New test.
Yuan Fu [Sat, 14 Sep 2024 05:53:06 +0000 (22:53 -0700)]
Revert "Read more on each call to treesit's buffer reader"
This reverts commit
bf23382f1f2d6ea072db4e4750f8a345f77a3ef2.
We move around the gap, narrow regions, ralloc, etc, and don't have a
way to invalidate previously given range. So tree-sitter can't be given
the full range.
Yuan Fu [Fri, 13 Sep 2024 07:23:13 +0000 (00:23 -0700)]
Fix tree-sitter indent preset prev-adaptive-prefix
* lisp/treesit.el (treesit-simple-indent-presets): Use looking-at so the
call to match-string has the match data to work with.
Eli Zaretskii [Sat, 14 Sep 2024 06:52:59 +0000 (09:52 +0300)]
; * CONTRIBUTE: Minor copyedits.
Robert Pluim [Fri, 13 Sep 2024 13:42:39 +0000 (15:42 +0200)]
Improve NEWS entries
* etc/NEWS: Fix typos, and add information about default values of new
user options.
Mattias Engdegård [Fri, 13 Sep 2024 10:13:53 +0000 (12:13 +0200)]
Don't fail uniquify-tests in non-version-controlled source trees
* test/lisp/uniquify-tests.el (uniquify-project-transform):
Skip test if there is no project (bug#73205).
Robert Pluim [Fri, 13 Sep 2024 07:50:01 +0000 (09:50 +0200)]
; * etc/ORG-NEWS: Fix typo.
Stefan Kangas [Thu, 12 Sep 2024 22:17:35 +0000 (00:17 +0200)]
* doc/misc/auth.texi: Minor copy edits.
Stefan Kangas [Thu, 12 Sep 2024 21:01:08 +0000 (23:01 +0200)]
; * admin/MAINTAINERS: Remove some entries for Artur Malabarba.
Change agreed with Artur Malabarba <arturmalabarba@gmail.com>.
Po Lu [Thu, 12 Sep 2024 00:22:25 +0000 (08:22 +0800)]
Fix bug#72254
* src/pgtkselect.c (Fpgtk_get_selection_internal): If requesting
TARGETS with just one result, return it as a vector.
(bug#72254)
Andrea Corallo [Wed, 11 Sep 2024 20:14:09 +0000 (22:14 +0200)]
Bump Emacs version to 30.0.91
* nt/README.W32: Update Emacs version.
* msdos/sed2v2.inp: Likewise.
* exec/configure.ac: Likewise.
* configure.ac: Likewise.
* README: Likewise.
Andrea Corallo [Wed, 11 Sep 2024 19:52:56 +0000 (21:52 +0200)]
; * ChangeLog.4: Update.
Andrea Corallo [Wed, 11 Sep 2024 19:49:52 +0000 (21:49 +0200)]
; * etc/AUTHORS: Update.
Po Lu [Wed, 11 Sep 2024 04:53:29 +0000 (12:53 +0800)]
; Update version number of exec/configure.ac
* admin/admin.el (set-version): Update AC_INIT expansion in
exec/configure.ac.
* exec/configure.ac: Update version to 30.0.90.
Yuan Fu [Wed, 11 Sep 2024 02:29:31 +0000 (19:29 -0700)]
Fix heex-ts-mode indentation following previews elixir-mode change
After the previous fix in elixir-ts-mode (
0fd259d166c), embedded heex
code are indented like this:
1 defmodule Foo do
2 def foo(assigns) do
3 ~H"""
4 <span>
5 text
6 </span>
7 """
8 end
9 end
The indent rule finds the beginning of the parent heex node, and uses
the indentation of that line as anchor with an offset of 0. Previously
the parent heex node (fragment) starts at EOL of line 3; after the
previous commit, it now starts at BOL of line 4. To fix the
indentation, I changed the anchor to the beginning of the elixir
(rather than heex) node at point, which is at EOL at line 3.
* lisp/progmodes/heex-ts-mode.el (heex-ts--indent-rules): Use the elixir
node that contains the heex code as the anchor, instead of the heex root
node.
Andrea Corallo [Tue, 10 Sep 2024 22:43:47 +0000 (00:43 +0200)]
; * admin/make-tarball.txt: Improve last change.
Andrea Corallo [Tue, 10 Sep 2024 22:39:26 +0000 (00:39 +0200)]
; * admin/make-tarball.txt: Remove now unnecessary configure flag.
Andrea Corallo [Tue, 10 Sep 2024 21:39:34 +0000 (23:39 +0200)]
* lisp/ldefs-boot.el: Update.
Eli Zaretskii [Tue, 10 Sep 2024 12:14:47 +0000 (15:14 +0300)]
Fix use of Uniscribe font driver in MinGW build
This was inadvertently broken when Windows 9X support was
fixed in June 2024.
* src/w32uniscribe.c (syms_of_w32uniscribe_for_pdumper): Set
'uniscribe_available' non-zero in non-Cygwin builds. (Bug#73159)
Eli Zaretskii [Tue, 10 Sep 2024 11:43:52 +0000 (14:43 +0300)]
Avoid crashes in redisplay in batch-mode testing
* src/xdisp.c (try_window_id): Don't crash for "initial" frame.
(Bug#72765)
Michael Albinus [Tue, 10 Sep 2024 07:24:33 +0000 (09:24 +0200)]
; * etc/NEWS: Fix indentation.
Dmitry Gutov [Tue, 10 Sep 2024 01:34:53 +0000 (04:34 +0300)]
eglot-test-rust-completion-exit-function: Fix failure in -Q session
* test/lisp/progmodes/eglot-tests.el (eglot--call-with-fixture):
Check for buffer liveness (https://debbugs.gnu.org/72765#29).
(eglot-test-rust-completion-exit-function): Don't expect snippet
expansion to happen (no yasnippet in batch mode).
Mattias Engdegård [Mon, 9 Sep 2024 13:18:36 +0000 (15:18 +0200)]
; * doc/lispref/searching.texi (Rx Notation): Simplify rx example
Eli Zaretskii [Mon, 9 Sep 2024 11:28:12 +0000 (14:28 +0300)]
Clarify the semantics of 'string-pixel-width'
* doc/lispref/display.texi (Size of Displayed Text):
* lisp/emacs-lisp/subr-x.el (string-pixel-width):
* src/xdisp.c (Fwindow_text_pixel_size, Fbuffer_text_pixel_size):
Doc fixes. (Bug#73129)
Eli Zaretskii [Mon, 9 Sep 2024 11:03:15 +0000 (14:03 +0300)]
; * src/treesit.c: Minor cleanups of recent changes.
Andrea Corallo [Mon, 9 Sep 2024 07:09:48 +0000 (09:09 +0200)]
* src/treesit.c (treesit_debug_print_parser_list): Fix format string.
Yuan Fu [Mon, 9 Sep 2024 04:14:00 +0000 (21:14 -0700)]
; * src/treesit.c (treesit_debug_print_parser_list): Fix formatting.
Yuan Fu [Mon, 9 Sep 2024 04:04:29 +0000 (21:04 -0700)]
; * src/treesit.c: Add a prototype so there's no warning about it.
Yuan Fu [Mon, 9 Sep 2024 00:46:18 +0000 (17:46 -0700)]
Read more on each call to treesit's buffer reader
* src/treesit.c (treesit_read_buffer): Read until the gap or visible
end, instead of reading a single char.
Yuan Fu [Mon, 9 Sep 2024 00:50:52 +0000 (17:50 -0700)]
Fix the range handling in treesit.c
1. In treesit_sync_visible_region, reduce the ranges for a parser so it
doesn't go beyond the visible range.
2. To avoid possible infinite recursion, add a within_reparse field to
parsers. Previously we were using the need_reparse field to avoid
infinite recursion, but lisp programs in a parser's after change hook
might make some buffer edit which turns need_reparse to true. To avoid
that, we now use an explicit field. If a parser's after change function
makes a buffer edit, lisp program ends up with a desynced parse tree,
but that's better than possible infinite recursion. Also after change
function shouldn't edit the buffer.
3. In treesit_make_ranges, use parser's visible_beg instead of buffer's
BEGV. I mean technically whenever we make ranges, buffer's BEGV should
be equal to parser's visible_beg, but better not take that uncertainty,
also makes the code more readable.
4. In Ftreesit_parser_included_ranges, move visible region sync code
before the body of the function.
* src/treesit.c (treesit_sync_visible_region): Minimally fix ranges so
it doesn't exceed parser's visible range.
(treesit_call_after_change_functions): Update calling sigature to
treesit_make_ranges.
(treesit_ensure_parsed, make_treesit_parser): Use the new field
within_reparse.
(treesit_make_ranges): Use parser's visible_beg instead of buffer's
BEGV.
(Ftreesit_parser_included_ranges): Move visible region check before
function body.
* src/treesit.h (Lisp_TS_Parser): Add new field within_reparse.
Yuan Fu [Mon, 9 Sep 2024 00:30:21 +0000 (17:30 -0700)]
Add debugging function for treesit.c
* src/treesit.c (treesit_debug_print_parser_list): New function.
Yuan Fu [Mon, 9 Sep 2024 00:28:26 +0000 (17:28 -0700)]
Fix elixir-ts-mode's range query
* lisp/progmodes/elixir-ts-mode.el:
(elixir-ts--treesit-range-rules): Add underscore in front of the name
capture, so Emacs won't put heex parser on it.
Dmitry Gutov [Sun, 8 Sep 2024 20:50:58 +0000 (23:50 +0300)]
; project-files-relative-names: Update docstring (bug#72701)
Mattias Engdegård [Sun, 8 Sep 2024 18:02:34 +0000 (20:02 +0200)]
Make json-serialize always return a unibyte string (bug#70007)
The JSON format is defined as a byte sequence and will always be used as
such, so returning a multibyte string makes little sense.
* src/json.c (json_out_to_string): Remove.
(Fjson_serialize): Return unibyte string.
* test/src/json-tests.el (json-serialize/roundtrip)
(json-serialize/roundtrip-scalars, json-serialize/string):
Update tests.
* doc/lispref/text.texi (Parsing JSON): Document.
* etc/NEWS: Announce.
Eli Zaretskii [Sat, 7 Sep 2024 16:41:36 +0000 (19:41 +0300)]
; * doc/lispref/os.texi (Suspending Emacs): Fix last change.
Eli Zaretskii [Sat, 7 Sep 2024 15:38:40 +0000 (18:38 +0300)]
; Improve documentation of 'suspend-emacs'
* doc/lispref/os.texi (Suspending Emacs):
* src/keyboard.c (Fsuspend_emacs): Document possible failures
in sending STUFFSTRING to the shell. (Bug#73100).
Eli Zaretskii [Sat, 7 Sep 2024 09:41:29 +0000 (12:41 +0300)]
Fix a typo in ediff-init.el
* lisp/vc/ediff-init.el (ediff-nonempty-string-p): Fix typo.
Reported by Jurgen De Backer
<jurgen.de-backer.ext@eurocontrol.int> (bug#73042).
Eli Zaretskii [Sat, 7 Sep 2024 09:17:24 +0000 (12:17 +0300)]
Fix 'chart-space-usage' on MS-Windows
* lisp/emacs-lisp/chart.el (chart--file-size)
(chart--directory-size): New functions.
(chart-space-usage): Invoke 'du' correctly on MS-Windows. Provide
alternative implementation in Lisp when 'du' is not installed,
using 'chart--directory-size' and 'chart--file-size'. (Bug#72919)
Eli Zaretskii [Sat, 7 Sep 2024 08:27:03 +0000 (11:27 +0300)]
Fix alignment and documentation of vtable.el
* lisp/emacs-lisp/vtable.el (vtable--insert-header-line): Ensure
proper alignment between the columns in header-line and in the
body of the table. (Bug#73032)
* doc/misc/vtable.texi (Making A Table): Document the defaults of
the various keyword parameters.
Eli Zaretskii [Fri, 6 Sep 2024 16:02:50 +0000 (19:02 +0300)]
; * lisp/which-key.el: Fix ':package-version' (bug#73072).
Eli Zaretskii [Thu, 5 Sep 2024 19:09:40 +0000 (22:09 +0300)]
; Improve doc strings of 'tab-bar-mode' and 'tab-line-mode'
* lisp/tab-line.el (tab-line-mode):
* lisp/tab-bar.el (tab-bar-mode): Doc fixes (bug#73049)
Ulrich Müller [Wed, 4 Sep 2024 11:35:51 +0000 (13:35 +0200)]
Fix test failure in erc-networks-tests
* test/lisp/erc/erc-networks-tests.el
(erc-networks--id-sort-buffers): Make sure that buffers have
different timestamps. (Bug#73036)
Eli Zaretskii [Thu, 5 Sep 2024 06:23:23 +0000 (09:23 +0300)]
; * doc/emacs/building.texi (Lisp Libraries): Update (bug#72961).
Eli Zaretskii [Wed, 4 Sep 2024 17:43:25 +0000 (20:43 +0300)]
Fix :hook in 'use-package'
* lisp/use-package/use-package-core.el
(use-package-handler/:hook): Support mode variables in :hook
declarations. (Bug#72993)