GNU bug report logs -
#21647
24.5; Perl-mode indenting fooled by ...=cut region
Previous Next
Reported by: 積丹尼 Dan Jacobson <jidanni <at> jidanni.org>
Date: Thu, 8 Oct 2015 13:13:02 UTC
Severity: minor
Tags: patch
Found in version 24.5
Fixed in version 27.1
Done: Stefan Kangas <stefan <at> marxist.se>
Bug is archived. No further changes may be made.
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 21647 in the body.
You can then email your comments to 21647 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#21647
; Package
emacs
.
(Thu, 08 Oct 2015 13:13:02 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
積丹尼 Dan Jacobson <jidanni <at> jidanni.org>
:
New bug report received and forwarded. Copy sent to
bug-gnu-emacs <at> gnu.org
.
(Thu, 08 Oct 2015 13:13:02 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
Perl-mode indents the %Y wrong, if %X is commented.
If %X is uncommented, then both will be indented correctly.
if ( $ARGV[0] eq "TAIWAN" ) {
# my %X;
=zz
my %points = (
A => [ 25.08, 120.61 ],
B => [ 25.08, 121.40 ],
);
use constant TAIWAN_MAP => '
_aBC
_dEF
_GH_
jKL_
MNO_
pQR_
_Tu_
_vW';
=cut
my %Y;
}
In GNU Emacs 24.5.1 (i586-pc-linux-gnu, GTK+ Version 3.16.6)
of 2015-09-21 on binet, modified by Debian
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#21647
; Package
emacs
.
(Wed, 14 Oct 2015 22:06:02 GMT)
Full text and
rfc822 format available.
Message #8 received at 21647 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Hey,
The attached patch fixes indentation for the situation described above
in the master branch.
Cheers,
Tom
[0001-Fix-indenting-in-perl-functions-with-doc-comments.patch (text/x-diff, inline)]
From f9296dc710998577434959f7d5af30792cb2df26 Mon Sep 17 00:00:00 2001
From: Tom Willemse <tom <at> ryuslash.org>
Date: Mon, 12 Oct 2015 00:45:49 +0200
Subject: [PATCH] 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.
---
lisp/progmodes/perl-mode.el | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/lisp/progmodes/perl-mode.el b/lisp/progmodes/perl-mode.el
index 55d69bf..b4d7127 100644
--- a/lisp/progmodes/perl-mode.el
+++ b/lisp/progmodes/perl-mode.el
@@ -946,8 +946,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 ":")))))
--
2.6.1
Added tag(s) patch.
Request was from
Stefan Kangas <stefan <at> marxist.se>
to
control <at> debbugs.gnu.org
.
(Sat, 06 Jul 2019 03:33:01 GMT)
Full text and
rfc822 format available.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#21647
; Package
emacs
.
(Sun, 29 Sep 2019 22:12:01 GMT)
Full text and
rfc822 format available.
Message #13 received at 21647 <at> debbugs.gnu.org (full text, mbox):
close 21647 27.1
thanks
Tom Willemse <tom <at> ryuslash.org> writes:
> Hey,
>
> The attached patch fixes indentation for the situation described above
> in the master branch.
Thanks. The patch looks reasonable to me, and also fixes the reported
problem. I've therefore pushed it to master, and I'm closing this bug
report.
Best regards,
Stefan Kangas
bug marked as fixed in version 27.1, send any further explanations to
21647 <at> debbugs.gnu.org and 積丹尼 Dan Jacobson <jidanni <at> jidanni.org>
Request was from
Stefan Kangas <stefan <at> marxist.se>
to
control <at> debbugs.gnu.org
.
(Sun, 29 Sep 2019 22:12:02 GMT)
Full text and
rfc822 format available.
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Mon, 28 Oct 2019 11:24:12 GMT)
Full text and
rfc822 format available.
This bug report was last modified 4 years and 180 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.