Mercurial > emacs
diff lisp/font-lock.el @ 70530:958e92b75789
(cpp-font-lock-keywords-source-directives): Addded
"warning" and "import".
(cpp-font-lock-keywords): Added "warning".
author | Masatake YAMATO <jet@gyve.org> |
---|---|
date | Tue, 09 May 2006 04:07:25 +0000 |
parents | caf8f09897bc |
children | d254902ce935 1321f6cfb389 146cd8369025 |
line wrap: on
line diff
--- a/lisp/font-lock.el Mon May 08 23:21:34 2006 +0000 +++ b/lisp/font-lock.el Tue May 09 04:07:25 2006 +0000 @@ -1974,17 +1974,17 @@ ;; ;; (regexp-opt ;; '("define" "elif" "else" "endif" "error" "file" "if" "ifdef" -;; "ifndef" "include" "line" "pragma" "undef")) +;; "ifndef" "import" "include" "line" "pragma" "undef" "warning")) ;; (defconst cpp-font-lock-keywords-source-directives - "define\\|e\\(?:l\\(?:if\\|se\\)\\|ndif\\|rror\\)\\|file\\|i\\(?:f\\(?:n?def\\)?\\|nclude\\)\\|line\\|pragma\\|undef" + "define\\|e\\(?:l\\(?:if\\|se\\)\\|ndif\\|rror\\)\\|file\\|i\\(?:f\\(?:n?def\\)?\\|mport\\|nclude\\)\\|line\\|pragma\\|undef\\|warning" "Regular expressoin used in `cpp-font-lock-keywords'.") ;; `cpp-font-lock-keywords-source-depth' is calculated from: ;; ;; (regexp-opt-depth (regexp-opt ;; '("define" "elif" "else" "endif" "error" "file" "if" "ifdef" -;; "ifndef" "include" "line" "pragma" "undef"))) +;; "ifndef" "import" "include" "line" "pragma" "undef" "warning"))) ;; (defconst cpp-font-lock-keywords-source-depth 0 "An integer representing regular expression depth of `cpp-font-lock-keywords-source-directives'. @@ -1996,7 +1996,7 @@ (list ;; ;; Fontify error directives. - '("^#[ \t]*error[ \t]+\\(.+\\)" 1 font-lock-warning-face prepend) + '("^#[ \t]*\\(?:error\\|warning\\)[ \t]+\\(.+\\)" 1 font-lock-warning-face prepend) ;; ;; Fontify filenames in #include <...> preprocessor directives as strings. '("^#[ \t]*\\(?:import\\|include\\)[ \t]*\\(<[^>\"\n]*>?\\)"