[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
compilation-last-buffer and compilation-minor-mode
From: |
Stefan Monnier |
Subject: |
compilation-last-buffer and compilation-minor-mode |
Date: |
Mon, 20 Mar 2006 16:46:22 -0500 |
User-agent: |
Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux) |
In Emacs-21, calling compilation-minor-mode used to set
compilation-last-buffer to the current-buffer. In Emacs-CVS this is not the
case any more. The change that causes this is:
2004-04-21 Teodor Zlatanov <address@hidden>
* simple.el (next-error-last-buffer, next-error-function):
New variables for the next-error framework.
(next-error-buffer-p): New function.
(next-error-find-buffer): Generalize compilation-find-buffer.
(next-error, previous-error, first-error, next-error-no-select)
(previous-error-no-select): Move from compile.el.
* replace.el (occur-next-error, occur-1): Hook into the next-error
framework.
* progmodes/compile.el (compilation-start):
Set next-error-last-buffer so next-error knows where to jump.
(compilation-setup): Set the buffer-local variable
next-error-function to 'compilation-next-error-function.
(compilation-buffer-p, compilation-buffer-internal-p): Use an
alternate way to find if a buffer is a compilation buffer, for
next-error convenience.
(next-error-no-select, previous-error-no-select, next-error)
(previous-error, first-error): Move to simple.el.
(compilation-find-buffer): Move to next-error-find-buffer in simple.el.
(compilation-last-buffer): Remove.
(compilation-start, compilation-next-error, compilation-setup)
(compilation-next-error-function, compilation-find-buffer):
Remove compilation-last-buffer use.
The problem with this change is that for packages which use an inferior
(comint) interactive process to do the compilation (such as sml-mode,
haskell-mode, etc...), C-x ` doesn't work from the source buffer any more
(at least not until you used it from the comint buffer).
Now, the only place where compilation-last-buffer (aka
next-error-last-buffer) is set is in `compilation-start', which can't be
used for those cases.
So should we revert this part of the above change, or should sml-mode and
haskell-mode just manually set next-error-last-buffer, or should we introduce
a function that they can call?
Stefan
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- compilation-last-buffer and compilation-minor-mode,
Stefan Monnier <=