emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

master f518543aa4e 3/3: Merge from origin/emacs-29


From: Eli Zaretskii
Subject: master f518543aa4e 3/3: Merge from origin/emacs-29
Date: Thu, 18 May 2023 07:50:49 -0400 (EDT)

branch: master
commit f518543aa4ed00f91842dc5a58cc90a320e3e2e5
Merge: 92a00de5c59 f8d9e40d2c1
Author: Eli Zaretskii <eliz@gnu.org>
Commit: Eli Zaretskii <eliz@gnu.org>

    Merge from origin/emacs-29
    
    f8d9e40d2c1 Attempt to fix redisplay problems on macOS
    4daa6f70497 ; * lisp/simple.el (async-shell-command): Add commentary ...
    dc1a437d460 Clarify misleading comment in isearch.el
    af3b0dc53ff Improve documentation of package-menu commands
    d879847cd4d Fix M-x completion-predicate under python-ts-mode
    1e57b2b4c79 * Account for `byte-compile-warnings' during native compi...
    b5bfd808c6b Avoid duplicate VC packages in 'package-selected-packages'
    c18f9f155f6 * lisp/tab-bar.el (tab-bar-new-tab-to): Set 'window-side'...
    33485fe8f74 ; Better warning message when loading tree-sitter fails
    95a724abaac Update to Org 9.6.6
    c665ca79ff4 ; * admin/make-tarball.txt: Minor copyedits.
    3aef46e466f Merge branch 'emacs-29' of git.sv.gnu.org:/srv/git/emacs ...
    229af8e4b31 ; * lisp/progmodes/csharp-mode.el (csharp-ts-mode--defun-...
---
 admin/make-tarball.txt        |   7 +--
 doc/emacs/package.texi        |  19 +++++---
 etc/refcards/orgcard.tex      |   2 +-
 lisp/emacs-lisp/comp.el       |   2 +
 lisp/emacs-lisp/package-vc.el |   8 +--
 lisp/emacs-lisp/package.el    | 110 ++++++++++++++++++++++--------------------
 lisp/isearch.el               |   6 +--
 lisp/org/org-clock.el         | 103 +++++++++++++++++++--------------------
 lisp/org/org-version.el       |   4 +-
 lisp/org/org.el               |   2 +-
 lisp/progmodes/python.el      |   4 +-
 lisp/simple.el                |   4 ++
 lisp/tab-bar.el               |   4 +-
 lisp/treesit.el               |   5 +-
 src/nsterm.m                  |   3 +-
 15 files changed, 156 insertions(+), 127 deletions(-)

diff --git a/admin/make-tarball.txt b/admin/make-tarball.txt
index 00516a0edd7..1cc97c883af 100644
--- a/admin/make-tarball.txt
+++ b/admin/make-tarball.txt
@@ -75,9 +75,10 @@ General steps (for each step, check for possible errors):
     For the first pretest of a new major release, consider starting a
     new top-level ChangeLog.N file if the last versioned ChangeLog.N
     file is too large.  A good point to start a new ChangeLog.N file
-    is when the last one gets larger than 1.5 MiB.  If so, start a new
-    one by bumping N, and also update the line in top-level
-    Makefile.in which says
+    is when the last one gets larger than 5 MiB, or when you make the
+    first pretest of a new major release, whichever happens later.  If
+    so, start a new ChangeLog.N file by bumping N, and also update the
+    line in top-level Makefile.in which says
 
       CHANGELOG_HISTORY_INDEX_MAX = N
 
diff --git a/doc/emacs/package.texi b/doc/emacs/package.texi
index 1229557673d..f1f88ac7f58 100644
--- a/doc/emacs/package.texi
+++ b/doc/emacs/package.texi
@@ -207,7 +207,8 @@ from lower-priority archives 
(@code{package-menu-toggle-hiding}).
 @findex package-menu-filter-by-archive
 Filter package list by archive (@code{package-menu-filter-by-archive}).
 This prompts for a package archive (e.g., @samp{gnu}), then shows only
-packages from that archive.
+packages from that archive.  You can specify several archives by
+typing their names separated by commas.
 
 @item / d
 @kindex / d @r{(Package Menu)}
@@ -222,7 +223,8 @@ matching that regexp.
 @findex package-menu-filter-by-keyword
 Filter package list by keyword (@code{package-menu-filter-by-keyword}).
 This prompts for a keyword (e.g., @samp{games}), then shows only
-packages with that keyword.
+packages with that keyword.  You can specify several keywords by
+typing them separated by commas.
 
 @item / N
 @kindex / N @r{(Package Menu)}
@@ -243,16 +245,19 @@ with names matching that regexp.
 @kindex / s @r{(Package Menu)}
 @findex package-menu-filter-by-status
 Filter package list by status (@code{package-menu-filter-by-status}).
-This prompts for one or more statuses (e.g., @samp{available}), then
-shows only packages with matching status.
+This prompts for one or more statuses (e.g., @samp{available},
+@pxref{Package Statuses}), then shows only packages with matching
+status.  You can specify several status values by typing them
+separated by commas.
 
 @item / v
 @kindex / v @r{(Package Menu)}
 @findex package-menu-filter-by-version
 Filter package list by version (@code{package-menu-filter-by-version}).
-This prompts first for one of the qualifiers @samp{<}, @samp{>} or
-@samp{=}, and then a package version, and shows packages that has a
-lower, equal or higher version than the one specified.
+This prompts first for one of the comparison symbols @samp{<},
+@samp{>} or @samp{=} and for a version string, and then shows packages
+whose versions are correspondingly lower, equal or higher than the
+version you typed.
 
 @item / m
 @kindex / m @r{(Package Menu)}
diff --git a/etc/refcards/orgcard.tex b/etc/refcards/orgcard.tex
index 6ee77758e06..07463ee6a33 100644
--- a/etc/refcards/orgcard.tex
+++ b/etc/refcards/orgcard.tex
@@ -1,5 +1,5 @@
 % Reference Card for Org Mode
-\def\orgversionnumber{9.6.5}
+\def\orgversionnumber{9.6.6}
 \def\versionyear{2023}          % latest update
 \input emacsver.tex
 
diff --git a/lisp/emacs-lisp/comp.el b/lisp/emacs-lisp/comp.el
index 576cd26dba7..2e07b0b0e60 100644
--- a/lisp/emacs-lisp/comp.el
+++ b/lisp/emacs-lisp/comp.el
@@ -3732,6 +3732,7 @@ Prepare every function for final compilation and drive 
the C back-end."
                            ',native-comp-compiler-options
                            native-comp-driver-options
                            ',native-comp-driver-options
+                           byte-compile-warnings ',byte-compile-warnings
                            load-path ',load-path)
                      ,native-comp-async-env-modifier-form
                      (message "Compiling %s..." ',output)
@@ -4004,6 +4005,7 @@ display a message."
                                              native-comp-driver-options
                                              load-path
                                              backtrace-line-length
+                                             byte-compile-warnings
                                              ;; package-load-list
                                              ;; package-user-dir
                                              ;; package-directory-list
diff --git a/lisp/emacs-lisp/package-vc.el b/lisp/emacs-lisp/package-vc.el
index 3975618ae44..f34cfb3120b 100644
--- a/lisp/emacs-lisp/package-vc.el
+++ b/lisp/emacs-lisp/package-vc.el
@@ -551,9 +551,11 @@ documentation and marking the package as installed."
         (package--reload-previously-loaded new-desc)))
 
     ;; Mark package as selected
-    (package--save-selected-packages
-     (cons (package-desc-name pkg-desc)
-           package-selected-packages))
+    (let ((name (package-desc-name pkg-desc)))
+      (unless (memq name package-selected-packages)
+        (package--save-selected-packages
+         (cons name package-selected-packages))))
+
     (package--quickstart-maybe-refresh)
 
     ;; Confirm that the installation was successful
diff --git a/lisp/emacs-lisp/package.el b/lisp/emacs-lisp/package.el
index 325c7b4e0a6..78017b77677 100644
--- a/lisp/emacs-lisp/package.el
+++ b/lisp/emacs-lisp/package.el
@@ -3597,7 +3597,8 @@ The regexp is added to the list in the user option
 `package-hidden-regexps' and saved for future sessions.
 
 To unhide a package, type
-`\\[customize-variable] RET package-hidden-regexps'.
+`\\[customize-variable] RET package-hidden-regexps', and then modify
+the regexp such that it no longer matches the package's name.
 
 Type \\[package-menu-toggle-hiding] to toggle package hiding."
   (declare (interactive-only "change `package-hidden-regexps' instead."))
@@ -3624,7 +3625,9 @@ Type \\[package-menu-toggle-hiding] to toggle package 
hiding."
 
 (defun package-menu-describe-package (&optional button)
   "Describe the current package.
-If optional arg BUTTON is non-nil, describe its associated package."
+The current package is the package at point.
+If optional arg BUTTON is non-nil, describe its associated
+package(s); this is always nil in interactive invocations."
   (interactive nil package-menu-mode)
   (let ((pkg-desc (if button (button-get button 'package-desc)
                     (tabulated-list-get-id))))
@@ -3634,7 +3637,8 @@ If optional arg BUTTON is non-nil, describe its 
associated package."
 
 ;; fixme numeric argument
 (defun package-menu-mark-delete (&optional _num)
-  "Mark a package for deletion and move to the next line."
+  "Mark the current package for deletion and move to the next line.
+The current package is the package at point."
   (interactive "p" package-menu-mode)
   (package--ensure-package-menu-mode)
   (if (member (package-menu-get-status)
@@ -3643,7 +3647,8 @@ If optional arg BUTTON is non-nil, describe its 
associated package."
     (forward-line)))
 
 (defun package-menu-mark-install (&optional _num)
-  "Mark a package for installation and move to the next line."
+  "Mark the current package for installation and move to the next line.
+The current package is the package at point."
   (interactive "p" package-menu-mode)
   (package--ensure-package-menu-mode)
   (if (member (package-menu-get-status) '("available" "avail-obso" "new" 
"dependency"))
@@ -3651,13 +3656,14 @@ If optional arg BUTTON is non-nil, describe its 
associated package."
     (forward-line)))
 
 (defun package-menu-mark-unmark (&optional _num)
-  "Clear any marks on a package and move to the next line."
+  "Clear any marks on the current package and move to the next line.
+The current package is the package at point."
   (interactive "p" package-menu-mode)
   (package--ensure-package-menu-mode)
   (tabulated-list-put-tag " " t))
 
 (defun package-menu-backup-unmark ()
-  "Back up one line and clear any marks on that package."
+  "Back up one line and clear any marks on that line's package."
   (interactive nil package-menu-mode)
   (package--ensure-package-menu-mode)
   (forward-line -1)
@@ -3695,15 +3701,15 @@ If optional arg BUTTON is non-nil, describe its 
associated package."
     (package--prettify-quick-help-key (cons desc 0))))
 
 (defun package-menu-quick-help ()
-  "Show short key binding help for `package-menu-mode'.
-The full list of keys can be viewed with \\[describe-mode]."
+  "Show short help for key bindings in `package-menu-mode'.
+You can view the full list of keys with \\[describe-mode]."
   (interactive nil package-menu-mode)
   (package--ensure-package-menu-mode)
   (message (mapconcat #'package--prettify-quick-help-key
                       package--quick-help-keys "\n")))
 
 (defun package-menu-get-status ()
-  "Return status text of package at point in Package Menu."
+  "Return status description of package at point in Package Menu."
   (package--ensure-package-menu-mode)
   (let* ((id (tabulated-list-get-id))
          (entry (and id (assoc id tabulated-list-entries))))
@@ -3732,8 +3738,8 @@ consideration."
 (defun package-menu--find-upgrades ()
   "In Package Menu, return an alist of packages that can be upgraded.
 The alist has the same form as `package-alist', namely a list
-of (PKG . DESCS), but where DESCS is the `package-desc' object
-corresponding to the newer version."
+of elements of the form (PKG . DESCS), but where DESCS is the `package-desc'
+object corresponding to the newer version."
   (let (installed available upgrades)
     ;; Build list of installed/available packages in this buffer.
     (dolist (entry tabulated-list-entries)
@@ -3784,10 +3790,10 @@ Implementation of `package-menu-mark-upgrades'."
 
 (defun package-menu-mark-upgrades ()
   "Mark all upgradable packages in the Package Menu.
-For each installed package with a newer version available, place
-an (I)nstall flag on the available version and a (D)elete flag on
-the installed version.  A subsequent \\[package-menu-execute]
-call will upgrade the package.
+For each installed package for which a newer version is available,
+place an (I)nstall flag on the available version and a (D)elete flag
+on the installed version.  A subsequent \\[package-menu-execute] command will 
upgrade
+the marked packages.
 
 If there's an async refresh operation in progress, the flags will
 be placed as part of `package-menu--post-refresh' instead of
@@ -3906,17 +3912,19 @@ packages list, respectively."
     (package--save-selected-packages package-selected-packages)))
 
 (defun package-menu-execute (&optional noquery)
-  "Perform marked Package Menu actions.
+  "Perform Package Menu actions on marked packages.
 Packages marked for installation are downloaded and installed,
 packages marked for deletion are removed, and packages marked for
 upgrading are downloaded and upgraded.
 
 If no packages are marked, the action taken depends on the state
-of the package under point.  If it's not already installed, this
-command will install the package, and if it's installed, it will
-delete the package.
+of the current package, the one at point.  If it's not already
+installed, this command will install the package; if it's installed,
+the command will delete the package.
 
-Optional argument NOQUERY non-nil means do not ask the user to confirm."
+Optional argument NOQUERY non-nil means do not ask the user to
+confirm the installations/deletions; this is always nil in interactive
+invocations."
   (interactive nil package-menu-mode)
   (package--ensure-package-menu-mode)
   (let (install-list delete-list cmd pkg-desc)
@@ -4167,13 +4175,12 @@ the header line of the first column."
 (defun package-menu-filter-by-archive (archive)
   "Filter the \"*Packages*\" buffer by ARCHIVE.
 Display only packages from package archive ARCHIVE.
+ARCHIVE can be the name of a single archive (a string), or
+a list of archive names.  If ARCHIVE is nil or an empty
+string, show all packages.
 
-When called interactively, prompt for ARCHIVE, which can be a
-comma-separated string.  If ARCHIVE is empty, show all packages.
-
-When called from Lisp, ARCHIVE can be a string or a list of
-strings.  If ARCHIVE is nil or the empty string, show all
-packages."
+When called interactively, prompt for ARCHIVE.  To specify
+several archives, type their names separated by commas."
   (interactive (list (completing-read-multiple
                       "Filter by archive (comma separated): "
                       (mapcar #'car package-archives)))
@@ -4189,9 +4196,9 @@ packages."
      (concat "archive:" (string-join archives ",")))))
 
 (defun package-menu-filter-by-description (description)
-  "Filter the \"*Packages*\" buffer by DESCRIPTION regexp.
-Display only packages with a description that matches regexp
-DESCRIPTION.
+  "Filter the \"*Packages*\" buffer by the regexp DESCRIPTION.
+Display only packages whose description matches the regexp
+given as DESCRIPTION.
 
 When called interactively, prompt for DESCRIPTION.
 
@@ -4208,14 +4215,16 @@ If DESCRIPTION is nil or the empty string, show all 
packages."
 
 (defun package-menu-filter-by-keyword (keyword)
   "Filter the \"*Packages*\" buffer by KEYWORD.
-Display only packages with specified KEYWORD.
+Display only packages whose keywords match the specified KEYWORD.
+KEYWORD can be a string or a list of strings.  If KEYWORD is nil
+or the empty string, show all packages.
 
-When called interactively, prompt for KEYWORD, which can be a
-comma-separated string.  If KEYWORD is empty, show all packages.
+In addition to package keywords, KEYWORD can include the name(s)
+of archive(s) and the package status, such as \"available\"
+or \"built-in\" or \"obsolete\".
 
-When called from Lisp, KEYWORD can be a string or a list of
-strings.  If KEYWORD is nil or the empty string, show all
-packages."
+When called interactively, prompt for KEYWORD.  To specify several
+keywords, type them separated by commas."
   (interactive (list (completing-read-multiple
                       "Keywords (comma separated): "
                       (package-all-keywords)))
@@ -4233,8 +4242,8 @@ packages."
   'package-menu-filter #'package-menu-filter-by-keyword "27.1")
 
 (defun package-menu-filter-by-name-or-description (name-or-description)
-  "Filter the \"*Packages*\" buffer by NAME-OR-DESCRIPTION regexp.
-Display only packages with a name-or-description that matches regexp
+  "Filter the \"*Packages*\" buffer by the regexp NAME-OR-DESCRIPTION.
+Display only packages whose name or description matches the regexp
 NAME-OR-DESCRIPTION.
 
 When called interactively, prompt for NAME-OR-DESCRIPTION.
@@ -4255,8 +4264,8 @@ packages."
                       (format "name-or-desc:%s" name-or-description))))
 
 (defun package-menu-filter-by-name (name)
-  "Filter the \"*Packages*\" buffer by NAME regexp.
-Display only packages with name that matches regexp NAME.
+  "Filter the \"*Packages*\" buffer by the regexp NAME.
+Display only packages whose name matches the regexp NAME.
 
 When called interactively, prompt for NAME.
 
@@ -4274,13 +4283,11 @@ If NAME is nil or the empty string, show all packages."
 (defun package-menu-filter-by-status (status)
   "Filter the \"*Packages*\" buffer by STATUS.
 Display only packages with specified STATUS.
+STATUS can be a single status, a string, or a list of strings.
+If STATUS is nil or the empty string, show all packages.
 
-When called interactively, prompt for STATUS, which can be a
-comma-separated string.  If STATUS is empty, show all packages.
-
-When called from Lisp, STATUS can be a string or a list of
-strings.  If STATUS is nil or the empty string, show all
-packages."
+When called interactively, prompt for STATUS.  To specify
+several possible status values, type them seperated by commas."
   (interactive (list (completing-read "Filter by status: "
                                       '("avail-obso"
                                         "available"
@@ -4309,12 +4316,12 @@ packages."
 
 (defun package-menu-filter-by-version (version predicate)
   "Filter the \"*Packages*\" buffer by VERSION and PREDICATE.
-Display only packages with a matching version.
+Display only packages whose version satisfies the condition
+defined by VERSION and PREDICATE.
 
-When called interactively, prompt for one of the qualifiers `<',
-`>' or `=', and a package version.  Show only packages that has a
-lower (`<'), equal (`=') or higher (`>') version than the
-specified one.
+When called interactively, prompt for one of the comparison operators
+`<', `>' or `=', and for a version.  Show only packages whose version
+is lower (`<'), equal (`=') or higher (`>') than the specified VERSION.
 
 When called from Lisp, VERSION should be a version string and
 PREDICATE should be the symbol `=', `<' or `>'.
@@ -4352,7 +4359,8 @@ If VERSION is nil or the empty string, show all packages."
        (format "versions:%s%s" predicate version)))))
 
 (defun package-menu-filter-marked ()
-  "Filter \"*Packages*\" buffer by non-empty upgrade mark.
+  "Filter \"*Packages*\" buffer by non-empty mark.
+Show only the packages that have been marked for installation or deletion.
 Unlike other filters, this leaves the marks intact."
   (interactive nil package-menu-mode)
   (package--ensure-package-menu-mode)
diff --git a/lisp/isearch.el b/lisp/isearch.el
index 094e02d605e..3d2bbda4975 100644
--- a/lisp/isearch.el
+++ b/lisp/isearch.el
@@ -633,9 +633,9 @@ This is like `describe-bindings', but displays only Isearch 
keys."
 
     (define-key map "\M-\t" 'isearch-complete)
 
-    ;; Pass frame events transparently so they won't exit the search.
-    ;; In particular, if we have more than one display open, then a
-    ;; switch-frame might be generated by someone typing at another keyboard.
+    ;; Frame events should exit the search, because such frame events
+    ;; as `switch-frame’ and `delete-frame’ change the current buffer.
+    ;; See Bug#41338 for details.
     (define-key map [switch-frame] nil)
     (define-key map [delete-frame] nil)
     (define-key map [iconify-frame] nil)
diff --git a/lisp/org/org-clock.el b/lisp/org/org-clock.el
index f9daf3f14d8..d7fe14cd5e1 100644
--- a/lisp/org/org-clock.el
+++ b/lisp/org/org-clock.el
@@ -3062,57 +3062,58 @@ PROPERTIES: The list properties specified in the 
`:properties' parameter
 Otherwise, return nil."
   (interactive)
   (let ((origin (point))) ;; `save-excursion' may not work when deleting.
-    (save-excursion
-      (beginning-of-line 1)
-      (skip-chars-forward " \t")
-      (when (looking-at org-clock-string)
-        (let ((re (concat "[ \t]*" org-clock-string
-                         " *[[<]\\([^]>]+\\)[]>]\\(-+[[<]\\([^]>]+\\)[]>]"
-                         "\\([ \t]*=>.*\\)?\\)?"))
-             ts te h m s neg)
-          (cond
-          ((not (looking-at re))
-           nil)
-          ((not (match-end 2))
-           (when (and (equal (marker-buffer org-clock-marker) (current-buffer))
-                      (> org-clock-marker (point))
-                       (<= org-clock-marker (line-end-position)))
-             ;; The clock is running here
-             (setq org-clock-start-time
-                   (org-time-string-to-time (match-string 1)))
-             (org-clock-update-mode-line)))
-          (t
-            ;; Prevent recursive call from `org-timestamp-change'.
-            (cl-letf (((symbol-function 'org-clock-update-time-maybe) 
#'ignore))
-              ;; Update timestamps.
-              (save-excursion
-                (goto-char (match-beginning 1)) ; opening timestamp
-                (save-match-data (org-timestamp-change 0 'day)))
-              ;; Refresh match data.
-              (looking-at re)
-              (save-excursion
-                (goto-char (match-beginning 3)) ; closing timestamp
-                (save-match-data (org-timestamp-change 0 'day))))
-            ;; Refresh match data.
-            (looking-at re)
-            (and (match-end 4) (delete-region (match-beginning 4) (match-end 
4)))
-            (end-of-line 1)
-            (setq ts (match-string 1)
-                  te (match-string 3))
-            (setq s (- (org-time-string-to-seconds te)
-                      (org-time-string-to-seconds ts))
-                  neg (< s 0)
-                  s (abs s)
-                  h (floor (/ s 3600))
-                  s (- s (* 3600 h))
-                  m (floor (/ s 60))
-                  s (- s (* 60 s)))
-           (insert " => " (format (if neg "-%d:%02d" "%2d:%02d") h m))
-           t)))))
-    ;; Move back to initial position, but never beyond updated
-    ;; clock.
-    (unless (< (point) origin)
-      (goto-char origin))))
+    (prog1
+        (save-excursion
+          (beginning-of-line 1)
+          (skip-chars-forward " \t")
+          (when (looking-at org-clock-string)
+            (let ((re (concat "[ \t]*" org-clock-string
+                             " *[[<]\\([^]>]+\\)[]>]\\(-+[[<]\\([^]>]+\\)[]>]"
+                             "\\([ \t]*=>.*\\)?\\)?"))
+                 ts te h m s neg)
+              (cond
+              ((not (looking-at re))
+               nil)
+              ((not (match-end 2))
+               (when (and (equal (marker-buffer org-clock-marker) 
(current-buffer))
+                          (> org-clock-marker (point))
+                           (<= org-clock-marker (line-end-position)))
+                 ;; The clock is running here
+                 (setq org-clock-start-time
+                       (org-time-string-to-time (match-string 1)))
+                 (org-clock-update-mode-line)))
+              (t
+                ;; Prevent recursive call from `org-timestamp-change'.
+                (cl-letf (((symbol-function 'org-clock-update-time-maybe) 
#'ignore))
+                  ;; Update timestamps.
+                  (save-excursion
+                    (goto-char (match-beginning 1)) ; opening timestamp
+                    (save-match-data (org-timestamp-change 0 'day)))
+                  ;; Refresh match data.
+                  (looking-at re)
+                  (save-excursion
+                    (goto-char (match-beginning 3)) ; closing timestamp
+                    (save-match-data (org-timestamp-change 0 'day))))
+                ;; Refresh match data.
+                (looking-at re)
+                (and (match-end 4) (delete-region (match-beginning 4) 
(match-end 4)))
+                (end-of-line 1)
+                (setq ts (match-string 1)
+                      te (match-string 3))
+                (setq s (- (org-time-string-to-seconds te)
+                          (org-time-string-to-seconds ts))
+                      neg (< s 0)
+                      s (abs s)
+                      h (floor (/ s 3600))
+                      s (- s (* 3600 h))
+                      m (floor (/ s 60))
+                      s (- s (* 60 s)))
+               (insert " => " (format (if neg "-%d:%02d" "%2d:%02d") h m))
+               t)))))
+      ;; Move back to initial position, but never beyond updated
+      ;; clock.
+      (unless (< (point) origin)
+        (goto-char origin)))))
 
 (defun org-clock-save ()
   "Persist various clock-related data to disk.
diff --git a/lisp/org/org-version.el b/lisp/org/org-version.el
index ef61dc9cbd6..8d93af2c20d 100644
--- a/lisp/org/org-version.el
+++ b/lisp/org/org-version.el
@@ -5,13 +5,13 @@
 (defun org-release ()
   "The release version of Org.
 Inserted by installing Org mode or when a release is made."
-   (let ((org-release "9.6.5"))
+   (let ((org-release "9.6.6"))
      org-release))
 ;;;###autoload
 (defun org-git-version ()
   "The Git version of Org mode.
 Inserted by installing Org or when a release is made."
-   (let ((org-git-version "release_9.6.5-3-g2993f4"))
+   (let ((org-git-version "release_9.6.6"))
      org-git-version))
 
 (provide 'org-version)
diff --git a/lisp/org/org.el b/lisp/org/org.el
index f4aa28cc486..d3e14fecec3 100644
--- a/lisp/org/org.el
+++ b/lisp/org/org.el
@@ -9,7 +9,7 @@
 ;; URL: https://orgmode.org
 ;; Package-Requires: ((emacs "26.1"))
 
-;; Version: 9.6.5
+;; Version: 9.6.6
 
 ;; This file is part of GNU Emacs.
 ;;
diff --git a/lisp/progmodes/python.el b/lisp/progmodes/python.el
index f9b645cc3df..0ddce92b21e 100644
--- a/lisp/progmodes/python.el
+++ b/lisp/progmodes/python.el
@@ -5032,7 +5032,7 @@ the if condition."
 (defun python--completion-predicate (_ buffer)
   (provided-mode-derived-p
    (buffer-local-value 'major-mode buffer)
-   'python-mode))
+   'python-base-mode))
 
 (defmacro python-skeleton-define (name doc &rest skel)
   "Define a `python-mode' skeleton using NAME DOC and SKEL.
@@ -6856,7 +6856,7 @@ implementations: `python-mode' and `python-ts-mode'."
 (defun python-shell--completion-predicate (_ buffer)
   (provided-mode-derived-p
    (buffer-local-value 'major-mode buffer)
-   'python-mode 'inferior-python-mode))
+   'python-base-mode 'inferior-python-mode))
 
 ;; Commands that only make sense in the Python shell or when editing
 ;; Python code.
diff --git a/lisp/simple.el b/lisp/simple.el
index cbcdefa7a0f..e2bec58a7b0 100644
--- a/lisp/simple.el
+++ b/lisp/simple.el
@@ -4463,6 +4463,10 @@ whose `car' is BUFFER."
                           '(nil (inhibit-switch-frame . t)))))
                 (set-window-point win pos)))))))))
 
+;; Implementation note: the next function intentionally tries to use
+;; the same signature as 'shell-command', although the 3rd arg is
+;; currently ignored, to allow us to implement support for specifying
+;; ERROR-BUFFER in the future.
 (defun async-shell-command (command &optional output-buffer error-buffer)
   "Execute string COMMAND asynchronously in background.
 
diff --git a/lisp/tab-bar.el b/lisp/tab-bar.el
index 9d703b5d048..10b876d1d61 100644
--- a/lisp/tab-bar.el
+++ b/lisp/tab-bar.el
@@ -1582,7 +1582,9 @@ After the tab is created, the hooks in
           (delete-other-windows)
           (if (eq tab-bar-new-tab-choice 'window)
               ;; Create new unique window from remaining window
-              (window-state-put (window-state-get))
+              (progn
+                (set-window-parameter nil 'window-side nil)
+                (window-state-put (window-state-get)))
             ;; Create a new window to get rid of old window parameters
             ;; (e.g. prev/next buffers) of old window.
             (split-window) (delete-window))))
diff --git a/lisp/treesit.el b/lisp/treesit.el
index 2e6c77f64d5..49eeba64a14 100644
--- a/lisp/treesit.el
+++ b/lisp/treesit.el
@@ -2424,7 +2424,10 @@ instead of emitting a warning."
     ;; Check for each condition and set MSG.
     (catch 'term
       (when (not (treesit-available-p))
-        (setq msg "tree-sitter library is not compiled with Emacs")
+        (setq msg (if (fboundp 'treesit-node-p)
+                      ;; Windows loads tree-sitter dynakically.
+                      "tree-sitter library is not available or failed to load"
+                    "Emacs is not compiled with tree-sitter library"))
         (throw 'term nil))
       (when (> (position-bytes (max (point-min) (1- (point-max))))
                treesit-max-buffer-size)
diff --git a/src/nsterm.m b/src/nsterm.m
index b9e3cbf81a1..3e089cc1ff1 100644
--- a/src/nsterm.m
+++ b/src/nsterm.m
@@ -2704,11 +2704,12 @@ ns_scroll_run (struct window *w, struct run *run)
   {
     NSRect srcRect = NSMakeRect (x, from_y, width, height);
     NSPoint dest = NSMakePoint (x, to_y);
+    NSRect destRect = NSMakeRect (x, from_y, width, height);
     EmacsView *view = FRAME_NS_VIEW (f);
 
     [view copyRect:srcRect to:dest];
 #ifdef NS_IMPL_COCOA
-    [view setNeedsDisplayInRect:srcRect];
+    [view setNeedsDisplayInRect:destRect];
 #endif
   }
 



reply via email to

[Prev in Thread] Current Thread [Next in Thread]