# HG changeset patch # User Roland McGrath # Date 793834650 0 # Node ID 076c2c2b4f06cf955ae3e208df76699c95caaeb3 # Parent 88926963f1aec26d6a7eebebcb54600b2ffdd22f (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 -r 88926963f1ae -r 076c2c2b4f06 lisp/progmodes/compile.el --- a/lisp/progmodes/compile.el Sun Feb 26 21:05:42 1995 +0000 +++ b/lisp/progmodes/compile.el Sun Feb 26 21:37:30 1995 +0000 @@ -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 @@ 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.