]> git.eshelyaron.com Git - emacs.git/commitdiff
(f90-font-lock-keywords-1): Fix highlighting of `type' forms.
authorGlenn Morris <rgm@gnu.org>
Sat, 3 Aug 2002 16:57:43 +0000 (16:57 +0000)
committerGlenn Morris <rgm@gnu.org>
Sat, 3 Aug 2002 16:57:43 +0000 (16:57 +0000)
(f90-font-lock-keywords-2): Fix highlighting of `implicit type(foo)' forms.
(f90-type-def-re): Fix value.

lisp/ChangeLog
lisp/progmodes/f90.el

index fd3be9a816681b7272c425cc3ecfa657c831444c..630e4a40ae637cf2cc5c3bf52886db5ce4894d4d 100644 (file)
@@ -1,3 +1,10 @@
+2002-08-03  Glenn Morris  <gmorris@ast.cam.ac.uk>
+
+       * progmodes/f90.el (f90-font-lock-keywords-1): Fix highlighting of
+       `type' forms.
+       (f90-font-lock-keywords-2): Fix `implicit type(foo)' case.
+       (f90-type-def-re): Fix value.
+
 2002-08-03  Kai Gro\e,b_\e(Bjohann  <Kai.Grossjohann@CS.Uni-Dortmund.DE>
 
        * net/tramp.el: Version 2.0.6.
index 097f0bcba6b5e9fe376722cc71d4fc360ed4bc71..3c73fab604eb02baf3cb7abbd6383890ea6e2f0c 100644 (file)
@@ -340,11 +340,12 @@ The options are 'downcase-word, 'upcase-word, 'capitalize-word and nil."
    ;; Special highlighting of "module procedure".
    '("\\<\\(module[ \t]*procedure\\)\\>" (1 font-lock-keyword-face))
    ;; Highlight declaration of derived type.
-;;;   '("\\<\\(type\\)[ \t]*\\(.*::[ \t]*\\|[ \t]+\\)\\(\\sw+\\)"
-;;;     (1 font-lock-keyword-face) (3 font-lock-function-name-face))
+   '("\\<\\(\\(?:end[ \t]*\\)?type\\)\\>[ \t]*\\([^()\n]*::[ \t]*\\)?\
+\\(\\sw+\\)"
+     (1 font-lock-keyword-face) (3 font-lock-function-name-face))
    ;; Other functions and declarations.
    '("\\<\\(\\(?:end[ \t]*\\)?\\(program\\|module\\|function\\|\
-subroutine\\|type\\)\\|use\\|call\\)\\>[ \t]*\\(\\sw+\\)?"
+subroutine\\)\\|use\\|call\\)\\>[ \t]*\\(\\sw+\\)?"
      (1 font-lock-keyword-face) (3 font-lock-function-name-face nil t))
    "\\<\\(\\(end[ \t]*\\)?\\(interface\\|block[ \t]*data\\)\\|contains\\)\\>")
   "This does fairly subdued highlighting of comments and function calls.")
@@ -366,7 +367,7 @@ do\\([ \t]*while\\)?\\|select[ \t]*case\\|where\\|forall\\)\\)\\>"
       (2 font-lock-constant-face nil t) (3 font-lock-keyword-face))
     ;; Implicit declaration.
     '("\\<\\(implicit\\)[ \t]*\\(real\\|integer\\|c\\(haracter\\|omplex\\)\
-\\|logical\\|type[ \t]*(\\sw+)\\|none\\)\\>"
+\\|logical\\|type[ \t]*(\\sw+)\\|none\\)[ \t]*"
       (1 font-lock-keyword-face) (2 font-lock-type-face))
     '("\\<\\(namelist\\|common\\)[ \t]*\/\\(\\sw+\\)?\/"
       (1 font-lock-keyword-face) (2 font-lock-constant-face nil t))
@@ -632,7 +633,7 @@ do\\([ \t]*while\\)?\\|select[ \t]*case\\|where\\|forall\\)\\)\\>"
   "Regexp matching the end of a TYPE, INTERFACE, BLOCK DATA section.")
 
 (defconst f90-type-def-re
-  "\\<\\(type\\)[ \t]+\\(\\sw+\\)\\>"
+  "\\<\\(type\\)\\>[ \t]*\\(?:[^()\n]*::[ \t]*\\)?\\(\\sw+\\)"
   "Regexp matching the definition of a derived type.")
 
 (defconst f90-no-break-re