From: Tom Willemse Date: Sun, 11 Oct 2015 22:45:49 +0000 (+0200) Subject: Fix indenting in perl functions with doc-comments X-Git-Tag: emacs-27.0.90~1365 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=a4688030b4be6e7ef71b6c58c3051fa4bd399d33;p=emacs.git Fix indenting in perl functions with doc-comments * lisp/progmodes/perl-mode.el (perl-calculate-indent): Skip doc-comments as well as comments and skip the entire comment, not just the line. (Bug#21647) --- diff --git a/lisp/progmodes/perl-mode.el b/lisp/progmodes/perl-mode.el index 55ea3417ffd..ab3680bfb76 100644 --- a/lisp/progmodes/perl-mode.el +++ b/lisp/progmodes/perl-mode.el @@ -1007,8 +1007,8 @@ Returns (parse-state) if line starts inside a string." ;; Skip over comments and labels following openbrace. (while (progn (skip-chars-forward " \t\f\n") - (cond ((looking-at ";?#") - (forward-line 1) t) + (cond ((looking-at ";?#\\|^=\\w+") + (forward-comment 1) t) ((looking-at "\\(\\w\\|\\s_\\)+:[^:]") (setq colon-line-end (line-end-position)) (search-forward ":")))))