Commit graph

173879 commits

Author SHA1 Message Date
Eli Zaretskii
a3e57a29be ; Fix doc string of 'string-fill'
* lisp/emacs-lisp/subr-x.el (string-fill): Rename LENGTH to WIDTH
and update the doc string accordingly.  (Bug#71856)
2024-07-06 11:28:39 +03:00
Eli Zaretskii
1b5cf29431 Fix returning to original TTY frame after 'rmail-reply'
* lisp/mail/rmail.el (rmail-start-mail): Record the frame from
which an Rmail command, such as 'rmail-mail' or 'rmail-reply', was
invoked.
(rmail--find-orig-rmail-frame): New function.
(rmail-mail-return): Use 'rmail--find-orig-rmail-frame' to find
the original frame, and make it the top frame on its TTY terminal.
(Bug#69738)
2024-07-06 10:32:39 +03:00
Eli Zaretskii
814710067f Improve warnings from native compiler
* src/comp.c (syms_of_comp) <native-compiler>: Rename from 'comp'.

* src/lread.c (maybe_swap_for_eln):
* lisp/emacs-lisp/comp.el (comp--fwprop):
* lisp/emacs-lisp/comp-run.el
(comp--accept-and-process-async-output, native--compile-async):
Adjust to the new symbol.
2024-07-05 22:00:08 +03:00
Stefan Kangas
cefec59df7 Document adding package dependency on Emacs version
* doc/lispref/package.texi (Simple Packages, Multi-file Packages):
Document how to make a package depend on a specific version of Emacs.
2024-07-05 15:02:23 +02:00
Eli Zaretskii
d190cb0e88 Fix file-name detection in Dired under -F
* lisp/files.el (insert-directory-clean): Support all the symbols
appended to file names by the -F/--classify option of 'ls'.  See
https://lists.gnu.org/archive/html/emacs-devel/2024-07/msg00366.html
for the details.
2024-07-05 13:58:11 +03:00
Stefan Monnier
334d513220 (edebug--called-interactively-skip): Fix bug#71934
* lisp/emacs-lisp/edebug.el (edebug--called-interactively-skip):
Adjust to new interpreted functions.
2024-07-04 11:47:01 -04:00
Eli Zaretskii
6e8b9ccaec ; * lisp/ibuffer.el (ibuffer-mode): Doc fix. 2024-07-04 10:59:45 +03:00
Eli Zaretskii
3eaf1abbff Fix MS-Windows build with native-compilation
* src/w32.c (globals_of_w32): Move re-initialization of
Vlibrary_cache from here...
* src/emacs.c (main): ...to here, as it must be after load_pdump.
(Bug#71916)
2024-07-03 22:13:42 +03:00
Andrea Corallo
fc375359ed Tag dbus-test05-register-signal-with-nils as unstable
* test/lisp/net/dbus-tests.el (dbus-test05-register-signal-with-nils):
Tag it as unstable.
2024-07-03 20:13:13 +02:00
Eli Zaretskii
99230d7080 ; * src/w32fns.c (funhook): Restore mistakenly lost line. 2024-07-03 21:06:27 +03:00
Eli Zaretskii
81a7358a33 Merge branch 'emacs-30' of git.savannah.gnu.org:/srv/git/emacs into emacs-30 2024-07-03 13:55:13 +03:00
Yuan Fu
b085d68396
Fix treesit test (bug#71907)
* test/src/treesit-tests.el (treesit-node-check): Re-parse buffer before
checking for node outdated-ness.
2024-07-03 00:31:16 -07:00
Stefan Kangas
f39cf0beb7 Focus more on MS-Windows than MS-DOS in FAQ
* doc/misc/efaq.texi (Editing Windows files): Rename section from
"Editing MS-DOS files", and update the text to focus on Windows.
* doc/misc/efaq.texi (Colors on a TTY)
(Emacs does not display 8-bit characters): Mention MS-Windows before
MS-DOS.
2024-07-03 02:08:19 +02:00
Stefan Kangas
d64396b8e4 Autoload some string functions
These functions are documented in both `(elisp) Creating Strings' and
'M-x shortdoc RET string RET', so users will expect them to be available
without having to require 'subr-x'.

* lisp/emacs-lisp/subr-x.el (string-fill, string-limit, string-pad)
(string-chop-newline): Autoload.
2024-07-03 02:08:19 +02:00
Eli Zaretskii
bd482b745a Merge branch 'emacs-30' of git.savannah.gnu.org:/srv/git/emacs into emacs-30 2024-07-02 17:41:48 +03:00
Michael Albinus
b534183135 * etc/NEWS: Fix typos. 2024-07-02 14:28:52 +02:00
Eshel Yaron
850fc68481
; (grep-read-files): Fix completion table
* lisp/progmodes/grep.el (grep-read-files): Cease returning
some completion candidates unconditionally.  Use
'completion-file-name-table' over 'read-file-name-internal'
because the latter uses 'completion-table-with-quoting', and
that doesn't blend well with other tables in
'completion-table-merge'.

https://lists.gnu.org/archive/html/emacs-devel/2024-06/msg01194.html
2024-07-02 14:12:40 +02:00
Eli Zaretskii
2853259935 Merge branch 'emacs-30' of git.savannah.gnu.org:/srv/git/emacs into emacs-30 2024-07-02 14:08:58 +03:00
Alan Mackenzie
921d40759e Remove a reference to a non-existant variable from a doc-string
* lisp/progmodes/cc-langs.el (c-opt-extra-label-key): Remove
reference to c-nonlabel-decl-prefix-re from the doc string.
2024-07-01 20:37:28 +00:00
Eli Zaretskii
5d2a115ab0 ; * src/fns.c (value_cmp): ASCIIfy. 2024-07-01 21:58:17 +03:00
Eli Zaretskii
4c64b99087 ; * etc/NEWS: Fix level of several entrries. 2024-07-01 20:33:52 +03:00
Eli Zaretskii
459e635099 ; * etc/NEWS: Fix typo. 2024-07-01 20:30:23 +03:00
Eli Zaretskii
7050128cfe ; * src/search.c (Fmatch_beginning, Fmatch_end): Doc fix. 2024-07-01 15:59:05 +03:00
Mattias Engdegård
1647494c04 ; * etc/NEWS: Clarify. 2024-07-01 10:44:22 +02:00
Yuan Fu
b2c966f839
; * src/treesit.c (Ftreesit_query_capture): Fix typo. 2024-06-30 22:36:34 -07:00
Po Lu
ae38579420 * java/res/mipmap-v26/emacs_icon.xml: Define monospace icon. 2024-07-01 11:22:18 +08:00
Stefan Kangas
b2d99c0d0a Improve sentence-end-double-space docstring
* lisp/textmodes/paragraphs.el (sentence-end-double-space):
Improve and expand docstring.
2024-07-01 02:41:52 +02:00
Stefan Kangas
9d62dbc1f7 Backport file backup FAQ item to Emacs <28
* doc/misc/efaq.texi (Not writing files to the current directory):
Backport recommendation to Emacs 27 or older.
Problem reported by David Hedlund <davidh@gnu.org>.
2024-07-01 01:50:51 +02:00
Eli Zaretskii
2f71460d52 More updates of documentation for Emacs 30
* etc/NEWS: Improve wording and move/mark entries.

* doc/lispref/positions.texi (List Motion): Document
'forward-sentence-function'.
* doc/lispref/functions.texi (What Is a Function): Document
'primitive-function-p' and 'cl-functionp'.
* doc/emacs/misc.texi (Saving Emacs Sessions): Improve wording and
indexing.
* doc/lispref/tips.texi (Documentation Tips): Adapt to the new
value of 'emacs-lisp-docstring-fill-column'.
* doc/emacs/fixit.texi (Spelling): Document
'flyspell-check-changes'.
2024-06-30 22:25:31 +03:00
Mattias Engdegård
a9df581c40 ; * etc/NEWS: Copy-edit. 2024-06-30 17:27:08 +02:00
Mattias Engdegård
dfbdd38f70 Revert "; * etc/NEWS: Move items to "Incompatible Lisp Changes"."
This reverts commit 000ef8876a.
Most of the moved items weren't actually incompatible changes.
2024-06-30 17:27:08 +02:00
Po Lu
64851d101a Improve Android "adaptive icon"
* java/res/drawable/emacs_background.xml:

* java/res/drawable/emacs_foreground.xml: Transform borders and
gradient colors to better align with the original.
2024-06-30 23:11:19 +08:00
Eli Zaretskii
9b294059d7 Fix documentation for Emacs 30
* etc/NEWS: Mark entries and improve wording.

* doc/emacs/dired.texi (Operating on Files): Document
'dired-do-open'.  Fix indexing.
* doc/emacs/files.texi (Diff Mode): Document 'diff-apply-buffer'.
Fix indexing.
* doc/emacs/maintaining.texi (Project File Commands)
(Project Buffer Commands): Document 'project-any-command'.
* doc/emacs/building.texi (Other GDB Buffers): Document the user
option 'gdb-display-io-buffer'.
(Grep Searching): Document 'grep-use-headings'.
* doc/emacs/text.texi (Outline Visibility): Document Outline
commands that hide/show by heading regexp.
* doc/emacs/killing.texi (Kill Options): Document
'kill-ring-deindent-mode'.
* doc/emacs/basic.texi (Continuation Lines): Improve wording.
2024-06-30 17:42:38 +03:00
Eli Zaretskii
f50167ab95 ; Update NEWS and corresponding manuals
* etc/NEWS: Improve wording and mark entries as approriate.

* doc/emacs/buffers.texi (Kill Buffer): Document new commands.
* doc/emacs/mini.texi (Completion Options, Completion Commands):
Document new completion options and behaviors.
2024-06-30 15:06:06 +03:00
Robert Church
4e22ef870c Add D-Bus test
* test/lisp/net/dbus-tests.el (dbus-test05-register-signal-with-nils):
New test.  (Bug#69926)
2024-06-30 12:16:20 +02:00
Po Lu
f784d946d4 ; Repair corruption in etc/DEBUG
* etc/DEBUG: Repair corruption reported by Eli Zaretskii
<eliz@gnu.org>.
2024-06-30 17:38:07 +08:00
Eli Zaretskii
c750fbb539 ; * etc/DEBUG: Advice for debugging Emacs on OpenBSD (bug#71712). 2024-06-30 12:18:22 +03:00
Po Lu
38179f85f8 Merge remote-tracking branch 'savannah/scratch/windows-98' into emacs-30
* configure.ac (W32_LIBS): Don't link with -lusp10 on non-Cygwin
systems.

* src/emacs.c (main): Call globals_of_w32 before the startup
directory is initialized.

* src/w32.c (maybe_load_unicows_dll): Call
load_unicows_dll_for_w32fns.

* src/w32.h: Update prototypes.

* src/w32fns.c (Fx_create_frame, w32_create_tip_frame): Do not
register the Uniscribe font driver when unavailable.
(pfnSHFileOperationW): New function pointer.
(Fsystem_move_file_to_trash): Load UNICOWS.DLL if not yet
loaded.  Call SHFileOperationW through said function pointer.
(pfnShellExecuteExW): New function pointer.
(Fw32_shell_execute) [!CYGWIN]: Load UNICOWS.DLL if not yet
loaded.  Call ShellExecuteExW through said function pointer.
(pfnShell_NotifyIconW): New function pointer.
(add_tray_notification, delete_tray_notification): Call
Shell_NotifyIconW through said function pointer.
(Fw32_notification_notify): Load UNICOWS.DLL.
(Fw32_notification_close): Return if Shell_NotifyIconW is
unavailable, as when UNICOWS.DLL has yet to be loaded.
(load_unicows_dll_for_w32fns): New function.

* src/w32notify.c (pfnReadDirectoryChangesW): New function
pointer.
(watch_completion, remove_watch, Fw32notify_add_watch)
(Fw32notify_rm_watch, Fw32notify_valid_p): Call
ReadDirectoryChangesW through said function pointer, and assert
its presence.
(globals_of_w32notify): Load ReadDirectoryChangesW from
KERNEL32.DLL.

* src/w32uniscribe.c (pfnScriptItemize, pfnScriptShape)
(pfnScriptPlace, pfnScriptGetGlyphABCWidth, pfnScriptFreeCache)
(pfnScriptGetCMap): New function pointers.
(uniscribe_close, uniscribe_shape, uniscribe_encode_char)
(uniscribe_check_otf_1): Call Uniscribe functions through the
same.
(syms_of_w32uniscribe_for_pdumper): Load Uniscribe library and
required functions from the same, and if unavailable, return
while leaving uniscribe_available intact.  On Cygwin, simply
assign USP10.DLL functions to the said new function pointers.
2024-06-30 10:08:35 +08:00
Po Lu
72cf9964f3 Inaccuracy in efaq.texi
; * doc/misc/efaq.texi (New in Emacs 30): Mention GNUStep and
Mac OS separately.
2024-06-30 10:04:43 +08:00
Po Lu
fc48e9e8ed ; Fix typos in DOS Makefile scripts
* msdos/sedlibmk.inp (NEXT_AS_FIRST_DIRECTIVE_ENDIAN_H)
(NEXT_ENDIAN_H): Use a different command deliminter character
from `/'.
2024-06-30 10:03:53 +08:00
Stefan Kangas
9b8d754579 ; * etc/NEWS: Explain Nextstep. 2024-06-30 03:58:09 +02:00
Yuan Fu
8819e5a45d
Fix treesit crash (bug#71681)
To reproduce the problem:

0. emacs -Q
1. eval: (add-to-list 'major-mode-remap-alist '(c-mode . c-ts-mode))
2. C-x v L
3. in the *vc-change-log* buffer move point to the commit 20af58d3a1
4. type D
5. crash caused by diff-font-lock-syntax fontification that uses treesit

Emacs: 6f2036243f (2024-06-23, latest master)
Tree-sitter: 3da7deed (2024-06-08, version 0.22.6)

The immediate cause of the crash is that tree-sitter accessed a node's
tree, but the tree is already deleted.  Commenting out the
ts_tree_delete line in treesit_ensure_parsed can "fix" the crash.

What happended, I think, is this:

1. Buffer modified, parser->need_reparse set to true,
parser->timestamp incremented.
2. A node is created from the parser, this node has the old tree but
the new timestamp (bad!).
3. Parser re-parses (treesit_ensure_parsed), new tree created, old
tree deleted.
4. Ftreesit_query_capture accessed the old node, and the old tree,
crash.

We shouldn't bump the parser timestamp when we set
parser->need_reparse to true; instead, we should bump the timestamp
when we actually reparsed and created a new tree.

* src/treesit.c (treesit_record_change): Don't bump parser timestamp.
(treesit_sync_visible_region): Don't bump parser timestamp.
(Ftreesit_parser_set_included_ranges): Don't bump parser timestamp.
(treesit_ensure_parsed): Bump parser timestamp.
(Ftreesit_query_capture): Add node check.
2024-06-29 16:49:52 -07:00
Jim Porter
eaf2dc96c1 ; Fix SHR test on MS-Windows
* test/lisp/net/shr-tests.el (shr-test/zoom-image): Ensure the image URL
is properly formatted: it should always have 3 slashes after "file:".
2024-06-29 14:59:20 -07:00
Stefan Kangas
57880f597c Delete redundant mention of `with-eval-after-load'
* lisp/progmodes/dcl-mode.el (dcl-mode): Delete redundant mention of
`with-eval-after-load'.
2024-06-29 21:16:58 +02:00
Michael Albinus
ea8ce98434 * doc/misc/efaq.texi (New in Emacs 30): Fix typos. 2024-06-29 18:42:13 +02:00
Stefan Kangas
45a20d781a ; Fix typos in symbols 2024-06-29 17:29:38 +02:00
Stefan Kangas
d95f039af4 Document security fixes in FAQ
* doc/misc/efaq.texi (New in Emacs 29): Recommend using Emacs 29.4.
* doc/misc/efaq.texi (Security risks with Emacs): New item with a
recommendation to upgrade Emacs for improved security.
2024-06-29 17:03:18 +02:00
Stefan Kangas
d063af203c Add "New in Emacs 30" to FAQ
* doc/misc/efaq.texi (New in Emacs 30): New section.
2024-06-29 16:45:23 +02:00
Stefan Kangas
ca6b484162 ; * etc/NEWS: Move "Minibuffer and Completions"
As a generally applicable feature, it belongs under "Changes" rather
than under "Changes in Specialized Modes and Packages".
2024-06-29 16:37:07 +02:00
Stefan Kangas
35c46663e4 ; * etc/NEWS: Move item to "Lisp Changes". 2024-06-29 16:36:17 +02:00