From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Paul Eggert Newsgroups: gmane.emacs.bugs Subject: bug#40671: [DOC] modify literal objects Date: Sun, 19 Apr 2020 14:02:42 -0700 Organization: UCLA Computer Science Department Message-ID: <527dc4b5-3176-38b5-f2c1-1483ffc814a1@cs.ucla.edu> References: <83tv1finob.fsf@gnu.org> <1E9E4C19-37C2-4E24-91B7-8101F9CFBF35@acm.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="54246"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.7.0 Cc: ke.vigouroux@laposte.net, 40671@debbugs.gnu.org To: Mattias =?UTF-8?Q?Engdeg=C3=A5rd?= , Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun Apr 19 23:03:14 2020 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jQH5t-000E1Y-7Z for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 19 Apr 2020 23:03:13 +0200 Original-Received: from localhost ([::1]:47678 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jQH5s-0008BC-8y for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 19 Apr 2020 17:03:12 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:45440 helo=eggs1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jQH5i-0008Ah-Nx for bug-gnu-emacs@gnu.org; Sun, 19 Apr 2020 17:03:03 -0400 Original-Received: from Debian-exim by eggs1p.gnu.org with spam-scanned (Exim 4.90_1) (envelope-from ) id 1jQH5i-0001vD-AI for bug-gnu-emacs@gnu.org; Sun, 19 Apr 2020 17:03:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:34556) by eggs1p.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jQH5h-0001tV-TZ for bug-gnu-emacs@gnu.org; Sun, 19 Apr 2020 17:03:01 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jQH5h-0000V5-PI for bug-gnu-emacs@gnu.org; Sun, 19 Apr 2020 17:03:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Paul Eggert Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 19 Apr 2020 21:03:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 40671 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 40671-submit@debbugs.gnu.org id=B40671.15873301721909 (code B ref 40671); Sun, 19 Apr 2020 21:03:01 +0000 Original-Received: (at 40671) by debbugs.gnu.org; 19 Apr 2020 21:02:52 +0000 Original-Received: from localhost ([127.0.0.1]:46102 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jQH5Y-0000Ui-5X for submit@debbugs.gnu.org; Sun, 19 Apr 2020 17:02:52 -0400 Original-Received: from zimbra.cs.ucla.edu ([131.179.128.68]:34466) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jQH5W-0000UV-9K for 40671@debbugs.gnu.org; Sun, 19 Apr 2020 17:02:50 -0400 Original-Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id 3AC0E160065; Sun, 19 Apr 2020 14:02:44 -0700 (PDT) Original-Received: from zimbra.cs.ucla.edu ([127.0.0.1]) by localhost (zimbra.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10032) with ESMTP id koMqF3tLf7nu; Sun, 19 Apr 2020 14:02:42 -0700 (PDT) Original-Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id E2FFE160094; Sun, 19 Apr 2020 14:02:42 -0700 (PDT) X-Virus-Scanned: amavisd-new at zimbra.cs.ucla.edu Original-Received: from zimbra.cs.ucla.edu ([127.0.0.1]) by localhost (zimbra.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id v7vEA_e79U5D; Sun, 19 Apr 2020 14:02:42 -0700 (PDT) Original-Received: from [192.168.1.9] (cpe-23-242-74-103.socal.res.rr.com [23.242.74.103]) by zimbra.cs.ucla.edu (Postfix) with ESMTPSA id B415816008E; Sun, 19 Apr 2020 14:02:42 -0700 (PDT) In-Reply-To: <1E9E4C19-37C2-4E24-91B7-8101F9CFBF35@acm.org> Content-Language: en-US X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-Received-From: 209.51.188.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:178672 Archived-At: On 4/19/20 9:59 AM, Mattias Engdeg=C3=A5rd wrote: > What about we add a separate section about literals of all types, why t= hey should be treated as immutable even though mutation currently isn't d= etected or disallowed at runtime, and recommended ways of coping with it = (constructor functions, copy-sequence)? It would serve as a point of refe= rence for all sections describing destructive operations. In my recent patches to the emacs-27 branch I added a section "Constants = and=20 Mutability" that discusses many of these issues. It's a fundamental topic= so I=20 put the new section into doc/lispref/objects.texi, and cross-referenced i= t from=20 the destructive-operation sections. I didn't think of recommending ways of coping with it, and that's a good=20 suggestion. I'm not sure that the coping-mechanism discussion belongs in=20 objects.texi, though, as it's pragmatic rather than fundamental. > There is also a need for some cautionary text in the backquote section= . Yes, my recent patches added a brief note there. > I'd volunteer to write it all but won't do the work just to have it sho= t down on general principles. I know the feeling.