1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-02-08 08:43:52 -08:00
Commit graph

174192 commits

Author SHA1 Message Date
Stefan Kangas
d00a10333f Use strnlen to avoid unnecessary work in pgtkfns.c
* src/pgtkfns.c (pgtk_get_defaults_value, pgtk_set_defaults_value):
Factor out new function...
(pgtk_check_resource_key_length): ...to here.  Avoid unnecessary work by
using strnlen.
2024-07-18 14:48:27 +02:00
Eli Zaretskii
a90a1ed527 Minor cleanup of code in insdel.c
* src/insdel.c (del_range_2): Update *_BYTE variables _after_
updating the corresponding character values.  This follows what we
do everywhere else, and allows to put a watchpoint on, say, Z_BYTE
to check consistency between the character and byte counts.  See
bug#72165 for one situation where it is useful.
2024-07-18 12:59:28 +03:00
Robert Pluim
da97096fdb ; fix previous find-function change 2024-07-18 09:05:53 +02:00
Po Lu
d31b202377 Merge from savannah/emacs-30
4c35382e98 ; * src/emacs.c (syms_of_emacs) <Vsystem_type>: Fix doc s...
34882d5243 Port better to Android 3.0
765cfaed77 ; * doc/emacs/anti.texi (Antinews): Fix typos (bug#72167).
7093504da2 ; Fix typos (bug#72167)
8c7c4f4baa New Tramp tests
85d2d7982d Update Tramp manual
504bdd560a ; Fix last change
3ccebbe17b Fix 'toggle-window-dedicated' documentation
719d5753ca ; * doc/lispref/help.texi (Keys in Documentation): Add cr...
e3bba63ecb Checkdoc fixes in transient.el
2024-07-18 13:36:46 +08:00
Po Lu
4c35382e98 ; * src/emacs.c (syms_of_emacs) <Vsystem_type>: Fix doc string indentation. 2024-07-18 13:35:47 +08:00
Po Lu
34882d5243 Port better to Android 3.0
* java/org/gnu/emacs/EmacsNoninteractive.java (main): Use the
old getPackageInfo calling convention if it exists rather than
on Android 2.3.3 and earlier.
2024-07-18 13:34:55 +08:00
john muhl
765cfaed77 ; * doc/emacs/anti.texi (Antinews): Fix typos (bug#72167). 2024-07-18 08:24:37 +03:00
john muhl
7093504da2 ; Fix typos (bug#72167)
* lisp/minibuffer.el (completion-auto-deselect): Correct
spelling of "minibuffer".
* lisp/progmodes/peg.el (peg--actions): Correct spelling
of "post-processing".
* lisp/progmodes/php-ts-mode.el: Correct spelling of
"taken".
2024-07-18 08:23:13 +03:00
Michael Albinus
8c7c4f4baa New Tramp tests
* test/lisp/net/tramp-tests.el
(tramp-test41-special-characters-direct-async)
(tramp-test42-utf8-direct-async): New tests.
2024-07-17 18:05:02 +02:00
Michael Albinus
85d2d7982d Update Tramp manual
* doc/misc/tramp.texi (Remote processes): Add another reason why a
direct asynchronous process could fail.
2024-07-17 17:57:20 +02:00
Paul Eggert
3a790abd86 Go back to preferring -isystem to -I
* configure.ac: Go back to preferring -isystem to -I,
as headers like <gobject/gparam.h> still need it.  This
reverts almost all of 2024-07-16T02:25:44!eggert@cs.ucla.edu,
except that the ‘nw="$nw -Wsystem-headers"’ line continues to
be removed as it is no longer needed due to recent Gnulib changes.
Problem reported by Eli Zaretskii in:
https://lists.gnu.org/r/emacs-devel/2024-07/msg00756.html
2024-07-17 08:28:12 -07:00
Eli Zaretskii
504bdd560a ; Fix last change
* doc/lispref/windows.texi (Dedicated Windows):
* doc/emacs/windows.texi (Displaying Buffers): Mention keybinding.
2024-07-17 14:10:50 +03:00
Robert Pluim
a1f29998bf Add history variables for find-func entry points
* lisp/emacs-lisp/find-func.el (find-function--read-history-library):
New defvar.
(read-library-name): Use it in 'completing-read' calls.
(find-function--read-history-function,
find-function--read-history-variable, find-function--read-history-face):
New defvars.
(find-function-read): Use them in 'completing-read' calls.
2024-07-17 10:56:17 +02:00
Robert Pluim
3ccebbe17b Fix 'toggle-window-dedicated' documentation
* doc/emacs/windows.texi (Displaying Buffers): Fix the cross reference
to the elisp manual.  Add missing 'toggle-window-dedicated'.
* doc/lispref/windows.texi (Dedicated Windows): Mention
'toggle-window-dedicated'.
2024-07-17 09:47:28 +02:00
Yuan Fu
5684fc5207
Handle an edge case in c-ts-mode filling (bug#72116)
* lisp/progmodes/c-ts-common.el:
(c-ts-common-comment-setup): Add a new regexp branch.
2024-07-16 21:07:55 -07:00
João Távora
d7b93f63f6 Eglot: supported nested {} patterns in globs
The tailwindcss-language server issues patterns like this:

   **/{tailwind,tailwind.config,tailwind.*.config,\
   tailwind.config.*}.{js,cjs,ts,mjs}

Notive the nested "*" blob inside the the {} group.

Eglot used to reject them in 'workspace/didChangeWatchedFiles' requests,
responding with "Internal Error".  This could confuse some servers.  Now
I've done some changes to the state machine generation and it supports
them.

* lisp/progmodes/eglot.el (eglot--glob-parse): Relax parser.
(eglot--glob-fsm): New helper.
(eglot--glob-compile, eglot--glob-emit-{}): Use it.

* test/lisp/progmodes/eglot-tests.el (eglot-test-glob-test):
Uncomment some test cases.

Github-reference: https://github.com/joaotavora/eglot/issues/1403
2024-07-17 01:21:59 +01:00
Paul Eggert
7cda30602f Check for more ‘find’ failures and port ‘find’
* Makefile.in (install-eln), configure.ac (emacs_cv_find_delete):
* make-dist: Use ‘find ... -exec CMD {} +’ rather than ‘find
... -exec CMD {} \;’ so that if CMD fails, ‘find’ fails too.
* Makefile.in (install-eln): Port to ‘find’ implementations that
behave differently from GNU ‘find’ when given an argument
that contains ‘{}’ within a longer string.  POSIX allows
this behavior.
2024-07-16 15:37:23 -07:00
Paul Eggert
a826296cff Quote BIN_DESTDIR better
* Makefile.in (BIN_DESTDIR, install-eln, uninstall):
* src/Makefile.in ($(pdmp)):
Be more consistent about quoting BIN_DESTDIR and ELN_DESTDIR,
avoiding double-quoting ''like this'' which does not work as
expected.
2024-07-16 15:37:22 -07:00
Paul Eggert
a86c25c91f Prefer -I to -isystem
* configure.ac: Simplify configuration by using -I instead of
-isystem, as -isystem is no longer helpful for suppressing
diagnostics (and likely has not been helpful for years).
Do not suppress -Wsystem-headers, as Gnulib no longer enables it.
2024-07-16 15:37:22 -07:00
Paul Eggert
e1089cc9b6 Simplify time form analysis
This does not change behavior; it merely refactors the code
for simplicity.
* src/timefns.c (enum timeform, struct form_time):
Remove.  All uses removed.
(decode_time_components): Accept HZ instead of FORM.
This saves a switch.  All uses changed.
(decode_lisp_time): Return union c_time instead of struct form_time.
All uses changed.
(lisp_time_cform): Remove.  All uses changed to just use
decode_lisp_time.
(time_arith, Ftime_convert): Check (TICKS . HZ) form directly
using CONSP, instead of using the old struct form_time.
That's fast enough here.
2024-07-16 15:37:22 -07:00
Paul Eggert
d10c1796c9 Test !FASTER_TIMEFNS with builtin resolutions
* src/timefns.c (timespec_hz, trillion, ztrillion):
If !FASTER_TIMEFNS, do not optimize the calculations of
these variables.  This gives better test coverage of the
slow-path code, when compiling with -DFASTER_TIMEFNS=0.
(NEED_ZTRILLION_INIT): Move up, to simplify #ifdefery.
Now defined or not defined, instead of being 1 or not defined,
since it is used only via #ifdef.
2024-07-16 15:37:21 -07:00
Paul Eggert
51d096ec07 Make ztrillion static
* src/timefns.c (ztrillion): Now static, when it is a variable,
since no other module uses it.
2024-07-16 15:37:21 -07:00
Paul Eggert
a53fd69fe2 Fix buffer size problem in print_bool_vector
* src/print.c (print_bool_vector): Don’t assume SIZE fits
into ptrdiff_t, since it is an EMACS_INT.  This
pacifies gcc -Wformat-overflow on i686 --with-wide-int.
2024-07-16 15:37:21 -07:00
Paul Eggert
b77abd2bfe alloc.c: ckd_add, not by-hand checks
* src/alloc.c (lmalloc, lrealloc): Prefer ckd_add to
by-hand checks for integer addition overflow.
2024-07-16 15:37:20 -07:00
Paul Eggert
b4050ab75e Fix get_conversion_field --with-wide-wint overflow
* src/textconv.c (get_conversion_field): Set max value to
PTRDIFF_MAX, not MOST_POSITIVE_FIXNUM, since the variable is
ptrdiff_t, not EMACS_INT.  Problem caught by gcc -Woverflow on a
32-bit platform with --with-wide-int.
2024-07-16 15:37:20 -07:00
Paul Eggert
a4bafce01e Pacify -Wmissing-variable-declarations for lisp_malloc_user
* src/alloc.c (lisp_malloc_user) [!USE_LSB_TAG]:
Provide extern decl.
2024-07-16 15:37:20 -07:00
Paul Eggert
31517e81d0 Pacify 32-bit GCC 14.1.1 in timer_check_2
* src/keyboard.c (timer_check_2): Refactor to make flow control
more obvious, to pacify -Wanalyzer-use-of-uninitialized-value with
gcc 14.1.1 20240607 (Red Hat 14.1.1-5) on i686.
2024-07-16 15:37:19 -07:00
Paul Eggert
2067c255e6 Use Gnulib workaround for Android strnlen bug
The workaround for the Android 5.0 (API 21) strnlen bug
is now done in m4/strnlen.m4, taken from Gnulib, so
there is no need for Emacs to have its own workaround.
* configure.ac (ORIGINAL_AC_FUNC_STRNLEN, AC_FUNC_STRNLEN):
Remove.
2024-07-16 15:37:19 -07:00
Paul Eggert
f5dbdedcc5 Update from Gnulib by running admin/merge-gnulib 2024-07-16 15:37:18 -07:00
Eli Zaretskii
719d5753ca ; * doc/lispref/help.texi (Keys in Documentation): Add cross-reference. 2024-07-16 17:35:42 +03:00
Michael Albinus
fd8bdedde9 Merge branch 'master' of git.sv.gnu.org:/srv/git/emacs 2024-07-16 10:11:45 +02:00
Michael Albinus
7d8ff5a56c Adapt tressitter tests on EMBA
* test/infra/Makefile.in (TREE-SITTER-FILES): Simplify.

* test/infra/test-jobs.yml: Regenerate.
2024-07-16 10:11:10 +02:00
Stefan Kangas
970409916e Make error messages adhere to our standards
* src/cygw32.c (chdir_to_default_directory):
* src/fns.c (secure_hash):
* src/keyboard.c (Finternal_handle_focus_in):
* src/keymap.c (store_in_keymap):
* src/pgtkfns.c (pgtk_set_scroll_bar_foreground)
(pgtk_set_scroll_bar_background, Fx_export_frames)
(Fpgtk_set_monitor_scale_factor, pgtk_get_defaults_value)
(pgtk_set_defaults_value, Fpgtk_print_frames_dialog)
(pgtk_get_monitor_scale_factor):
* src/pgtkterm.c (pgtk_set_parent_frame):
* src/process.c (network_interface_info, send_process):
* src/w32.c (w32_read_registry):
* src/w32fns.c (Fw32_read_registry):
* src/window.c (Frecenter):
* src/xfns.c (Fx_export_frames, Fx_print_frames_dialog)
(x_set_mouse_color): Make 'error' message strings follow our guidelines.
More specifically, they should not end in a period, and normally also be
capitalized.  See '(elisp) Programming Tips'.
2024-07-16 10:08:15 +02:00
Po Lu
06ce99b76a Merge remote-tracking branch 'savannah/master' into master-android-1 2024-07-16 10:15:59 +08:00
Po Lu
0fc8d88367 Merge from savannah/emacs-30
a7b68c2564 Fix intermittent failure of dired-test-bug27243-02
fc25b4d837 * etc/TODO: Refer to Bug#72127 for Magit assignments.
17c62c1242 Rename treesitter test
2024-07-16 10:15:27 +08:00
Po Lu
35606d575b ; Merge from savannah/emacs-30
The following commit was skipped:

684e96a30d Adapt tressitter tests on EMBA
2024-07-16 10:15:27 +08:00
Po Lu
f54ad127ee Merge from savannah/emacs-30
68b7806c31 Support passing signals like 'SIGCODE' to 'tramp-signal-p...
510ca5e84b Merge branch 'emacs-30' of git.sv.gnu.org:/srv/git/emacs ...
fe28ba5d55 ; Replace quotes with @code{...} in texinfo files
ecc8516d9c ; Replace (non-)nil with (non-)@code{nil} in texinfo files
3407e27499 Don't save to history from 'eshell-command' when aborting
2024-07-16 10:15:26 +08:00
Stefan Kangas
72c8e0df87 Delete commented out code from signal_or_quit
* src/eval.c (signal_or_quit): Delete code commented out since 2001.
2024-07-16 04:12:35 +02:00
Stefan Kangas
fcb4d89aaa Prefer memcpy to strcpy in image.c
* src/image.c (lookup_image, xpm_cache_color)
(imagemagick_create_cache): Prefer 'memcpy' to 'strcpy'.
2024-07-16 04:12:35 +02:00
Stefan Kangas
72ba45e274 Restrict loop variable scope in xpm_str_to_color_key
* src/image.c (xpm_str_to_color_key): Restrict scope of
loop variable.
2024-07-16 04:12:34 +02:00
Spencer Baugh
6b2f51633e Add project argument to project-kill-buffers
Previously, project-kill-buffers always called (project-current t).  A
Lisp program could change what project project-kill-buffers operated
on by binding project-current-directory-override.  However, in some
edge cases (for example, if the project was deleted between looking it
up and calling project-kill-buffers) this might fail to detect a
project, and so (project-current t) would prompt the user.

To avoid this, accept the project to kill buffers for as an argument.

* lisp/progmodes/project.el (project-kill-buffers): Take project as an
optional argument (bug#72019).
2024-07-16 04:59:11 +03:00
Stefan Kangas
e3bba63ecb Checkdoc fixes in transient.el
* lisp/transient.el (transient-format-description): Checkdoc fixes.
2024-07-16 03:36:31 +02:00
Peter Oliver
a7b68c2564 Fix intermittent failure of dired-test-bug27243-02
* test/lisp/dired-tests.el (dired-test-bug27243-02): Exclude free disk
space from dired listing in this test, in case it changes while it's
running and confuses the result.  (Bug#72120)
2024-07-15 23:22:16 +02:00
Stefan Kangas
fc25b4d837 * etc/TODO: Refer to Bug#72127 for Magit assignments. 2024-07-15 22:59:50 +02:00
Michael Albinus
17c62c1242 Rename treesitter test
* test/lisp/align-tests.el (align-ts-lua): Rename test in order to
fit to treesitter tests on EMBA.
2024-07-15 19:25:42 +02:00
Michael Albinus
684e96a30d Adapt tressitter tests on EMBA
* test/infra/Makefile.in (TREE-SITTER-FILES): Simplify.

* test/infra/test-jobs.yml: Regenerate.
2024-07-15 19:24:56 +02:00
Jim Porter
68b7806c31 Support passing signals like 'SIGCODE' to 'tramp-signal-process'
POSIX specifies that "kill" should take signal names without the "SIG"
prefix.

* lisp/net/tramp.el (tramp-signal-process): Strip the "SIG" prefix when
present.
2024-07-15 09:34:43 -07:00
Michael Albinus
510ca5e84b Merge branch 'emacs-30' of git.sv.gnu.org:/srv/git/emacs into emacs-30 2024-07-15 18:20:59 +02:00
Steven Allen
fe28ba5d55 ; Replace quotes with @code{...} in texinfo files
* doc/misc/cc-mode.texi:
* doc/misc/cl.texi: Replace quotes with @code{...}
2024-07-15 18:20:24 +02:00
Steven Allen
ecc8516d9c ; Replace (non-)nil with (non-)@code{nil} in texinfo files
* doc/lispref/functions.texi:
* doc/lispref/keymaps.texi:
* doc/lispref/strings.texi:
* doc/misc/cl.texi:
* doc/misc/dbus.texi:
* doc/misc/eshell.texi:
* doc/misc/message.texi:
* doc/misc/ses.texi:
* doc/misc/vtable.texi: Replace (non-)nil with (non-)@code{nil}.
2024-07-15 18:16:41 +02:00