]> code.delx.au - gnu-emacs/blobdiff - lisp/progmodes/make-mode.el
(grep-default-command): Use find-tag-default.
[gnu-emacs] / lisp / progmodes / make-mode.el
index ae977b1e52e74db9b35222628ec9d0d8c76b4ed2..c887b14496508ba4535a619e84d3c37ac86be1f9 100644 (file)
@@ -8,11 +8,6 @@
 ;; Adapted-By: ESR
 ;; Keywords: unix, tools
 
-;; RMS:
-;; This needs work.
-;; Also, the doc strings need fixing: the first line doesn't stand alone,
-;; and other usage is not high quality.  Symbol names don't have `...'.
-
 ;; This file is part of GNU Emacs.
 
 ;; GNU Emacs is free software; you can redistribute it and/or modify
@@ -63,6 +58,7 @@
 ;;
 ;; To Do:
 ;;
+;; * Add missing doc strings, improve terse doc strings.
 ;; * Eliminate electric stuff entirely.
 ;; * It might be nice to highlight targets differently depending on
 ;;   whether they are up-to-date or not.  Not sure how this would
@@ -301,9 +297,14 @@ not be enclosed in { } or ( )."
    '("^\\( +\\)\t" 1 makefile-space-face)))
 
 (defconst makefile-font-lock-syntactic-keywords
-  (list
-   ;; Change the syntax of a quoted newline so that it does not end a comment.
-   '("\\\\\n" 0 " ")))
+  ;; From sh-script.el.
+  ;; A `#' begins a comment in sh when it is unquoted and at the beginning
+  ;; of a word.  In the shell, words are separated by metacharacters.
+  ;; The list of special chars is taken from the single-unix spec of the
+  ;; shell command language (under `quoting') but with `$' removed.
+  '(("[^|&;<>()`\\\"' \t\n]\\(#+\\)" 1 "_")
+    ;; Change the syntax of a quoted newline so that it does not end a comment.
+    ("\\\\\n" 0 ".")))
 
 (defvar makefile-imenu-generic-expression
   (list
@@ -1369,7 +1370,7 @@ and generates the overview, one line per target name."
   (delete-file filename))              ; remove the tmpfile
 
 (defun makefile-query-by-make-minus-q (target &optional filename)
-  (not (zerop
+  (not (eq 0
        (call-process makefile-brave-make nil nil nil
                      "-f" filename "-q" target))))