Commit 2394b5c2 authored by Barry Warsaw's avatar Barry Warsaw

(python-font-lock-keywords): Add highlighting of `as' as a keyword,

but only in "import foo as bar" statements (including optional
preceding `from' clause).
parent 460c7eb3
......@@ -332,6 +332,8 @@ support for features needed by `python-mode'.")
;; block introducing keywords with immediately following colons.
;; Yes "except" is in both lists.
(cons (concat "\\b\\(" kw2 "\\)[ \n\t(]") 1)
;; `as' but only in "import foo as bar"
'("[ \t]*\\(\\bfrom\\b.*\\)?\\bimport\\b.*\\b\\(as\\)\\b" . 2)
;; classes
'("\\bclass[ \t]+\\([a-zA-Z_]+[a-zA-Z0-9_]*\\)"
1 font-lock-type-face)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment