X-Git-Url: https://code.delx.au/gnu-emacs/blobdiff_plain/2c302df3a13236bfbf8ea1b771d13618fcda8d71..69c41c4070c86baac11a627e9c3d366420aeb7cc:/lisp/progmodes/fortran.el diff --git a/lisp/progmodes/fortran.el b/lisp/progmodes/fortran.el index c8bbbf4834..665b0767b2 100644 --- a/lisp/progmodes/fortran.el +++ b/lisp/progmodes/fortran.el @@ -1,8 +1,6 @@ ;;; fortran.el --- Fortran mode for GNU Emacs -;; Copyright (C) 1986, 1993, 1994, 1995, 1997, 1998, 1999, 2000, 2001, -;; 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 -;; Free Software Foundation, Inc. +;; Copyright (C) 1986, 1993-1995, 1997-2012 Free Software Foundation, Inc. ;; Author: Michael D. Prange ;; Maintainer: Glenn Morris @@ -31,7 +29,7 @@ ;; form. For editing Fortran 90 free format source, use `f90-mode' ;; (f90.el). It is meant to support the GNU Fortran language ;; implemented by g77 (its extensions to Fortran77 and -;; interpretations, e.g. of blackslash in strings). +;; interpretations, e.g. of backslash in strings). ;;; History: @@ -167,7 +165,7 @@ allow trailing comments on a line." (defcustom fortran-directive-re "^[ \t]*#.*" "Regexp to match a directive line. -The matching text will be fontified with `font-lock-keyword-face'. +The matching text will be fontified with `font-lock-preprocessor-face'. The matching line will be given zero indentation." :version "22.1" :type 'regexp @@ -293,7 +291,7 @@ buffer). This corresponds to the g77 compiler option :type 'integer :safe 'integerp :initialize 'custom-initialize-default - :set (lambda (symbol value) + :set (lambda (_symbol value) ;; Do all fortran buffers, and the default. (fortran-line-length value t)) :version "23.1" @@ -454,7 +452,7 @@ The only difference is, it returns t in a case when the default returns nil." ;; Standard continuation character and in a TAB-formatted line. '("^ \\{5\\}\\([^ 0\n]\\)" 1 font-lock-string-face) '("^\t\\([1-9]\\)" 1 font-lock-string-face)) - `((,fortran-directive-re (0 font-lock-keyword-face t))) + `((,fortran-directive-re (0 font-lock-preprocessor-face t))) ;; `fortran-font-lock-keywords-2' without types (see above). (cdr (nthcdr (length fortran-font-lock-keywords-1) fortran-font-lock-keywords-2))) @@ -494,7 +492,7 @@ This varies according to the value of LINE-LENGTH. This is used to fontify fixed-format Fortran comments." ;; This results in a non-byte-compiled function. We could pass it through ;; `byte-compile', but simple benchmarks indicate that it's probably not - ;; worth the trouble (about ½% of slow down). + ;; worth the trouble (about 0.5% of slow down). (eval ;I hate `eval', but it's hard to avoid it here. `(syntax-propertize-rules ("^[cd\\*]" (0 "<")) @@ -573,7 +571,7 @@ in the Fortran entry in `hs-special-modes-alist'.") ;; An alternative is to match on THEN at a line end, eg: ;; ".*)[ \t]*then[ \t]*\\($\\|!\\)" ;; This would also match ELSE branches, though. This does not seem - ;; right to me, because then one has neighbouring blocks that are + ;; right to me, because then one has neighboring blocks that are ;; not nested in each other. "\\(if[ \t]*(\\(.*\\|" ".*\n\\([^if]*\\([^i].\\|.[^f]\\|.\\>\\)\\)\\)\\