From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: =?UTF-8?Q?Elias_M=C3=A5rtenson?= Newsgroups: gmane.emacs.devel Subject: Re: custom-set-variables considered harmful Date: Fri, 24 Nov 2017 15:04:22 +0800 Message-ID: References: NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="94eb2c0abc10897f90055eb52933" X-Trace: blaine.gmane.org 1511507134 8841 195.159.176.226 (24 Nov 2017 07:05:34 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Fri, 24 Nov 2017 07:05:34 +0000 (UTC) Cc: emacs-devel To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Nov 24 08:05:15 2017 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eI82u-0000rC-Tm for ged-emacs-devel@m.gmane.org; Fri, 24 Nov 2017 08:05:09 +0100 Original-Received: from localhost ([::1]:47502 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eI832-0001c1-4V for ged-emacs-devel@m.gmane.org; Fri, 24 Nov 2017 02:05:16 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:60562) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eI82H-0001bm-Lc for emacs-devel@gnu.org; Fri, 24 Nov 2017 02:04:33 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eI82B-0006qx-I3 for emacs-devel@gnu.org; Fri, 24 Nov 2017 02:04:29 -0500 Original-Received: from mail-it0-x22e.google.com ([2607:f8b0:4001:c0b::22e]:44511) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1eI82B-0006qW-EJ for emacs-devel@gnu.org; Fri, 24 Nov 2017 02:04:23 -0500 Original-Received: by mail-it0-x22e.google.com with SMTP id b5so12385852itc.3 for ; Thu, 23 Nov 2017 23:04:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=uewUlnJ6NgjTy0RTrOP0hhbBZUmACsUM/1HUH+DTopQ=; b=bAQn7bH/K2BW7ldYK2Iz9sg/+eYK9QeLM5MrB2ZEkd3lSmNHJqsNxcOZVa41KGOwSJ UVtMiEEXVLl05gQn9edCZOTAhOVj+A3KFg70Mz8L0zuN405zUaCGbsr2GQMHVU1Gbxy8 taqOjOdopuSqm72HwuRFmfzKgNRO2Nf970t4zGfq2coU+HzxqSxjEAuKh9uMO5ldWqEa LOeOS+VAm6Wo8ZP9SBUV5+LPgeO1h58TyGlsqgPO0XDB+X34n+ZLktnz6jXSAhjD7BXT K0Xq6n7fZXy89zbVGvpxhDXhqDew85kReTl8mm0sJtYJJSSUmNhcUayL2ZMwE7S60zGP B6vQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=uewUlnJ6NgjTy0RTrOP0hhbBZUmACsUM/1HUH+DTopQ=; b=sZGQ5IBhfo9rBHOJ/myUTH4IJHdnQVZjotmyQBGJuNtKK54GNFvwnYUVHowhU+0Sj7 94DCAHXg+iPtKZxZPLE/20CkpVDa4oIGZ14GDyKgJ9Fewvpj6tMUqX29kj+BrIebAChT OaxqnuciUUBBVi9zSZUIQEEUd8OhrjOi86uQD81cQKM015DQhl0K+Tg+1XQ61y3TIvi+ H+YSlv37Cc+grZ16vN4+XuDtyAtISsbuzh+9TBKoLoZxNbaBkwPLx0NCTCq1a8Tf7lpN 0n54DZl9JMPzRDSG88k3cN7FSnNQQHNoFZP0ch6EGlFfHpmBMFyqZLRCDNQ+sUx4ZhYV T0Iw== X-Gm-Message-State: AJaThX6jXZSP/F4Y2w8s28p93vwy3C8bJ/U8rzPP65XGxeSeNyoqdiN4 dPzMDB6Z1aZ3XkDZ6KSpaX4tJ+GHOo29S9AfhuQ= X-Google-Smtp-Source: AGs4zMaUdmpf/NI8uT2l+1Wj0hEbQdy3P/d/tcMqIeCO4Kno9qNPEORralJNQ/pcr5mYbOWSdJUEsswEWMFeJBnABcU= X-Received: by 10.36.243.13 with SMTP id t13mr12623450ith.19.1511507062519; Thu, 23 Nov 2017 23:04:22 -0800 (PST) Original-Received: by 10.107.62.134 with HTTP; Thu, 23 Nov 2017 23:04:22 -0800 (PST) In-Reply-To: X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:4001:c0b::22e X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 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.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:220416 Archived-At: --94eb2c0abc10897f90055eb52933 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On 14 November 2017 at 00:26, Stefan Monnier wrote: > > When writing customizations, instead of writing > > > > (custom-set-variables > > ;; Big ugly warning which doesn't help enough. > > '(VAR1 VAL1) > > '(VAR2 VAL2 nil '(REQUEST) COMMENT) > > '(VAR3 VAL3) > > ...) > > > > we write > > > > (autogenerated-custom-settings > > ;; Big warning, still, but less important. > > (setq VAR1 VAL1) > > (require 'REQUEST) > > (customize-set-variable VAR2 VAL2 COMMENT) > > (customize-set-variable VAR3 VAL3) > > ...) > > Here's a sample patch to do that. Comments? > Is there a particular reson you're not using =E2=80=98customize-set-variabl= e=E2=80=99 for all values? It would be more consistent, and also avoid problems in case a package is changed and a setter function is added to a variable which previously did not use it. Regards, Elias --94eb2c0abc10897f90055eb52933 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable