]> git.eshelyaron.com Git - emacs.git/commitdiff
Use 'alist-set' in a few more places
authorEshel Yaron <me@eshelyaron.com>
Sat, 4 Jan 2025 17:05:38 +0000 (18:05 +0100)
committerEshel Yaron <me@eshelyaron.com>
Sat, 4 Jan 2025 17:05:38 +0000 (18:05 +0100)
lisp/calc/calc-yank.el
lisp/completion-preview.el
lisp/help.el
lisp/international/mule-cmds.el
lisp/progmodes/elisp-mode.el

index 780e5327fb5c4681d5c789907af02be541e8b9bf..f8993354a66e8a6a431a844c857872e59c32af28 100644 (file)
@@ -259,7 +259,7 @@ TEXT and CALCVAL are the TEXT and internal structure of stack entries.")
   "Set the contents of the Calc register REGISTER to (TEXT . CALCVAL),
 as well as set the contents of the Emacs register REGISTER to TEXT."
   (set-register register text)
-  (setf (alist-get register calc-register-alist) (cons text calcval)))
+  (alist-set register calc-register-alist (cons text calcval)))
 
 (defun calc-get-register (reg)
   "Return the CALCVAL portion of the contents of the Calc register REG,
index 744ca004e76f7d66be94156d8fdadd90e841e743..085cf43c14525b06d2a565c68030e5d86fbe6d46 100644 (file)
@@ -368,9 +368,9 @@ set to the value of this option while the completion preview is visible."
           (completion-preview--modify-cursor))
         (setq completion-preview--window (selected-window)
               completion-preview--buffer (current-buffer))
-        (setf (alist-get 'completion-preview-active-mode
-                         minor-mode-overriding-map-alist)
-              completion-preview-active-mode-map))
+        (alist-set 'completion-preview-active-mode
+                   minor-mode-overriding-map-alist
+                   completion-preview-active-mode-map))
     (remove-hook 'post-command-hook #'completion-preview--cleanup)
     (completion-preview--restore-cursor)
     (setq completion-preview--window nil
index 0b6fd3c229027c803a91f073cf5cb1c35ee3cb9a..5d1dcd46858564461afee5604726cfaacf5d57b5 100644 (file)
@@ -472,7 +472,7 @@ immediate bindings."
   :group 'help)
 
 (defun help--complete-keys-add (key val)
-  (setf (alist-get key help--complete-keys-alist nil nil #'equal) val))
+  (alist-set key help--complete-keys-alist val #'equal))
 
 (defcustom help-complete-keys-max-depth 3
   "Maximum length of prefix key sequence to flatten in `help-complete-keys'."
index b3d0f4d551f40c64e064ba6fde7dd8a4b781a314..b1556689f531cea8a94c89d4c648e8fae1a20580 100644 (file)
@@ -2973,7 +2973,7 @@ See also the documentation of `get-char-code-property' and
       ;; undo that, probably because `charprop.el' is being re-loaded.
       ;; Just skip it, in order to work around a recursive load (bug#52945).
       nil
-    (setf (alist-get name char-code-property-alist) table)
+    (alist-set name char-code-property-alist table)
     (put name 'char-code-property-documentation (purecopy docstring))))
 
 (defvar char-code-property-table
index d5a28f0041ea9d1cd7b6f0699cbb77cbebcc6209..606cedc691cbd5c6f7da522f775a0b4d29222bab 100644 (file)
@@ -457,9 +457,9 @@ be used instead.
   (cl-pushnew 'cursor-sensor-functions
               (alist-get 'font-lock-extra-managed-props
                          (nthcdr 5 font-lock-defaults)))
-  (setf (alist-get 'font-lock-fontify-region-function
-                   (nthcdr 5 font-lock-defaults))
-        #'elisp-fontify-region)
+  (alist-set 'font-lock-fontify-region-function
+             (nthcdr 5 font-lock-defaults)
+             #'elisp-fontify-region)
   (setf (nth 2 font-lock-defaults) nil)
   (add-hook 'after-load-functions #'elisp--font-lock-flush-elisp-buffers)
   (if (boundp 'electric-pair-text-pairs)