[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Two binding features
From: |
Stefan Monnier |
Subject: |
Re: Two binding features |
Date: |
Thu, 08 May 2008 21:30:02 -0400 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux) |
> Two primitive features that would be useful for mumamo
> (and perhaps othere programs) are:
> * A primitive that would let-bind variables from an alist.
> I think Common Lisp has such a construct; is that correct?
> I do not recall its name, though.
> * A way to temporarily turn off all buffer-local bindings. This could
> take the form of a variable which you would bind with `let', and when
> it is non-nil, the buffer-local bindings are not visible.
> `with-current-buffer' should bind it to nil so that the buffer-local
> bindings of the newly current buffer always do take effect.
> It would be ok if certain variables whose values are stored directly
> in the buffer object, such as `buffer-file-name', fail to be affected
> by this feature.
> I think any feature to temporarily switch modes, or pretend to do so,
> would find these features useful. Could someone implement them?
The above features can be simulated fairly well and easily with Elisp
code, so I think it'd be better to first try an Elisp implementation and
when it turns out that it is indeed useful and that the performance
and/or semantics of the Elisp code is problematic, we can consider
adding the feature in C.
Stefan