]> git.eshelyaron.com Git - emacs.git/commitdiff
Add calling convention to face-attr-construct
authorStefan Kangas <stefankangas@gmail.com>
Wed, 9 Aug 2023 01:30:56 +0000 (03:30 +0200)
committerStefan Kangas <stefankangas@gmail.com>
Wed, 9 Aug 2023 01:30:56 +0000 (03:30 +0200)
* lisp/faces.el (face-attr-construct): Add
advertised-calling-convention declaration.

lisp/cus-edit.el
lisp/faces.el

index f5143bdb53f25705cfe506d16fbecae8c4cd78d9..9b73a72b2384a406824aefec2736a6eb71c90e31 100644 (file)
@@ -3751,7 +3751,7 @@ WIDGET should be a `custom-face' widget."
     ;; If the user has changed this face in some other way,
     ;; edit it as the user has specified it.
     (if (not (face-spec-match-p face spec (selected-frame)))
-       (setq spec `((t ,(face-attr-construct face (selected-frame))))))
+        (setq spec `((t ,(face-attr-construct face)))))
     spec))
 
 (defun custom-face-get-current-spec (face)
index 8017f5fa65ed2010255d812bffdecf029841233f..1a446aacacd0ffa06600622cbeabd8beb13dbb84 100644 (file)
@@ -1540,15 +1540,12 @@ argument, prompt for a regular expression using `read-regexp'."
 ;;; Face specifications (defface).
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 
-;; Parameter FRAME Is kept for call compatibility to with previous
-;; face implementation.
-
 (defun face-attr-construct (face &optional _frame)
   "Return a `defface'-style attribute list for FACE.
 Value is a property list of pairs ATTRIBUTE VALUE for all specified
 face attributes of FACE where ATTRIBUTE is the attribute name and
-VALUE is the specified value of that attribute.
-Argument FRAME is ignored and retained for compatibility."
+VALUE is the specified value of that attribute."
+  (declare (advertised-calling-convention (face) "30.1"))
   (let (result)
     (dolist (entry face-attribute-name-alist result)
       (let* ((attribute (car entry))