[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: make-variable-buffer-local change
From: |
Dan Nicolaescu |
Subject: |
Re: make-variable-buffer-local change |
Date: |
Fri, 25 Sep 2009 14:25:12 -0700 (PDT) |
Stefan Monnier <address@hidden> writes:
> >> Isn't it slightly more efficient to access global bindings than buffer
> >> local bindings,
> > No.
>
> Sorry, I think I misread. The answer is "yes".
> But the efficiency is the same for a variable after
> make-variable-buffer-local as after make-local-variable.
So if you have:
(defvar foo nil)
(make-variable-buffer-local 'foo)
The do: (if (buffer-local-value 'foo) BLAH)
vs
(defvar foo nil)
and then in very few buffers, majority do not change the value of foo:
(set (make-local-variable 'foo) 'bar)
and do the same computation:
(if (buffer-local-value 'foo) BLAH)
is one of these 2 versions more efficient than the other?
- Re: make-variable-buffer-local change, (continued)
- Re: make-variable-buffer-local change, Dan Nicolaescu, 2009/09/25
- Re: make-variable-buffer-local change, Juanma Barranquero, 2009/09/25
- Re: make-variable-buffer-local change, Dan Nicolaescu, 2009/09/25
- Re: make-variable-buffer-local change, Juanma Barranquero, 2009/09/25
- Re: make-variable-buffer-local change, Dan Nicolaescu, 2009/09/25
- Re: make-variable-buffer-local change, Juanma Barranquero, 2009/09/25
- Re: make-variable-buffer-local change, Tom Tromey, 2009/09/25
- Re: make-variable-buffer-local change, Stefan Monnier, 2009/09/25
- Re: make-variable-buffer-local change, Stefan Monnier, 2009/09/25
- Re: make-variable-buffer-local change,
Dan Nicolaescu <=
- Re: make-variable-buffer-local change, Tom Tromey, 2009/09/25
Re: make-variable-buffer-local change, Stefan Monnier, 2009/09/25