From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Philipp Stephani Newsgroups: gmane.emacs.bugs Subject: bug#26624: 26.0.50; Generalized variable `buffer-local-value' does't restore local flag Date: Fri, 29 Dec 2017 16:20:49 +0000 Message-ID: References: <87zid6udys.fsf@drachen> <87o9q0m77u.fsf@users.sourceforge.net> <87d16gm1qf.fsf@users.sourceforge.net> <837ewi9c4z.fsf@gnu.org> <837ewg65vl.fsf@gnu.org> <871sjhcetm.fsf@web.de> <83po70gnhy.fsf@gnu.org> <877et8ymiz.fsf@web.de> <83d12zhq71.fsf@gnu.org> <87a7y1hbiu.fsf@web.de> <83o9mhfr4w.fsf@gnu.org> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="001a11447f109ad8e705617d04fb" X-Trace: blaine.gmane.org 1514564427 17010 195.159.176.226 (29 Dec 2017 16:20:27 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Fri, 29 Dec 2017 16:20:27 +0000 (UTC) Cc: Michael Heerdegen , 26624@debbugs.gnu.org, npostavs@users.sourceforge.net To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Dec 29 17:20:22 2017 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1eUxOJ-0003NJ-0G for geb-bug-gnu-emacs@m.gmane.org; Fri, 29 Dec 2017 17:20:15 +0100 Original-Received: from localhost ([::1]:46137 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eUxQD-0004Uk-5O for geb-bug-gnu-emacs@m.gmane.org; Fri, 29 Dec 2017 11:22:13 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:57532) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eUxQ6-0004UG-Ds for bug-gnu-emacs@gnu.org; Fri, 29 Dec 2017 11:22:07 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eUxQ2-0004io-Cn for bug-gnu-emacs@gnu.org; Fri, 29 Dec 2017 11:22:06 -0500 Original-Received: from debbugs.gnu.org ([208.118.235.43]:48178) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1eUxQ2-0004iU-9o for bug-gnu-emacs@gnu.org; Fri, 29 Dec 2017 11:22:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1eUxQ2-00089i-2r for bug-gnu-emacs@gnu.org; Fri, 29 Dec 2017 11:22:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Philipp Stephani Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 29 Dec 2017 16:22:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 26624 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 26624-submit@debbugs.gnu.org id=B26624.151456446731274 (code B ref 26624); Fri, 29 Dec 2017 16:22:02 +0000 Original-Received: (at 26624) by debbugs.gnu.org; 29 Dec 2017 16:21:07 +0000 Original-Received: from localhost ([127.0.0.1]:56859 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eUxP9-00088M-C9 for submit@debbugs.gnu.org; Fri, 29 Dec 2017 11:21:07 -0500 Original-Received: from mail-qk0-f179.google.com ([209.85.220.179]:45117) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eUxP7-00087X-8z for 26624@debbugs.gnu.org; Fri, 29 Dec 2017 11:21:05 -0500 Original-Received: by mail-qk0-f179.google.com with SMTP id o126so40860799qke.12 for <26624@debbugs.gnu.org>; Fri, 29 Dec 2017 08:21:05 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=mK5vU+W9ygy1Bcno1dsaKAlCpHEQztwUtM9TjwDV6p0=; b=eKQS2HwvHv5K3tqjgLQTmZgEvK2MvfGFmwDc5+sdtrjMVxowbxEvsDH/45FCX+/dO+ HInxhc0O2CuIsK0FS6jmVDf/z+RjZE/dblbb5ldQumPa1b8e81QPDHycrygE5IL8kBEZ 67ZYaZ/UL1aG906IvYQbcuX8yysP3Bhp2HU8WCAM54amLs6wErJf69HX3+pQcVSxjNj+ SFP247doV+8qhy8HldZ4ZOfPPrzUxocttUe1oMui10OuMl46EdXq1aPvsmRGUUZtv0pI NIagwAG+PiT1c/Zsw7XMVmPekPZ9Hreq1K6TasPY7g5yFQR12fXmUxPlvxd9qtTH/BCF 8fJg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=mK5vU+W9ygy1Bcno1dsaKAlCpHEQztwUtM9TjwDV6p0=; b=X9PP98DQ6NxIra3Nu8OCJYiRdh3jaLz7S09IcghKSMNUqI339SSZeiCx4dB2wxXueA 2iDzCBYffVVu14gpCrM7Roo1WxZfJ/kqIDiKu/d4SKHBzCfVuxHFk4wjfq0ERqzaaumU dmJor/wHWDvEKmslxlVKL+zVS4tg5IHSkMIQ82j0D84GQYY4rd0FfomK9Gmrc+LGjblb 40OBRF3co2y4OWHFm+3IDBhmnKI16RyQz4yXsaV28pydYVgiFTZ8U3YH1onh2Q4j6tW7 N1SHt1GIsjZDg/zsqC6y75Q+HU64hsGfY3Le81JBi3IWtw23okU/1T/1BPfPu7355TXi Vfww== X-Gm-Message-State: AKGB3mL/IY+lir7f1e2QBG5AUV9pwI4fVeTKDZ+aH7PYHedVlSbRcHyM EAAWdy/XeAV2uzigXvaI0f2jM1H7FbOvFmPtVf0= X-Google-Smtp-Source: ACJfBosrjlbVCle8v4CiWgZ59erHSNmGHdSllKIZ5eeYKg6qqTR/iVjyYlQcLF7Uyaq3WRIz+hALdm5YfbAu13rBajU= X-Received: by 10.55.20.198 with SMTP id 67mr2624153qku.55.1514564459614; Fri, 29 Dec 2017 08:20:59 -0800 (PST) In-Reply-To: <83o9mhfr4w.fsf@gnu.org> 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: 208.118.235.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:141594 Archived-At: --001a11447f109ad8e705617d04fb Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Eli Zaretskii schrieb am Fr., 29. Dez. 2017 um 17:15 Uhr: > > From: Michael Heerdegen > > Cc: p.stephani2@gmail.com, 26624@debbugs.gnu.org, > npostavs@users.sourceforge.net > > Date: Fri, 29 Dec 2017 15:08:41 +0100 > > > > Eli Zaretskii writes: > > > > > Does this warning pop up during bootstrap, and if so, how many times? > > > > It currently would pop up five times: > > > > | ../lisp/electric.el:Warning: Warning: obsolete gv-setter: > =E2=80=98buffer-local-value=E2=80=99 > > | -------------------- > > | ../lisp/electric.el:Warning: Warning: obsolete gv-setter: > =E2=80=98buffer-local-value=E2=80=99 > > | -------------------- > > | electric.el:350:40:Warning: Warning: obsolete gv-setter: > =E2=80=98buffer-local-value=E2=80=99 > > | -------------------- > > | electric.el:580:39:Warning: Warning: obsolete gv-setter: > =E2=80=98buffer-local-value=E2=80=99 > > | -------------------- > > | elec-pair.el:608:38:Warning: Warning: obsolete gv-setter: > =E2=80=98buffer-local-value=E2=80=99 > > > > > > Yes, these would need to be treated. > > Can we treat them as part of fixing this issue? > Yes, but I think changing them should be a separate commit because it's not straightforward. These are all modes that can be locally or globally enabled. I think typically such modes would be defined using `define-minor-mode` and `define-globalized-minor-mode`, but the electric modes are defined the other way round, i.e. the main modes are global, and then there are local modes that use `buffer-local-value` as mode variable. I'd suggest to turn this around to use `define-minor-mode` for the local modes and `define-globalized-minor-mode` for the global ones. Would that have any downsides? --001a11447f109ad8e705617d04fb Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable


Eli Za= retskii <eliz@gnu.org> schrieb am= Fr., 29. Dez. 2017 um 17:15=C2=A0Uhr:
> From: Michael Heerdegen <michael_heerdegen@web.de>
> Cc: p.steph= ani2@gmail.com,=C2=A0 26624@debbugs.gnu.org,=C2=A0 npostavs@users.sourceforge.net > Date: Fri, 29 Dec 2017 15:08:41 +0100
>
> Eli Zaretskii <el= iz@gnu.org> writes:
>
> > Does this warning pop up during bootstrap, and if so, how many ti= mes?
>
> It currently would pop up five times:
>
> | ../lisp/electric.el:Warning: Warning: obsolete gv-setter: =E2=80=98b= uffer-local-value=E2=80=99
> | --------------------
> | ../lisp/electric.el:Warning: Warning: obsolete gv-setter: =E2=80=98b= uffer-local-value=E2=80=99
> | --------------------
> | electric.el:350:40:Warning: Warning: obsolete gv-setter: =E2=80=98bu= ffer-local-value=E2=80=99
> | --------------------
> | electric.el:580:39:Warning: Warning: obsolete gv-setter: =E2=80=98bu= ffer-local-value=E2=80=99
> | --------------------
> | elec-pair.el:608:38:Warning: Warning: obsolete gv-setter: =E2=80=98b= uffer-local-value=E2=80=99
>
>
> Yes, these would need to be treated.

Can we treat them as part of fixing this issue?

Yes, but I think changing them should be a separate commit because= it's not straightforward.
These are all modes that can be lo= cally or globally enabled. I think typically such modes would be defined us= ing `define-minor-mode` and `define-globalized-minor-mode`, but the electri= c modes are defined the other way round, i.e. the main modes are global, an= d then there are local modes that use `buffer-local-value` as mode variable= . I'd suggest to turn this around to use `define-minor-mode` for the lo= cal modes and `define-globalized-minor-mode` for the global ones. Would tha= t have any downsides?=C2=A0
--001a11447f109ad8e705617d04fb--