]> code.delx.au - gnu-emacs/commitdiff
(compilation-set-window-height): Rearrange the save-* functions because a buffer...
authorDaniel Pfeiffer <occitan@esperanto.org>
Tue, 8 Jun 2004 21:36:37 +0000 (21:36 +0000)
committerDaniel Pfeiffer <occitan@esperanto.org>
Tue, 8 Jun 2004 21:36:37 +0000 (21:36 +0000)
(compilation-error-regexp-alist-alist): Recognize {standard input} GNU messages (for gcc --pipe) and more kinds of Oracle messages.

lisp/progmodes/compile.el

index 0a1ed9e707765726ec8f8073eb62c951d080bdcc..3a880a4c9eaa3aa2f7e4edfb78b130caafffc5e0 100644 (file)
@@ -210,7 +210,7 @@ of[ \t]+\"?\\([a-zA-Z]?:?[^\":\n]+\\)\"?:" 3 2 nil (1))
 
     (gnu
      "^\\(?:[[:alpha:]][-[:alnum:].]+: ?\\)?\
-\\([/.]*[a-zA-Z]:?[^ \t\n:]*\\): ?\
+\\([/.]*[a-zA-Z]:?[^ \t\n:]*\\|{standard input}\\): ?\
 \\([0-9]+\\)\\([.:]?\\)\\([0-9]+\\)?\
 \\(?:-\\(?:\\([0-9]+\\)\\3\\)?\\.?\\([0-9]+\\)?\\)?:\
 \\(?: *\\(\\(?:Future\\|Runtime\\)?[Ww]arning\\|W:\\)\\|\
@@ -242,7 +242,9 @@ of[ \t]+\"?\\([a-zA-Z]?:?[^\":\n]+\\)\"?:" 3 2 nil (1))
 : \\(?:error\\|warnin\\(g\\)\\) C[0-9]+:" 1 2 nil (3))
 
     (oracle
-     "^Semantic error at line \\([0-9]+\\), column \\([0-9]+\\), file \\(.*\\):$"
+     "^\\(?:Semantic error\\|Error\\|PCC-[0-9]+:\\).* line \\([0-9]+\\)\
+\\(?:\\(?:,\\| at\\)? column \\([0-9]+\\)\\)?\
+\\(?:,\\| in\\| of\\)? file \\(.*?\\):?$"
      3 1 2)
 
     (perl
@@ -988,13 +990,11 @@ exited abnormally with code %d\n"
         ;; If window is alone in its frame, aside from a minibuffer,
         ;; don't change its height.
         (not (eq window (frame-root-window (window-frame window))))
-        ;; This save-current-buffer prevents us from changing the current
-        ;; buffer, which might not be the same as the selected window's buffer.
-        (save-current-buffer
+        ;; Stef said that doing the saves in this order is safer:
+        (save-excursion
           (save-selected-window
-            (save-excursion
-              (select-window window)
-              (enlarge-window (- height (window-height)))))))))
+            (select-window window)
+            (enlarge-window (- height (window-height))))))))
 
 (defvar compilation-menu-map
   (let ((map (make-sparse-keymap "Errors")))