all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Juri Linkov <juri@jurta.org>
To: martin rudalics <rudalics@gmx.at>
Cc: Chong Yidong <cyd@gnu.org>, emacs-devel@gnu.org
Subject: Re: window-next-buffers
Date: Thu, 24 Nov 2011 21:00:05 +0200	[thread overview]
Message-ID: <8739dduz0q.fsf@mail.jurta.org> (raw)
In-Reply-To: <4ECE159F.8080300@gmx.at> (martin rudalics's message of "Thu, 24 Nov 2011 10:59:59 +0100")

>> 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	other threads:[~2011-11-24 19:00 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-11-24  7:58 window-next-buffers Chong Yidong
2011-11-24  9:24 ` window-next-buffers Chong Yidong
2011-11-24 10:07   ` window-next-buffers martin rudalics
2011-11-24  9:59 ` window-next-buffers martin rudalics
2011-11-24 19:00   ` Juri Linkov [this message]
2011-11-25 10:15     ` window-next-buffers martin rudalics
2011-11-25 10:33       ` window-next-buffers Juri Linkov
2011-11-25 13:55         ` window-next-buffers martin rudalics
2011-11-25 15:11         ` window-next-buffers Stephen J. Turnbull
2011-11-25 16:05           ` window-next-buffers Chong Yidong
2011-11-25 19:02             ` window-next-buffers Juri Linkov
2011-11-26  6:59               ` window-next-buffers Chong Yidong
2011-11-26 11:44               ` window-next-buffers martin rudalics

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=8739dduz0q.fsf@mail.jurta.org \
    --to=juri@jurta.org \
    --cc=cyd@gnu.org \
    --cc=emacs-devel@gnu.org \
    --cc=rudalics@gmx.at \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.