1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-01-03 18:41:25 -08:00
emacs/doc
Paul Eggert 3db388b0bf Speed up (format "%s" STRING) and the like
Although the Lisp manual said that ‘format’ returns a
newly-allocated string, this was not true for a few cases like
(format "%s" ""), and fixing the documentation to allow reuse of
arguments lets us improve performance in common cases like
(format "foo") and (format "%s" "foo") (Bug#28625).
* doc/lispref/strings.texi (Formatting Strings):
* etc/NEWS:
Say that the result of ‘format’ might not be newly allocated.
* src/callint.c (Fcall_interactively):
* src/dbusbind.c (XD_OBJECT_TO_STRING):
* src/editfns.c (Fmessage, Fmessage_box):
* src/xdisp.c (vadd_to_log, Ftrace_to_stderr):
Just use Fformat or Fformat_message, as that’s simpler and no
longer makes unnecessary copies.
* src/editfns.c (styled_format): Remove last argument, as it
is no longer needed: all callers now want it to behave as if it
were true.  All remaining callers changed.  Make this function
static again.  Simplify the function now that we no longer
need to worry about whether the optimization is allowed.
2017-10-04 14:45:08 -07:00
..
emacs Prefer HTTPS to HTTP for gnu.org 2017-10-01 19:59:01 -07:00
lispintro Merge from Gnulib 2017-10-01 18:31:10 -07:00
lispref Speed up (format "%s" STRING) and the like 2017-10-04 14:45:08 -07:00
man Prefer HTTPS to HTTP for gnu.org 2017-09-29 17:48:22 -07:00
misc Start rewriting Flymake manual 2017-10-03 14:20:30 +01:00