unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#42296: 27.0.91; Correct manual entry for 'concat' w.r.t. allocation [PATCH]
@ 2020-07-09 15:54 Mattias Engdegård
  2020-07-09 17:31 ` Eli Zaretskii
  0 siblings, 1 reply; 18+ messages in thread
From: Mattias Engdegård @ 2020-07-09 15:54 UTC (permalink / raw)
  To: 42296

[-- Attachment #1: Type: text/plain, Size: 143 bytes --]

'concat' hasn't guaranteed the allocation of a new string since 1997 at least (79d137ffe7d). Remove claims to the contrary from the manual.


[-- Attachment #2: 0001-Correct-concat-manual-entry.patch --]
[-- Type: application/octet-stream, Size: 1658 bytes --]

From 3c6d4f9cefc7571df26e390b94f1c39da08a78e1 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Mattias=20Engdeg=C3=A5rd?= <mattiase@acm.org>
Date: Thu, 9 Jul 2020 17:32:13 +0200
Subject: [PATCH] Correct 'concat' manual entry

* doc/lispref/strings.texi (Creating Strings): 'concat' does not
necessarily return a newly allocated string.  This has been the case
at least since 1997 (Emacs 20.3).
---
 doc/lispref/strings.texi | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/doc/lispref/strings.texi b/doc/lispref/strings.texi
index 2ef88b9025..0aab326dc7 100644
--- a/doc/lispref/strings.texi
+++ b/doc/lispref/strings.texi
@@ -248,7 +248,7 @@ Creating Strings
 @defun concat &rest sequences
 @cindex copying strings
 @cindex concatenating strings
-This function returns a new string consisting of the characters in the
+This function returns a string consisting of the characters in the
 arguments passed to it (along with their text properties, if any).  The
 arguments may be strings, lists of numbers, or vectors of numbers; they
 are not themselves changed.  If @code{concat} receives no arguments, it
@@ -269,10 +269,6 @@ Creating Strings
 @end example
 
 @noindent
-This function always constructs a new string that is not @code{eq} to
-any existing string, except when the result is the empty string (to
-save space, Emacs makes only one empty multibyte string).
-
 For information about other concatenation functions, see the
 description of @code{mapconcat} in @ref{Mapping Functions},
 @code{vconcat} in @ref{Vector Functions}, and @code{append} in @ref{Building
-- 
2.21.1 (Apple Git-122.3)


^ permalink raw reply related	[flat|nested] 18+ messages in thread

end of thread, other threads:[~2020-07-12  3:03 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-07-09 15:54 bug#42296: 27.0.91; Correct manual entry for 'concat' w.r.t. allocation [PATCH] Mattias Engdegård
2020-07-09 17:31 ` Eli Zaretskii
2020-07-09 17:56   ` Mattias Engdegård
2020-07-09 18:51     ` Eli Zaretskii
2020-07-09 19:17       ` Mattias Engdegård
2020-07-09 19:24         ` Eli Zaretskii
2020-07-10 17:04           ` Mattias Engdegård
2020-07-10 18:08             ` Eli Zaretskii
2020-07-11 11:15               ` Mattias Engdegård
2020-07-11 11:52                 ` Eli Zaretskii
2020-07-11 12:51                   ` Mattias Engdegård
2020-07-11 13:07                     ` Eli Zaretskii
2020-07-11 13:16                       ` Mattias Engdegård
2020-07-11 13:37                         ` Eli Zaretskii
2020-07-11 13:47                           ` Mattias Engdegård
2020-07-11 16:17                       ` Drew Adams
2020-07-12  3:03                       ` Richard Stallman
2020-07-09 19:20       ` Eli Zaretskii

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).