From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Noam Postavsky Newsgroups: gmane.emacs.bugs Subject: bug#30846: 26.0.91; debug-watch of kill-all-local-variables triggers 'assertion failed: found == !EQ (blv->defcell, blv->valcell)' Date: Thu, 22 Mar 2018 20:20:13 -0400 Message-ID: <87in9nskw2.fsf@gmail.com> References: <87sh8xttpq.fsf@gmail.com> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1521764351 16652 195.159.176.226 (23 Mar 2018 00:19:11 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Fri, 23 Mar 2018 00:19:11 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.0.90 (gnu/linux) Cc: 30846@debbugs.gnu.org To: Stefan Monnier Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Mar 23 01:19:07 2018 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 1ezAQD-00049c-QD for geb-bug-gnu-emacs@m.gmane.org; Fri, 23 Mar 2018 01:19:06 +0100 Original-Received: from localhost ([::1]:35425 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ezASG-0006eK-Nl for geb-bug-gnu-emacs@m.gmane.org; Thu, 22 Mar 2018 20:21:12 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:49449) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ezASB-0006c6-8X for bug-gnu-emacs@gnu.org; Thu, 22 Mar 2018 20:21:08 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ezAS6-0000rv-8v for bug-gnu-emacs@gnu.org; Thu, 22 Mar 2018 20:21:07 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:40363) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1ezAS6-0000rr-4s for bug-gnu-emacs@gnu.org; Thu, 22 Mar 2018 20:21:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1ezAS5-0005tD-Ra for bug-gnu-emacs@gnu.org; Thu, 22 Mar 2018 20:21:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Noam Postavsky Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 23 Mar 2018 00:21:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 30846 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 30846-submit@debbugs.gnu.org id=B30846.152176442222586 (code B ref 30846); Fri, 23 Mar 2018 00:21:01 +0000 Original-Received: (at 30846) by debbugs.gnu.org; 23 Mar 2018 00:20:22 +0000 Original-Received: from localhost ([127.0.0.1]:48260 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ezARS-0005sE-Ct for submit@debbugs.gnu.org; Thu, 22 Mar 2018 20:20:22 -0400 Original-Received: from mail-io0-f169.google.com ([209.85.223.169]:38110) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ezARQ-0005s1-Vn for 30846@debbugs.gnu.org; Thu, 22 Mar 2018 20:20:21 -0400 Original-Received: by mail-io0-f169.google.com with SMTP id b20so13145865iof.5 for <30846@debbugs.gnu.org>; Thu, 22 Mar 2018 17:20:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=0OY3cyIufeP0+0ENLTCPg0u8fwNfbI/Y8fwtr8QVk2I=; b=bl8hd591JcLPB0FEu4qUvQqgX5y1qhuUsrnjN3FscqteM2ty2VZ9LzMCpzRiJmweu/ 74AUVirw3LV3l4grjYEA6ICUkUEhEtJY8rxeCmvaF/AliO60MAYWqQZB1rhMnGEUH4J6 iwjkmkHfj6PRcQGtcmBsRD99ovFDah37YKr1D6i6sTqTDt8mBvu3I2AG1C1D1MSvEslO JYXAjYZgvlky1FSm4ge139tR2nSzjtJQchLO42PV4vnK7639UN+3GJjucn00xaZd9JLW yh1JUEATjpZMlJyzAAoFZ1QT3y22NIEnQ6U6WgAZf/j91K31/zdUwzQL0sCghpK+Of03 xkMA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=0OY3cyIufeP0+0ENLTCPg0u8fwNfbI/Y8fwtr8QVk2I=; b=WKYsvrOWBnQe2GLzEdx4R2u+GXw4WNCZZMkKaZFpm7Bt16yvXH8INScX3d4r4Nfve0 wT+3tKEw/ZQ01Lu3/JaDeARW6EKpYHr7ykAacysJ52d9bFLIF4eBUYwr1WH4/RVp9K5f DTn+5ZcvBmaErp7kESxAEDW08vM5PIEk+0xw0ejD96X5Amjvj4hzGKGHH04Vl/bLsxDc ImIthJL69m16NhK67P/2le3Bmnz/splFG4+pIA0aY9M0j2W/pvx1krEmTrCjn4kN0EBp aDEz66zA7Y6M+bv8hoEEjNazlo/9PliAA/vH9gEbJKCy7z2d3NPdvMAK+tQVFzKDx5MU Ia+Q== X-Gm-Message-State: AElRT7Gbne1fmowWzdBlKyHHj7Rb3tQhmwULo+gi1NwYCNs6tHNgDtiD pJwwX++VEB2IfHu0re6ZDXbjTg== X-Google-Smtp-Source: AG47ELv0FNhVkWGLMxlmNfgrX1H4cKJ1P8EqyEhO70NUxyTN7UfwKUm2z0fQM91lvCC0zec2uK2/UQ== X-Received: by 10.107.29.84 with SMTP id d81mr29052176iod.59.1521764415237; Thu, 22 Mar 2018 17:20:15 -0700 (PDT) Original-Received: from zebian (cbl-45-2-119-34.yyz.frontiernetworks.ca. [45.2.119.34]) by smtp.googlemail.com with ESMTPSA id q21-v6sm4961531itb.2.2018.03.22.17.20.14 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Thu, 22 Mar 2018 17:20:14 -0700 (PDT) In-Reply-To: (Stefan Monnier's message of "Thu, 22 Mar 2018 11:45:32 -0400") 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:144541 Archived-At: Stefan Monnier writes: > If you feel this is too risky for emacs-26, I wouldn't blame you (this > is pretty tricky code): while the assertion crashes Emacs, a normal > build without assertions will likely not notice the problem at all. > I came up with a test case that catches the problem, but I think that in > "real" life it's very unlikely to cause a problem. Should we disable the assertion in emacs-26 then? And would the diff below updating comments on struct Lisp_Buffer_Local_Value be correct? --- i/src/lisp.h +++ w/src/lisp.h @@ -2593,10 +2593,10 @@ XUSER_PTR (Lisp_Object a) variable, you must first make sure the right binding is loaded; then you can access the value in (or through) `realvalue'. - `buffer' and `frame' are the buffer and frame for which the loaded - binding was found. If those have changed, to make sure the right + `where' is the buffer for which the loaded + binding was found. If it has changed, to make sure the right binding is loaded it is necessary to find which binding goes with - the current buffer and selected frame, then load it. To load it, + the current buffer, then load it. To load it, first unload the previous binding, then copy the value of the new binding into `realvalue' (or through it). Also update LOADED-BINDING to point to the newly loaded binding. @@ -2615,14 +2615,14 @@ XUSER_PTR (Lisp_Object a) bool_bf found : 1; /* If non-NULL, a forwarding to the C var where it should also be set. */ union Lisp_Fwd *fwd; /* Should never be (Buffer|Kboard)_Objfwd. */ - /* The buffer or frame for which the loaded binding was found. */ + /* The buffer for which the loaded binding was found. */ Lisp_Object where; /* A cons cell that holds the default value. It has the form (SYMBOL . DEFAULT-VALUE). */ Lisp_Object defcell; /* The cons cell from `where's parameter alist. It always has the form (SYMBOL . VALUE) - Note that if `forward' is non-nil, VALUE may be out of date. + Note that if `fwd' is non-NULL, VALUE may be out of date. Also if the currently loaded binding is the default binding, then this is `eq'ual to defcell. */ Lisp_Object valcell;