From: Stefan Monnier Date: Tue, 22 Mar 2005 19:43:13 +0000 (+0000) Subject: (perl-font-lock-keywords-2): X-Git-Tag: ttn-vms-21-2-B4~1624 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=44ebeb1b6ea04630f98f18c296ae098fc400dcbd;p=emacs.git (perl-font-lock-keywords-2): Accept qualified variable and function names. --- diff --git a/lisp/progmodes/perl-mode.el b/lisp/progmodes/perl-mode.el index c65ae0d284e..6fcd16e97c6 100644 --- a/lisp/progmodes/perl-mode.el +++ b/lisp/progmodes/perl-mode.el @@ -207,11 +207,11 @@ The expansion is entirely correct because it uses the C preprocessor." '("\\<\\(local\\|my\\)\\>" . font-lock-type-face) ;; ;; Fontify function, variable and file name references. - '("&\\(\\sw+\\)" 1 font-lock-function-name-face) + '("&\\(\\sw+\\(::\\sw+\\)*\\)" 1 font-lock-function-name-face) ;; Additionally underline non-scalar variables. Maybe this is a bad idea. ;;'("[$@%*][#{]?\\(\\sw+\\)" 1 font-lock-variable-name-face) - '("[$*]{?\\(\\sw+\\)" 1 font-lock-variable-name-face) - '("\\([@%]\\|\\$#\\)\\(\\sw+\\)" + '("[$*]{?\\(\\sw+\\(::\\sw+\\)*\\)" 1 font-lock-variable-name-face) + '("\\([@%]\\|\\$#\\)\\(\\sw+\\(::\\sw+\\)*\\)" (2 (cons font-lock-variable-name-face '(underline)))) '("<\\(\\sw+\\)>" 1 font-lock-constant-face) ;;