[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] Proposal to change cursor appearance to indicate region acti
From: |
Kelly Dean |
Subject: |
Re: [PATCH] Proposal to change cursor appearance to indicate region activation |
Date: |
Fri, 30 Jan 2015 07:20:10 +0000 |
David Kastrup wrote:
> Multiple independent use cases. add-hook/remove-hook is a mechanism for
> organizing independent use cases for one feature, but there is no such
> mechanism for organizing independent use cases for the varhook feature
> in your implementation even though you actually use add-hook. But it
> requires first individually allocating, naming, and using a hook for any
> variable you might want to varhook into.
IIUC, you mean independent uses of varhook might choose different symbols for
the hook. It seems that would be solved by the convention of using the symbol
⌜foo-varhook⌝ as the hook for ⌜foo⌝; all independent uses would add/remove
their functions on that same hook.
I guess another solution would be to put the car of the list of functions
directly in a dedicated varhook slot for the target symbol, rather than
indirecting through a regular hook. That would increase the size of each symbol
from 24 to 28 bytes (on 32-bit platforms). But even in my main Emacs session,
which has been up for 54 days (with 300MB reserved memory), I only have 10k
symbols, so an extra 40kB of memory usage isn't much overhead.
- [PATCH] Run hook when variable is set, Kelly Dean, 2015/01/28
- Re: [PATCH] Proposal to change cursor appearance to indicate region activation, Kelly Dean, 2015/01/28
- Re: [PATCH] Proposal to change cursor appearance to indicate region activation, David Kastrup, 2015/01/28
- Re: [PATCH] Proposal to change cursor appearance to indicate region activation, David Kastrup, 2015/01/28
- Re: [PATCH] Proposal to change cursor appearance to indicate region activation, Kelly Dean, 2015/01/29
- Re: [PATCH] Proposal to change cursor appearance to indicate region activation, David Kastrup, 2015/01/29
- Re: [PATCH] Proposal to change cursor appearance to indicate region activation,
Kelly Dean <=
- Re: [PATCH] Proposal to change cursor appearance to indicate region activation, David Kastrup, 2015/01/30
- Re: [PATCH] Proposal to change cursor appearance to indicate region activation, Kelly Dean, 2015/01/30
- Re: [PATCH] Proposal to change cursor appearance to indicate region activation, David Kastrup, 2015/01/30
- Re: [PATCH] Proposal to change cursor appearance to indicate region activation, Kelly Dean, 2015/01/30
Re: [PATCH] Run hook when variable is set, Stefan Monnier, 2015/01/28