From unknown Tue Jun 24 05:12:13 2025 X-Loop: help-debbugs@gnu.org Subject: bug#27348: 24.5; [PATCH] let defvars benefit from defcustom keywords and persistence Resent-From: Drew Adams Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 12 Jun 2017 21:35:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 27348 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch To: 27348@debbugs.gnu.org X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.14973032987664 (code B ref -1); Mon, 12 Jun 2017 21:35:02 +0000 Received: (at submit) by debbugs.gnu.org; 12 Jun 2017 21:34:58 +0000 Received: from localhost ([127.0.0.1]:44115 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dKWzC-0001zX-7N for submit@debbugs.gnu.org; Mon, 12 Jun 2017 17:34:58 -0400 Received: from eggs.gnu.org ([208.118.235.92]:36048) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dKWzA-0001zF-TB for submit@debbugs.gnu.org; Mon, 12 Jun 2017 17:34:57 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dKWz4-0003cG-AH for submit@debbugs.gnu.org; Mon, 12 Jun 2017 17:34:51 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50 autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:51427) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1dKWz4-0003c8-6d for submit@debbugs.gnu.org; Mon, 12 Jun 2017 17:34:50 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:55252) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dKWz2-0006uq-NQ for bug-gnu-emacs@gnu.org; Mon, 12 Jun 2017 17:34:50 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dKWyz-0003bL-JC for bug-gnu-emacs@gnu.org; Mon, 12 Jun 2017 17:34:48 -0400 Received: from aserp1040.oracle.com ([141.146.126.69]:51285) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1dKWyz-0003ab-5O for bug-gnu-emacs@gnu.org; Mon, 12 Jun 2017 17:34:45 -0400 Received: from userv0022.oracle.com (userv0022.oracle.com [156.151.31.74]) by aserp1040.oracle.com (Sentrion-MTA-4.3.2/Sentrion-MTA-4.3.2) with ESMTP id v5CLYf2r022046 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK) for ; Mon, 12 Jun 2017 21:34:41 GMT Received: from aserv0121.oracle.com (aserv0121.oracle.com [141.146.126.235]) by userv0022.oracle.com (8.14.4/8.14.4) with ESMTP id v5CLYeGT030439 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Mon, 12 Jun 2017 21:34:41 GMT Received: from abhmp0009.oracle.com (abhmp0009.oracle.com [141.146.116.15]) by aserv0121.oracle.com (8.13.8/8.13.8) with ESMTP id v5CLYbTj015995 for ; Mon, 12 Jun 2017 21:34:39 GMT MIME-Version: 1.0 Message-ID: <85d6df89-9c08-4927-9b10-93a0b43808a7@default> Date: Mon, 12 Jun 2017 14:34:35 -0700 (PDT) From: Drew Adams X-Priority: 3 X-Mailer: Oracle Beehive Extensions for Outlook 2.0.1.9.1 (1003210) [OL 12.0.6767.5000 (x86)] Content-Type: multipart/mixed; boundary="__149730327705166159abhmp0009.oracle.com" X-Source-IP: userv0022.oracle.com [156.151.31.74] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic] [fuzzy] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -4.0 (----) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -4.0 (----) --__149730327705166159abhmp0009.oracle.com Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable This is an enhancement request, with a patch. [NOTE: I suggested this enhancement to emacs-devel in 2009. There was exactly one reply, with only this text: "YAGNI". http://lists.gnu.org/archive/html/emacs-devel/2009-10/msg00668.html http://lists.gnu.org/archive/html/emacs-devel/2015-10/msg01481.html] The ability to type-check, provide :set and :initialize trigger functions, automatically :require libraries, add links to doc, associate with one or more :groups, etc. - these are useful things to be able to do with at least some defvars, not just with defcustoms. Similarly, the ability to persist non-option variables in a user's custom file can be useful. In sum, this enhancement makes it possible to uncouple interactive customization from the other features that `custom.el' offers, in particular, type-checking and persistence, and to provide the latter for non-option variables. Patch description: 1. New `defcustom' keyword `:not-custom-var'. If non-nil, the variable does not satisfy `custom-variable-p'. This means that users cannot customize it interactively, and it is not available for other interactive use (completion, `set-variable', inclusion in `apropos-user-option' output, etc.). Anyone and any code can still use `custom*' and other functions that do not check `custom-variable-p', to treat such a variable as a defcustom. Similarly, users can still use `M-:', `C-x C-e' etc. to customize it. See also #5, below. 2. New `defcustom' keyword `:not-custom-var'. It causes property `not-custom-var' to be put on the variable symbol. This property is what governs the behavior of `custom-variable-p'. 3. New macro `defvarc'. It just invokes `defcustom', passing non-nil `:not-custom-var'. The idea is to have a macro with a name similar to `defvar'. Using it can make the non-customizable nature more apparent than using `defcustom' with explicit `:not-custom-var'. [Another possibility would be to directly modify `defvar', so that it optionally accepts `defcustom' keywords etc., but maybe that would not be acceptable immediately. (For one thing, the cases of no initial value and no doc, `(defvar foo)' and `(defvar foo 4)', would still need to be supported.)] 4. `custom-variable-p' respects not only whether the variable has a non-nil `not-custom-var' property but also whether (new) global variable `custom-vars-all-customizable' is non-nil. If either is true then the variable is not customizable (the predicate returns nil). 5. New macro `with-user-vars'. It temporarily allows a set of variables to be customizable. It takes as its first argument either a list of variables or the symbol `all', meaning all variables. For `all', it just binds `custom-vars-all-customizable' to `t'. For a list of variables, it sets property `not-custom-var' to `t' for each one. (The original property values are restored when done.) I'm open as to how such a feature gets implemented. That includes names of things (`defvarc', for example) and whether or not to include this or that part. And I'm open to changes to the particular code in the patch. There might be better ways to realize such a feature - what I came up with is a pretty simple, naive approach. FWIW: I haven't understood why apparently no one else has thought this kind of thing could improve Emacs. I've long thought that the power of defcustom keywords and persistence should be freed from their coupling with interactive customizing. That combination is great, of course, but it should not be obligatory - I see no reason why a non-user variable should not take advantage of defcustom features. In GNU Emacs 24.5.1 (i686-pc-mingw32) of 2015-04-11 on LEG570 Windowing system distributor `Microsoft Corp.', version 6.1.7601 Configured using: `configure --prefix=3D/c/usr --host=3Di686-pc-mingw32' --__149730327705166159abhmp0009.oracle.com Content-Type: application/octet-stream; name="custom-2017-06-12.patch" Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename="custom-2017-06-12.patch" ZGlmZiAtdSBjdXN0b20tMjAxNy0wNi0xMi5lbCBjdXN0b20tcGF0Y2hlZC5lbAotLS0gY3VzdG9t LTIwMTctMDYtMTIuZWwJMjAxNy0wNi0xMiAxMDo0NTowNy4xMTY4NjgzMDAgLTA3MDAKKysrIGN1 c3RvbS1wYXRjaGVkLmVsCTIwMTctMDYtMTIgMTM6NTQ6MDYuMDI0NTY3MzAwIC0wNzAwCkBAIC00 Nyw2ICs0NywxMCBAQAogKGRlZnZhciBjdXN0b20tY3VycmVudC1ncm91cC1hbGlzdCBuaWwKICAg IkFsaXN0IG9mIChGSUxFIC4gR1JPVVApIGluZGljYXRpbmcgdGhlIGN1cnJlbnQgZ3JvdXAgdG8g dXNlIGZ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zLnAiKSkpCisgICAgYChsZXQgKCgsc3ltYnMg ICcsc3ltYm9scykpCisgICAgICAgKGlmIChlcSAnYWxsICxzeW1icykKKyAgICAgICAgICAgKGxl dCAoKGN1c3RvbS12YXJzLWFsbC1jdXN0b21pemFibGUgIHQpKSAsQGJvZHkpCisgICAgICAgICAo bGV0ICgoLGJpbmRzICAobWFwY2FyIChsYW1iZGEgKCxzeW1iKSAoY29ucyAsc3ltYiAoZ2V0ICxz eW1iICdub3QtY3VzdG9tLXZhcikpKQorICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAs c3ltYnMpKSkKKyAgICAgICAgICAgKHVud2luZC1wcm90ZWN0CisgICAgICAgICAgICAgICAgKHBy b2duIChkb2xpc3QgKCxzeW1iICAsc3ltYnMpIChwdXQgLHN5bWIgJ25vdC1jdXN0b20tdmFyIG5p bCkpCisgICAgICAgICAgICAgICAgICAgICAgICxAYm9keSkKKyAgICAgICAgICAgICAoZG9saXN0 ICgscy5wICAsYmluZHMpCisgICAgICAgICAgICAgICAocHV0IChjYXIgLHMucCkgJ25vdC1jdXN0 b20tdmFyIChjZHIgLHMucCkpKSkpKSkpKQorCiA7OzsgVGhlIGBkZWZmYWNlJyBNYWNyby4KIAog KGRlZm1hY3JvIGRlZmZhY2UgKGZhY2Ugc3BlYyBkb2MgJnJlc3QgYXJncykKQEAgLTUzOCw2ICs1 NzMsOCBAQAogCSAocHV0IHN5bWJvbCAnY3VzdG9tLXRhZyB2YWx1ZSkpCiAJKChlcSBrZXl3b3Jk IDpzZXQtYWZ0ZXIpCiAJIChjdXN0b20tYWRkLWRlcGVuZGVuY2llcyBzeW1ib2wgdmFsdWUpKQor ICAgICAgICAoKGVxIGtleXdvcmQgOm5vdC1jdXN0b20tdmFyKQorICAgICAgICAgKHB1dCBzeW1i b2wgJ25vdC1jdXN0b20tdmFyIHZhbHVlKSkKIAkodAogCSAoZXJyb3IgIlVua25vd24ga2V5d29y ZCAlcyIga2V5d29yZCkpKSkKIApAQCA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c3RhbmRhcmQtdmFsdWUpCisg ICAgICAgICAgIChnZXQgdmFyaWFibGUgJ2N1c3RvbS1hdXRvbG9hZCkpKSkKIAogKGRlZmluZS1v YnNvbGV0ZS1mdW5jdGlvbi1hbGlhcyAndXNlci12YXJpYWJsZS1wICdjdXN0b20tdmFyaWFibGUt cCAiMjQuMyIpCiAK --__149730327705166159abhmp0009.oracle.com-- From unknown Tue Jun 24 05:12:13 2025 X-Loop: help-debbugs@gnu.org Subject: bug#27348: 24.5; [PATCH] let defvars benefit from defcustom keywords and persistence Resent-From: Lars Ingebrigtsen Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 24 Jun 2019 16:36:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 27348 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Drew Adams Cc: 27348@debbugs.gnu.org Received: via spool by 27348-submit@debbugs.gnu.org id=B27348.15613941122388 (code B ref 27348); Mon, 24 Jun 2019 16:36:01 +0000 Received: (at 27348) by debbugs.gnu.org; 24 Jun 2019 16:35:12 +0000 Received: from localhost ([127.0.0.1]:57796 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hfRvz-0000cS-JU for submit@debbugs.gnu.org; Mon, 24 Jun 2019 12:35:11 -0400 Received: from quimby.gnus.org ([80.91.231.51]:33186) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hfRvy-0000cG-59 for 27348@debbugs.gnu.org; Mon, 24 Jun 2019 12:35:10 -0400 Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=stories) by quimby.gnus.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1hfRvt-0005Kx-OP; Mon, 24 Jun 2019 18:35:08 +0200 From: Lars Ingebrigtsen References: <85d6df89-9c08-4927-9b10-93a0b43808a7@default> Date: Mon, 24 Jun 2019 18:35:05 +0200 In-Reply-To: <85d6df89-9c08-4927-9b10-93a0b43808a7@default> (Drew Adams's message of "Mon, 12 Jun 2017 14:34:35 -0700 (PDT)") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Drew Adams writes: > The ability to type-check, provide :set and :initialize trigger > functions, automatically :require libraries, add links to doc, associate > with one or more :groups, etc. - these are useful things [...] Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Drew Adams writes: > The ability to type-check, provide :set and :initialize trigger > functions, automatically :require libraries, add links to doc, associate > with one or more :groups, etc. - these are useful things to be able to > do with at least some defvars, not just with defcustoms. Similarly, the > ability to persist non-option variables in a user's custom file can be > useful. I think this is an interesting idea, but perhaps a bug report isn't the right venue for it? Did you take this up on emacs-devel? (And here's my two pennies on the subject after considering it for about 60 seconds: I'm not sure this sort of extension of the type system is that useful... If we want a more expressive type system in Emacs, this is the wrong place to start.) -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From unknown Tue Jun 24 05:12:13 2025 X-Loop: help-debbugs@gnu.org Subject: bug#27348: 24.5; [PATCH] let defvars benefit from defcustom keywords and persistence Resent-From: Drew Adams Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 24 Jun 2019 18:05:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 27348 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Lars Ingebrigtsen Cc: 27348@debbugs.gnu.org Received: via spool by 27348-submit@debbugs.gnu.org id=B27348.156139949327875 (code B ref 27348); Mon, 24 Jun 2019 18:05:01 +0000 Received: (at 27348) by debbugs.gnu.org; 24 Jun 2019 18:04:53 +0000 Received: from localhost ([127.0.0.1]:57930 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hfTKn-0007FX-Al for submit@debbugs.gnu.org; Mon, 24 Jun 2019 14:04:53 -0400 Received: from userp2130.oracle.com ([156.151.31.86]:42098) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hfTKl-0007FH-DR for 27348@debbugs.gnu.org; Mon, 24 Jun 2019 14:04:52 -0400 Received: from pps.filterd (userp2130.oracle.com [127.0.0.1]) by userp2130.oracle.com (8.16.0.27/8.16.0.27) with SMTP id x5OHwduM003840; Mon, 24 Jun 2019 18:04:44 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=mime-version : message-id : date : from : sender : to : cc : subject : references : in-reply-to : content-type : content-transfer-encoding; s=corp-2018-07-02; bh=SUHl76k8gkxlCbynRssMSbkZjDzrJlPkwvKtN/fahrQ=; b=dYZmRHgeZN/AQqWlwm39x83zLYBaQmzP/9UeQv6ubU21iQ2wBh/emwmN+IYx6kVMgwYU zJ4Zavddq2Eb4xeWZboO8PcN4p8aWlBiaaf1ibpRxDSYPSTi5eEsA5OkmU2/Tbv5WJVQ X5I/jFqUn0blZ50ZKNYRYRTtsVCpEamkXF4kUfqybnFtmaWgjCuSjtU4nc71i2MIDbXJ ydeekoor27nlihQruVVVujNgj/bjEsWtOrz/b5YaQfaIccCYAlqAsaVVB9Ph6fgGHnr7 sey2aezoclWMzqCqZPgqSAP4ZatWQ6QosZcCB4jBz2N2g8OZzwAMWkV9K4tN16tFiYQK ZA== Received: from userp3030.oracle.com (userp3030.oracle.com [156.151.31.80]) by userp2130.oracle.com with ESMTP id 2t9brsywr8-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 24 Jun 2019 18:04:44 +0000 Received: from pps.filterd (userp3030.oracle.com [127.0.0.1]) by userp3030.oracle.com (8.16.0.27/8.16.0.27) with SMTP id x5OI3ov4136737; Mon, 24 Jun 2019 18:04:44 GMT Received: from aserv0121.oracle.com (aserv0121.oracle.com [141.146.126.235]) by userp3030.oracle.com with ESMTP id 2t99f3dpdr-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 24 Jun 2019 18:04:44 +0000 Received: from abhmp0006.oracle.com (abhmp0006.oracle.com [141.146.116.12]) by aserv0121.oracle.com (8.14.4/8.13.8) with ESMTP id x5OI4fP1013677; Mon, 24 Jun 2019 18:04:41 GMT MIME-Version: 1.0 Message-ID: <30a84ebd-5903-4e74-8083-48b2f6cddabd@default> Date: Mon, 24 Jun 2019 11:04:40 -0700 (PDT) From: Drew Adams References: <85d6df89-9c08-4927-9b10-93a0b43808a7@default> In-Reply-To: X-Priority: 3 X-Mailer: Oracle Beehive Extensions for Outlook 2.0.1.9.1 (1003210) [OL 16.0.4861.0 (x86)] Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9298 signatures=668687 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=0 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 mlxscore=0 mlxlogscore=928 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1906240143 X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9298 signatures=668687 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 priorityscore=1501 malwarescore=0 suspectscore=0 phishscore=0 bulkscore=0 spamscore=0 clxscore=1011 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=979 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1906240143 X-Spam-Score: -2.3 (--) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > > The ability to type-check, provide :set and :initialize trigger > > functions, automatically :require libraries, add links to doc, associat= e > > with one or more :groups, etc. - these are useful things to be able to > > do with at least some defvars, not just with defcustoms. Similarly, th= e > > ability to persist non-option variables in a user's custom file can be > > useful. >=20 > I think this is an interesting idea, but perhaps a bug report isn't the > right venue for it? Did you take this up on emacs-devel? >=20 > (And here's my two pennies on the subject after considering it for about > 60 seconds: I'm not sure this sort of extension of the type system is > that useful... If we want a more expressive type system in Emacs, this > is the wrong place to start.) It's an enhancement request. This is the place for that. And yes, I brought it up on emacs-devel some time ago. (Probably was told to file an enhancement request. ;-)) This is not an "extension of the [Lisp] type system". It simply gives Lisp programmers the ability to use some `defcustom' features for variables that users do not change using Customize. It separates such features, which are useful for programmers, from the use of Customize. From debbugs-submit-bounces@debbugs.gnu.org Mon May 04 07:54:05 2020 Received: (at control) by debbugs.gnu.org; 4 May 2020 11:54:05 +0000 Received: from localhost ([127.0.0.1]:59177 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jVZfg-0000wS-QI for submit@debbugs.gnu.org; Mon, 04 May 2020 07:54:05 -0400 Received: from ted.gofardesign.uk ([67.225.143.91]:47046) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jVZfe-0000vt-JM for control@debbugs.gnu.org; Mon, 04 May 2020 07:54:03 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=marxist.se; s=default; h=Subject:From:To:Date:Sender:Reply-To:Message-ID:Cc:MIME-Version :Content-Type:Content-Transfer-Encoding:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: In-Reply-To:References:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=zSUDnKi+0nMQkRhjZtPdQF181DyKR52BHZoDY2Wb+rY=; b=PHpRBys5Cwn3YgssqacTtU229u NTuLAqApsfiAYFxY4emVUarCvcFlaubF+U8PjRu/OpMTJt+G+Sef8RZTHxPH4cY70PTkjNUOdc/GE j27GHLMeYgrUcsPIdzgKGNSBsL3YH/U1/AJpxo24csmsVlJVCJ8I815jb57rbZjNgJQpMTEAFFgB9 Jbu4/7+dVK/rSStF/HKeHdyT2OXTMIWeigQq44gdGmuhOPI9tsQ0/quxv71SmoEN1ssZmfd9T1Evp K7tzAwJxR1w2dsk44XyNDsLaVYBDJHVBqheV6qofR0yy+F/MdhFSq7eoU0GEOvsQZOsqTAIEFBMaJ vJmBI0Ng==; Received: from h-4-70-69.a785.priv.bahnhof.se ([155.4.70.69]:33864 helo=localhost) by ted.gofardesign.uk with esmtpsa (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.93) (envelope-from ) id 1jVZfX-001dmQ-TX for control@debbugs.gnu.org; Mon, 04 May 2020 07:53:56 -0400 Date: Mon, 04 May 2020 13:53:53 +0200 To: control@debbugs.gnu.org From: Stefan Kangas Subject: control message for bug #27348 X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - ted.gofardesign.uk X-AntiAbuse: Original Domain - debbugs.gnu.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - marxist.se X-Get-Message-Sender-Via: ted.gofardesign.uk: authenticated_id: stefan@marxist.se X-Authenticated-Sender: ted.gofardesign.uk: stefan@marxist.se X-Source: X-Source-Args: X-Source-Dir: X-Spam-Score: 0.1 (/) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" Message-Id: X-Spam-Score: -1.0 (-) tags 27348 + patch quit From unknown Tue Jun 24 05:12:13 2025 X-Loop: help-debbugs@gnu.org Subject: bug#27348: 24.5; [PATCH] let defvars benefit from defcustom keywords and persistence Resent-From: Lars Ingebrigtsen Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 10 Aug 2020 15:05:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 27348 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch To: Drew Adams Cc: 27348@debbugs.gnu.org Received: via spool by 27348-submit@debbugs.gnu.org id=B27348.159707185812089 (code B ref 27348); Mon, 10 Aug 2020 15:05:02 +0000 Received: (at 27348) by debbugs.gnu.org; 10 Aug 2020 15:04:18 +0000 Received: from localhost ([127.0.0.1]:37177 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1k59LW-00038t-2Z for submit@debbugs.gnu.org; Mon, 10 Aug 2020 11:04:18 -0400 Received: from quimby.gnus.org ([95.216.78.240]:49262) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1k59LU-00038e-Pk for 27348@debbugs.gnu.org; Mon, 10 Aug 2020 11:04:17 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=reHv3uscyX3AlaW7KHuZHCcB52n3s6fAgt3l8xUvJ1Y=; b=n5DxyJOVMjuFGfNKbcrvwrVx3r CUzUVVwAzKVfZ9wONRPhW7G2R/xCJpVb5koLqGkjGTOlmLoPOX9bAbHTLV3kyJwb5954ygbtpN9Oa qhnBo7W32Qg4RVsiXxk79m9EThnELyuE6snLwVayVjV+QRh39P50qyhGhcAB17lyfk3U=; Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=xo) by quimby with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1k59LF-0006BN-U4; Mon, 10 Aug 2020 17:04:10 +0200 From: Lars Ingebrigtsen References: <85d6df89-9c08-4927-9b10-93a0b43808a7@default> Date: Mon, 10 Aug 2020 17:04:00 +0200 In-Reply-To: <85d6df89-9c08-4927-9b10-93a0b43808a7@default> (Drew Adams's message of "Mon, 12 Jun 2017 14:34:35 -0700 (PDT)") Message-ID: <87k0y6zgnz.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Drew Adams writes: > This is an enhancement request, with a patch. > > [NOTE: I suggested this enhancement to emacs-devel in 2009. There was > exactly one reply, with only this text: "YAGNI". > http://lists.gnu.org/arch [...] Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Drew Adams writes: > This is an enhancement request, with a patch. > > [NOTE: I suggested this enhancement to emacs-devel in 2009. There was > exactly one reply, with only this text: "YAGNI". > http://lists.gnu.org/archive/html/emacs-devel/2009-10/msg00668.html > http://lists.gnu.org/archive/html/emacs-devel/2015-10/msg01481.html] > > The ability to type-check, provide :set and :initialize trigger > functions, automatically :require libraries, add links to doc, associate > with one or more :groups, etc. - these are useful things to be able to > do with at least some defvars, not just with defcustoms. Similarly, the > ability to persist non-option variables in a user's custom file can be > useful. So this has been brought up several times, and nobody seems to be enthusiastic about the idea. (I'm not either -- if we're extending Emacs Lisp to support static typing, I think this would be starting in at the wrong end.) So I'm closing this bug report. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Mon Aug 10 11:04:24 2020 Received: (at control) by debbugs.gnu.org; 10 Aug 2020 15:04:24 +0000 Received: from localhost ([127.0.0.1]:37180 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1k59Lc-00039F-AW for submit@debbugs.gnu.org; Mon, 10 Aug 2020 11:04:24 -0400 Received: from quimby.gnus.org ([95.216.78.240]:49276) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1k59La-00038s-TZ for control@debbugs.gnu.org; Mon, 10 Aug 2020 11:04:23 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Subject:From:To:Message-Id:Date:Sender:Reply-To:Cc: MIME-Version:Content-Type:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=0czEC/wGOzjqXmfLlR2qmxwjCXT2cWrw2eBu7YYfBBo=; b=B75SVm9s6wDXCG+2CmBBZD0YXI MNWPx9ih4+uGQvyZlbGt4Q10oa7ohPm9+zDmh7OM8IXgyMqqw4kZwDFFHe11OhFVO8i5ag9nYL6dj OFUmeCYz2vKVCQqTAWs85BMMYN/wzKyrD2KV4P1GUhBb5qQhEQREk9nCw18NqXl7FFYA=; Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=xo) by quimby with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1k59LT-0006BZ-4e for control@debbugs.gnu.org; Mon, 10 Aug 2020 17:04:17 +0200 Date: Mon, 10 Aug 2020 17:04:13 +0200 Message-Id: <87imdqzgnm.fsf@gnus.org> To: control@debbugs.gnu.org From: Lars Ingebrigtsen Subject: control message for bug #27348 X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: tags 27348 wontfix close 27348 quit Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) tags 27348 wontfix close 27348 quit