From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Dmitry Gutov Newsgroups: gmane.emacs.bugs Subject: bug#40671: [DOC] modify literal objects Date: Tue, 28 Apr 2020 22:33:50 +0300 Message-ID: <72399223-0ab5-dbe4-5027-d929450a4df0@yandex.ru> References: <93463227-33a8-85a0-fd19-8b29b75997f3@yandex.ru> <969b3497-0afd-d104-6792-d744d31548fa@cs.ucla.edu> <2935ec84-bdea-2e20-01b9-8ed08cc61c6c@yandex.ru> <669981e5-f601-5c18-1a8b-ee316ad001ec@cs.ucla.edu> <4b8b7e98-029e-58ac-59ff-6cd984b7eb85@yandex.ru> <530d3597-aaaa-f019-bafa-8229d13e7248@yandex.ru> <60b88f52-c50d-c57a-9ce5-495e6157d36e@cs.ucla.edu> <0721d8c1-4fe3-335c-7dbc-171487cb648a@yandex.ru> <6d1015da-0dc1-376c-f84b-5e3ee3149213@cs.ucla.edu> <286139d2-bbe1-2d5a-bec1-f781666376f1@yandex.ru> <10b89e6f-6fa6-f855-65b6-3361a74472d3@cs.ucla.edu> <8542efe2-c4a6-1da5-2513-7ffcaa6c4ec9@yandex.ru> <293d0eab-4617-08fe-aafa-d6841a750af0@cs.ucla.edu> <4085994e-f42d-b90f-9c86-ad42689bbff2@yandex.ru> <9cfc3b63-7df6-145a-8a78-e3320b6d3861@cs.ucla.edu> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="25796"; 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: Michael Heerdegen , Mattias =?UTF-8?Q?Engdeg=C3=A5rd?= , ke.vigouroux@laposte.net, 40671@debbugs.gnu.org, Richard Stallman To: Paul Eggert Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Apr 28 21:40:23 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 1jTW5f-0006ab-9f for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 28 Apr 2020 21:40:23 +0200 Original-Received: from localhost ([::1]:47462 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jTW5e-0004db-9n for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 28 Apr 2020 15:40:22 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:60692) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jTW43-0001Zg-Ad for bug-gnu-emacs@gnu.org; Tue, 28 Apr 2020 15:38:57 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.90_1) (envelope-from ) id 1jTW0U-00049U-8O for bug-gnu-emacs@gnu.org; Tue, 28 Apr 2020 15:38:43 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:58253) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jTW0T-00049O-S7 for bug-gnu-emacs@gnu.org; Tue, 28 Apr 2020 15:35:01 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jTW0T-0001xy-Oz for bug-gnu-emacs@gnu.org; Tue, 28 Apr 2020 15:35:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Dmitry Gutov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 28 Apr 2020 19:35: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.15881024417466 (code B ref 40671); Tue, 28 Apr 2020 19:35:01 +0000 Original-Received: (at 40671) by debbugs.gnu.org; 28 Apr 2020 19:34:01 +0000 Original-Received: from localhost ([127.0.0.1]:41566 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jTVzV-0001wJ-8N for submit@debbugs.gnu.org; Tue, 28 Apr 2020 15:34:01 -0400 Original-Received: from mail-wr1-f41.google.com ([209.85.221.41]:40182) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jTVzT-0001w4-Lo for 40671@debbugs.gnu.org; Tue, 28 Apr 2020 15:34:00 -0400 Original-Received: by mail-wr1-f41.google.com with SMTP id k13so26125900wrw.7 for <40671@debbugs.gnu.org>; Tue, 28 Apr 2020 12:33:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=ayQC7BXoFE0+Zm9b9/MEpsxGhKEXvHwZKca7NEPlppU=; b=jgHjye6yE33GosjOHtKoCR5k9CD3ULiccTl0qS3j9i7j1cro4dvBaxZaGeds1MJ9X3 kFgTGkM9F7V+79eZlCg5JIwWfZ9/LPfX56TYOMflExQH4r+QcBEDbggtUXFPNcU+qz7o 0zy1S2AazvMB0+8KFPznWQEh826sRmPTdNGCkUgnfpsLdG6m3CYlDeKY90pkPD8i1u88 nSXVqwj6ROv8iLNlPJVOQgc6f9pfpNAsmd3/dUHtEMode9CIpVTjJslsHqzxiGKr7iie y1uAXAvCiSEWsw1H737VGt4ow470inzPJhZ5oSbxgWAbXderz45ICivgH9HAKb2okUIV 7kFw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:subject:to:cc:references:from:message-id :date:user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=ayQC7BXoFE0+Zm9b9/MEpsxGhKEXvHwZKca7NEPlppU=; b=dTsUEC61N5JfEss7KCrkxzIxtkkExukt3X9OTVaAQNwyE3NhEuubSLn9D0zn3+1Xxf wLzNV0TqJ9cjLqn1uOZ3oU/AklWmxG3DH9QZoUoMGpSJtDJ9dogGwdtycodss/DOELQ3 Q149viPJQnm9i4PmgFWk7SxSmOHOTIwWmIx3eexYlw8qr0z2OE3vNamtYE69Md8APCGr XpkKLbrzzF8NRdcdb9jtgtn/34jOMmvpbqgTPqCpa6WK4s44RFrE7Gv6YbfWeLOC1spa XQ23iKpBQOKEI+3et+6AgepsnJsjcJe7q3fHWnep5cbpR2PxmrjaLxVfqugraRewwBvu JyiA== X-Gm-Message-State: AGi0PuY7Aw2cfS/FF5Bsg9Jie0F1Y5mq7YZg1UlRnAtfX4Z/JvRq5OW/ SJx96z7H2ySGdOg0L2hVzFY= X-Google-Smtp-Source: APiQypJBjfMmqSl/3FX+SDTuNUxgDhjnqDLBoB6n6vyArpWcA2yM1rJ8wDXTHutQcr223Vib4oRXKQ== X-Received: by 2002:a5d:4645:: with SMTP id j5mr33747501wrs.282.1588102433668; Tue, 28 Apr 2020 12:33:53 -0700 (PDT) Original-Received: from [192.168.0.2] ([66.205.73.129]) by smtp.googlemail.com with ESMTPSA id t16sm27336508wrb.8.2020.04.28.12.33.51 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 28 Apr 2020 12:33:52 -0700 (PDT) In-Reply-To: <9cfc3b63-7df6-145a-8a78-e3320b6d3861@cs.ucla.edu> 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:179245 Archived-At: On 28.04.2020 22:20, Paul Eggert wrote: > On 4/28/20 11:46 AM, Dmitry Gutov wrote: > >> That sounds like something we have to fix. > > Yes, absolutely, though we can't feasibly do that before the next release. Yeah, ok. >> That's not a constant, that's an eldritch abomination. > > I say "constant", you say "eldritch". :-) And then I explain why "constant" is bad, multiple times. With examples from other languages. >> Using semantics that might be "slightly familiar" >> only to grizzled C programmers is also bad. > > It's not just "slightly familiar" to grizzled C/C++/etc. programmers. It's a > concept that's pretty much part of their daily lives. You take the concept of "constant values", look it up in the C standard (where modifying a constant is "undefined behavior") and then make a conclusion that if modifying something is "undefined behavior", it must be called a constant. Outside of C standard, to boot. Emacs users are not C programmers. >> There is a particular kind of values called fizzleworp (see {String literals}, {Quote} and {Backquote}), which are dangerous to modify. > > Let's not go that route. It'd be overdocumenting internal details that are not > generally known. I don't know all the details, so I couldn't write all that > documentation without a lot of nontrivial investigation. And these details are > likely to change so users should not rely on them anyway. That's not what I was suggesting. I gave an example on using the words, not on which cases to enumerate. > Instead of going out into the wilderness and tagging and identifying each dragon > and its lair, the documentation should keep things simple and merely say "there > are dragons out in the wilderness; you shouldn't go there". This is much simpler > and easier to understand and maintain, and is safer overall. The map still has to circle the wilderness on the map somehow. >> Lisp form literals, and any members of such forms. I might be forgetting something, but this list is not too long, is it? > > Yes the list isn't *that* long, and it's in the documentation already - as long > as we are willing to put up with a conservative list (e.g., you shouldn't modify > anything in the list) rather than insisting on an exhaustive list (e.g., here's > what happens if you try to modify X, here's what happens if you try to modify Y, > etc.). Conservative list is fine, as long as we don't use the word "constant".