Stefan Kangas [Mon, 3 Feb 2025 11:37:06 +0000 (12:37 +0100)]
; Don't use HTTPS in HTTP-specific example
* doc/misc/org.org (External Links): Change HTTP example to use HTTP.
Changing it to HTTPS has been done before, but it's a mistake. To avoid
making this mistake again, change the URL to orgmode.org to make it more
similar to the example on the next line, thereby contrasting the two.
Ulrich Müller [Sat, 1 Feb 2025 22:10:53 +0000 (23:10 +0100)]
Avoid ln(10) expression in calc units definition
* lisp/calc/calc-ext.el (calc-init-extensions): Autoload calc-math
for math-ln-10.
* lisp/calc/calc-units.el (math-standard-units): Use new ln10
constant instead of ln(10) in the decibel definition.
(math-find-base-units-rec): Allow ln10 in expression.
(math-to-standard-rec): Recognize the ln10 constant. (Bug#75861)
Michael Albinus [Mon, 3 Feb 2025 11:51:48 +0000 (12:51 +0100)]
Better NaN handling in proced-tests.el
* test/lisp/proced-tests.el (proced--cpu-at-point): Make it more robust.
(proced--assert-process-valid-cpu-refinement):
Handle `ert-test-skipped' signal.
Eli Zaretskii [Sun, 2 Feb 2025 13:58:18 +0000 (15:58 +0200)]
Improve documentation of 'display-monitor-attributes-
* doc/lispref/frames.texi (Multiple Terminals):
* lisp/frame.el (display-monitor-attributes-list): Better
documentation of what the 'source' key means on X. (Bug#75936)
Stephen Gildea [Mon, 3 Feb 2025 04:14:40 +0000 (20:14 -0800)]
; time-stamp: documentation, tests, NEWS
* lisp/time-stamp.el (time-stamp-pattern, time-stamp-count): Document
how to update different time stamps on multiple lines.
* doc/emacs/files.texi (Time stamps): Add an example showing a time
stamp at the end of a file.
* etc/NEWS: Announce time-stamp format additions.
* test/lisp/time-stamp-tests.el: More title-case tests.
F. Jason Park [Fri, 31 Jan 2025 03:07:00 +0000 (19:07 -0800)]
Run erc-services-regain-mode callback on a timer
* lisp/erc/erc-services.el (erc-services-regain-timeout-seconds): New
variable.
(erc-services-regain-mode): Mention CertFP in doc string.
(erc--nickname-in-use-make-request): Ensure the 900 RPL_LOGGEDIN
callback always runs after `erc-services-regain-timeout-seconds', even
when SASL isn't being used.
* test/lisp/erc/erc-scenarios-services-misc.el
(erc-scenarios-services-misc--regain-command/oftc): New test.
* test/lisp/erc/resources/services/regain/taken-regain-oftc.eld: New
file.
Paul Eggert [Sun, 2 Feb 2025 06:20:04 +0000 (22:20 -0800)]
Improve format-seconds on negative args
* lisp/calendar/time-date.el (format-seconds):
Work better with negative seconds (Bug#75849).
* test/lisp/calendar/time-date-tests.el (test-format-seconds): Test it.
Eli Zaretskii [Sun, 2 Feb 2025 06:23:02 +0000 (08:23 +0200)]
Fix mouse pointer inside mouse-face on text with 'pointer' property
* src/dispnew.c (gui_update_window_end): Don't consider mouse face
overwritten.
* src/xdisp.c (show_mouse_face): Accept an additional argument;
redefine the mouse cursor only if that argument is 'true'. All
callers changed. (Bug#75931)
Paul Eggert [Sat, 1 Feb 2025 22:09:06 +0000 (14:09 -0800)]
Omit 2 ‘volatile’s in internal_lisp_condition_case
* src/eval.c (internal_lisp_condition_case): Omit an unnecessary
‘volatile’ and an unnecessary pointer-to-volatile local var.
Perhaps these were needed in previous versions of Emacs, or to
pacify older versions of GCC when using --enable-gcc-warnings,
but they are not needed to pacify current GCC.
shipmints [Sat, 25 Jan 2025 18:12:56 +0000 (13:12 -0500)]
Add missing custom :set to 'savehist-autosave-interval'
* lisp/savehist.el (savehist-autosave-interval): Correctly
reset 'savehist-timer' when 'savehist-autosave-interval' changes
via setopt or a Customize command. (Bug#75834)
shipmints [Sat, 25 Jan 2025 19:04:51 +0000 (14:04 -0500)]
Add auto save timer to save-place (bug#75837)
* lisp/saveplace.el (save-place-autosave-interval):
New user option 'save-place-autosave-interval' which defaults to nil,
and has a custom :set to manage the timer. Add
'save-place--manage-timer' to enable or cancel the timer if the mode is
enabled and 'save-place-autosave-interval' is non-nil. Amend
'save-place-mode' to invoke save-place--manage-timer. Add
'save-place--cancel-timer'. Add 'save-place--autosave'.
Pip Cet [Sat, 18 Jan 2025 20:55:18 +0000 (20:55 +0000)]
Use #$ for lambda fixups in native compilation data vectors
The "#$" syntax is recognized by Fread, which substitutes
Vload_file_name in its place. If Vload_file_name is bound
appropriately, no other value can produce an object EQ to the one
produced by "#$".
We use this to check the data vector for entries that we know should
have been initialized: if the value is still equal to what we bound
Vload_file_name to when it was read, it wasn't initialized, and we
abort.
* lisp/emacs-lisp/comp.el (comp--#$): New defvar.
(comp--finalize-container): Use it.
* src/comp.c (ABI_VERSION): Bump.
(emit_static_object): Ensure 'comp--#$' prints as "#$".
(load_static_obj): Ensure '#$' reads as Vcomp__hashdollar.
(check_comp_unit_relocs): Adjust assertion.
(syms_of_comp): Define 'comp--#$'.
* src/pdumper.c (dump_do_dump_relocation): Adjust assertion.
When the visited TAGS file was removed, commands that depend on
TAGS, such as auto-completion, may invoke an interactive question
whether a user wants to re-read the file. From that point on,
the question will be asked over and over, because the file no
longer exists, which results in mtime mismatch and inability to
"fix the mismatch" by reading from the file. Fix that by simply
ignoring the mismatch if the file no longer exists.
* lisp/progmodes/etags.el (tags-verify-table): Avoid infinite
questions if TAGS file was removed. (Bug#75946)
Pengji Zhang [Mon, 27 Jan 2025 11:42:00 +0000 (19:42 +0800)]
New user option 'Buffer-menu-human-readable-sizes'
* lisp/buff-menu.el (Buffer-menu-human-readable-sizes): New user
option.
(list-buffers--refresh): Use it.
* etc/NEWS: Announce the new user option. (Bug#75825)
shipmints [Mon, 27 Jan 2025 16:16:04 +0000 (11:16 -0500)]
Add new user option bookmark-bmenu-type-column-width
* lisp/bookmark.el (bookmark-bmenu-mode):
Add new user option bookmark-bmenu-type-column-width, defaulting to 8
for backwards compatibility, and use it when creating the tabulated
bookmark list. (Bug#75826)
Eli Zaretskii [Sat, 1 Feb 2025 10:22:13 +0000 (12:22 +0200)]
Rename a recently-added variable (bug#56197)
* lisp/emacs-lisp/lisp-mode.el
(lisp-fill-paragraphs-as-doc-string): Renamed from
'lisp-fill-paragraph-as-displayed' and default value reversed.
(lisp-fill-paragraph): Adjust to the change.
* test/lisp/emacs-lisp/lisp-mode-tests.el
(lisp-fill-paragraph-as-displayed): Likewise.
Paul Eggert [Fri, 31 Jan 2025 22:42:33 +0000 (14:42 -0800)]
Don’t use garbage after tty_frame_at returns nil
* src/term.c (handle_one_term_event): Don’t access possibly
uninitialized storage if frame is nil. This fixes an issue introduced
in commit 5eae7f5227c7789dea45cef26fec17c057024670 dated 2025-01-26
14:43:51 -0800. Issue caught by --enable-gcc-warnings, which enables
-Wanalyzer-use-of-uninitialized-value with gcc (GCC) 14.2.1 20250110
(Red Hat 14.2.1-7).
Paul Eggert [Fri, 31 Jan 2025 22:42:33 +0000 (14:42 -0800)]
Port dest-mountpoint test to suspicious bwrap
* test/lisp/emacs-lisp/bytecomp-tests.el:
(bytecomp-tests--dest-mountpoint): Skip test if bwrap prohibits
even ‘true’, which it does on my Ubuntu 24.10 platform.
João Távora [Fri, 31 Jan 2025 10:31:37 +0000 (10:31 +0000)]
Eglot: add server menu into main menu
* lisp/progmodes/eglot.el (eglot-menu): Add separator at end
and add in eglot-server menu at load-time.
(eglot-server-menu): Rework menu title and description.
Martin Rudalics [Fri, 31 Jan 2025 08:31:05 +0000 (09:31 +0100)]
In 'replace-buffer-in-windows' try to preserve current buffer (Bug#75949)
* lisp/window.el (replace-buffer-in-windows): Preserve current
buffer when 'kill-buffer-quit-windows' is non-nil and a window
showing BUFFER shall be quit. Running 'kill-buffer-hook' relies
on it (Bug#75949).
shipmints [Thu, 30 Jan 2025 17:57:00 +0000 (12:57 -0500)]
Add new variable tab-bar-format-tab-help-text-function
* lisp/tab-bar.el (tab-bar--format-tab):
Add new variable 'tab-bar-format-tab-help-text-function' and a default
function 'tab-bar-format-tab-help-text-default'. 'tab-bar--format-tab'
respects this new variable when producing a tab's help text, normally
shown in the echo area or via tooltips (bug#75950).
Yuan Fu [Fri, 31 Jan 2025 00:54:20 +0000 (16:54 -0800)]
Add treesit-add-simple-indent-rules
* lisp/treesit.el:
(treesit-add-simple-indent-rules): New function.
* etc/NEWS: Update NEWS.
*
test/src/treesit-tests.el:
(treesit-test-add-simple-indent-rules): Add a test for the new
function.
Stefan Kangas [Sun, 26 Jan 2025 13:53:49 +0000 (14:53 +0100)]
Do not set `trusted-content` in major modes
* lisp/progmodes/elisp-mode.el (lisp-interaction-mode):
* lisp/ielm.el (inferior-emacs-lisp-mode): Do not set `trusted-content.
* lisp/ielm.el (ielm):
* lisp/simple.el (get-scratch-buffer-create): Set `trusted-content` here
instead.
* lisp/files.el (trusted-content): Doc fix; warn against setting this
option to :all in a major or mode mode.
Problem reported by Max Nikulin <manikulin@gmail.com>.
shipmints [Thu, 30 Jan 2025 12:20:34 +0000 (07:20 -0500)]
* lisp/tab-bar.el (tab-bar-select-tab): Fix wc-bl/wc-bbl when nil
Remove the nil-check conditionals around 'wc-bl' and 'wc-bbl' that reset
frame parameters 'buffer-list' and 'buried-buffer-list'. This ensures
originating nil values correctly propagate (bug#75935).
shipmints [Wed, 29 Jan 2025 18:43:04 +0000 (13:43 -0500)]
Add new user option tab-bar-define-keys
* lisp/tab-bar.el (tab-bar-define-keys):
Add new defcustom tab-bar-define-keys. Reorganize key binding functions
to accommodate. Also remove checks for tab-bar-mode enabled in
'tab-bar-select-tab-modifiers', as unnecessary and which prevented user
changes from being accepted in cases where the user defers enabling
tab-bar-mode (bug#75918).
Stefan Kangas [Sun, 26 Jan 2025 20:57:34 +0000 (21:57 +0100)]
Update cc-mode URL to point to nongnu.org
* doc/misc/cc-mode.texi (Getting Started)
(Custom Filling and Breaking, Updating CC Mode)
(Mailing Lists and Bug Reports):
* lisp/progmodes/cc-mode.el: Update cc-mode URL to point to nongnu.org,
instead of old URL on SourceForge.
Eli Zaretskii [Mon, 27 Jan 2025 13:19:06 +0000 (15:19 +0200)]
; Improve documentation of '.dir-locals.el'
* doc/lispref/variables.texi (Directory Local Variables):
* doc/emacs/custom.texi (Directory Variables): Document that
'.dir-locals-2.el' must be in the same directory as
'.dir-locals.el'. (Bug#75890)
Stefan Kangas [Sun, 26 Jan 2025 21:39:10 +0000 (22:39 +0100)]
; Prefer HTTPS to HTTP in docs
* doc/emacs/android.texi (Android Software):
* doc/lispref/frames.texi (X Selections):
* doc/misc/cc-mode.texi (Custom Filling and Breaking):
* doc/misc/efaq.texi (Basic editing):
* doc/misc/gnus.texi (Propagating marks, Spam Statistics Package):
* doc/misc/org.org (External Links, Images in HTML export)
(LaTeX Export, LaTeX math snippets): Prefer HTTPS to HTTP. Fix or
mark some broken links while we're at it.
Stefan Kangas [Tue, 10 Dec 2024 22:35:31 +0000 (23:35 +0100)]
Delete variable pure-space-overflow
* lisp/startup.el (pure-space-overflow): Make variable obsolete.
* lisp/loadup.el (pure-space-overflow): Do not set. Remove call to
`garbage-collect', as that is done by `dump-emacs-portable'.
Stefan Kangas [Tue, 10 Dec 2024 18:39:03 +0000 (19:39 +0100)]
Make 'purecopy' an obsolete function alias for 'identity'
* lisp/subr.el (purecopy): New obsolete function alias for 'identity'.
* src/alloc.c (purecopy): Remove function.
(Fpurecopy): Remove DEFUN.
(syms_of_alloc): Remove defsubr for above DEFUN.
* lisp/loadup.el (purify-flag): Don't set to hash table.
Stefan Kangas [Tue, 10 Dec 2024 10:07:01 +0000 (11:07 +0100)]
Remove check for working malloc_set_state
This check was added to 'malloc_initialize_hook' in order to "insulate
Emacs better from configuration screwups" (commit b4788b9394f3). With
unexec gone, we no longer use 'malloc_set_state', and thus don't need
this check.
Note that this patch removes the last uses of the deprecated glibc
functions 'malloc_set_state' and 'malloc_get_state' from our code.
* src/alloc.c (malloc_initialize_hook) [DOUG_LEA_MALLOC]:
Remove check for working 'malloc_set_state'.
(alloc_unexec_pre) [DOUG_LEA_MALLOC]: Delete unused function.
(alloc_unexec_post) [DOUG_LEA_MALLOC]: Delete function.
(malloc_state_ptr) [DOUG_LEA_MALLOC]: Delete variable.
* configure.ac (emacs_cv_var_doug_lea_malloc): Don't check for
malloc_set_state and malloc_get_state.