From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Drew Adams" Newsgroups: gmane.emacs.bugs Subject: bug#5971: 23.1.95; `delete' modifies default value instead of buffer-local value Date: Mon, 19 Apr 2010 10:03:09 -0700 Message-ID: <8092CBDD05AF419298FFE73B27D1E5C7@us.oracle.com> References: <1ED47ADCD80A4C019EF77D4CB7C5D863@us.oracle.com><8348D62071EB468F8FD5D95D35201C08@us.oracle.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1271698247 9061 80.91.229.12 (19 Apr 2010 17:30:47 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 19 Apr 2010 17:30:47 +0000 (UTC) Cc: 5971@debbugs.gnu.org, tracker@debbugs.gnu.org, 'GNU bug Tracking System' To: "'Andreas Schwab'" Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Apr 19 19:30:39 2010 connect(): No such file or directory Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1O3unu-0003Ua-GB for geb-bug-gnu-emacs@m.gmane.org; Mon, 19 Apr 2010 19:30:39 +0200 Original-Received: from localhost ([127.0.0.1]:50551 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1O3uns-0007Wh-Om for geb-bug-gnu-emacs@m.gmane.org; Mon, 19 Apr 2010 13:30:36 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1O3umr-0006Qm-Lc for bug-gnu-emacs@gnu.org; Mon, 19 Apr 2010 13:29:33 -0400 Original-Received: from [140.186.70.92] (port=37473 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1O3umm-0006Kh-QA for bug-gnu-emacs@gnu.org; Mon, 19 Apr 2010 13:29:32 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1O3umi-0002T1-Ts for bug-gnu-emacs@gnu.org; Mon, 19 Apr 2010 13:29:28 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:45015) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1O3umg-0002Rv-Cp for bug-gnu-emacs@gnu.org; Mon, 19 Apr 2010 13:29:22 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.69) (envelope-from ) id 1O3uP8-0001KJ-4T; Mon, 19 Apr 2010 13:05:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: "Drew Adams" Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 19 Apr 2010 17:05:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 5971 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 5971-submit@debbugs.gnu.org id=B5971.12716966525088 (code B ref 5971); Mon, 19 Apr 2010 17:05:02 +0000 Original-Received: (at 5971) by debbugs.gnu.org; 19 Apr 2010 17:04:12 +0000 Original-Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1O3uOK-0001K1-EX for submit@debbugs.gnu.org; Mon, 19 Apr 2010 13:04:12 -0400 Original-Received: from rcsinet10.oracle.com ([148.87.113.121]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1O3uOI-0001Jv-8K; Mon, 19 Apr 2010 13:04:10 -0400 Original-Received: from acsinet15.oracle.com (acsinet15.oracle.com [141.146.126.227]) by rcsinet10.oracle.com (Switch-3.4.2/Switch-3.4.1) with ESMTP id o3JH3xVC027614 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Mon, 19 Apr 2010 17:04:01 GMT Original-Received: from acsmt353.oracle.com (acsmt353.oracle.com [141.146.40.153]) by acsinet15.oracle.com (Switch-3.4.2/Switch-3.4.1) with ESMTP id o3J62kHw010189; Mon, 19 Apr 2010 17:03:56 GMT Original-Received: from abhmt001.oracle.com by acsmt354.oracle.com with ESMTP id 188211441271696590; Mon, 19 Apr 2010 10:03:10 -0700 Original-Received: from dradamslap1 (/130.35.178.194) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Mon, 19 Apr 2010 10:03:08 -0700 X-Mailer: Microsoft Office Outlook 11 In-Reply-To: X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.5579 Thread-Index: Acrf3dnm4eLw/1V7SQSMciuf9vvDTAAA3hjw X-Auth-Type: Internal IP X-Source-IP: acsinet15.oracle.com [141.146.126.227] X-CT-RefId: str=0001.0A090204.4BCC8D02.0049:SCFMA922111,ss=1,fgs=0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list Resent-Date: Mon, 19 Apr 2010 13:05:02 -0400 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) 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: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:36317 Archived-At: > > Nothing in the doc states that they share list structure. > > There is no buffer-local value before you set it. Yes, I know that. And I noted that explicitly. > The doc is pretty clear that a buffer-local value only starts to exist > the first time it is set: > > Make VARIABLE become buffer-local whenever it is set. > At any time, the value for the current buffer is in effect, > unless the variable has never been set in this buffer, > in which case the default value is in effect. > ^^^^^^^^^^^^^^^^^^^^^^^^^^ Yes, and I explictly said that too. Please read what I wrote. I am not questioning the fact that the default value is used if no buffer-local value is set. And that behavior is adequately documented. What is _not_ documented AFAICT is that using `delete' to set the buffer-local value in buffer X also modifies the default value. There is no reason to expect that, from reading the doc. Once the default value has been modified, it is clear that buffer Y will (and should) pick it up if you have not yet set a buffer-local value in Y. What is not clear is why the _default_ value gets modified, just by setting the _buffer-local_ value (in X). And as I noted, using `nconc' (which is destructive like `delete') does not have this effect. The same code uses `nconc' to set the buffer-local value in X, and that does not also modify the default value.