emacs-devel
[Top][All Lists]
Advanced

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

Re: next-error-last-buffer


From: Juri Linkov
Subject: Re: next-error-last-buffer
Date: Tue, 11 May 2004 02:45:12 +0300
User-agent: Gnus/5.110002 (No Gnus v0.2) Emacs/21.3.50 (gnu/linux)

Stefan Monnier <address@hidden> writes:
>> If you switch to another source buffer that was last reached
>> through C-x ` from a compilation error, then C-x ` will get the
>> next compilation error, rather than the next occurrence.
>> At least, it sounds like your change would have that result.
>
> Indeed.  In order to get the right behavior in all cases, we'd need
> to read the user's mind.  So the current approach at least has the
> advantage of being simple for the user to understand (and thus predict),
> while working correctly for the most common cases.

The current approach is simple, but unusable in real situations.

Imagine for example such a typical scenario:

1. Start compilation.  The compilation buffer is displayed in
another window.

2. Type C-x `.  A source file is visited in the same window.

3. Make a new frame.

4. Run grep or occur.  A grep or occur buffer is displayed in
another window.

5. Type C-x `.  A file found by grep or occur is visited in the same window.

6. Switch back to the initial frame.  Buffers are displayed in the same
state as they were left - with two windows: one with the source buffer
and another with the compilation buffer, and the point in the source
buffer on the line with previous error.

7. Now type C-x `.  What is the most expected behavior when the point
is located in the file visited by C-x ` is that next C-x ` will
find next errors in the same file.

But alas, the buffer is unexpectedly switched to some file which happens
to be the next found by last grep/occur.  This is very confusing.
And even if the user can remember always to switch to the compilation
buffer before typing C-x ` to make it last, it is still too inconvenient.

-- 
Juri Linkov
http://www.jurta.org/emacs/





reply via email to

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