1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2025-12-15 18:40:39 -08:00
Commit graph

171346 commits

Author SHA1 Message Date
Po Lu
7a0f4de3c1 Improve C++ standard library detection on Android
* configure.ac: Stop relaying --with-ndk-cxx-shared to the
nested invocation of configure.

* build-aux/ndk-build-helper-1.mk (SYSTEM_LIBRARIES):

* build-aux/ndk-build-helper-2.mk (SYSTEM_LIBRARIES): Insert all
of the C++ libraries available on Android.

* configure.ac: Call ndk_LATE and ndk_LATE_EARLY within if
statement at toplevel, averting needless calls to AC_PROG_CXX.

* cross/ndk-build/Makefile.in (NDK_BUILD_CXX_STL)
(NDK_BUILD_CXX_LDFLAGS):

* cross/ndk-build/ndk-build.mk.in (NDK_BUILD_CXX_STL)
(NDK_BUILD_CXX_LDFLAGS): New variables.

* cross/ndk-build/ndk-resolve.mk (NDK_SYSTEM_LIBRARIES):
Introduce several other C++ libraries sometimes present on
Android.
(NDK_SO_EXTRA_FLAGS_$(LOCAL_MODULE)): Insert NDK_BUILD_CXX_STL
when any of these new C++ libraries are requested.

* m4/ndk-build.m4: Completely rewrite C++ compiler and library
detection.

* java/org/gnu/emacs/EmacsNative.java (EmacsNative): Attempt to
load more libraries from static initializer.

* java/INSTALL: Remove obsolete information.
2024-03-17 19:34:09 +08:00
Stefan Monnier
445e2499ba debug.el: Prevent re-entering the debugger for the same error
We can have several active `handler-bind`s that all want to invoke the
debugger, in which case we can have the following sequence:

- The more deeply nested handler calls the debugger.
- After a while the user invokes `debugger-continue`.
- `signal_or_quit` propagates the error up the stack to the
  second handler, which calls the debugger again.
- The user thus ends up right back at the same place, as if
  `debugger-continue` had not be processed.

Fix this by remembering the last processed error and skipping
the debugger if we bump into it again.

* lisp/emacs-lisp/debug.el (debugger--last-error): New var.
(debugger--duplicate-p): New function.
(debug): Use them.
2024-03-16 23:10:48 -04:00
Basil L. Contovounesios
ad3a3ad6e6 ; Pacify -Wmaybe-uninitialized in coding.c.
Warning seen with GCC 13 -Og.
2024-03-16 14:15:25 +01:00
Eli Zaretskii
685f4295f9 ; Document more DND functions with limited support
* lisp/dnd.el (dnd-begin-text-drag, dnd-begin-file-drag)
(dnd-begin-drag-files): Document platforms that support these
functions.  (Bug#69662)
2024-03-16 12:58:33 +02:00
Eli Zaretskii
d855f1c3f9 ; Fix recent changes in documentation
* doc/lispref/markers.texi (Information from Markers):
* etc/NEWS: Improve description of 'marker-last-position'.
2024-03-16 11:58:56 +02:00
Eli Zaretskii
d60d625f6e Merge branch 'master' of git.sv.gnu.org:/srv/git/emacs 2024-03-16 05:52:31 -04:00
Eli Zaretskii
cc8a2c57b5 Merge from origin/emacs-29
3b791ebbe1 ; Fix 'usage:' keyword in Ffile_name_concat doc.
ed48b0d657 ; * CONTRIBUTE: Ask not to use non-ASCII unless necessary.
b708e639d6 ; * src/lread.c (maybe_swap_for_eln): Clarify warning mes...
db027a0697 ; Fix bibtex-biblatex-field-alist docstring typo.
a9be5c7ea9 ; * doc/lispref/control.texi (Conditionals): Add missing ...
db5915f30b Fix 'with-sqlite-transaction'
fe491173e8 ; * doc/emacs/files.texi (Image Mode): Fix typo (bug#69671).
2024-03-16 05:47:41 -04:00
Martin Rudalics
c12852bbf6 Document and announce 'marker-last-position'
* doc/lispref/markers.texi (Information from Markers): Document
'marker-last-position'.
* etc/NEWS: Announce 'marker-last-position'.
* src/window.c (window_restore_killed_buffer_windows): Minor
doc-string fix.
* doc/lispref/windows.texi (Window Configurations): Minor fix.
2024-03-16 10:46:02 +01:00
Martin Rudalics
899ea79310 In window-related documentation write 'symbol' instead of 'constant'
Suggested by Michael Heerdegen <michael_heerdegen@web.de>.

* src/window.c (window_restore_killed_buffer_windows): In
doc-string write 'symbol' instead of 'constant'.
* lisp/window.el (display-buffer--lru-window)
(display-buffer-use-least-recent-window): In doc-strings write
'symbol' instead of 'constant'.
* doc/lispref/windows.texi (Window Configurations): Write
'symbol' instead of 'constant'.
2024-03-16 10:10:29 +01:00
Po Lu
deebf74b0e ; * src/xterm.c (syms_of_xterm): Fix typo. 2024-03-16 15:18:07 +08:00
Po Lu
28e481bf7a Respond to default action from Gnus notifications
* lisp/gnus/gnus-notifications.el (gnus-notifications-action):
Consider default equivalent to read.
2024-03-16 15:16:00 +08:00
Po Lu
6585299216 Support x-*-keysym on Android
* src/androidterm.c (android_android_to_emacs_modifiers)
(android_emacs_to_android_modifiers, syms_of_androidterm): Port
x-*-keysym from xterm.c.
2024-03-16 15:13:09 +08:00
Po Lu
4d03f70b7f Correct doc strings for x-*-keysym
* src/xterm.c (syms_of_xterm): Clarify whether x-*-keysym
affects the modifier key reported for a keysym or the other way
around.
2024-03-16 15:12:33 +08:00
Po Lu
c77e35efd3 * doc/lispref/frames.texi (Window System Selections): Fix misuse of xref. 2024-03-16 09:55:23 +08:00
Po Lu
6461854f47 ; Circumvent miscompilations on Sun C 5.12 (148917-07)
* src/minibuf.c (Ftry_completion, Fall_completions): Transform
ternary expressions after open-ended if statements into proper
if/else statements.
2024-03-16 09:50:58 +08:00
Po Lu
bbbf1e6f2d Fix calc.texi for Texinfo 4.13
* doc/misc/calc.texi (Fractions): Replace instances of @U with
raw Unicode characters and adjust the document encoding
suitably.
2024-03-16 09:29:42 +08:00
Basil L. Contovounesios
983d173099 ; * src/eval.c (Fhandler_bind_1): Fix docstring. 2024-03-16 00:23:41 +01:00
Basil L. Contovounesios
3b791ebbe1 ; Fix 'usage:' keyword in Ffile_name_concat doc. 2024-03-16 00:20:41 +01:00
Stefan Monnier
7231a89524 * lisp/emacs-lisp/bindat.el (sint): Burp in dynbind (bug#69749) 2024-03-15 12:45:09 -04:00
Andrea Corallo
0055362855 * Don't install unnecessary trampolines (bug#69573)
* lisp/emacs-lisp/comp-run.el (comp-subr-trampoline-install):
Check that subr-name actually matches the target subr.
2024-03-15 14:44:22 +01:00
Andrea Corallo
c393c04679 * lisp/emacs-lisp/advice.el (comp-subr-trampoline-install): Don't declare. 2024-03-15 14:43:40 +01:00
Eli Zaretskii
bf3d296d24 ; Fix documentation of a recent change (bug#68235)
* etc/NEWS:
* doc/lispref/windows.texi (Window Configurations): Improve
wording of 'window-restore-killed-buffer-windows's doc.
* src/window.c (syms_of_window)
<window-restore-killed-buffer-windows>: Doc fix.

* etc/NEWS:
* doc/lispref/buffers.texi (Buffer Names): Document
'buffer-last-name'.
2024-03-15 14:22:14 +02:00
Eli Zaretskii
ed48b0d657 ; * CONTRIBUTE: Ask not to use non-ASCII unless necessary. 2024-03-15 13:29:31 +02:00
Martin Rudalics
3858e4f229 Fix bug with CHECK_STRUCTS introduced by last buffer.h change
* src/pdumper.c (dump_buffer): Fix HASH_buffer_.  Assign
last_name_ field.
2024-03-15 11:53:31 +01:00
Martin Rudalics
5bba1b95b8 Further adjustments for restoring killed buffer windows (Bug#68235)
* etc/NEWS: Announce 'window-restore-killed-buffer-windows'.
* src/buffer.h (struct buffer) : New field last_name_.
* src/buffer.c (Fbuffer_last_name): New function to return last
name of buffer before it was killed or renamed.
(bset_last_name, Fget_buffer_create, Fmake_indirect_buffer)
(Frename_buffer, Fkill_buffer, init_buffer_once): Set buffer's
last_name_ field accordingly.
* src/window.c (window_restore_killed_buffer_windows): New
variable replacing Vwindow_kept_windows_functions.
(Fset_window_configuration): Use
window_restore_killed_buffer_windows instead of
Vwindow_kept_windows_functions.
* lisp/window.el (window--state-put-2, window-state-put): Use
'window-restore-killed-buffer-windows' instead of
'window-kept-windows-functions'.
* doc/lispref/windows.texi (Window Configurations): Describe
'window-restore-killed-buffer-windows' which replaces
'window-kept-windows-functions'.
2024-03-15 10:35:27 +01:00
Eli Zaretskii
1c4233b9a3 ; Fix documentation of 'flyspell-check-changes'
* lisp/textmodes/flyspell.el (flyspell-check-changes): Doc fixes.

* etc/NEWS: Improve wording of entry for 'flyspell-check-changes'.
2024-03-15 10:44:23 +02:00
Eli Zaretskii
ebd32040e0 ; * src/xwidget.c (xwidget-webkit-disable-javascript): Doc fix. 2024-03-15 10:29:06 +02:00
Juri Linkov
ffbf876a93 * lisp/vc/diff-mode.el (diff-mode-menu): Add menu item "Apply all hunks".
It's bound to the recently added command 'diff-apply-buffer'.
2024-03-15 09:45:48 +02:00
Spencer Baugh
9dcb28d601 With visible-completions, only bind RET when completion is selected
Previously, if minibuffer-visible-completions was non-nil, we bound RET
whenever the *Completions* buffer was visible.  This meant that RET in
completion-in-region would not enter a newline, which is a somewhat
annoying behavior change from minibuffer-visible-completions=nil.

Now, we only bind RET when a completion is selected.  This means
RET will newline in completion-in-region.

So that completion help continues to suggest the correct keys,
we also add minibuffer-visible-completions--always-bind.  When
let-bound to a non-nil value, it makes the
minibuffer-visible-completions binds always active.  We let-bind
it around substitute-command-keys.

* lisp/minibuffer.el (minibuffer-visible-completions--always-bind)
(minibuffer-visible-completions--filter): Add.
(minibuffer-visible-completions-bind): Use
minibuffer-visible-completions--filter.  (bug#68801)
* lisp/simple.el (minibuffer-visible-completions--always-bind)
(completion-setup-function): Let-bind
minibuffer-visible-completions--always-bind so the completion
help is correct.
2024-03-15 09:40:48 +02:00
Kévin Le Gouguec
09ab669351 Keep indenting text when 'shr-fill-text' is nil (bug#69555)
The 'shr-fill-...' functions handle both hard-filling (adding
newlines to break long lines) and indentation.  Setting
'shr-fill-text' to nil currently causes these functions to be
short-circuited completely, so e.g. blockquotes are no longer
indented, whereas the intent of this user option is only to
prevent hard-filling to let visual-line-mode reflow text.

* lisp/net/shr.el (shr-fill-lines): Document that the function
handles more than just filling; move the 'shr-fill-text' check...
(shr-fill-line): ... here, after indentation has been taken care
of.
* test/lisp/net/shr-resources/blockquote.html:
* test/lisp/net/shr-resources/blockquote.txt: New test resources.
* test/lisp/net/shr-tests.el (shr-test--rendering-check): Rename
from 'shr-test', to make the relationship with the 'rendering'
testcase clearer; prefer 'file-name-concat' to 'format'; raise
ERT failure if need be, calling (ert-fail ...) directly instead
of (should (not (list ...))).
(shr-test--rendering-extra-configs): New variable to easily check
that user customizations do not degrade rendering.
(rendering): Consult that new variable; delegate failure-raising
to reduce duplication.
2024-03-15 07:50:31 +01:00
Po Lu
1be33963f0 ; * src/androidselect.c (Fandroid_notifications_notify): Typo in doc string. 2024-03-15 11:52:11 +08:00
Po Lu
c453c82dc6 * src/sfntfont-android.c (init_sfntfont_android): Fix SDK check. 2024-03-15 11:52:11 +08:00
Dmitry Gutov
77a86d738e (project--value-in-dir): Ensure that the global value is still honored
* lisp/progmodes/project.el (project--value-in-dir):
Ensure that the global value of the variable is still honored,
when the variable is not in dir-locals.
2024-03-15 04:28:45 +02:00
Patrick Bader
5037b9eed7 fix: project submodule detection does not work for worktrees 2024-03-15 04:26:02 +02:00
Stefan Monnier
9422a67374 (set-auto-mode): Streamline to fix bug#67795
The old code tested if the mode function is `fboundp` but in an
inconsistent way and without paying attention to
`major-mode-remap`.

* lisp/files.el (set-auto-mode-0): Return `:keep` rather than nil if
the mode was already set.  And emit a warning when the mode function
doesn't exist.
(set-auto-mode): Remove checks that the mode function exists now that
`set-auto-mode-0` does it for us.  Adjust to the new return values of
that function, and simplify the code using a big `or` instead of
a sequence of steps each setting&testing `done`.
(hack-local-variables--find-variables): Use `major-mode-remap`
when skipping the "mode:" entries that specify modes we don't have.
Also, when (eq handle-mode t), don't bother building a list of results
only to return a single element in the end.
2024-03-14 22:15:41 -04:00
Stefan Monnier
c8c0d0a955 (customize-mode): Fix bug#69501
* lisp/cus-edit.el (customize-mode): Use the predicate arg of
`completing-read` instead of binding `completion-regexp-list`.
2024-03-14 22:00:14 -04:00
Po Lu
9a2c7d865f Fix last change
* src/xwidget.c (Fmake_xwidget): Cast boolean value to gboolean.
(syms_of_xwidget): Fix coding style and improve doc string.
2024-03-15 08:36:21 +08:00
Eli Zaretskii
b708e639d6 ; * src/lread.c (maybe_swap_for_eln): Clarify warning message. 2024-03-14 21:08:36 +02:00
Juri Linkov
f03f14165e * lisp/textmodes/flyspell.el (flyspell-check-changes): New user option.
(flyspell--mode-on): Add flyspell-check-changes to post-command-hook
when flyspell-check-changes is non-nil.
(flyspell--mode-off): Remove flyspell-check-changes from post-command-hook.
(flyspell-check-changes): New function (bug#61874).
2024-03-14 20:11:33 +02:00
Juri Linkov
bd6b64e0a8 * lisp/progmodes/project.el: Don't run modes from .dir-locals.el.
(project--value-in-dir): Use 'alist-get' on 'file-local-variables-alist'
to avoid calling 'hack-local-variables-apply' via
'hack-dir-local-variables-non-file-buffer' because it might enable
undesirable modes such as flyspell-mode in a temporary buffer (bug#69740).
2024-03-14 19:37:44 +02:00
Juri Linkov
f3deaa117a Context menu for project (bug#69566)
* lisp/menu-bar.el (menu-bar-project-item): New variable from
'project-menu-entry'.
(menu-bar-tools-menu): Use 'menu-bar-project-item'.

* lisp/mouse.el (context-menu-functions): Add
'context-menu-project' to choice.
(context-menu-project): New function.

* lisp/progmodes/project.el (project-menu-entry): Remove variable.
(project-mode-line-map): Use 'menu-bar-project-item' instead of
'project-menu-entry'.
2024-03-14 19:29:16 +02:00
Pankaj Jangid
eae2c73edb Add language server for Move to eglot
* lisp/progmodes/eglot.el (eglot-server-programs): Added
'move-analyzer' language server.  (Bug#69796)
2024-03-14 17:16:38 +02:00
Liu Hui
a7057745f5 Detect the readline support for Python shell completion
* lisp/progmodes/python.el
(python-shell-comint-watch-for-first-prompt-output-filter):
Detect the readline support.
(python-shell-readline-completer-delims): Update docstring.
(python-shell-completion-native-setup): Move the readline
detection code to ...
(python-shell-readline-detect): ... new function.
(python-shell-completion-native-turn-on-maybe): Skip if Python
has no readline support.
(python-shell-completion-at-point): Respect the delimiter of
readline completer in non-native completion.
* test/lisp/progmodes/python-tests.el
(python-shell-completion-at-point-1)
(python-shell-completion-at-point-native-1)
(python-completion-at-point-1, python-completion-at-point-2)
(python-completion-at-point-pdb-1)
(python-completion-at-point-while-running-1)
(python-completion-at-point-native-1)
(python-completion-at-point-native-2)
(python-completion-at-point-native-with-ffap-1)
(python-completion-at-point-native-with-eldoc-1): Skip tests if
Python has no readline support.
(python-shell-completion-at-point-jedi-completer): Add test for
non-native Python shell completion. (bug#68559)
2024-03-14 15:09:56 +01:00
Adam Porter
c94d680f6e Handle the case where 'vtable-update-object' doesn't find old object
* lisp/emacs-lisp/vtable.el (vtable-update-object): If OLD-OBJECT
is not found, don't call ELT, since SEQ-POSITION may return nil.
(Bug#69664)
2024-03-14 12:46:46 +02:00
Tim Landscheidt
6d1c1fca0a ; Simplify (with-current-buffer (get-buffer ...) ...)
There's no need to call 'get-buffer', since 'with-current-buffer'
does that internally.
* lisp/calendar/todo-mode.el (todo-merge-category):
* lisp/comint.el (comint-dynamic-list-completions):
* lisp/emacs-lisp/checkdoc.el (checkdoc-error):
* lisp/emacs-lisp/debug.el (debug, debugger-record-expression):
* lisp/emacs-lisp/eieio-opt.el (eieio-browse):
* lisp/emacs-lisp/re-builder.el (reb-restart-font-lock):
* lisp/erc/erc-dcc.el (erc-dcc-do-LIST-command):
* lisp/eshell/em-unix.el (eshell-poor-mans-grep):
* lisp/gnus/gnus-group.el (gnus-add-mark):
* lisp/net/eww.el (eww-next-bookmark, eww-previous-bookmark):
* lisp/net/sieve.el (sieve-upload):
* lisp/net/tramp-cmds.el (tramp-cleanup-some-buffers):
* lisp/obsolete/quickurl.el (quickurl-list-populate-buffer):
* lisp/org/ob-calc.el: (org-babel-execute:calc):
* lisp/org/org-agenda.el (org-agenda-use-sticky-p):
* lisp/pcomplete.el (pcomplete-show-completions):
* lisp/progmodes/bug-reference.el
(bug-reference--try-setup-gnus-article):
* lisp/progmodes/idlw-help.el
(idlwave-highlight-linked-completions):
* lisp/progmodes/verilog-mode.el (verilog-preprocess):
* lisp/replace.el (occur-1):
* lisp/term.el (term-dynamic-list-completions):
* lisp/time.el (world-clock-update):
* lisp/url/url-cache.el (url-store-in-cache):
* lisp/vc/vc-cvs.el (vc-cvs-merge, vc-cvs-merge-news):
* lisp/vc/vc-rcs.el (vc-rcs-system-release):
* lisp/vc/vc-svn.el (vc-svn-merge, vc-svn-merge-news):
* test/lisp/calendar/icalendar-tests.el
(icalendar-tests--get-error-string-for-export):
* test/lisp/erc/erc-dcc-tests.el
(pcomplete/erc-mode/DCC--get-1flag)
(pcomplete/erc-mode/DCC--get-2flags)
(pcomplete/erc-mode/DCC--get-2flags-reverse):
* test/lisp/erc/erc-networks-tests.el
(erc-networks--rename-server-buffer--existing--noreuse):
* test/lisp/erc/erc-scenarios-services-misc.el
(erc-scenarios-services-misc--reconnect-retry-nick):
* test/lisp/erc/erc-tests.el (erc--refresh-prompt):
Replace (with-current-buffer (get-buffer ...) ...) with
(with-current-buffer ...).
2024-03-14 12:40:26 +02:00
Phil Hagelberg
3807f380b3 bug#69685: Add language server for Fennel to eglot
* lisp/progmodes/eglot.el (eglot-server-programs): Add
fennel-ls language server.

Copyright-paperwork-exempt: yes
2024-03-14 11:52:06 +02:00
StrawberryTea
fd0a6cb172 ffap.el: Exclude angle brackets from file names in XML
* lisp/ffap.el (ffap-string-at-point-mode-alist): Add elements for
XML, to better recognize file names in XML buffers.

Copyright-paperwork-exempt: yes
2024-03-14 11:47:04 +02:00
Visuwesh
cb9ee24ea6 Add bounds-of-thing-at-point property for 'number'
* lisp/thingatpt.el (thing-at-point-decimal-regexp)
(thing-at-point-hexadecimal-regexp): Extract regexps from...
(number-at-point): ...here.  Use them in 'number-at-point'.
(number): Add 'bounds-of-thing-at-point' property as
`forward-word' does not always return the right boundary,
e.g., in latex-mode buffers.  (Bug#69239)
2024-03-14 11:39:33 +02:00
Eli Zaretskii
a60804ab95 ; Fix last change (bug#68604)
* lisp/xwidget.el (xwidget-webkit-disable-javascript): Move from
here...
* lisp/cus-start.el (standard): ...to here.

* src/xwidget.c (syms_of_xwidget)
<xwidget-webkit-disable-javascript>: Doc fix.

* doc/emacs/misc.texi (Embedded WebKit Widgets): Fix wording.
2024-03-14 11:32:00 +02:00
Noé Lopez
f6a27bc32d Add user option to disable JavaScript in xwidget webview
* src/xwidget.c: Add the 'xwidget-webkit-disable-javascript'
variable to disable JavaScript in WebKit sessions.  (Bug#68604)

* etc/NEWS:
* doc/emacs/misc.texi (Embedded Webkit Widgets): Document
the change.
2024-03-14 11:17:24 +02:00