From: Evgeni Kolev Date: Mon, 27 Mar 2017 06:30:10 +0000 (+0300) Subject: Propertize only perl prototype chars `][$%&*;+@\' as punctuation X-Git-Tag: emacs-26.0.90~522^2~4^2 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=a184a7edc58e1e053aa317a0f162df7e225597e1;p=emacs.git Propertize only perl prototype chars `][$%&*;+@\' as punctuation This prevents variables in signatures such as `sub add ($a, $b)' from being treated as punctuation. * lisp/progmodes/perl-mode.el (perl-syntax-propertize-function): Strictly match only prototype characters as punctuation. (Bug#26037) Copyright-paperwork-exempt: yes --- diff --git a/lisp/progmodes/perl-mode.el b/lisp/progmodes/perl-mode.el index a516f07e72f..b75f32ee200 100644 --- a/lisp/progmodes/perl-mode.el +++ b/lisp/progmodes/perl-mode.el @@ -255,9 +255,11 @@ ;; format statements ("^[ \t]*format.*=[ \t]*\\(\n\\)" (1 (prog1 "\"" (perl-syntax-propertize-special-constructs end)))) - ;; Funny things in `sub' arg-specs like `sub myfun ($)' or `sub ($)'. - ;; Be careful not to match "sub { (...) ... }". - ("\\