diff options
author | Evgeni Kolev <evgenysw@gmail.com> | 2018-03-03 13:07:26 +0200 |
---|---|---|
committer | Eli Zaretskii <eliz@gnu.org> | 2018-03-03 13:07:26 +0200 |
commit | f9dfad9358b2af36d1496c525585f761c130f095 (patch) | |
tree | d4d094a7ad598d9656e213e851b378b27567feb0 /lisp | |
parent | ed071fa79c05e88a2ec3830c0813ed94544854b2 (diff) | |
download | emacs-f9dfad9358b2af36d1496c525585f761c130f095.tar.gz |
Fix font-lock in perl-mode
* lisp/progmodes/perl-mode.el (perl-font-lock-keywords-1): Prevent
the regexp from matching keywords if they start with a Perl sigil.
(Bug#30549)
Diffstat (limited to 'lisp')
-rw-r--r-- | lisp/progmodes/perl-mode.el | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lisp/progmodes/perl-mode.el b/lisp/progmodes/perl-mode.el index 99480788f50..c1d94acfa59 100644 --- a/lisp/progmodes/perl-mode.el +++ b/lisp/progmodes/perl-mode.el @@ -165,7 +165,7 @@ ;; Fontify function and package names in declarations. ("\\<\\(package\\|sub\\)\\>[ \t]*\\(\\sw+\\)?" (1 font-lock-keyword-face) (2 font-lock-function-name-face nil t)) - ("\\<\\(import\\|no\\|require\\|use\\)\\>[ \t]*\\(\\sw+\\)?" + ("\\(^\\|[^$@%&\\]\\)\\<\\(import\\|no\\|require\\|use\\)\\>[ \t]*\\(\\sw+\\)?" (1 font-lock-keyword-face) (2 font-lock-constant-face nil t))) "Subdued level highlighting for Perl mode.") |