GNU bug report logs -
#79271
30.1; cperl-mode regexp indent issue
Previous Next
Full log
View this message in rfc822 format
> From: John C <john.ciolfi.32 <at> gmail.com>
> Date: Tue, 19 Aug 2025 13:43:14 -0400
>
> 1. In a temporary directory, say ~/tmp/, get latest cperl-mode.el from
> https://github.com/emacs-mirror/emacs/blob/master/lisp/progmodes/cperl-mode.el
> I used the Jul-28-2025 version
>
> https://github.com/emacs-mirror/emacs/blob/cef4302d309e26c2191821ba998518fb89fff54e/lisp/progmodes/cperl-mode.el
>
>
> 2. cd ~/tmp
>
> 3. emacs -Q -L . # Using emacs 30.1
>
> 4. M-x byte-compile-file RET cperl-mode.el RET
>
> 5. C-x C-f foo.pl
>
> C-x h # select all of foo.pl
> C-M-\ # indent foo.pl
>
> Here's the indented foo.pl:
>
> # -*- mode: cperl -*-
> my $str =~ s/^
> (Field1: [^\n]+) \s*
> Field2: \s* (\S+) \s*
> //xsm;
>
> Notice that the regexp is not indented nicely. I would expect "Field2 ..." to be aligned under
> "(Field...)":
>
> my $str =~ s/^
> (Field1: [^\n]+) \s*
> Field2: \s* (\S+) \s*
> //xsm;
And this one, too.
This bug report was last modified 20 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.