From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Gregory Heytings Newsgroups: gmane.emacs.bugs Subject: bug#21695: 25.0.50; Change most occurrences of `setq' in Emacs manual to `customize-set-variable'? Really? Date: Sat, 18 Sep 2021 09:20:50 +0000 Message-ID: References: <97d3ff2c-9e72-4004-88a9-08130ac99a74@default> <87v93avtoe.fsf@gnus.org> <87r1dyvtav.fsf@gnus.org> <87mtolx6de.fsf@gnus.org> <87ilz9x5c8.fsf@gnus.org> <87y284rb1z.fsf@gnus.org> <0d48a23084a8b0435f37@heytings.org> <83h7eqf9wx.fsf@gnu.org> <0d48a230848de1d1b255@heytings.org> <83ee9uf82a.fsf@gnu.org> <0d48a23084cf7a569554@heytings.org> <83czpef6hj.fsf@gnu.org> <97113ce8ba560c9ac39f@heytings.org> <6b0f1c8e-9cfa-99b5-2862-d25e85cff3e5@gmx.at> <97113ce8bab1a4e2456d@heytings.org> Mime-Version: 1.0 Content-Type: text/plain; format=flowed; charset=us-ascii Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="14683"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 21695@debbugs.gnu.org, hmelman@gmail.com, larsi@gnus.org To: Richard Stallman Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Sep 18 11:21:24 2021 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 1mRWXD-0003al-MD for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 18 Sep 2021 11:21:23 +0200 Original-Received: from localhost ([::1]:60928 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mRWXC-0003QH-4v for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 18 Sep 2021 05:21:22 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:38988) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mRWWt-0003OM-17 for bug-gnu-emacs@gnu.org; Sat, 18 Sep 2021 05:21:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:50231) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mRWWs-0002oU-OT for bug-gnu-emacs@gnu.org; Sat, 18 Sep 2021 05:21:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mRWWs-0002ay-HK for bug-gnu-emacs@gnu.org; Sat, 18 Sep 2021 05:21:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Gregory Heytings Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 18 Sep 2021 09:21:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 21695 X-GNU-PR-Package: emacs Original-Received: via spool by 21695-submit@debbugs.gnu.org id=B21695.16319568579949 (code B ref 21695); Sat, 18 Sep 2021 09:21:02 +0000 Original-Received: (at 21695) by debbugs.gnu.org; 18 Sep 2021 09:20:57 +0000 Original-Received: from localhost ([127.0.0.1]:33544 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mRWWn-0002aO-3f for submit@debbugs.gnu.org; Sat, 18 Sep 2021 05:20:57 -0400 Original-Received: from heytings.org ([95.142.160.155]:36814) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mRWWh-0002a8-IS for 21695@debbugs.gnu.org; Sat, 18 Sep 2021 05:20:55 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=heytings.org; s=20210101; t=1631956850; bh=4L5/3Kwb9Jc1zNp0JAiJCaGPuy/TAu8eceVk83MZhVw=; h=Date:From:To:cc:Subject:In-Reply-To:Message-ID:References:From; b=MrBEpkfWpXvaW/Id8H/Eq6UljO3NEgeQDRfDTjmZOYqEbmjnJhqDjDMC7QAhEE29X Tat4wJTm4rGvc/AhPd73iLpthCgS400uT+9BebSFvmp2oVZXOUT+jZFMKTa7UtocYL VM9Dv6wuKPQguxXlFAaWbSkf0xAWk/z+iuZkyYWxJPcNuGEQ7Egvv8RxwDCp7Wx3we 1ZKiG10YgTRB6zvXtL3Kw3XC+jrIz+wE3JYdtx1PwRboKALRHQ1AQ2GEOEKbB1stk2 KZEJPh9xgbwv26ZscijeJnqa/3I2G+PV/4cp7f9OvfZruuO4xK81avPio16zDirB/a qVlNIj5uza8Cg== In-Reply-To: X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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:214610 Archived-At: > > everything else in this discussion seems to support the opposite > conclusion: setting one of these variables with setq in an init file, in > the usual simple case (you haven't loaded the definition yet), is > perfectly ok. > Understanding statements always requires some context. Using setq on a variable that hasn't been loaded is indeed okay, but that does not contradict what Martin said, because a variable that hasn't been loaded never has a :set form (even if its definition contains a :set form). In summary: 1. 'foo' does not have a :set form in its definition => it's okay to set it with setq, no warning is displayed 2. 'foo' has a :set form in its definition, but its definition hasn't been loaded => it's okay to set it with setq, no warning is displayed 3. 'foo' has a :set form in its definition, and its definition has been loaded => it's a bug to set it with setq, a warning is displayed There are a number of corner cases that are not covered by the above description, however: 1. if you eval-buffer your init file during an Emacs session, definitions have been loaded in the meantime, so you get warnings you didn't get when you started Emacs; are these legitimate warnings? 2. if you byte-compile your init file, setq's become set's, so the warnings you would see with your non-byte-compiled init files are not displayed anymore; should they be displayed? 3. in (some) files in which variables with a :set form are defined, setq is used to set them (which means that warnings would be displayed if they were eval-buffer'd or loaded without byte-compiling them); are these legitimate warnings? is it a bug to use setq in those files?