]> git.eshelyaron.com Git - emacs.git/commitdiff
Fix indenting in perl functions with doc-comments
authorTom Willemse <tom@ryuslash.org>
Sun, 11 Oct 2015 22:45:49 +0000 (00:45 +0200)
committerStefan Kangas <stefankangas@gmail.com>
Sun, 29 Sep 2019 22:09:58 +0000 (00:09 +0200)
* 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)

lisp/progmodes/perl-mode.el

index 55ea3417ffd11bcaa6401d054c63458500c73927..ab3680bfb7682a8f86e2194fda2d1f04e1140d30 100644 (file)
@@ -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 ":")))))