aboutsummaryrefslogtreecommitdiffstats
path: root/doc
diff options
context:
space:
mode:
Diffstat (limited to 'doc')
-rw-r--r--doc/lispref/strings.texi10
1 files changed, 7 insertions, 3 deletions
diff --git a/doc/lispref/strings.texi b/doc/lispref/strings.texi
index dd004927caf..09c3bdf71f6 100644
--- a/doc/lispref/strings.texi
+++ b/doc/lispref/strings.texi
@@ -812,15 +812,19 @@ formatting feature described here; they differ from @code{format-message} only
812in how they use the result of formatting. 812in how they use the result of formatting.
813 813
814@defun format string &rest objects 814@defun format string &rest objects
815This function returns a new string that is made by copying 815This function returns a string equal to @var{string}, replacing any format
816@var{string} and then replacing any format specification 816specifications with encodings of the corresponding @var{objects}. The
817in the copy with encodings of the corresponding @var{objects}. The
818arguments @var{objects} are the computed values to be formatted. 817arguments @var{objects} are the computed values to be formatted.
819 818
820The characters in @var{string}, other than the format specifications, 819The characters in @var{string}, other than the format specifications,
821are copied directly into the output, including their text properties, 820are copied directly into the output, including their text properties,
822if any. Any text properties of the format specifications are copied 821if any. Any text properties of the format specifications are copied
823to the produced string representations of the argument @var{objects}. 822to the produced string representations of the argument @var{objects}.
823
824The output string need not be newly-allocated. For example, if
825@code{x} is the string @code{"foo"}, the expressions @code{(eq x
826(format x))} and @code{(eq x (format "%s" x))} might both yield
827@code{t}.
824@end defun 828@end defun
825 829
826@defun format-message string &rest objects 830@defun format-message string &rest objects