[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: window-next-buffers

From: Juri Linkov
Subject: Re: window-next-buffers
Date: Thu, 24 Nov 2011 21:00:05 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.91 (x86_64-pc-linux-gnu)

>> Maintaining separate prev-history and next-history lists is not very
>> Emacs-y.  Why isn't this a ring?
> Because `window-previous-buffers' returns a list of <buffer window-start
> pos> triples where the latter two are markers and `window-next-buffers'
> a plain list of buffers.  Maintaining markers is expensive, so I wanted
> to reduce the overhead for the next buffers part of the list.

This sounds like an overly optimization.  But actually I can't find
a case where `next-buffer' would fail to get information about markers.
Is this because information about markers of next buffers is retrieved
from `window-prev-buffers'?

> > I do find the window-next-buffers stuff a bit weird, somehow,
> > but it's not important.
> A window's next buffers are only needed while navigating back- and
> forwards through that window's buffers.  They are killed by
> `set-window-buffer' (more precisely by `record-window-buffer').  A
> window's previous buffers are persistent.

Isn't better to push a new window to the top of the list of next buffers
to not lose information about the rest of next buffers?

reply via email to

[Prev in Thread] Current Thread [Next in Thread]