Mercurial > emacs
changeset 79514:4ad6fcfba45b
(perl-font-lock-syntactic-keywords): Don't match "sub { (...) ... }".
author | Stefan Monnier <monnier@iro.umontreal.ca> |
---|---|
date | Fri, 30 Nov 2007 19:21:33 +0000 |
parents | 793a7a37a103 |
children | 610f486c0c19 |
files | lisp/ChangeLog lisp/progmodes/perl-mode.el |
diffstat | 2 files changed, 10 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/ChangeLog Fri Nov 30 16:09:01 2007 +0000 +++ b/lisp/ChangeLog Fri Nov 30 19:21:33 2007 +0000 @@ -1,3 +1,8 @@ +2007-11-30 Stefan Monnier <monnier@iro.umontreal.ca> + + * progmodes/perl-mode.el (perl-font-lock-syntactic-keywords): + Don't match "sub { (...) ... }". + 2007-11-29 Richard Stallman <rms@gnu.org> * international/mule-cmds.el (toggle-input-method-active): New var. @@ -45,8 +50,8 @@ 2007-11-16 Eli Zaretskii <eliz@gnu.org> - * international/mule-cmds.el (set-locale-environment): Set - default-file-name-coding-system _after_ keyboard and terminal + * international/mule-cmds.el (set-locale-environment): + Set default-file-name-coding-system _after_ keyboard and terminal coding systems. This fixes last change. * mail/rmail.el (rmail-current-subject-regexp): Allow more than
--- a/lisp/progmodes/perl-mode.el Fri Nov 30 16:09:01 2007 +0000 +++ b/lisp/progmodes/perl-mode.el Fri Nov 30 19:21:33 2007 +0000 @@ -266,7 +266,9 @@ ;; format statements ("^[ \t]*format.*=[ \t]*\\(\n\\)" (1 '(7))) ;; Funny things in sub arg specifications like `sub myfunc ($$)' - ("\\<sub\\s-+\\S-+\\s-*(\\([^)]+\\))" 1 '(1)) + ;; Be careful not to match "sub { (...) ... }". + ("\\<sub[[:space:]]+[^{}[:punct:][:space:]]+[[:space:]]*(\\([^)]+\\))" + 1 '(1)) ;; Regexp and funny quotes. ("\\(?:[?:.,;=!~({[]\\|\\(^\\)\\)[ \t\n]*\\(/\\)" (2 (if (and (match-end 1)