summaryrefslogtreecommitdiff
path: root/lisp/emacs-lisp
diff options
context:
space:
mode:
Diffstat (limited to 'lisp/emacs-lisp')
-rw-r--r--lisp/emacs-lisp/cl-macs.el7
-rw-r--r--lisp/emacs-lisp/derived.el16
-rw-r--r--lisp/emacs-lisp/eieio.el5
3 files changed, 16 insertions, 12 deletions
diff --git a/lisp/emacs-lisp/cl-macs.el b/lisp/emacs-lisp/cl-macs.el
index 6d6482c3497..833c1d19737 100644
--- a/lisp/emacs-lisp/cl-macs.el
+++ b/lisp/emacs-lisp/cl-macs.el
@@ -3083,9 +3083,10 @@ Supported keywords for slots are:
;; The arg "cl-x" is referenced by name in eg pred-form
;; and pred-check, so changing it is not straightforward.
(push `(,defsym ,accessor (cl-x)
- ,(format "Access slot \"%s\" of `%s' struct CL-X.%s"
- slot name
- (if doc (concat "\n" doc) ""))
+ ,(internal--format-docstring-line
+ "Access slot \"%s\" of `%s' struct CL-X.%s"
+ slot name
+ (if doc (concat "\n" doc) ""))
(declare (side-effect-free t))
,access-body)
forms)
diff --git a/lisp/emacs-lisp/derived.el b/lisp/emacs-lisp/derived.el
index 5aa745262ad..dd30846546b 100644
--- a/lisp/emacs-lisp/derived.el
+++ b/lisp/emacs-lisp/derived.el
@@ -321,7 +321,7 @@ No problems result if this variable is not bound.
(format "Major mode derived from `%s' by `define-derived-mode'.
It inherits all of the parent's attributes, but has its own keymap%s:
- `%s'%s
+%s
which more-or-less shadow%s %s's corresponding table%s."
parent
@@ -330,12 +330,14 @@ which more-or-less shadow%s %s's corresponding table%s."
(abbrev "\nand abbrev table")
(syntax "\nand syntax table")
(t ""))
- map
- (cond ((and abbrev syntax)
- (format ", `%s' and `%s'" abbrev syntax))
- ((or abbrev syntax)
- (format " and `%s'" (or abbrev syntax)))
- (t ""))
+ (internal--format-docstring-line
+ " `%s'%s"
+ map
+ (cond ((and abbrev syntax)
+ (format ", `%s' and `%s'" abbrev syntax))
+ ((or abbrev syntax)
+ (format " and `%s'" (or abbrev syntax)))
+ (t "")))
(if (or abbrev syntax) "" "s")
parent
(if (or abbrev syntax) "s" "")))))
diff --git a/lisp/emacs-lisp/eieio.el b/lisp/emacs-lisp/eieio.el
index c16d8e110ec..2dc3e0aeffa 100644
--- a/lisp/emacs-lisp/eieio.el
+++ b/lisp/emacs-lisp/eieio.el
@@ -205,7 +205,7 @@ and reference them using the function `class-option'."
(eieio-oset this ',sname value))
accessors)
(push `(cl-defmethod ,acces ((this ,name))
- ,(format
+ ,(internal--format-docstring-line
"Retrieve the slot `%S' from an object of class `%S'."
sname name)
;; FIXME: Why is this different from the :reader case?
@@ -285,7 +285,8 @@ This method is obsolete."
;; Non-abstract classes need a constructor.
`(defun ,name (&rest slots)
- ,(format "Create a new object of class type `%S'." name)
+ ,(internal--format-docstring-line
+ "Create a new object of class type `%S'." name)
(declare (compiler-macro
(lambda (whole)
(if (not (stringp (car slots)))