From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Mauro Aranda Newsgroups: gmane.emacs.bugs Subject: bug#15214: 24.3.50; `Revert This Session's Customization' does not do what it says Date: Mon, 30 Dec 2019 18:30:31 -0300 Message-ID: References: <8b504c44-91b3-4c9f-bca5-3b4d1547f67f@default> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="0000000000004339e4059af28e8e" Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="126912"; mail-complaints-to="usenet@blaine.gmane.org" To: 15214@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Dec 30 22:31:13 2019 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1im2d7-000Wkv-66 for geb-bug-gnu-emacs@m.gmane.org; Mon, 30 Dec 2019 22:31:13 +0100 Original-Received: from localhost ([::1]:36788 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1im2d5-0001O5-U0 for geb-bug-gnu-emacs@m.gmane.org; Mon, 30 Dec 2019 16:31:11 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:39777) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1im2cy-0001Np-FF for bug-gnu-emacs@gnu.org; Mon, 30 Dec 2019 16:31:05 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1im2cw-0000n0-44 for bug-gnu-emacs@gnu.org; Mon, 30 Dec 2019 16:31:04 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:55794) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1im2cv-0000mb-Ug for bug-gnu-emacs@gnu.org; Mon, 30 Dec 2019 16:31:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1im2cv-0001A5-S3 for bug-gnu-emacs@gnu.org; Mon, 30 Dec 2019 16:31:01 -0500 X-Loop: help-debbugs@gnu.org In-Reply-To: <8b504c44-91b3-4c9f-bca5-3b4d1547f67f@default> Resent-From: Mauro Aranda Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 30 Dec 2019 21:31:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 15214 X-GNU-PR-Package: emacs Original-Received: via spool by 15214-submit@debbugs.gnu.org id=B15214.15777414524449 (code B ref 15214); Mon, 30 Dec 2019 21:31:01 +0000 Original-Received: (at 15214) by debbugs.gnu.org; 30 Dec 2019 21:30:52 +0000 Original-Received: from localhost ([127.0.0.1]:33534 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1im2cl-00019c-Jq for submit@debbugs.gnu.org; Mon, 30 Dec 2019 16:30:51 -0500 Original-Received: from mail-lj1-f171.google.com ([209.85.208.171]:33640) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1im2cj-00019H-8h for 15214@debbugs.gnu.org; Mon, 30 Dec 2019 16:30:50 -0500 Original-Received: by mail-lj1-f171.google.com with SMTP id y6so26591201lji.0 for <15214@debbugs.gnu.org>; Mon, 30 Dec 2019 13:30:49 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to:cc; bh=/UoA4Nc/XHZnRc//2FMoOuRO9pOppuBetqE2VrO2AhA=; b=l8YTDWobaz1/JntNWdaAfgEvEvYtX/uIIaXpWkFmo+zX4Hwa53kSJzTsQ3OHW1GTVs 4nKyNZZj32NPfmR8OvmhrLW8wGv9+F6YHL0knzb0u+fLlAgaf15sGoMrgpbTQfPraQ3Q YdyNhgsF6hrfiNgiGizQ44qDrmEMmvjsa3knTk/Uv6Ml9Gd9eTVDo9knrbmt1iGvQ8T4 2avqU+s03+TtNSBepVYcddtygmYxFJ97qKlPFXFRIniPHT3JGYivX3y1KhfUUaygPr8J rVX0qQhzbhWIIUinYbY/g12qRWojXJsn/X7PSpmkwys8dOpNVRiKl995QVrBzURa/1hx /qkQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to:cc; bh=/UoA4Nc/XHZnRc//2FMoOuRO9pOppuBetqE2VrO2AhA=; b=Gw2k67nP0GyfuPCZKVVu9ZI+S1/ehxojR5Jr7vzgOfQc7nhZwdi0oqTmSqPQ8paNvi 9IkHW5iiKUlRF2H/TPJuAWvckKj/PeXS6ic4fXXSqaSIvvSOctFU3YmkOI7mYqvRGh4b QZ6rAPn+Am7WJOKYeLAGX1mS/aIuIPT2iFJUsh9pKkzVC9utx7xvmVTX5EHDAmxd4cnp l7HZ7rbc9NzMI5SR0gtnxxsZCJj2X9MPyRC+pqnyqdv96gm+XQBxMyIf1i7SukeQTsSg 6H/swteYJt7A/t+9ZxxfOlxA3Gdh29/4VfwE+dEVez9Jp7Ey9kZC4ahJsnmwU2Ei/96C Gb6A== X-Gm-Message-State: APjAAAXBi8PACSg92ssC3MEE1zluTP46t5LjX3HoXnyop08LHO6SIEjZ JXhm1krfmfm2giYDp7u48KDMEGeqq7RO8kjYQgdQuJ0/ X-Google-Smtp-Source: APXvYqw6EEjRV6PBGERAnxmsQl8vNo8Sfkn/6uQ64rZbq87zFj7+YRDVKnI9Olp6+IeElsxD4f+TQ1z9FnS+ZHxGyXo= X-Received: by 2002:a2e:b010:: with SMTP id y16mr40658686ljk.238.1577741443078; Mon, 30 Dec 2019 13:30:43 -0800 (PST) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] 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.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:173966 Archived-At: --0000000000004339e4059af28e8e Content-Type: multipart/alternative; boundary="0000000000004339e2059af28e8c" --0000000000004339e2059af28e8c Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable tags 15214 patch thanks Drew Adams writes: > 1. emacs -Q > > M-x customize-option backup-by-copying > > Click Toggle, then State and Set For Current Session. > You have changed the value. > > Click State and Revert This Session's Customization. > > The current value does not change back to what it was before you changed > the setting for the session. This session's customization was not > reverted. However, even though the value was not changed, you see the > message "CHANGED outside Customize". I can reproduce this in latest master and emacs-27 branch. > 2. The State choice of Revert This Session's Customization is not even > documented at (emacs) `Changing a Variable'. Other State actions are > documented. So it's hard to tell whether #1 above is really a bug: it's > not even clear what this menu item is supposed to do. Current (emacs) Changing a Variable says: =E2=80=98Revert This Session's Customizations=E2=80=99 This restores the value of the variable to the last saved value, if there was one. Otherwise it restores the standard value. It updates the text accordingly. The function that runs for that option is custom-variable-reset-saved, and the doc string of custom-variable-reset-saved says something similar. The attached patch fixes custom-variable-reset-saved to do what it says it does when the variable has no previous saved value. Best regards, Mauro. --0000000000004339e2059af28e8c Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
tags 15214 patch
thanks

Drew Adams <drew.adams@or= acle.com> writes:

> 1. emacs -Q
>
> M-x cust= omize-option backup-by-copying
>
> Click Toggle, then State and= Set For Current Session.
> You have changed the value.
>
&g= t; Click State and Revert This Session's Customization.
>
>= The current value does not change back to what it was before you changed> the setting for the session.=C2=A0 This session's customization = was not
> reverted.=C2=A0 However, even though the value was not chan= ged, you see the
> message "CHANGED outside Customize".
=
I can reproduce this in latest master and emacs-27 branch.

> = 2. The State choice of Revert This Session's Customization is not even<= br>> documented at (emacs) `Changing a Variable'.=C2=A0 Other State = actions are
> documented.=C2=A0 So it's hard to tell whether #1 a= bove is really a bug: it's
> not even clear what this menu item i= s supposed to do.

Current (emacs) Changing a Variable says:
=E2= =80=98Revert This Session's Customizations=E2=80=99
=C2=A0 =C2=A0 = =C2=A0This restores the value of the variable to the last saved value, if=C2=A0 =C2=A0 =C2=A0there was one.=C2=A0 Otherwise it restores the standa= rd value.=C2=A0 It
=C2=A0 =C2=A0 =C2=A0updates the text accordingly.
=
The function that runs for that option is custom-variable-reset-saved,<= br>and the doc string of custom-variable-reset-saved says something similar= .

The attached patch fixes custom-variable-reset-saved to do what it= says
it does when the variable has no previous saved value.

Best= regards,
Mauro.
--0000000000004339e2059af28e8c-- --0000000000004339e4059af28e8e Content-Type: text/x-patch; charset="US-ASCII"; name="0001-Reset-to-the-standard-value-when-reverting-session-s.patch" Content-Disposition: attachment; filename="0001-Reset-to-the-standard-value-when-reverting-session-s.patch" Content-Transfer-Encoding: base64 Content-ID: X-Attachment-Id: f_k4syame10 RnJvbSAyMDkyZmIwYjlhMzY3NzVlMjJlZmM1ZmQ5NjdhMDVmNmU0YmZmYmViIE1vbiBTZXAgMTcg MDA6MDA6MDAgMjAwMQpGcm9tOiBNYXVybyBBcmFuZGEgPG1hdXJvb2FyYW5kYUBnbWFpbC5jb20+ CkRhdGU6IE1vbiwgMzAgRGVjIDIwMTkgMTg6MTA6MjggLTAzMDAKU3ViamVjdDogW1BBVENIXSBS ZXNldCB0byB0aGUgc3RhbmRhcmQgdmFsdWUgd2hlbiByZXZlcnRpbmcgc2Vzc2lvbidzCiBjdXN0 b21pemF0aW9uCgoqIGxpc3AvY3VzLWVkaXQuZWwgKGN1c3RvbS12YXJpYWJsZS1yZXNldC1zYXZl ZCk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