|
From: | Dmitry Gutov |
Subject: | Re: xref and leaving "temporary" buffers open |
Date: | Sat, 25 Jul 2015 16:36:14 +0300 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.0 |
On 07/25/2015 11:28 AM, martin rudalics wrote:
I'd try to implement some sort of heuristics, like adding a buffer to some sort of a cache only after its file has been visited by an application (like xref) at least N times and removing a buffer from that cache if it has not been visited by an application (like xref) for at least T minutes.
N > 1 won't help too much. I'm talking about a situation like xref-find-references followed by xref-query-replace. It already gives a performance hit (if there are matches in a lot of different files). And xref-find-references only opens each buffer once already.
What kind of cache?
[Automatic reverting] should be made customizable.
I suppose a user option might govern whether xref will prompt before reverting. But then, will it prompt for each file? There might be a lot.
I think so. Each buffer should maintain a list of all the applications that visited its file and all operations on buffer lists should be aware of it.
You might want to elaborate. This seems to go further than my suggestion.
[Prev in Thread] | Current Thread | [Next in Thread] |