From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Pip Cet Newsgroups: gmane.emacs.devel Subject: Re: master f51f963: Fix some side-effecting uses of make-text-button Date: Fri, 05 Jun 2020 14:31:43 +0000 Message-ID: <871rmt1t4g.fsf@gmail.com> References: <20200604223056.17078.81265@vcs0.savannah.gnu.org> <20200604223058.1850020A26@vcs0.savannah.gnu.org> <87eeqtiy4x.fsf@tcd.ie> <87img51y04.fsf@gmail.com> <87tuzpmxii.fsf@tcd.ie> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="83218"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: Stefan Monnier , emacs-devel@gnu.org To: "Basil L. Contovounesios" Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Fri Jun 05 16:33:03 2020 Return-path: Envelope-to: ged-emacs-devel@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 1jhDP4-000LWp-CQ for ged-emacs-devel@m.gmane-mx.org; Fri, 05 Jun 2020 16:33:02 +0200 Original-Received: from localhost ([::1]:57584 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jhDP3-0004h2-Cq for ged-emacs-devel@m.gmane-mx.org; Fri, 05 Jun 2020 10:33:01 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:47976) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jhDO4-000443-En for emacs-devel@gnu.org; Fri, 05 Jun 2020 10:32:01 -0400 Original-Received: from mail-wm1-x32f.google.com ([2a00:1450:4864:20::32f]:34674) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jhDNv-0002In-2J for emacs-devel@gnu.org; Fri, 05 Jun 2020 10:32:00 -0400 Original-Received: by mail-wm1-x32f.google.com with SMTP id u26so9226024wmn.1 for ; Fri, 05 Jun 2020 07:31:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:in-reply-to:references:user-agent:date :message-id:mime-version; bh=hzI9E7t2Km3HQwQNmot7ZoN0ZkYXoPmdeDZKw1XVu08=; b=HsjPR0F37PESDrQgIlFvFzktA5xwKV3JIrEtawJr3f1l6+ceRPqxwubENR8Fu6s38B dNOqJb/I7lQ7FxFN1JLdaR09zqF8e+3g+DFw6UmdYhQuBIyCbmayyVbVYcH16vstraYi sv54pNl0Ij8+bAcEWIzfThg78DXfQqQRVFTBbiE6HsGGelAJTnfvHXk80IV4JMmsS6BP ACJwCujg7Gb9HupagAty7Q2Js6S0Hmg3QeIYpl3OeFrN/DB6JgdZYUJFymHNexeKDspN 76vkOZHwvrDucym+y3ZD3LhoEWj0gZJ/ywShYWodOjJIzsxx8w+RxWEEF3QR4qXU+OFS mBEQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:in-reply-to:references :user-agent:date:message-id:mime-version; bh=hzI9E7t2Km3HQwQNmot7ZoN0ZkYXoPmdeDZKw1XVu08=; b=UTtwwPHaPByWVk7hKBPXOHdFD5Qg7sdQ4qxuV0yXCwToP8jpwQD8PH9rZaeqsi05Sj 9uUaG+NDmfhAQmIWHQ/N9CSJseDFfyLq2wL0sN8QgUQgSZnNf1L9BFAqkZoQUu7e8+0I ZDL9n79fUu/PiE9AX/S8xnhZ7j/wjbUSvREA+Ml3K/b3OUJTotWSyJttnaGF/RUWOUCR zJfDTEzepEiDppGhhOB6qcyoCGx51Z8soxIz5hd1YVST4mP+d9u8UVsKwsVM+bdSYCOI mebdfE1gTAvjVxBjziWEOKhkVh9mAugNZWk7DkcrmYfxmzXdQoTqg0sZw4bImVijJ8tl +A0A== X-Gm-Message-State: AOAM5328OTrDxjRoAqlBJcJ6Jg9lyVKzP7JIA23lDIGfkbNhLaIfXrdr WfiImTJolPSCD6+A680UMrP6VNNTbtc= X-Google-Smtp-Source: ABdhPJxb1mK1ehrHx12HajsyOjjr/T4sHxEFbLgNhpZ9nQpE7sTznwpUmpB4oMGEndHefmbGpNqP2A== X-Received: by 2002:a1c:c203:: with SMTP id s3mr2911205wmf.174.1591367509095; Fri, 05 Jun 2020 07:31:49 -0700 (PDT) Original-Received: from chametz (tor-exit-13.zbau.f3netze.de. [185.220.100.240]) by smtp.gmail.com with ESMTPSA id d13sm11046086wmb.39.2020.06.05.07.31.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 05 Jun 2020 07:31:47 -0700 (PDT) In-Reply-To: <87tuzpmxii.fsf@tcd.ie> (Basil L. Contovounesios's message of "Fri, 05 Jun 2020 14:51:17 +0100") Received-SPF: pass client-ip=2a00:1450:4864:20::32f; envelope-from=pipcet@gmail.com; helo=mail-wm1-x32f.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:251902 Archived-At: "Basil L. Contovounesios" writes: > Pip Cet writes: > > [...] > >> It would not be a quick bug fix for code that uses (propertize "string" >> 'a 'b). > > propertize returns a copy of its argument, so it's not problematic in > this context. Thanks for pointing that out. I hope it was still clear what I meant. >> In particular, I'm not convinced code like that is buggy at all. It's >> true that it will fail under certain conditions (the string constant is >> used again in the same function, the function is byte compiled, that >> sort of thing), and it's true there are better ways of doing that, but >> is that reason enough to off-handedly ban all such code? > > [...] > > My only concern with destructively modifying string literals as in the > (make-text-button "here" ...) example is that it can "pollute" that > string literal for all of its users, which is both "rude" and > unnecessary in this case. I simply find it cleaner, less intrusive, and > less surprising to modify only one's own copy of a string in such a > trivial case. I'm not personally concerned with crashes, theoretical > purity or mutability, or anything like that; for that I defer to you, > Paul, and other experts. I'd like to apologise. I made several mistakes in that email (including using the word "off-handedly" when a less offensive term would have done). Most importantly, I think, I was commenting on a change that, as you correctly point out, made the code cleaner and less surprising, as though it were a whole-hearted endorsement of breaking any existing code that is more surprising or less clean. I see now that you said no such thing.