emacs-devel
[Top][All Lists]
Advanced

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

Re: switch-to-buffer: for interactive use only


From: Chong Yidong
Subject: Re: switch-to-buffer: for interactive use only
Date: Thu, 07 Jul 2011 16:50:25 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux)

Stefan Monnier <address@hidden> writes:

>> How would you change this?
>
>> (defun unbury-buffer ()
>>   "Switch to the last buffer in the buffer list."
>>   (interactive)
>>   (switch-to-buffer (last-buffer)))
>
> Either using with-no-warnings or using set-window-buffer.

What's wrong with using switch-to-buffer?

If you could elaborate a bit more on what bugs you are referring to when
you say

> Most of those calls were bugs waiting to catch you in Emacs<23 ("you"
> being typically a user like myself who uses dedicated windows and/or
> minibuffer-only frames).

then maybe we could come up with a way to issue the warning more
selectively.  Because AFAICT the usage in unbury-buffer, and probably
many other places in Emacs, is completely correct, and I agree with
Glenn that issuing a zillion warnings for this not satisfactory.



reply via email to

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