From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Dan Nicolaescu Newsgroups: gmane.emacs.devel Subject: Re: make-variable-buffer-local change Date: Fri, 25 Sep 2009 12:46:32 -0700 (PDT) Message-ID: <200909251946.n8PJkWuI021889@godzilla.ics.uci.edu> References: <200909251609.n8PG97YN020225@godzilla.ics.uci.edu> <200909251707.n8PH7nuk020712@godzilla.ics.uci.edu> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1253911039 4186 80.91.229.12 (25 Sep 2009 20:37:19 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 25 Sep 2009 20:37:19 +0000 (UTC) Cc: emacs-devel@gnu.org To: Juanma Barranquero Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Sep 25 22:37:12 2009 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1MrHXT-0005dH-La for ged-emacs-devel@m.gmane.org; Fri, 25 Sep 2009 22:37:11 +0200 Original-Received: from localhost ([127.0.0.1]:46603 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MrHXS-0005Gj-Q0 for ged-emacs-devel@m.gmane.org; Fri, 25 Sep 2009 16:37:10 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MrGmB-000081-4C for emacs-devel@gnu.org; Fri, 25 Sep 2009 15:48:19 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MrGm5-00005T-RX for emacs-devel@gnu.org; Fri, 25 Sep 2009 15:48:18 -0400 Original-Received: from [199.232.76.173] (port=39310 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MrGm5-00005N-Nq for emacs-devel@gnu.org; Fri, 25 Sep 2009 15:48:13 -0400 Original-Received: from barrelv2.ics.uci.edu ([128.195.1.114]:37209) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_3DES_EDE_CBC_SHA1:24) (Exim 4.60) (envelope-from ) id 1MrGm5-00054h-6J for emacs-devel@gnu.org; Fri, 25 Sep 2009 15:48:13 -0400 Original-Received: from godzilla.ics.uci.edu (godzilla.ics.uci.edu [128.195.10.101]) by barrelv2.ics.uci.edu (8.13.8+Sun/8.13.8) with ESMTP id n8PJkWEg024808; Fri, 25 Sep 2009 12:46:32 -0700 (PDT) Original-Received: (from dann@localhost) by godzilla.ics.uci.edu (8.13.8+Sun/8.13.6/Submit) id n8PJkWuI021889; Fri, 25 Sep 2009 12:46:32 -0700 (PDT) In-Reply-To: (Juanma Barranquero's message of "Fri, 25 Sep 2009 19:31:09 +0200") Original-Lines: 46 X-ICS-MailScanner-Information: Please contact the ISP for more information X-ICS-MailScanner-ID: n8PJkWEg024808 X-ICS-MailScanner: Found to be clean X-ICS-MailScanner-SpamCheck: not spam, SpamAssassin (score=-1.44, required 5, autolearn=disabled, ALL_TRUSTED -1.44) X-ICS-MailScanner-From: dann@godzilla.ics.uci.edu X-detected-operating-system: by monty-python.gnu.org: Solaris 10 (beta) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:115628 Archived-At: Juanma Barranquero writes: > On Fri, Sep 25, 2009 at 19:07, Dan Nicolaescu wrote: >=20 > > "All packages that assign it" >=20 > Of course. For packages that read it, they only want to find the right > (local) value, or nil when it has not been assigned. >=20 > > It is globally assigned to nil. >=20 > That's the default. Every buffer-local variable has a global default. > Surely you're not implying that is a reason for assigning it globally. >=20 > > All buffers that don't set it explicitly use the global nil value. >=20 > All buffers that don't set it explicitly don't use it. All packages > that don't set it but read it expect it to be locally set (or globally > nil). >=20 > > Isn't it slightly more efficient to access global bindings than buffer > > local bindings, so forcing `make-variable-buffer-local' will force th= is > > inefficiency everywhere. >=20 > Sorry, I think I'm not understanding your point. The packages that My point is that it is cheaper to make this variable buffer local exactly in the buffers that need to have it buffer local, rather than making it buffer local in all buffers.=20 What this discussion points out is that it would be good to have a clarification of the use of make-variable-buffer-local vs make-local-variable in the docstring of one (or both) of them. Stefan? > > IMHO the first thing to do there is to decide if this is a problem wi= th > > uniquify, or if it's just working as expected. =C2=A0(no idea here). >=20 > If you create a buffer *vc-dir* with working dir /emacs/lisp, and > another with working dir /emacs/src, one of the *vc-dir* buffers will > have a value for uniquify-managed and the other will not. That cannot > be right. That's just a restatement of the facts, I am looking for an analysis of the cause of issue. Like, is this a bug in uniquify? Or is uniquify working as expected, but it needs extra hand holding to do the right thing? Something else?...