From: Roland McGrath Date: Sun, 26 Feb 1995 21:37:30 +0000 (+0000) Subject: (compilation-buffer-p): Check for compilation-minor-mode or X-Git-Tag: emacs-19.34~5016 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=8fca6c30ae3bf0bb077872abbab5f46b64a5febb;p=emacs.git (compilation-buffer-p): Check for compilation-minor-mode or compilation-mode major mode, rather than internal state variables. Don't want to match a buffer that was once in compilation-minor-mode but is not now. --- diff --git a/lisp/progmodes/compile.el b/lisp/progmodes/compile.el index 4cd464e1c2a..3d879313d05 100644 --- a/lisp/progmodes/compile.el +++ b/lisp/progmodes/compile.el @@ -1,6 +1,6 @@ ;;; compile.el --- run compiler as inferior of Emacs, parse error messages. -;; Copyright (C) 1985, 86, 87, 93, 94 Free Software Foundation, Inc. +;; Copyright (C) 1985, 86, 87, 93, 94, 1995 Free Software Foundation, Inc. ;; Author: Roland McGrath ;; Maintainer: FSF @@ -586,7 +586,7 @@ Just inserts the text, but uses `insert-before-markers'." errors)) (defsubst compilation-buffer-p (buffer) - (assq 'compilation-error-list (buffer-local-variables buffer))) + (or compilation-minor-mode (eq major-mode 'compilation-mode))) (defun compilation-next-error (n) "Move point to the next error in the compilation buffer.