]> git.eshelyaron.com Git - emacs.git/log
emacs.git
2 years agoFix XDS file name expansion
Po Lu [Sat, 15 Oct 2022 05:27:05 +0000 (13:27 +0800)]
Fix XDS file name expansion

* lisp/x-dnd.el (x-dnd-handle-xds-drop): Expand file names
again.  That code was mistakenly removed.

2 years ago; improve test coverage of time-stamp-pattern parsing
Stephen Gildea [Sat, 15 Oct 2022 03:46:38 +0000 (20:46 -0700)]
; improve test coverage of time-stamp-pattern parsing

* test/lisp/time-stamp-tests.el (time-stamp-test-pattern-multiply,
time-stamp-test-pattern-sequential): broaden range of test data

2 years ago; Auto-commit of loaddefs files.
Stefan Kangas [Sat, 15 Oct 2022 03:07:35 +0000 (05:07 +0200)]
; Auto-commit of loaddefs files.

2 years agoUse file-size-human-readable in memory-report--format
Stefan Kangas [Sat, 15 Oct 2022 01:02:17 +0000 (03:02 +0200)]
Use file-size-human-readable in memory-report--format

* lisp/emacs-lisp/memory-report.el (memory-report--format): Use
file-size-human-readable.

2 years agoUpdate image-circular-tests.el
Basil L. Contovounesios [Mon, 3 Oct 2022 20:34:07 +0000 (23:34 +0300)]
Update image-circular-tests.el

* test/manual/image-circular-tests.el
(image-test-duplicate-keywords): Skip unless images are supported.
(image-test-circular-plist, image-test-:type-property-value): Ditto.
Wrap only failing forms in should[-error] rather than entire test
bodies.  Use simpler printed notation in place of function calls.
(image-test-circular-specs): Ditto.  Wrap overly wide docstring.
Mark as failing since shortly after its introduction (bug#36403#63).

2 years agoRename `file-attribute-file-number' to `file-attribute-file-identifier'
Michael Albinus [Fri, 14 Oct 2022 19:32:15 +0000 (21:32 +0200)]
Rename `file-attribute-file-number' to `file-attribute-file-identifier'

* doc/lispref/files.texi (File Attributes):
* etc/NEWS:
* lisp/files.el (find-buffer-visiting, find-file-noselect)
(set-visited-file-name, basic-save-buffer)
(file-attribute-file-identifier):
* lisp/startup.el (normal-top-level-add-subdirs-to-load-path):
* lisp/eshell/em-unix.el (eshell-shuffle-files):
* src/dired.c (Ffile_attributes):
Rename `file-attribute-file-number' to `file-attribute-file-identifier'.

2 years agoCorrectly fontify C++'s operator"" _tag (...)
Alan Mackenzie [Fri, 14 Oct 2022 17:40:26 +0000 (17:40 +0000)]
Correctly fontify C++'s operator"" _tag (...)

Give both the "" and _tag font-lock-function-name-face.  Also correct the
fontification of an inherited class name when there is an attribute between
the class name being declared and the colon introducing the inheritance.

* lisp/progmodes/cc-engine.el (c-forward-over-colon-type-list): New function.
(c-forward-keyword-clause): Use the above new function instead of a
looking-at.
(c-forward-name, c-forward-declarator): Accept both the "" and the tag as part
of the name.

* lisp/progmodes/cc-fonts.el (c-font-lock-declarators): Fontify the "" (which
already has font-lock-string-face) and the tag with
font-lock-function-name-face.

* lisp/progmodes/cc-langs.el (c-overloadable-operators): Add "" to this list.
(c-sub-colon-type-list-re): New lang-const and lang-var.

2 years agoAdd a quick-help menu
Philip Kaludercic [Sat, 17 Sep 2022 14:52:01 +0000 (16:52 +0200)]
Add a quick-help menu

* lisp/help.el (help-map): Bind 'help-quit-or-quick' instead of 'help-quit'.
(help-quick-sections): Add variable.
(help-quick): Add main command.
(cheat-sheet): Add alias for 'help-quick'.
(help-quit-or-quick): Add auxiliary command.
lisp/help.el (help-for-help):  Mention 'help-quit-or-quick'.
* etc/NEWS (https): Mention 'help-quit'.

2 years ago* lisp/net/rcirc.el (rcirc-bridged-nick): Inherit from highlight
Philip Kaludercic [Fri, 14 Oct 2022 07:39:45 +0000 (09:39 +0200)]
* lisp/net/rcirc.el (rcirc-bridged-nick): Inherit from highlight

2 years agoAllow filtering what items are added to Ecomplete
Philip Kaludercic [Thu, 13 Oct 2022 10:02:02 +0000 (12:02 +0200)]
Allow filtering what items are added to Ecomplete

* etc/NEWS: Mention new option.
* lisp/ecomplete.el (ecomplete-filter-regexp): Add new option.
(ecomplete-add-item): Respect new option.  (bug#58487)

2 years agoPrevent .dir-locals.el from being byte-compiled
Philip Kaludercic [Wed, 5 Oct 2022 17:45:27 +0000 (19:45 +0200)]
Prevent .dir-locals.el from being byte-compiled

* lisp/files-x.el (modify-dir-local-variable): Add a 'no-byte-compile'
file local variable when generating a .dir-locals.el
file.
* .dir-locals.el:  Add 'no-byte-compile'.  (Bug#58486)

2 years ago* lisp/net/rcirc.el (rcirc-generate-log-filename): Append ".log"
Philip Kaludercic [Thu, 6 Oct 2022 12:03:04 +0000 (14:03 +0200)]
* lisp/net/rcirc.el (rcirc-generate-log-filename): Append ".log"

(Bug#54718)

2 years ago; * lisp/vc/vc.el (vc-default-prepare-patch): Add missing argument
Philip Kaludercic [Tue, 11 Oct 2022 19:23:26 +0000 (21:23 +0200)]
; * lisp/vc/vc.el (vc-default-prepare-patch): Add missing argument

2 years agoPrepare all inline patches at once
Philip Kaludercic [Tue, 11 Oct 2022 18:46:15 +0000 (20:46 +0200)]
Prepare all inline patches at once

* lisp/vc/vc.el (vc-prepare-patch): Remove the usage of
'recursive-edit' when 'vc-prepare-patches-separately' is non-nil.

2 years agoAllow reordering commits in 'vc-prepare-patch' prompt
Philip Kaludercic [Tue, 11 Oct 2022 18:43:40 +0000 (20:43 +0200)]
Allow reordering commits in 'vc-prepare-patch' prompt

* lisp/vc/vc.el (vc-prepare-patch): Use marked log-view commits as
initial input.

2 years agoMention that vc-prepare-patch can interact with a log-view
Philip Kaludercic [Tue, 11 Oct 2022 16:09:58 +0000 (18:09 +0200)]
Mention that vc-prepare-patch can interact with a log-view

; * doc/emacs/vc1-xtra.texi (Preparing Patches): Extend documentation.

2 years ago* lisp/play/zone.el (zone): Allow selecting a program
Philip Kaludercic [Tue, 11 Oct 2022 10:28:45 +0000 (12:28 +0200)]
* lisp/play/zone.el (zone): Allow selecting a program

2 years agoDo perl documentation lookups case-insensitively, like man
Reuben Thomas [Fri, 14 Oct 2022 11:30:43 +0000 (13:30 +0200)]
Do perl documentation lookups case-insensitively, like man

* lisp/progmodes/cperl-mode.el (cperl-perldoc): add -i to the perldoc
command.

2 years agoFix bug#56153
Po Lu [Fri, 14 Oct 2022 11:04:44 +0000 (19:04 +0800)]
Fix bug#56153

* src/nsterm.m (get_keysym_name)
(ns_draw_glyphless_glyph_string_foreground): Fix new Mac OS
deprecations.

([EmacsApp terminate:]): Use kbd_buffer_store_event instead
of emacs_event.  (bug#56153)
([EmacsView windowDidChangeBackingProperties:]): Fix new Mac
OS deprecation.

2 years agoAvoid redundant creation of XRender pictures
Po Lu [Fri, 14 Oct 2022 07:52:16 +0000 (15:52 +0800)]
Avoid redundant creation of XRender pictures

* src/xterm.c (x_composite_image): Take arg DESTINATION.  Do not
create a picture if it is set.
(x_draw_image_foreground, x_draw_image_foreground_1): Pass
destination where appropriate.

2 years ago; Fix recent change in documentation of "device number"
Eli Zaretskii [Fri, 14 Oct 2022 07:12:03 +0000 (10:12 +0300)]
; Fix recent change in documentation of "device number"

* src/dired.c (Ffile_attributes):
* lisp/files.el (buffer-file-number, file-attribute-file-number):
Fix wording of the doc strings.

* etc/NEWS:
* doc/lispref/buffers.texi (Buffer File Name):
* doc/lispref/files.texi (File Attributes): Fix a typo and
wording.  (Bug#58446)

2 years agoMerge from origin/emacs-28
Stefan Kangas [Fri, 14 Oct 2022 04:31:49 +0000 (06:31 +0200)]
Merge from origin/emacs-28

85e47d9a9e ; Continued cleanup of "-hooks"

2 years agoClarify structure of file-attribute's device number
Michael Albinus [Thu, 13 Oct 2022 19:13:45 +0000 (21:13 +0200)]
Clarify structure of file-attribute's device number

* doc/lispref/buffers.texi (Buffer File Name): Fix description of
buffer-file-number.

* doc/lispref/files.texi (File Attributes): Clarify type of device
number.  Describe file-attribute-file-number.  (Bug#58446)

* etc/NEWS: Mention file-attribute-file-number.

* lisp/files.el (buffer-file-number, file-attribute-device-number)
(file-attribute-collect): Fix docstring.
(file-attribute-file-number): New defsubst.
(find-buffer-visiting, find-file-noselect)
(set-visited-file-name, basic-save-buffer):
* lisp/startup.el (normal-top-level-add-subdirs-to-load-path):
* lisp/eshell/em-unix.el (eshell-shuffle-files): Use it.

* src/dired.c (Ffile_attributes): Fix docstring.

2 years ago; Continued cleanup of "-hooks"
Bill Wohler [Thu, 13 Oct 2022 16:49:55 +0000 (09:49 -0700)]
; Continued cleanup of "-hooks"

* doc/misc/mh-e.texi: Replace mh-kill-folder-suppress-prompt-hook with
mh-kill-folder-suppress-prompt-functions.

2 years agoImprove checks for recent "File exists" fixup
Paul Eggert [Thu, 13 Oct 2022 16:33:46 +0000 (09:33 -0700)]
Improve checks for recent "File exists" fixup

* src/fileio.c (Finsert_file_contents): Add an assertion (bug#42431).

2 years agoMake `info' treat "\n" in node names as "\s"
Stefan Kangas [Thu, 13 Oct 2022 13:46:56 +0000 (15:46 +0200)]
Make `info' treat "\n" in node names as "\s"

* lisp/info.el (info): Treat "\n" in node name as "\s".  (Bug#57936)

2 years agoShrink client list window structure
Po Lu [Thu, 13 Oct 2022 10:47:49 +0000 (18:47 +0800)]
Shrink client list window structure

* src/xterm.c (struct x_client_list_window): Rearrange members
for better alignment.

2 years agoSimplify recent "File exists" fix
Paul Eggert [Thu, 13 Oct 2022 08:48:10 +0000 (01:48 -0700)]
Simplify recent "File exists" fix

* src/fileio.c (Finsert_file_contents):
Simplify previous change that fixed bug#42431.

2 years agoFix hl-line-mode/global-hl-line-mode logic again
Lars Ingebrigtsen [Thu, 13 Oct 2022 08:08:55 +0000 (10:08 +0200)]
Fix hl-line-mode/global-hl-line-mode logic again

* lisp/hl-line.el (hl-line-mode): Make explicit calls to
(hl-line-mode 1) work again when global-hl-line-mode is on
(bug#58478).

2 years agoFix browse-url-emacs for file: URLs on Windows
Lars Ingebrigtsen [Thu, 13 Oct 2022 07:52:44 +0000 (09:52 +0200)]
Fix browse-url-emacs for file: URLs on Windows

* lisp/net/browse-url.el (browse-url-emacs): Fix up
file:///c:/foo/bar URLs on windows (bug#58464).

2 years ago* lisp/outline.el: Rearrange button/margin functions.
Juri Linkov [Thu, 13 Oct 2022 07:23:44 +0000 (10:23 +0300)]
* lisp/outline.el: Rearrange button/margin functions.

(outline--make-button-overlay, outline--make-margin-overlay)
(outline--insert-open-button, outline--insert-close-button)
(outline--fix-up-all-buttons): Move to the section "Button/margin indicators".

2 years ago* lisp/outline.el (outline--fix-buttons-after-change): New function.
Juri Linkov [Thu, 13 Oct 2022 07:13:07 +0000 (10:13 +0300)]
* lisp/outline.el (outline--fix-buttons-after-change): New function.

(outline-minor-mode): Use it.
(outline--make-margin-overlay): Remove inhibit-read-only.

2 years agoFix misleading "File exists, but cannot be read" in browse-url-emacs
Lars Ingebrigtsen [Thu, 13 Oct 2022 07:00:17 +0000 (09:00 +0200)]
Fix misleading "File exists, but cannot be read" in browse-url-emacs

* src/fileio.c (Finsert_file_contents): Don't signal an error
about not being able to open the file when we're fetching things
via handlers -- in that case, modtime isn't necessarily set, and
if there's a handler, it should take care of this (bug#42431).

2 years agoMerge from origin/emacs-28
Stefan Kangas [Thu, 13 Oct 2022 04:31:52 +0000 (06:31 +0200)]
Merge from origin/emacs-28

4b4b093ab3 ; * admin/make-tarball.txt: Fix typo.

2 years ago; * admin/make-tarball.txt: Fix typo.
Stefan Kangas [Thu, 13 Oct 2022 02:46:32 +0000 (04:46 +0200)]
; * admin/make-tarball.txt: Fix typo.

2 years agosrc/frame.c (do_switch_frame): Fix bug#58343
Stefan Monnier [Wed, 12 Oct 2022 21:06:33 +0000 (17:06 -0400)]
src/frame.c (do_switch_frame): Fix bug#58343

* src/frame.c (do_switch_frame): Move call to `get-mru-window` outside
of the "critical region" where (selected-window) != (frame-selected-window).
* src/minibuf.c (move_minibuffers_onto_frame): Add arg `frame`.
Use it instead of `selected_frame`.  Adjust all callers.
* src/lisp.h (move_minibuffers_onto_frame): Adjust declaration.

2 years agoClarify Native-Compilation Variables slightly
Lars Ingebrigtsen [Wed, 12 Oct 2022 12:59:25 +0000 (14:59 +0200)]
Clarify Native-Compilation Variables slightly

* doc/lispref/compile.texi (Native-Compilation Variables): Clarify
trampoline bit (bug#58429).

2 years agoImprove makefile-imake-mode
Po Lu [Wed, 12 Oct 2022 12:40:03 +0000 (20:40 +0800)]
Improve makefile-imake-mode

* lisp/progmodes/make-mode.el
(makefile-imake-font-lock-keywords): Give Imake priority over
CPP keywords, and don't require comments to start at BOL.
(makefile-imake-mode): Set comment-start to some sensible value.

2 years agoFix thinko in read-string-from-buffer
Lars Ingebrigtsen [Wed, 12 Oct 2022 11:40:51 +0000 (13:40 +0200)]
Fix thinko in read-string-from-buffer

* lisp/textmodes/string-edit.el (string-edit-done): Return an empty
string when the user has entered no text.

2 years agoFix Python completion when point in shell buffer is before prompt
kobarity [Wed, 12 Oct 2022 11:14:33 +0000 (13:14 +0200)]
Fix Python completion when point in shell buffer is before prompt

* lisp/progmodes/python.el (python-shell-completion-at-point): Limit
prompt boundaries check to shell buffer.
* test/lisp/progmodes/python-tests.el (python-shell-completion-2):
(python-shell-completion-native-2): New tests (bug#58441).

2 years agoStop relying on Xt hack to set window manager hints
Po Lu [Wed, 12 Oct 2022 07:07:49 +0000 (15:07 +0800)]
Stop relying on Xt hack to set window manager hints

* src/widget.c (get_wm_shell): Return WMShellWidget.
(update_wm_hints, widget_update_wm_size_hints): Return whether
or not size hints changed.
* src/widget.h: Delete `size_switch'.
* src/widgetprv.h (EmacsFramePart): Likewise.
* src/xterm.c (x_wm_set_size_hint): Set size hints the usual way
if Xt did not set them.  (bug#58412)

2 years agoMerge from origin/emacs-28
Stefan Kangas [Wed, 12 Oct 2022 04:31:27 +0000 (06:31 +0200)]
Merge from origin/emacs-28

3787d0b11a ; * doc/lispref/windows.texi (Window Hooks): Fix markup (b...

2 years ago; lisp/progmodes/project.el: Bump version
Dmitry Gutov [Tue, 11 Oct 2022 21:04:54 +0000 (00:04 +0300)]
; lisp/progmodes/project.el: Bump version

2 years agoAdd trampoline AOT compilation target (bug#58318)
Andrea Corallo [Tue, 11 Oct 2022 19:17:55 +0000 (21:17 +0200)]
Add trampoline AOT compilation target (bug#58318)

* Makefile.in (trampolines): New target.
* lisp/Makefile.in (trampolines): Likewise.
* lisp/emacs-lisp/comp.el (comp-compile-all-trampolines): New
function.

2 years ago; * doc/lispref/windows.texi (Window Hooks): Fix markup (bug#58445).
Eli Zaretskii [Tue, 11 Oct 2022 17:20:44 +0000 (20:20 +0300)]
; * doc/lispref/windows.texi (Window Hooks): Fix markup (bug#58445).

2 years agoAlso avoid setting _NET_WM_USER_TIME on crossing
Po Lu [Tue, 11 Oct 2022 11:55:14 +0000 (19:55 +0800)]
Also avoid setting _NET_WM_USER_TIME on crossing

* src/xterm.c (handle_one_xevent): Stop setting user time prop
on crossing events.

2 years ago; * src/fns.c (HAVE_FAST_UNALIGNED_ACCESS): run faster on mainframes
Mattias Engdegård [Tue, 11 Oct 2022 09:10:46 +0000 (11:10 +0200)]
; * src/fns.c (HAVE_FAST_UNALIGNED_ACCESS): run faster on mainframes

2 years agoMake read-string-from-buffer and string-edit mention each other
Lars Ingebrigtsen [Tue, 11 Oct 2022 11:02:20 +0000 (13:02 +0200)]
Make read-string-from-buffer and string-edit mention each other

* lisp/textmodes/string-edit.el (read-string-from-buffer)
(string-edit): Mention each other in the doc strings.

2 years agoSpeed up scrolling when lines are very long and truncated
Eli Zaretskii [Tue, 11 Oct 2022 10:26:01 +0000 (13:26 +0300)]
Speed up scrolling when lines are very long and truncated

* src/window.c (window_scroll_for_long_lines): New function.
(window_scroll): Call 'window_scroll_for_long_lines' when lines
are very long and truncated on display.  Also, disable
'fontification-functions' during scrolling in that case.
* src/xdisp.c (redisplay_window): When recentering the window's
display, go back to the centering position using a simplified
method, if lines in the buffer are very long and truncated on
display.

2 years agoRemove some more unnecessary calls to block_input
Po Lu [Tue, 11 Oct 2022 07:45:08 +0000 (15:45 +0800)]
Remove some more unnecessary calls to block_input

* src/xterm.c (x_update_opaque_region, show_back_buffer)
(XTbuffer_flipping_unblocked_hook, x_clear_under_internal_border)
(x_after_update_window_line): Remove and add calls to
block_input as required.

2 years agoAccommodate missing spec values in erc-format-message
F. Jason Park [Sat, 8 Oct 2022 04:55:30 +0000 (21:55 -0700)]
Accommodate missing spec values in erc-format-message

* lisp/erc/erc.el (erc-format-message): Although not mentioned in its
log message, commit 5281946fbf6b3cdbec5ce82e0057c71849faf4d2 "Make
format-spec accept function substitutions" also fixed a bug involving
the `ignore-missing' parameter of `format-spec'.  Until now, ERC has
been relying on the old behavior to gracefully handle malformed server
messages.  This commit tries to regain that functionality.

2 years agoAdd gettid to seccomp-filter
Philipp Stephani [Tue, 11 Oct 2022 00:52:51 +0000 (02:52 +0200)]
Add gettid to seccomp-filter

* lib-src/seccomp-filter.c (main): gettid is necessary on RHEL 9.0
(bug#56359).

2 years agoRemove the view-remove-frame-by-deleting variable
Lars Ingebrigtsen [Tue, 11 Oct 2022 00:39:05 +0000 (02:39 +0200)]
Remove the view-remove-frame-by-deleting variable

* lisp/view.el (view-remove-frame-by-deleting): Remove variable
that hasn't been used since 2011 -- 357f93d245344 reworked the
code and stopped using it (bug#58413).

2 years agoFix Python completion failure under certain conditions
kobarity [Mon, 10 Oct 2022 13:24:17 +0000 (22:24 +0900)]
Fix Python completion failure under certain conditions

* lisp/progmodes/python.el (python-shell-send-string-no-output):
Save and restore `comint-last-prompt-overlay' or `comint-last-prompt'.
* test/lisp/progmodes/python-tests.el (python-tests-shell-wait-for-prompt):
New helper function.
(python-tests-with-temp-buffer-with-shell): New helper macro.
(python-shell-completion-1, python-shell-completion-native-1)
(python-shell-completion-native-with-ffap-1)
(python-shell-completion-native-with-eldoc-1): New tests (bug#58389).

2 years agoImprove error message from sqlite-execute
Lars Ingebrigtsen [Tue, 11 Oct 2022 00:18:19 +0000 (02:18 +0200)]
Improve error message from sqlite-execute

* src/sqlite.c (sqlite_prepare_errmsg): New function.
(Fsqlite_execute): Use it to get the same error format for both
execute and select.
(Fsqlite_select): Factored out from here.

2 years agoDon't prompt when killing an Emacs client if it's the last client
Jim Porter [Sun, 9 Oct 2022 22:53:27 +0000 (15:53 -0700)]
Don't prompt when killing an Emacs client if it's the last client

* lisp/server.el (server-kill-emacs-query-function): Ignore the
current client (if any) when checking for live clients (bug#58404).

2 years agoFix Tramp completion on MS Windows
Michael Albinus [Mon, 10 Oct 2022 19:46:24 +0000 (21:46 +0200)]
Fix Tramp completion on MS Windows

* lisp/net/tramp.el (tramp-build-remote-file-name-spec-regexp):
Revert previous change, it's too complicate.
(tramp-build-completion-file-name-regexp):
Use `tramp-prefix-format' instead of `tramp-prefix-regexp'.  (Bug#558133)

2 years agoPort bwrap/allows-stdout test to Ubuntu 22.04.1
Paul Eggert [Mon, 10 Oct 2022 19:35:56 +0000 (12:35 -0700)]
Port bwrap/allows-stdout test to Ubuntu 22.04.1

Without this patch, Ubuntu 22.04.1 x86-64 "make check" reports a
failure in test/src/emacs-tests.el’s
emacs-tests/bwrap/allows-stdout.  One can reproduce the bug
without using the Emacs executable, by running this script:

  #!/bin/bash
  export LC_ALL=C
  exec strace -f -o /tmp/tr bwrap --ro-bind / / --seccomp 20 -- \
    cat /dev/null 20< lib-src/seccomp-filter-exec.bpf

This script exits with status 159, because "cat" didn’t get
started (it got a SIGSYS signal early on).

The command "journalctl -g SECCOMP" indicated that rseq (syscall
334) was the problem.  This syscall is issued by
/lib64/ld-linux-x86-64.so.2 before ‘main’ is called.

There’s another problem with the clone3 syscall, which is used by
pthread_create starting in glibc 2.34.  pthread_create is called
by g_child_watch_source_new, which is called by
init_process_emacs.

* lib-src/seccomp-filter.c (main): Allow rseq, clone3.  This
causes the test to pass.  Perhaps a fancier, more accurate patch
could be written by someone who has the time.

2 years agoAdd a test for sqlite "insert ... returning"
Lars Ingebrigtsen [Mon, 10 Oct 2022 12:09:54 +0000 (14:09 +0200)]
Add a test for sqlite "insert ... returning"

* test/src/sqlite-tests.el (sqlite-returning): Add a test for
"insert ... returning".

2 years agoFix `vc-prepare-patch' docstring
Robert Pluim [Mon, 10 Oct 2022 10:45:45 +0000 (12:45 +0200)]
Fix `vc-prepare-patch' docstring

* lisp/vc/vc.el (vc-prepare-patch): Correct description of
`vc-prepare-patches-separately'.

2 years ago; Update the doc string of 'compilation-auto-jump-to-first-error'
Eli Zaretskii [Mon, 10 Oct 2022 09:37:04 +0000 (12:37 +0300)]
; Update the doc string of 'compilation-auto-jump-to-first-error'

* lisp/progmodes/compile.el
(compilation-auto-jump-to-first-error): Doc fix.  (Bug#58407)

2 years ago; * doc/lispref/text.texi (Database): Fix markup in last change.
Eli Zaretskii [Mon, 10 Oct 2022 09:14:33 +0000 (12:14 +0300)]
; * doc/lispref/text.texi (Database): Fix markup in last change.

2 years agoSupport "insert into ... returning ..." in sqlite-execute
Lars Ingebrigtsen [Mon, 10 Oct 2022 08:58:33 +0000 (10:58 +0200)]
Support "insert into ... returning ..." in sqlite-execute

* doc/lispref/text.texi (Database): Mention it.
* src/sqlite.c (Fsqlite_execute): Support syntax like "insert into
... returning ..." (bug#58390).

2 years agoFix some indentation in Fsqlite_execute
Lars Ingebrigtsen [Sun, 9 Oct 2022 15:06:46 +0000 (17:06 +0200)]
Fix some indentation in Fsqlite_execute

* src/sqlite.c (Fsqlite_execute): Fix indentation.

2 years ago; Fix last change.
Eli Zaretskii [Mon, 10 Oct 2022 08:09:43 +0000 (11:09 +0300)]
; Fix last change.

2 years ago; Clarify correct use of 'xref-query-replace-in-results'
Eli Zaretskii [Mon, 10 Oct 2022 08:05:18 +0000 (11:05 +0300)]
; Clarify correct use of 'xref-query-replace-in-results'

* lisp/progmodes/xref.el (xref--query-replace-1): Improve the
user-error message.
(xref-query-replace-in-results): Clarify restrictions in the doc
string.

* doc/emacs/maintaining.texi (Xref Commands, Identifier Search):
Clarify the correct usage of 'xref-query-replace-in-results'.

2 years ago; * lisp/progmodes/gdb-mi.el (gdb): Fix a typo. (Bug#58400)
Eli Zaretskii [Mon, 10 Oct 2022 06:42:19 +0000 (09:42 +0300)]
; * lisp/progmodes/gdb-mi.el (gdb): Fix a typo.  (Bug#58400)

2 years agoTry to speed up extended command shorthand computation
Michael Heerdegen [Sun, 18 Sep 2022 10:26:53 +0000 (12:26 +0200)]
Try to speed up extended command shorthand computation

Discussed in Bug#51143.

* lisp/simple.el (execute-extended-command--shorter): Compute a
complete list of `commandp' symbols once.  This significantly speeds
up complicated cases while the slowdown of simple cases is still
accetable.

2 years agoSet the PARENTS argument for language environments
समीर सिंह Sameer Singh [Sat, 8 Oct 2022 10:07:00 +0000 (15:37 +0530)]
Set the PARENTS argument for language environments

* lisp/language/indonesian.el
* lisp/language/philippine.el
* lisp/language/misc-lang.el
(set-language-info-alist): Add PARENTS argument.  (Bug#58376)

2 years agoMake Fsqlite_select error data better
Lars Ingebrigtsen [Sun, 9 Oct 2022 14:17:22 +0000 (16:17 +0200)]
Make Fsqlite_select error data better

* src/sqlite.c (Fsqlite_select): Add more the more specific error
text to the error data (bug#58363).

2 years agoClean up Fsqlite_select slightly
Lars Ingebrigtsen [Sun, 9 Oct 2022 00:19:14 +0000 (02:19 +0200)]
Clean up Fsqlite_select slightly

* src/sqlite.c (Fsqlite_select): Clean up code slightly.

2 years agoFix user time handling bug on GNOME Shell and Metacity
Po Lu [Sun, 9 Oct 2022 11:58:07 +0000 (19:58 +0800)]
Fix user time handling bug on GNOME Shell and Metacity

* src/xfns.c (x_window): Avoid extraneous
XChangeWindowAttributes.
* src/xterm.c (x_display_set_last_user_time): New argument
SET_PROPERTY.  Do not change the user time property if it is not
true.  All callers changed.
(handle_one_xevent): Avoid setting the user time property on
LeaveNotify and XI_Leave events.

2 years agoMerge from origin/emacs-28
Stefan Kangas [Sun, 9 Oct 2022 04:31:06 +0000 (06:31 +0200)]
Merge from origin/emacs-28

32ef7550ed ; Improve documentation of 'file-in-directory-p'

2 years ago* lisp/url/url-file.el (url-file): Don't bind `coding-system-for-read`
Stefan Monnier [Sun, 9 Oct 2022 03:06:03 +0000 (23:06 -0400)]
* lisp/url/url-file.el (url-file): Don't bind `coding-system-for-read`

Binding it causes errors when some of the enclosed code ends up
loading a `.el` file, and it is unnecessary since the rest of
the code (in `url-file-asynch-callback`) is already careful to
use `insert-file-contents-literally`.

2 years ago; * test/src/fns-tests.el (fns-tests--string-lessp-cases): Extend.
Mattias Engdegård [Sat, 8 Oct 2022 16:39:48 +0000 (18:39 +0200)]
; * test/src/fns-tests.el (fns-tests--string-lessp-cases): Extend.

2 years agoRestrict string-lessp vectorisation to safe architectures
Mattias Engdegård [Sat, 8 Oct 2022 13:25:50 +0000 (15:25 +0200)]
Restrict string-lessp vectorisation to safe architectures

* src/fns.c (HAVE_FAST_UNALIGNED_ACCESS): New.
(Fstring_lessp): Only use word operations where safe, because string
data from purespace may be unaligned.

2 years agoBetter Lisp_String comments
Mattias Engdegård [Sat, 8 Oct 2022 14:24:40 +0000 (16:24 +0200)]
Better Lisp_String comments

* src/lisp.h (struct Lisp_String): Comments improved.
* src/pdumper.c (dump_string): Update hash (comment change only).

2 years agoImproved format string error message (bug#58168)
Mattias Engdegård [Fri, 7 Oct 2022 16:17:40 +0000 (18:17 +0200)]
Improved format string error message (bug#58168)

* src/editfns.c (styled_format): Better message when the conversion
char is non-ASCII from a unibyte format string.

2 years agopackage.el: Understand a few more variations in tarball formats
Stefan Monnier [Sat, 8 Oct 2022 16:19:40 +0000 (12:19 -0400)]
package.el: Understand a few more variations in tarball formats

* lisp/emacs-lisp/package.el (package-untar-buffer): Fix thinko.
(package-tar-file-info): Handle the case where the first file is in
a subdirectory.

* test/lisp/emacs-lisp/package-tests.el (package-test-bug58367): New test.
* test/lisp/emacs-lisp/package-resources/ustar-withsub-0.1.tar:
* test/lisp/emacs-lisp/package-resources/v7-withsub-0.1.tar: New files.

2 years ago; * lisp/vc/vc.el (vc-prepare-patches-separately): Doc fix.
Eli Zaretskii [Sat, 8 Oct 2022 14:40:25 +0000 (17:40 +0300)]
; * lisp/vc/vc.el (vc-prepare-patches-separately): Doc fix.

2 years ago; * lisp/vc/vc.el (vc-prepare-patches-separately): Fix docstring
Philip Kaludercic [Sat, 8 Oct 2022 13:06:26 +0000 (15:06 +0200)]
; * lisp/vc/vc.el (vc-prepare-patches-separately): Fix docstring

Noticed by German Pacenza.

2 years ago; Add missing documentation strings
Philip Kaludercic [Sat, 8 Oct 2022 12:41:53 +0000 (14:41 +0200)]
; Add missing documentation strings

* lisp/vc/vc.el (vc-read-revision): Add a docstring.
(vc-read-multiple-revisions): Add a docstring.

2 years agoMake sqlite-select signal errors when there's an error
Lars Ingebrigtsen [Sat, 8 Oct 2022 13:41:14 +0000 (15:41 +0200)]
Make sqlite-select signal errors when there's an error

* src/sqlite.c (load_dll_functions): Update.
(Fsqlite_select): Signal an error when there's an error preparing
the statement.

2 years agoFix vtable-insert-object line insertion
Lars Ingebrigtsen [Sat, 8 Oct 2022 13:26:01 +0000 (15:26 +0200)]
Fix vtable-insert-object line insertion

* lisp/emacs-lisp/vtable.el (vtable-insert-object): Pass in the
correct ellipsis values (bug#58370).
(vtable--insert-line): Don't bug out on missing optional arguments.

2 years agoFix misleading prompt in vc-git-create-tag
Visuwesh [Sat, 8 Oct 2022 13:13:48 +0000 (15:13 +0200)]
Fix misleading prompt in vc-git-create-tag

* lisp/vc/vc-git.el (vc-git-create-tag): Actually pass the DEFAULT
argument to vc-read-revision (bug#58378).

2 years agoFix typo in etc/TODO
Lars Ingebrigtsen [Sat, 8 Oct 2022 12:57:47 +0000 (14:57 +0200)]
Fix typo in etc/TODO

2 years ago* etc/TODO (Wishlist items): Add libarchive(3) integration.
Michael Albinus [Sat, 8 Oct 2022 12:54:38 +0000 (14:54 +0200)]
* etc/TODO (Wishlist items): Add libarchive(3) integration.

2 years agoMention seq-keep in shortdoc
Lars Ingebrigtsen [Sat, 8 Oct 2022 11:20:17 +0000 (13:20 +0200)]
Mention seq-keep in shortdoc

* lisp/emacs-lisp/shortdoc.el (sequence): Mention seq-keep.

2 years ago; Improve documentation of 'file-in-directory-p'
Eli Zaretskii [Sat, 8 Oct 2022 11:13:50 +0000 (14:13 +0300)]
; Improve documentation of 'file-in-directory-p'

* lisp/files.el (file-in-directory-p): Clarify doc string.

* doc/lispref/files.texi (Truenames): Move the documentation of
'file-in-directory-p' from here...
(Contents of Directories): ...to here.  Add index entries.
(Bug#58364)

2 years agoAdd a VC command to prepare patches
Philip Kaludercic [Mon, 3 Oct 2022 18:54:38 +0000 (20:54 +0200)]
Add a VC command to prepare patches

* doc/emacs/vc1-xtra.texi (Miscellaneous VC):  Add new node.
(Editing VC Commands):  Document new feature.
* etc/NEWS:  Mention 'vc-prepare-patch'.
* lisp/vc/log-view.el: Autoload 'log-view-get-marked'.
* lisp/vc/vc-git.el (vc-git-prepare-patch):  Add Git implementation.
* lisp/vc/vc-hg.el (vc-git-prepare-patch):  Add Mercurial implementation.
* lisp/vc/vc-bzr.el (vc-git-prepare-patch):  Add Bazaar implementation.
* lisp/vc/vc.el (vc-read-revision):  Add a MULTIPLE argument.
(vc-read-multiple-revisions):  Add an auxiliary function that always
calls 'vc-read-revision' with a non-nil value for MULTIPLE.
(vc-prepare-patches-separately):  Add user option.
(message-goto-body):  Declare function.
(message--name-table):  Declare function.
(vc-default-prepare-patch): Add a default implementation.
(vc-prepare-patch):  Add command.  (Bug#57400)

2 years agoStop passing CurrentTime to SetInputFocus
Po Lu [Sat, 8 Oct 2022 08:38:30 +0000 (16:38 +0800)]
Stop passing CurrentTime to SetInputFocus

* src/xterm.c (xi_focus_handle_for_device, handle_one_xevent):
Set the last user time where required for focus to be handled
correctly.
(x_focus_frame): Do not perform actions prohibited by the ICCCM.

2 years agoAdd support for the Coptic script (bug#58330)
समीर सिंह Sameer Singh [Thu, 6 Oct 2022 12:04:28 +0000 (17:34 +0530)]
Add support for the Coptic script (bug#58330)

* lisp/language/misc-lang.el ("Coptic"): New language environment.
Add sample text and input method.
* lisp/international/fontset.el (script-representative-chars)
(setup-default-fontset): Support coptic.
* lisp/leim/quail/misc-lang.el ("coptic"): New input method.

* etc/HELLO: Add a Coptic greeting.
* etc/NEWS: Announce the new language environment.

2 years agoMerge from origin/emacs-28
Stefan Kangas [Sat, 8 Oct 2022 04:30:23 +0000 (06:30 +0200)]
Merge from origin/emacs-28

cfb1e21844 Update name of hs-mouse-toggle-hiding in Emacs manual

2 years ago; Silence byte-compiler in benchmark.el
Stefan Kangas [Fri, 7 Oct 2022 21:14:52 +0000 (23:14 +0200)]
; Silence byte-compiler in benchmark.el

* lisp/emacs-lisp/benchmark.el (cl-lib): Require.

2 years agoPrefer defvar-keymap in bibtex.el
Stefan Kangas [Fri, 7 Oct 2022 20:43:51 +0000 (22:43 +0200)]
Prefer defvar-keymap in bibtex.el

* lisp/textmodes/bibtex.el (bibtex-mode-map): Prefer defvar-keymap.

2 years agoFix setting the wallpaper with "swaybg" and "wbg"
Stefan Kangas [Fri, 7 Oct 2022 20:07:09 +0000 (22:07 +0200)]
Fix setting the wallpaper with "swaybg" and "wbg"

* lisp/image/wallpaper.el (wallpaper-setter): Add 'init-action'
and 'detach' fields to structure.
(wallpaper--init-action-kill): New helper function.
(wallpaper--default-setters): Use above new fields for "swaybg" and
"wbg", to start/restart the corresponding processes as needed.
(wallpaper-default-set-function): Call 'init-action' function if
there is one.  If 'detach', use 'call-process' instead of
'start-process'.  (Bug#57781)

* test/lisp/image/wallpaper-tests.el (wallpaper--find-setter)
(wallpaper--find-setter/call-predicate)
(wallpaper--find-setter/set-current-setter)
(wallpaper-set/runs-command, wallpaper-set/runs-command/detach)
(wallpaper-set/calls-init-action)
(wallpaper-set/calls-wallpaper-set-function): New tests.

2 years agosubr.el (inhibit-point-motion-hooks): Mark it as obsolete
Stefan Monnier [Fri, 7 Oct 2022 18:15:40 +0000 (14:15 -0400)]
subr.el (inhibit-point-motion-hooks): Mark it as obsolete

When Emacs-25 changed the default of `inhibit-point-motion-hooks` to t,
/etc/NEWS declared it as obsolete and so did its docstring, but
it was not marked as obsolete so as not to emit too many warnings
in code where it was impractical to remove the let-binding while
keeping backward compatibility with older Emacsen.
Those backward compatibility issues are not serious any more now that
Emacs-25 is itself considered old.

* lisp/subr.el (inhibit-point-motion-hooks): Mark it as obsolete.
* src/textprop.c (inhibit-point-motion-hooks): Don't mention it being
obsolete in the docstring any more.
* lisp/simple.el (line-move-1, line-move-finish): Silence warnings.

2 years ago* lisp/isearch.el (isearch-search): Don't bind `inhibit-point-motion-hooks`
Stefan Monnier [Fri, 7 Oct 2022 18:07:17 +0000 (14:07 -0400)]
* lisp/isearch.el (isearch-search): Don't bind `inhibit-point-motion-hooks`

The let-binding was added back in 1997 (commit 79c7a4fa5f974a9d3b)
"because we might have to search inside invisible and intangible text".
So it's been redundant since Emacs-25 changed the default to t.

2 years agoverilog-mode.el: Don't bind `inhibit-point-motion-hooks`
Stefan Monnier [Fri, 7 Oct 2022 17:54:36 +0000 (13:54 -0400)]
verilog-mode.el: Don't bind `inhibit-point-motion-hooks`

Keep binding it in Emacs<25 but not in Emacs≥25 (where such bindings
are redundant and the var is declared obsolete).

* lisp/progmodes/verilog-mode.el (verilog-save-buffer-state):
Don't bind `inhibit-point-motion-hooks` if Emacs≥25.
(verilog-save-font-no-change-functions): Same, and refrain from
binding `before/after-change-functions` as well while we're at it,
since `inhibit-modification-hooks` already covers it in Emacs≥25.

2 years ago(nxml-with-invisible-motion): Delete macro.
Stefan Monnier [Fri, 7 Oct 2022 17:25:36 +0000 (13:25 -0400)]
(nxml-with-invisible-motion): Delete macro.

Don't use this macro any more since it doesn't do anything since Emacs-25
changed the default of `inhibit-point-motion-hooks` to t.

* lisp/nxml/nxml-util.el (nxml-with-invisible-motion): Delete macro.
* lisp/nxml/nxml-mode.el (nxml-mode, nxml-cleanup):
* lisp/nxml/rng-valid.el (rng-do-some-validation):
* lisp/nxml/rng-nxml.el (rng-set-state-after): Don't use it.