In JDE 2.3.4 under XEmacs 21.4.14 on Fedora Core 1, we've found that
running jde-javadoc-make-buffer and friends leaves emacs in an annoying
state.  Every subsequent compilation, even if unrelated to javadoc,
tries to tell your browser to view the last javadoc generated.  This
affects all compilations that go via the machinery behind "M-x compile",
including "M-x grep".

The "diff -u" patch below does seem to fix the problem, by avoiding a
global assignment to the compilation-finish-function variable.

Having said that, it is noticeable that all but one of the
compilation-finish-functions in the JDE end by setting it back to nil
themselves.  The exception is the one bound to jde-javadoc-maker's
comp-finish-fcn instance variable.  It almost looks as though someone
wanted to factor out the management of compilation-finish-function into
the efc-compiler class, but didn't get as far as restoring the nil value
once the subclass comp-finish-fcn has run.

Cheers,

---- Dave


--- efc.el.orig 2004-10-17 03:47:00.000000000 +0100 +++ efc.el 2004-12-08 11:26:53.000000000 +0000 @@ -497,7 +497,8 @@ nomessage-regexp-alist)))

       (if (slot-boundp this 'comp-finish-fcn)
-         (setq compilation-finish-function (oref this comp-finish-fcn)))
+         (set (make-local-variable 'compilation-finish-function)
+              (oref this comp-finish-fcn)))

       (setq default-directory thisdir
            compilation-directory-stack (list default-directory)))))

Reply via email to