emacs-diffs
[Top][All Lists]
Advanced

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

master cc8726d2c8b 05/10: Merge from origin/emacs-29


From: Eli Zaretskii
Subject: master cc8726d2c8b 05/10: Merge from origin/emacs-29
Date: Sat, 23 Sep 2023 09:43:33 -0400 (EDT)

branch: master
commit cc8726d2c8bc0e3b67cb8b97e388f9339bea0f96
Merge: 36e78f14804 6bc3800000c
Author: Eli Zaretskii <eliz@gnu.org>
Commit: Eli Zaretskii <eliz@gnu.org>

    Merge from origin/emacs-29
    
    6bc3800000c Ensure ucs-names is consistent with Unicode names
    93134bb9c2f Make key-translate actually work
    85f49a9bc8b Update to Org 9.6.9
    2826c26537c Add leim subdirectories to emacs package
---
 etc/refcards/orgcard.tex              |  2 +-
 lisp/finder.el                        |  2 ++
 lisp/international/mule-cmds.el       | 26 ++++++++++++++++++--------
 lisp/keymap.el                        |  8 +++++---
 lisp/org/ob-python.el                 |  2 +-
 lisp/org/org-version.el               |  4 ++--
 lisp/org/org.el                       |  2 +-
 test/lisp/international/mule-tests.el | 24 ++++++++++++++++++++++++
 8 files changed, 54 insertions(+), 16 deletions(-)

diff --git a/etc/refcards/orgcard.tex b/etc/refcards/orgcard.tex
index 23a2f73dba7..62ba687c19f 100644
--- a/etc/refcards/orgcard.tex
+++ b/etc/refcards/orgcard.tex
@@ -1,5 +1,5 @@
 % Reference Card for Org Mode
-\def\orgversionnumber{9.6.8}
+\def\orgversionnumber{9.6.9}
 \def\versionyear{2023}          % latest update
 \input emacsver.tex
 
diff --git a/lisp/finder.el b/lisp/finder.el
index 811e3838349..4e3a3566ce9 100644
--- a/lisp/finder.el
+++ b/lisp/finder.el
@@ -148,6 +148,8 @@ would otherwise be.")
     ("international" . emacs)
     ("language" . emacs)
     ("leim" . emacs)
+    ("ja-dic" . emacs)
+    ("quail" . emacs)
     ("mh-e" . mh-e)
     ("obsolete" . emacs)
     ("semantic" . semantic)
diff --git a/lisp/international/mule-cmds.el b/lisp/international/mule-cmds.el
index c26898f7649..fe3610b0fbc 100644
--- a/lisp/international/mule-cmds.el
+++ b/lisp/international/mule-cmds.el
@@ -3094,6 +3094,10 @@ on encoding."
 (defun ucs-names ()
   "Return table of CHAR-NAME keys and CHAR-CODE values cached in `ucs-names'."
   (or ucs-names
+      ;; Sometimes these ranges will need adjusting as codepoints are
+      ;; added to unicode.  The test case
+      ;; 'mule-cmds-tests--ucs-names-missing-names' will tell you
+      ;; which are missing (Bug#65997).
       (let ((ranges
             '((#x0000 . #x33FF)
               ;; (#x3400 . #x4DBF) CJK Ideographs Extension A
@@ -3106,14 +3110,16 @@ on encoding."
                (#x14400 . #x14646)
               ;; (#x14647 . #x167FF) unused
               (#x16800 . #x16F9F)
-               (#x16FE0 . #x16FE3)
+               (#x16FE0 . #x16FF1)
                ;; (#x17000 . #x187FF) Tangut Ideographs
                ;; (#x18800 . #x18AFF) Tangut Components
                ;; (#x18B00 . #x18CFF) Khitan Small Script
                ;; (#x18D00 . #x18D0F) Tangut Ideograph Supplement
               ;; (#x18D10 . #x1AFEF) unused
-              (#x1AFF0 . #x1B12F)
-               ;; (#x1B130 . #x1B14F) unused
+              (#x1AFF0 . #x1B122)
+               ;; (#x1B123 . #x1B131) unused
+               (#x1B132 . #x1B132)
+               ;; (#x1B133 . #x1B14F) unused
                (#x1B150 . #x1B16F)
                (#x1B170 . #x1B2FF)
               ;; (#x1B300 . #x1BBFF) unused
@@ -3130,12 +3136,16 @@ on encoding."
            (while (<= c end)
              (let ((new-name (get-char-code-property c 'name))
                    (old-name (get-char-code-property c 'old-name)))
-               ;; In theory this code could end up pushing an "old-name" that
-               ;; shadows a "new-name" but in practice every time an
-               ;; `old-name' conflicts with a `new-name', the newer one has a
-               ;; higher code, so it gets pushed later!
+                ;; This code used to push both old-name and new-name
+                ;; on the assumption that the new-name codepoint would
+                ;; always be higher, which was true for a long time.
+                ;; As of at latest 2023-09-15, this is no longer true,
+                ;; so we now skip the old-name if it conflicts with an
+                ;; existing new-name (Bug#65997).
                (if new-name (puthash new-name c names))
-               (if old-name (puthash old-name c names))
+                (when (and old-name
+                           (not (gethash old-name names)))
+                  (puthash old-name c names))
                 ;; Unicode uses the spelling "lamda" in character
                 ;; names, instead of "lambda", due to "preferences
                 ;; expressed by the Greek National Body" (Bug#30513).
diff --git a/lisp/keymap.el b/lisp/keymap.el
index 093536eda93..7e659c42002 100644
--- a/lisp/keymap.el
+++ b/lisp/keymap.el
@@ -382,15 +382,17 @@ which is
 This function creates a `keyboard-translate-table' if necessary
 and then modifies one entry in it.
 
-Both KEY and TO should be specified by strings that satisfy `key-valid-p'."
+Both FROM and TO should be specified by strings that satisfy `key-valid-p'."
   (declare (compiler-macro
             (lambda (form) (keymap--compile-check from to) form)))
   (keymap--check from)
   (keymap--check to)
   (or (char-table-p keyboard-translate-table)
       (setq keyboard-translate-table
-           (make-char-table 'keyboard-translate-table nil)))
-  (aset keyboard-translate-table (key-parse from) (key-parse to)))
+            (make-char-table 'keyboard-translate-table nil)))
+  (aset keyboard-translate-table
+        (aref (key-parse from) 0)
+        (aref (key-parse to) 0)))
 
 (defun keymap-lookup (keymap key &optional accept-default no-remap position)
   "Return the binding for command KEY in KEYMAP.
diff --git a/lisp/org/ob-python.el b/lisp/org/ob-python.el
index c19af0ab331..6c05d1c8b2a 100644
--- a/lisp/org/ob-python.el
+++ b/lisp/org/ob-python.el
@@ -235,7 +235,7 @@ then create.  Return the initialized session."
           ;; multiple prompts during initialization.
           (with-current-buffer py-buffer
             (while (not org-babel-python--initialized)
-              (org-babel-comint-wait-for-output py-buffer)))
+              (sleep-for 0 10)))
         (org-babel-comint-wait-for-output py-buffer))
       (setq org-babel-python-buffers
            (cons (cons session py-buffer)
diff --git a/lisp/org/org-version.el b/lisp/org/org-version.el
index 3b58ea06818..a859fe6d412 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.8"))
+   (let ((org-release "9.6.9"))
      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.8-3-g21171d"))
+   (let ((org-git-version "release_9.6.9"))
      org-git-version))
 
 (provide 'org-version)
diff --git a/lisp/org/org.el b/lisp/org/org.el
index 0e06c6e6bbc..5a600a84f22 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.8
+;; Version: 9.6.9
 
 ;; This file is part of GNU Emacs.
 ;;
diff --git a/test/lisp/international/mule-tests.el 
b/test/lisp/international/mule-tests.el
index 3e0c5bf9f4b..4dc099a18af 100644
--- a/test/lisp/international/mule-tests.el
+++ b/test/lisp/international/mule-tests.el
@@ -49,6 +49,30 @@
                        (kbd "C-x RET c u t f - 8 RET C-u C-u c a b RET")
                      (read-string "prompt:"))))))
 
+;;Bug#65997, ensure that old-names haven't overriden new names.
+(ert-deftest mule-cmds-tests--ucs-names-old-name-override ()
+  (let (code-points)
+    (dotimes (u (1+ (max-char 'ucs)))
+      (when-let* ((name (get-char-code-property u 'name))
+                  (c (char-from-name name)))
+        (when (and (not (<= #xD800 u #xDFFF))
+                   (not (= c u)))
+          (push (format "%X" u) code-points))))
+    (setq code-points (nreverse code-points))
+    (should (null code-points))))
+
+;; Bug#65997, ensure that all codepoints with names are in '(ucs-names)'.
+(ert-deftest mule-cmds-tests--ucs-names-missing-names ()
+  (let (code-points)
+    (dotimes (u (1+ (max-char 'ucs)))
+      (when-let ((name (get-char-code-property u 'name)))
+        (when (and (not (<= #xD800 u #xDFFF))
+                   (not (<= #x18800 u #x18AFF))
+                   (not (char-from-name name)))
+          (push (format "%X" u) code-points))))
+    (setq code-points (nreverse code-points))
+    (should (null code-points))))
+
 (ert-deftest mule-utf-7 ()
   ;; utf-7 and utf-7-imap are not ASCII-compatible.
   (should-not (coding-system-get 'utf-7 :ascii-compatible-p))



reply via email to

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