]> git.eshelyaron.com Git - emacs.git/log
emacs.git
22 months ago; * configure.ac: Fix another typo.
Po Lu [Sun, 5 Mar 2023 02:57:06 +0000 (10:57 +0800)]
; * configure.ac: Fix another typo.

22 months ago; * cross/Makefile.in (builddir): Define.
Po Lu [Sun, 5 Mar 2023 02:42:41 +0000 (10:42 +0800)]
; * cross/Makefile.in (builddir): Define.

22 months ago; * cross/README: Update.
Po Lu [Sun, 5 Mar 2023 02:22:49 +0000 (10:22 +0800)]
; * cross/README: Update.

22 months agoRemove redundant gnulib files
Po Lu [Sun, 5 Mar 2023 02:22:33 +0000 (10:22 +0800)]
Remove redundant gnulib files

* cross/lib: Delete.  Make configure generate it instead.

22 months agoRemove redundant second copy of gnulib
Po Lu [Sun, 5 Mar 2023 02:18:28 +0000 (10:18 +0800)]
Remove redundant second copy of gnulib

* .gitignore: Simplify cross/lib rule.
* admin/merge-gnulib (avoided_flags): Stop copying to cross/lib.
* configure.ac: Link gnulib source and header files to
cross/lib.
* cross/Makefile.in (LIB_SRCDIR): Make relative to builddir.
(maintainer-clean): Merge with distclean.  Remove links created
by configure.

22 months agoMerge remote-tracking branch 'origin/master' into feature/android
Po Lu [Sun, 5 Mar 2023 00:09:03 +0000 (08:09 +0800)]
Merge remote-tracking branch 'origin/master' into feature/android

22 months agoUnbreak the unexec build
Eli Zaretskii [Sat, 4 Mar 2023 15:01:16 +0000 (17:01 +0200)]
Unbreak the unexec build

* src/alloc.c (BLOCK_ALIGN) [HAVE_UNEXEC]: Reset back to 1024.
(Bug#61960)

22 months agoFix x86_64 builds of libjpeg on Android
Po Lu [Sat, 4 Mar 2023 13:05:02 +0000 (21:05 +0800)]
Fix x86_64 builds of libjpeg on Android

* cross/ndk-build/ndk-build-shared-library.mk:
* cross/ndk-build/ndk-build-static-library.mk: Specify right ELF
format for 64 bit executables.

22 months agoFix calls to nasm in cross/ndk-build
Po Lu [Sat, 4 Mar 2023 13:01:28 +0000 (21:01 +0800)]
Fix calls to nasm in cross/ndk-build

* cross/ndk-build/ndk-build-shared-library.mk:
* cross/ndk-build/ndk-build-static-library.mk: Ensure nasm
generates ELF objects.

22 months agoMerge remote-tracking branch 'origin/master' into feature/android
Po Lu [Sat, 4 Mar 2023 12:22:39 +0000 (20:22 +0800)]
Merge remote-tracking branch 'origin/master' into feature/android

22 months agoFix out of bound write after poly of single pixel span
Po Lu [Sat, 4 Mar 2023 11:54:21 +0000 (19:54 +0800)]
Fix out of bound write after poly of single pixel span

* src/sfnt.c (sfnt_fill_span): Specifically handle spans that
span a single pixel by computing the coverage in the center.

22 months agobug#61489: Increase BLOCK_ALIGN from 1024 to 32768
Konstantin Kharlamov [Thu, 16 Feb 2023 15:07:55 +0000 (18:07 +0300)]
bug#61489: Increase BLOCK_ALIGN from 1024 to 32768

Originally discovered by Tyler Dodge in his article "Significant Garbage
Collection Improvement For Emacs".

While testing this change on Archlinux system with Intel i5-7200U CPU,
average time of garbage collection gets reduced by ≈25%. Other users
report improvements up to 50%. While monitoring PSS of emacs with and
without customizations loaded before and after the patch, no
statistically significant differences were discovered. So overall, this
change is a win.
* src/alloc.c (BLOCK_ALIGN): increase from 1024 to 32768.

22 months agoImprove context menus on old versions of Android
Po Lu [Sat, 4 Mar 2023 07:55:09 +0000 (15:55 +0800)]
Improve context menus on old versions of Android

* java/org/gnu/emacs/EmacsActivity.java (EmacsActivity): New
field `lastClosedMenu'.
(onContextMenuClosed): Don't send event if a menu is closed
twice in a row.  Also, clear wasSubmenuSelected immediately.
* java/org/gnu/emacs/EmacsContextMenu.java: Display submenus
manually in Android 6.0 and earlier.
* java/org/gnu/emacs/EmacsView.java (onCreateContextMenu)
(popupMenu): Adjust accordingly.

22 months agoPort to broken Android NDK version
Po Lu [Sat, 4 Mar 2023 05:38:00 +0000 (13:38 +0800)]
Port to broken Android NDK version

* configure.ac: Check for __ctype_get_mb_cur_max.
Then see if MB_CUR_MAX is defined to it, and define
REPLACEMENT_MB_CUR_MAX if so and it does not link.
* java/INSTALL: Update documentation.
* src/conf_post.h (MB_CUR_MAX): Define replacement if
necessary.

22 months agoMerge from origin/emacs-29
Stefan Kangas [Sat, 4 Mar 2023 05:30:12 +0000 (06:30 +0100)]
Merge from origin/emacs-29

bd5115e1347 Remove Eglot activation check from find-file-hook
adc04ad5247 * src/intervals.c (set_intervals_multibyte_1): Fix bug#61887
b3e930d328e Revert inadvertent change to lisp/icomplete.el in previou...
da8e4b6fe43 Revert previous change in go-ts-mode.el
7548446194a Release ERC 5.5
585faf4c173 ; More doc improvements for OClosures
2840895c1ae Don't create GUI frames in batch sessions
452b5ed1030 ; Fix wrong error name in erc-server-908 doc string.
1e9484f2fd1 ; * etc/ERC-NEWS: Mention more deprecations.
119b3a4dba1 Minor copyedits of documentation of OClosures
3a651773d29 Eglot: pay better attention to hints' paddingLeft/Right (...

# Conflicts:
# etc/NEWS

22 months ago; * m4/ndk-build.m4 (ndk_INIT): Fix typo.
Po Lu [Sat, 4 Mar 2023 03:47:32 +0000 (11:47 +0800)]
; * m4/ndk-build.m4 (ndk_INIT): Fix typo.

22 months agoMerge remote-tracking branch 'origin/master' into feature/android
Po Lu [Sat, 4 Mar 2023 03:25:09 +0000 (11:25 +0800)]
Merge remote-tracking branch 'origin/master' into feature/android

22 months agoImprove support for building Android C++ dependencies
Po Lu [Sat, 4 Mar 2023 03:19:25 +0000 (11:19 +0800)]
Improve support for building Android C++ dependencies

* configure.ac: Call ndk_LATE after gl_EARLY.
* cross/ndk-build/Makefile.in (NDK_BUILD_CXX): New variable.
* cross/ndk-build/ndk-build-shared-library.mk:
* cross/ndk-build/ndk-build-static-library.mk: Use it.
* java/INSTALL: Describe how to build C++ dependencies.
* m4/ndk-build.m4 (ndk_LATE): New macro.
(ndk_INIT): Try to find a suitable C++ compiler.
(ndk_CHECK_MODULES): Make sure the C++ compiler works before
allowing C++ dependencies.

22 months ago* lisp/icomplete.el (icomplete-in-buffer): Make into a defcustom.
Sean Whitton [Sat, 4 Mar 2023 02:17:40 +0000 (19:17 -0700)]
* lisp/icomplete.el (icomplete-in-buffer): Make into a defcustom.

22 months agoFix cross-compilation of C++ code with old NDK versions
Po Lu [Sat, 4 Mar 2023 00:45:11 +0000 (08:45 +0800)]
Fix cross-compilation of C++ code with old NDK versions

* cross/ndk-build/Makefile.in (NDK_BUILD_CFLAGS_CXX): New variable.
* cross/ndk-build/ndk-build-shared-library.mk
($(call objname,$(LOCAL_MODULE),$(basename $(1)))):
* cross/ndk-build/ndk-build-static-library.mk
($(call objname,$(LOCAL_MODULE),$(basename $(1)))): Use it to build
C++ code.

22 months agoRedirect eldoc messages to the mode-line when in edebug-mode
Dmitry Gutov [Sat, 4 Mar 2023 00:37:14 +0000 (02:37 +0200)]
Redirect eldoc messages to the mode-line when in edebug-mode

* lisp/emacs-lisp/eldoc.el (eldoc-minibuffer-message): Redirect
eldoc messages to the mode-line when in edebug-mode (bug#56459).
(eldoc-minibuffer--cleanup): New function, used in above.

22 months agoRevert "Revert "Don't disable eldoc when doing edebug""
Dmitry Gutov [Sat, 4 Mar 2023 00:27:35 +0000 (02:27 +0200)]
Revert "Revert "Don't disable eldoc when doing edebug""

This reverts commit 99df815c153265706edc839b7467fb3ae3b6e1b1.

22 months agoRemove Eglot activation check from find-file-hook
João Távora [Sat, 4 Mar 2023 00:09:32 +0000 (00:09 +0000)]
Remove Eglot activation check from find-file-hook

Adding eglot--maybe-activate-editing-mode to find-file-hook isn't
really necessary, since it is already in
'after-change-major-mode-hook', and that also runs every time we find
a file.

This reduces the number of project.el logic that runs every time the
user visits a file.

* lisp/progmodes/eglot.el (find-file-hook): No need to add
eglot--maybe-activate-editing-mode here.

22 months ago* src/intervals.c (set_intervals_multibyte_1): Fix bug#61887
Stefan Monnier [Sat, 4 Mar 2023 00:13:03 +0000 (19:13 -0500)]
* src/intervals.c (set_intervals_multibyte_1): Fix bug#61887

When `total_length` is 0 there should be no subtree at all, but
`delete_interval` only deletes one interval, so make sure we don't end
up with some stale child of `i`.

22 months agoRevert inadvertent change to lisp/icomplete.el in previous commit
João Távora [Fri, 3 Mar 2023 23:36:26 +0000 (23:36 +0000)]
Revert inadvertent change to lisp/icomplete.el in previous commit

The change

   commit 3a651773d29afb48ac4229cd19e532bd57a4ee2d
   Author: João Távora <joaotavora@gmail.com>
   Date:   Fri Mar 3 13:13:35 2023 +0000

       Eglot: pay better attention to hints' paddingLeft/Right (bug#61924)

Inadvertently added a line to this file, which shouldn't (yet) bet
added.

* lisp/icomplete.el (icomplete--vertical-minibuffer-setup): Remove
truncate-lines.

22 months agoRevert previous change in go-ts-mode.el
Yuan Fu [Fri, 3 Mar 2023 21:59:54 +0000 (13:59 -0800)]
Revert previous change in go-ts-mode.el

Reverts 59365f928565f1be551b1697b9246b00cb87a9b7 and
56cd810b9d1a4d537bee5a2fd954d6e0d346631a.

Reverting because the use of treesit-ready-p is very much intentional.

* lisp/progmodes/go-ts-mode.el (treesit-ready-p): Revert change.

22 months agoRelease ERC 5.5
F. Jason Park [Tue, 14 Feb 2023 07:27:50 +0000 (23:27 -0800)]
Release ERC 5.5

* doc/misc/erc.texi: Update ERCVER to 5.5.
* lisp/erc/erc.el: Increment main version header to 5.5.  Update
Compat version in package-requires header to 29.1.3.4.  Update
`customize-package-emacs-version-alist' entry by mapping ERC 5.5 to
Emacs 29.1.
(erc-version): Update value to 5.5.

22 months ago; More doc improvements for OClosures
Eli Zaretskii [Fri, 3 Mar 2023 19:44:54 +0000 (21:44 +0200)]
; More doc improvements for OClosures

* doc/lispref/functions.texi (OClosures):
* doc/lispref/commands.texi (Using Interactive):
* etc/NEWS: Some more docs improvements for OClosures.

22 months agoDon't create GUI frames in batch sessions
Jim Porter [Tue, 28 Feb 2023 19:35:21 +0000 (11:35 -0800)]
Don't create GUI frames in batch sessions

This resolves an issue with running test/lisp/server-tests.el when
'DISPLAY' is set: the tests would start the Emacs server in a batch
session, and then request a new GUI frame.  However, that caused the
tests to terminate with SIGIO, since a batch Emacs doesn't set a SIGIO
handler.

Ref: <https://lists.gnu.org/archive/html/emacs-devel/2023-02/msg00879.html>

* lisp/frame.el (make-frame): Always create a terminal frame in batch
sessions.

22 months agoMinor fixes to configury
Po Lu [Fri, 3 Mar 2023 13:58:48 +0000 (21:58 +0800)]
Minor fixes to configury

* configure.ac (ANDROID_SDK_8_OR_EARLIER): Pass through
`--with-ndk-cxx-shared'.
* m4/ndk-build.m4: Fix quoting of $CC.

22 months ago; Fix wrong error name in erc-server-908 doc string.
F. Jason Park [Fri, 3 Mar 2023 07:37:06 +0000 (23:37 -0800)]
; Fix wrong error name in erc-server-908 doc string.

* lisp/erc/erc-sasl.el (erc-server-908): Correct well-known name for
908 numeric in doc string.
(erc--register-connection): Fold overlong line.

22 months ago; * etc/ERC-NEWS: Mention more deprecations.
F. Jason Park [Fri, 3 Mar 2023 07:33:28 +0000 (23:33 -0800)]
; * etc/ERC-NEWS: Mention more deprecations.

22 months agoMinor copyedits of documentation of OClosures
Eli Zaretskii [Fri, 3 Mar 2023 13:23:22 +0000 (15:23 +0200)]
Minor copyedits of documentation of OClosures

* doc/lispref/functions.texi (OClosures): Improve wording,
indexing, and markup; add details.

22 months agoFix out-of-tree builds with native dependencies
Po Lu [Fri, 3 Mar 2023 13:22:00 +0000 (21:22 +0800)]
Fix out-of-tree builds with native dependencies

* cross/ndk-build/ndk-build-shared-library.mk:
* cross/ndk-build/ndk-build-static-library.mk: Include
ndk-resolve.mk in srcdir.

22 months agoEglot: pay better attention to hints' paddingLeft/Right (bug#61924)
João Távora [Fri, 3 Mar 2023 13:13:35 +0000 (13:13 +0000)]
Eglot: pay better attention to hints' paddingLeft/Right (bug#61924)

* lisp/progmodes/eglot.el (eglot--update-hints-1): Consider
:json-false, which is a non-nil value.

22 months ago; * cross/ndk-build/README: Update accordingly.
Po Lu [Fri, 3 Mar 2023 13:14:08 +0000 (21:14 +0800)]
; * cross/ndk-build/README: Update accordingly.

22 months agoImprove ndk-build implementation
Po Lu [Fri, 3 Mar 2023 13:13:58 +0000 (21:13 +0800)]
Improve ndk-build implementation

* build-aux/ndk-build-helper.mk: Define in terms of BUILD_AUXDIR.
* m4/ndk-build.m4 (ndk_INIT): Find right build-aux directory.
Remove uses of unportable shell constructs.

22 months agoRemove ineffective uses of condition-case
Mattias Engdegård [Fri, 3 Mar 2023 10:32:34 +0000 (11:32 +0100)]
Remove ineffective uses of condition-case

* lisp/gnus/message.el (message-setup-1):
* lisp/progmodes/cc-engine.el (c-forward-single-comment):
* lisp/progmodes/ruby-mode.el (ruby-add-log-current-method):
Eliminate uses of condition-case without handlers.  These seem to have
been there for quite a long time.  This change does not affect the
behaviour of the code and makes some warnings go away.

22 months agoFix visiting and saving writable content provider files
Po Lu [Fri, 3 Mar 2023 08:00:27 +0000 (16:00 +0800)]
Fix visiting and saving writable content provider files

* java/org/gnu/emacs/EmacsService.java (checkContentUri):
Improve debug output.
* lisp/files.el (basic-save-buffer): Check whether or not file
itself exists before checking for the existence of the directory
containing it.
* src/android.c (android_open): Don't forget to set errno after
open_content_uri fails.

22 months agoMerge remote-tracking branch 'origin/master' into feature/android
Po Lu [Fri, 3 Mar 2023 07:25:53 +0000 (15:25 +0800)]
Merge remote-tracking branch 'origin/master' into feature/android

22 months agoUpdate Android port
Po Lu [Fri, 3 Mar 2023 07:23:21 +0000 (15:23 +0800)]
Update Android port

* java/org/gnu/emacs/EmacsActivity.java (EmacsActivity)
(onCreate): Add view tree observer.
(onGlobalLayout): Sync fullscreen state.
(syncFullscreenWith): Improve visibility flag setting.

* src/textconv.c (select_window): New function.
(textconv_query):
(restore_selected_window):
(really_commit_text):
(really_set_composing_text):
(really_set_composing_region):
(really_delete_surrounding_text):
(really_set_point_and_mark):
(get_extracted_text): Call it instead of Fselect_window
to avoid selecting the mini window if it is no longer active.

22 months agoMerge from origin/emacs-29
Stefan Kangas [Fri, 3 Mar 2023 05:30:12 +0000 (06:30 +0100)]
Merge from origin/emacs-29

9e105d483fa Fix c-ts-mode indentation for statement after preproc (bu...
a72a55e3e49 Fix c/c++-ts-mode's mode lighter
67befc1f5a5 Eglot: use shell-file-name in eglot--cmd (bug#61748)
1c7b2673bdd Avoid signaling errors in url-basic-auth when password is...
756225e3778 Fix wdired-tests on MS-Windows
a137f71c67e Improvements to xwidget on macOS (bug#60703)
3f43a16bc63 ; Avoid byte-compilation warning in c-ts-mode.el

22 months agoFix c-ts-mode indentation for statement after preproc (bug#61893)
Yuan Fu [Fri, 3 Mar 2023 03:59:11 +0000 (19:59 -0800)]
Fix c-ts-mode indentation for statement after preproc (bug#61893)

Originally our c-ts-mode--anchor-prev-sibling only specially handled
labeled_statements, now we add special case for preproc in the similar
fasion: instead of using the preproc directive as anchor, use the last
statement in that preproc as the anchor. Thus effectively ignore the
preproc.

There should be an accompanying test, but there are some problem in
the elif preproc directive indent so it would pass, we'll add the test
when that is fixed.

* lisp/progmodes/c-ts-mode.el:
(c-ts-mode--anchor-prev-sibling): Add special case for preproc
directives.

22 months agoMerge remote-tracking branch 'origin/master' into feature/android
Po Lu [Fri, 3 Mar 2023 00:57:33 +0000 (08:57 +0800)]
Merge remote-tracking branch 'origin/master' into feature/android

22 months agoFix c/c++-ts-mode's mode lighter
Eli Zaretskii [Thu, 2 Mar 2023 19:34:22 +0000 (21:34 +0200)]
Fix c/c++-ts-mode's mode lighter

* lisp/progmodes/c-ts-mode.el (c-ts-mode-set-modeline): Remove
trailing blank from comment-start when indicating the comment
style on the mode line.

22 months agoFix `cond` miscompilation bug
Mattias Engdegård [Thu, 2 Mar 2023 08:56:59 +0000 (09:56 +0100)]
Fix `cond` miscompilation bug

This fixes a bug that miscompiled

  (cond ... C S1...Sn)

where S1...Sn are switch clauses (that can be compiled into a switch
op) and C a non-switch clause, by tucking on an extra copy of C at the
end.  This was a serious wrong-code bug when the condition of C had
side-effects; otherwise it was only a waste of time and space.

* lisp/emacs-lisp/bytecomp.el (byte-compile-cond): Fix.
* test/lisp/emacs-lisp/bytecomp-tests.el (bytecomp-tests--test-cases):
Add test case.

22 months agoSmall unwind-protect optimisation improvement
Mattias Engdegård [Wed, 1 Mar 2023 18:37:52 +0000 (19:37 +0100)]
Small unwind-protect optimisation improvement

* lisp/emacs-lisp/byte-opt.el (byte-optimize-form-code-walker):
Use the current for-effect mode when optimising the body form,
instead of always optimising it for value.

22 months agoEglot: use shell-file-name in eglot--cmd (bug#61748)
João Távora [Thu, 2 Mar 2023 13:27:14 +0000 (13:27 +0000)]
Eglot: use shell-file-name in eglot--cmd (bug#61748)

* lisp/progmodes/eglot.el (eglot--cmd): Use shell-file-name.

22 months agoTramp cleanup
Michael Albinus [Thu, 2 Mar 2023 12:54:14 +0000 (13:54 +0100)]
Tramp cleanup

* lisp/net/tramp.el (tramp-handle-unlock-file): Raise a warning
only when `create-lockfiles'.

* test/lisp/net/tramp-tests.el (tramp-test26-file-name-completion):
Extend test.

22 months agoMerge remote-tracking branch 'origin/master' into feature/android
Po Lu [Thu, 2 Mar 2023 12:45:21 +0000 (20:45 +0800)]
Merge remote-tracking branch 'origin/master' into feature/android

22 months agoFix bootstrap failure
Po Lu [Thu, 2 Mar 2023 12:44:47 +0000 (20:44 +0800)]
Fix bootstrap failure

* lisp/man.el (Man-prefer-synchronous-call): Fix version
specification.

22 months agoAvoid signaling errors in url-basic-auth when password is nil
Eli Zaretskii [Thu, 2 Mar 2023 12:35:15 +0000 (14:35 +0200)]
Avoid signaling errors in url-basic-auth when password is nil

* lisp/url/url-auth.el (url-basic-auth): Handle nil PASS.
Suggested by Ellis Kenyo <me@elken.dev>.  (Bug#61411)

22 months agoFix wdired-tests on MS-Windows
Eli Zaretskii [Thu, 2 Mar 2023 12:21:33 +0000 (14:21 +0200)]
Fix wdired-tests on MS-Windows

* test/lisp/wdired-tests.el (wdired-test-bug32173-01)
(wdired-test-bug32173-02, wdired-test-unfinished-edit-01)
(wdired-test-bug39280): Run test-dir through file-truename, to
avoid failures due to MS-Windows "numeric tails" (mis)feature and
similar issues, which make file names fail to compare 'equal'.
(wdired-test-bug34915, wdired-test-bug61510): Skip if symlinks
fail.

22 months agoAdd option to keep some columns in dired-hide-details-mode
Augusto Stoffel [Sat, 25 Feb 2023 11:15:43 +0000 (12:15 +0100)]
Add option to keep some columns in dired-hide-details-mode

* lisp/dired.el (dired-hide-details-preserved-columns): New user
option.
(dired-insert-set-properties): Use it.  (Bug#61785)

22 months agoMerge remote-tracking branch 'origin/master' into feature/android
Po Lu [Thu, 2 Mar 2023 12:00:06 +0000 (20:00 +0800)]
Merge remote-tracking branch 'origin/master' into feature/android

22 months ago; * doc/emacs/input.texi (On-Screen Keyboards): Fix indexing.
Po Lu [Thu, 2 Mar 2023 11:51:06 +0000 (19:51 +0800)]
; * doc/emacs/input.texi (On-Screen Keyboards): Fix indexing.

22 months ago; Fix last change
Eli Zaretskii [Thu, 2 Mar 2023 11:28:28 +0000 (13:28 +0200)]
; Fix last change

* doc/emacs/programs.texi (Man Page): Improve wording.

* lisp/man.el (Man-prefer-synchronous-call): Fix quoting and
spelling.  (Bug#61552)

22 months agoAdd new user option Man-prefer-synchronous-call
Sebastian Tennant [Thu, 10 Mar 2022 08:36:04 +0000 (08:36 +0000)]
Add new user option Man-prefer-synchronous-call

* lisp/man.el (Man-getpage-in-background): Add new defcustom
Man-prefer-synchronous-call and modify #'Man-getpage-in-background.
Only call #'start-process when 'make-process satisfies #'fboundp AND
Man-prefer-synchronous-call is bound to nil.  (Bug#61552)

Copyright-paperwork-exempt: yes

22 months agoImprovements to xwidget on macOS (bug#60703)
Andrew De Angelis [Fri, 24 Feb 2023 03:47:41 +0000 (22:47 -0500)]
Improvements to xwidget on macOS (bug#60703)

* src/nsxwidget.m ()
([XwWebView initWithFrame:configuration:xwidget:])
(nsxwidget_init):  Fixed memory leaks: when sending an alloc
message to an object, send an autorelease message to any objects
we won't explictly release.
([XwWebView webView:didFinishNavigation:]): Second string to
store in 'store_xwidget_event_string' is "load finished" rather
than empty string.
([XwWebView webView:didStartProvisionalNavigation:])
([XwWebView webView:didReceiveServerRedirectForProvisionalNavigation:])
([XwWebView webView:didCommitNavigation:]): New functions.
(nsxwidget_webkit_estimated_load_progress): New function.
(nsxwidget_webkit_stop_loading): New function.
* src/xwidget.c (Fxwidget_webkit_estimated_load_progress): Call
'nsxwidget_webkit_estimated_load_progress' if we're on MacOS.
(Fxwidget_webkit_stop_loading): Call 'nsxwidget_webkit_stop_loading'
if we're on MacOS.
(syms_of_xwidget): Define symbol for function.
'xwidget_webkit_estimated_load_progress' if we're on MacOS.
* src/nsxwidget.h: Signature for functions
'nsxwidget_webkit_estimated_load_progress' and
'nsxwidget_webkit_stop_loading'.
* lisp/xwidget.el (xwidget-webkit-current-url): Message URL rather
than return value of 'kill-new' (which is always nil).

22 months agoAdd support for Zsh's case branches ;|.
Philippe Altherr [Sun, 15 Jan 2023 12:37:00 +0000 (13:37 +0100)]
Add support for Zsh's case branches ;|.

* lisp/progmodes/sh-script.el (sh-font-lock-paren)
(sh-smie-sh-grammar, sh-smie-sh-rules, sh-smie-rc-grammar):
Support case branches ending with ";|", per Zsh.  (Bug#60833)

* test/manual/indent/shell.sh (bar): Add ";|".

22 months agoUse 'sh-indent-for-continuation' for continued lines in 'sh-script-mode'
Philippe Altherr [Sat, 14 Jan 2023 04:22:26 +0000 (05:22 +0100)]
Use 'sh-indent-for-continuation' for continued lines in 'sh-script-mode'

* lisp/progmodes/sh-script.el (sh-smie--indent-continuation): Use
'sh-indent-for-continuation' instead of 'sh-basic-offset'.
(Bug#60832)

* test/lisp/progmodes/sh-script-tests.el
(test-indent-after-continuation): New test.

22 months agoSummary: Update Android port
Po Lu [Thu, 2 Mar 2023 10:31:35 +0000 (18:31 +0800)]
Summary: Update Android port

* INSTALL: Document where to find Android installation
instructions.
* configure.ac (CHECK_LISP_OBJECT_TYPE): Pacify
-Wsuggest-attribute=noreturn only on Android.
* cross/ndk-build/README: New file.
* doc/emacs/android.texi (Android):
* doc/emacs/emacs.texi (Top):
* doc/emacs/input.texi (Other Input Devices): Untabify menus.
* etc/NEWS: Move INSTALL.android to java/INSTALL.
* java/INSTALL: New file.
* java/README:
* src/coding.c (from_unicode_buffer): Make Android specific code
only build on Android.

22 months ago* INSTALL.android: Remove file.
Po Lu [Thu, 2 Mar 2023 10:29:46 +0000 (18:29 +0800)]
* INSTALL.android: Remove file.

22 months agoFix Makefile race conditions
Po Lu [Thu, 2 Mar 2023 07:59:33 +0000 (15:59 +0800)]
Fix Makefile race conditions

* configure.ac: Make cross/* and related directories.
* cross/Makefile.in (src/verbose.mk, lib/libgnu.a)
(src/config.h): Stop making directories here.
(lib-src/config.h): New config.h rule.
($(LIBSRC_BINARIES)): Add it.
(clean): Don't remove CLEAN_SUBDIRS, but clean inside.

22 months ago; Avoid byte-compilation warning in c-ts-mode.el
Eli Zaretskii [Thu, 2 Mar 2023 07:33:04 +0000 (09:33 +0200)]
; Avoid byte-compilation warning in c-ts-mode.el

* lisp/progmodes/c-ts-mode.el (treesit-node-first-child-for-pos):
Declare.

22 months agoFix Android handle wraparound
Po Lu [Thu, 2 Mar 2023 05:48:03 +0000 (13:48 +0800)]
Fix Android handle wraparound

* src/android.c (android_alloc_id): Return correct values upon
wraparound.

22 months agoMerge from origin/emacs-29
Stefan Kangas [Thu, 2 Mar 2023 05:30:15 +0000 (06:30 +0100)]
Merge from origin/emacs-29

59365f92856 * lisp/progmodes/go-ts-mode.el: Use treesit-language-avai...
56cd810b9d1 Don’t signal warning when loading go-ts-mode.el without g...
b06d5519664 Fix c-ts-mode empty line indentation (bug#61893)
6b2720778dc Improve tree-sitter's prev-sibling indent anchor

22 months ago; Merge from origin/emacs-29
Stefan Kangas [Thu, 2 Mar 2023 05:30:15 +0000 (06:30 +0100)]
; Merge from origin/emacs-29

The following commits were skipped:

db50545e3e9 * lisp/icomplete.el (fido-mode): Enable in-buffer complet...
ef72e99e867 * lisp/icomplete.el: Fix in-buffer completion.

22 months agoMerge from origin/emacs-29
Stefan Kangas [Thu, 2 Mar 2023 05:30:15 +0000 (06:30 +0100)]
Merge from origin/emacs-29

07f3236133b * src/profiler.c (malloc_probe): Make it safe for GC (bug...
1f1d36fa808 * lisp/emacs-lisp/debug-early.el (debug-early-backtrace):...
99df815c153 Revert "Don't disable eldoc when doing edebug"
0a4b1c0102d ; Eglot: improve bug-reference-url-format/bug-reference-u...
40c9fc8e3b3 Eglot: work around Tramp instability bug#61350
4a6db125b9e Fix treesit-indent-region
7ef9a8210c9 Replace C++ comments with C style equivalents

22 months agoImprove criteria for restoring fullscreen state on Android
Po Lu [Thu, 2 Mar 2023 04:30:36 +0000 (12:30 +0800)]
Improve criteria for restoring fullscreen state on Android

* java/Makefile.in ($(CLASS_FILES) &): Touch all class files,
even those javac chose not to rebuild.

* java/org/gnu/emacs/EmacsActivity.java (onWindowFocusChanged):
Restore fullscreen state here.
(onResume): And not here.

22 months ago; * src/haikufont.c (haikufont_open): Remove unused variable.
Po Lu [Thu, 2 Mar 2023 03:07:37 +0000 (03:07 +0000)]
; * src/haikufont.c (haikufont_open): Remove unused variable.

22 months agoFix sectioning of android texi files
Po Lu [Thu, 2 Mar 2023 02:50:08 +0000 (10:50 +0800)]
Fix sectioning of android texi files

* doc/emacs/android.texi (Android):
* doc/emacs/emacs.texi (Top, GNU Free Documentation License):
Rearrange menu and sectioning.

22 months agoUpdate Android port
Po Lu [Thu, 2 Mar 2023 01:27:37 +0000 (09:27 +0800)]
Update Android port

* doc/emacs/android.texi (Android Windowing): Reword
documentation.
* java/org/gnu/emacs/EmacsActivity.java (EmacsActivity):
* java/org/gnu/emacs/EmacsContextMenu.java (EmacsContextMenu):
* java/org/gnu/emacs/EmacsFontDriver.java (EmacsFontDriver):
* java/org/gnu/emacs/EmacsSdk7FontDriver.java
(EmacsSdk7FontDriver):
* java/org/gnu/emacs/EmacsService.java (queryBattery):
* java/org/gnu/emacs/EmacsWindow.java (EmacsWindow): Make
functions final and classes static where necessary.
* src/android.c (struct android_emacs_service): New method
`display_toast'.
(android_init_emacs_service): Load new method.
(android_display_toast): New function.
* src/android.h: Export.
* src/androidfns.c (Fandroid_detect_mouse):
* src/androidselect.c (Fandroid_clipboard_owner_p)
(Fandroid_set_clipboard, Fandroid_get_clipboard)
(Fandroid_browse_url): Prevent crashes when called from
libandroid-emacs.so.
* src/androidterm.c (handle_one_android_event): Fix out of date
commentary.

22 months agoMerge remote-tracking branch 'origin/master' into feature/android
Po Lu [Thu, 2 Mar 2023 00:38:06 +0000 (08:38 +0800)]
Merge remote-tracking branch 'origin/master' into feature/android

22 months ago* lisp/progmodes/go-ts-mode.el: Use treesit-language-available-p.
Yuan Fu [Wed, 1 Mar 2023 22:38:22 +0000 (14:38 -0800)]
* lisp/progmodes/go-ts-mode.el: Use treesit-language-available-p.

treesit-ready-p does more checks than language grammar availability.

22 months agoDon’t signal warning when loading go-ts-mode.el without grammar
Yuan Fu [Wed, 1 Mar 2023 22:34:56 +0000 (14:34 -0800)]
Don’t signal warning when loading go-ts-mode.el without grammar

* lisp/progmodes/go-ts-mode.el: Add a QUIET flag to the call of
treesit-ready-p, so that it doesn't signal a warning if
go-mod (tree-sitter grammar) is not available.

22 months agoFix c-ts-mode empty line indentation (bug#61893)
Yuan Fu [Wed, 1 Mar 2023 22:01:47 +0000 (14:01 -0800)]
Fix c-ts-mode empty line indentation (bug#61893)

* lisp/progmodes/c-ts-mode.el (c-ts-mode--indent-styles): Make the
"rest sibling" matchers catch the case where NODE is nil, when
indenting an empty line.
* test/lisp/progmodes/c-ts-mode-resources/indent.erts: New test.

22 months agoImprove tree-sitter's prev-sibling indent anchor
Yuan Fu [Wed, 1 Mar 2023 21:55:53 +0000 (13:55 -0800)]
Improve tree-sitter's prev-sibling indent anchor

Now it handles the case where NODE is nil when indenting an empty
line: it tries to get the previous sibling nonetheless.

* lisp/progmodes/c-ts-mode.el (c-ts-mode--anchor-prev-sibling):
* lisp/treesit.el (treesit-simple-indent-presets): Add an or form to
handle more cases.

22 months ago* lisp/icomplete.el (fido-mode): Enable in-buffer completion (bug#45763).
João Távora [Mon, 27 Feb 2023 18:40:48 +0000 (20:40 +0200)]
* lisp/icomplete.el (fido-mode): Enable in-buffer completion (bug#45763).

Backport:
(cherry picked from commit b5c13032538377b0037c745715613693a1580f81)

22 months ago* lisp/icomplete.el: Fix in-buffer completion.
Juri Linkov [Mon, 27 Feb 2023 18:32:53 +0000 (20:32 +0200)]
* lisp/icomplete.el: Fix in-buffer completion.

(icomplete-force-complete-and-exit, icomplete-force-complete): Use
'icomplete--field-beg/end' when not in the minibuffer to not erase
the current buffer.  Also disable 'completion-in-region-mode' instead
of calling 'exit-minibuffer' (bug#45764, bug#51575, bug#61479).

Backport:
(cherry picked from commit a7a984c0ebebb891e2052d8416544f0bd7002007)

22 months ago* src/profiler.c (malloc_probe): Make it safe for GC (bug#60237)
Stefan Monnier [Wed, 1 Mar 2023 17:36:58 +0000 (12:36 -0500)]
* src/profiler.c (malloc_probe): Make it safe for GC (bug#60237)

22 months ago* lisp/emacs-lisp/debug-early.el (debug-early-backtrace): Fix bug#61847
Stefan Monnier [Wed, 1 Mar 2023 17:31:09 +0000 (12:31 -0500)]
* lisp/emacs-lisp/debug-early.el (debug-early-backtrace): Fix bug#61847

The `noerror` arg of `require` doesn't do what Stefan naively thought
when he wrote this code, so use `condition-case` instead.
Also check for `cl-defmethod` since `cl-prin1` can't be loaded before
that anyway.

22 months agoMake Tramp file name completion more quiet
Michael Albinus [Wed, 1 Mar 2023 16:07:59 +0000 (17:07 +0100)]
Make Tramp file name completion more quiet

* lisp/net/tramp-sh.el (tramp-perl-file-name-all-completions):
Don't print status message.
(tramp-sh-handle-file-name-all-completions): Return nil when check
fails.  (Bug#61890)

* test/lisp/net/tramp-tests.el
(tramp-test26-file-name-completion-with-perl):
(tramp-test26-file-name-completion-with-ls): New tests.

22 months agoRevert "Don't disable eldoc when doing edebug"
Eli Zaretskii [Wed, 1 Mar 2023 15:35:51 +0000 (17:35 +0200)]
Revert "Don't disable eldoc when doing edebug"

This reverts commit 6fd1fb8a6837acde8e1c9ab26618ec0f36121c72.
It turns out ElDoc does show messages inside Edebug, if you
are (un)lucky enough to have point where ElDoc has something
to show.  Bug#56459 needs to be fixed in some more complex
way.

22 months ago; Eglot: improve bug-reference-url-format/bug-reference-url-regexp
João Távora [Wed, 1 Mar 2023 13:24:07 +0000 (13:24 +0000)]
; Eglot: improve bug-reference-url-format/bug-reference-url-regexp

* lisp/progmodes/eglot.el (eglot--debbugs-or-github-bug-uri): New helper.

22 months agoSimplify effect-free code elimination
Mattias Engdegård [Wed, 1 Mar 2023 12:37:06 +0000 (13:37 +0100)]
Simplify effect-free code elimination

* lisp/emacs-lisp/byte-opt.el (byte-optimize-form-code-walker):
Simplify overly defensive code.  This does not affect code generation.

22 months agoFix out-of-tree Android builds
Po Lu [Wed, 1 Mar 2023 11:34:45 +0000 (19:34 +0800)]
Fix out-of-tree Android builds

* configure.ac (JAVA_PUSH_LINT): Push to WARN_JAVAFLAGS instead
of JAVAFLAGS.
(cross/lib): Always AS_MKDIR_P.
* cross/Makefile.in (srcdir): New variable.
(LIB_SRCDIR): Take realpath relative to srcdir, not
.:(src/verbose.mk): Depend on verbose.mk.android in srcdir.
(lib/Makefile): Edit srcdir and VPATH to LIB_SRCDIR.
(src/Makefile): Edit -I$$(top_srcdir) to -I../$(srcdir)/lib,
instead of ommitting it.
(clean): Allow ndk-build clean to fail.

* java/Makefile.in (builddir): New variable.
(WARN_JAVAFLAGS): Likewise.
(JAVAFLAGS): Define in terms of WARN_JAVAFLAGS.
(SIGN_EMACS, SIGN_EMACS_V2): Use emacs.keystore relative to
srcdir.  Allow inclusion of ndk-build.mk to fail.
(install_temp, emacs.apk-in)
(../config.status): Depend relative to top_srcdir.
(AndroidManifest.xml, $(APK_NAME)): Likewise.
(RESOURCE_FILE, CLASS_FILES, classes.dex): Output class files
to $(srcdir); these are arch independents, so this is okay.

22 months agoEglot: work around Tramp instability bug#61350
João Távora [Wed, 1 Mar 2023 11:12:51 +0000 (11:12 +0000)]
Eglot: work around Tramp instability bug#61350

Unconditionally disable ControlMaster for the Eglot's Tramp
connection.

* lisp/progmodes/eglot.el (tramp-ssh-controlmaster-options)
(use-tramp-ssh-controlmaster-options): Forward declare
(eglot--connect): Set variables to unconditionally disable ControlMaster.

22 months agoFix treesit-indent-region
Yuan Fu [Wed, 1 Mar 2023 07:51:06 +0000 (23:51 -0800)]
Fix treesit-indent-region

Fix it for the case where there is no suitable rule for the line.
Right now treesit-indent-region would indent the line to column 0.
After the change the indentation is not altered.

* lisp/treesit.el (treesit-indent-region): Handle the case where
ANCHOR or OFFSET is nil specially.

22 months agoMerge remote-tracking branch 'origin/master' into feature/android
Po Lu [Wed, 1 Mar 2023 07:55:20 +0000 (15:55 +0800)]
Merge remote-tracking branch 'origin/master' into feature/android

22 months agoFix mostlyclean rules
Po Lu [Wed, 1 Mar 2023 07:54:57 +0000 (15:54 +0800)]
Fix mostlyclean rules

* cross/Makefile.in: Remove outdated comment.
* src/Makefile.in: (.PHONY): Clean android-emacs and
libemacs.so, not emacs.so and aemacs.

22 months agoUpdate Android port
Po Lu [Wed, 1 Mar 2023 07:49:02 +0000 (15:49 +0800)]
Update Android port

* doc/emacs/android.texi (Android File System): Document new
behavior of starting a subprocess from /assets.
* java/org/gnu/emacs/EmacsWindow.java (onSomeKindOfMotionEvent):
Don't use isFromSource where not present.
* src/androidterm.c (android_scroll_run): Avoid undefined
behavior writing to bitfields.
* src/callproc.c (get_current_directory): When trying to run a
subprocess inside /assets, run it from the home directory
instead.

22 months agoUpdate Android port
Po Lu [Wed, 1 Mar 2023 06:31:57 +0000 (14:31 +0800)]
Update Android port

* java/AndroidManifest.xml.in: Specify @style/EmacsStyle.
* java/org/gnu/emacs/EmacsActivity.java (onCreate): Stop setting
the theme here.
* java/res/values-v11/style.xml:
* java/res/values-v14/style.xml:
* java/res/values-v29/style.xml:
* java/res/values/style.xml: Extract style resources into
res/values.

22 months agoReplace C++ comments with C style equivalents
Po Lu [Wed, 1 Mar 2023 06:28:04 +0000 (14:28 +0800)]
Replace C++ comments with C style equivalents

* src/alloc.c (Fmake_byte_code, purecopy):
* src/bytecode.c (exec_byte_code):
* src/xdisp.c (face_at_pos): Do not use C++-style comments!

22 months ago; Merge from origin/emacs-29
Stefan Kangas [Wed, 1 Mar 2023 05:30:20 +0000 (06:30 +0100)]
; Merge from origin/emacs-29

The following commit was skipped:

ec1dea7b43f ; Auto-commit of loaddefs files.

22 months agoMerge from origin/emacs-29
Stefan Kangas [Wed, 1 Mar 2023 05:30:20 +0000 (06:30 +0100)]
Merge from origin/emacs-29

97a83ff31fa Eglot: fix M-x eglot-show-workspace-configuration (bug#61...
48a0804d10d ruby-mode: Fix method call indentation in rhs of multiple...
16d012cf3bd * lisp/net/tramp.el (tramp-remote-path): Improve docstring.
b371697cdca Minor change in 'dired--find-possibly-alternative-file'
c2b5c6acc58 Implement prefix arg for 'c-ts-mode-toggle-comment-style'
eb2ab52fb01 Defaults to zero for image-dired--number-of-thumbnails
5dc163f592a ; Add a doc string for 'ediff-window-display-p' obsolescence

22 months agoUpdate SKK-JISYO.L from upstream
Stefan Kangas [Wed, 1 Mar 2023 05:00:53 +0000 (06:00 +0100)]
Update SKK-JISYO.L from upstream

* leim/SKK-DIC/SKK-JISYO.L: Update from
https://raw.githubusercontent.com/skk-dev/dict/master/SKK-JISYO.L

22 months agoUpdate publicsuffix.txt from upstream
Stefan Kangas [Wed, 1 Mar 2023 05:00:51 +0000 (06:00 +0100)]
Update publicsuffix.txt from upstream

* etc/publicsuffix.txt: Update from
https://publicsuffix.org/list/public_suffix_list.dat
dated 2023-02-28 02:16:27 UTC.

22 months ago; Auto-commit of loaddefs files.
Stefan Kangas [Wed, 1 Mar 2023 04:08:22 +0000 (05:08 +0100)]
; Auto-commit of loaddefs files.

22 months ago; Auto-commit of loaddefs files.
Stefan Kangas [Wed, 1 Mar 2023 04:07:53 +0000 (05:07 +0100)]
; Auto-commit of loaddefs files.