unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Stefan Kangas <stefankangas@gmail.com>
To: Mauro Aranda <maurooaranda@gmail.com>
Cc: "積丹尼 Dan Jacobson" <jidanni@jidanni.org>, 35925-done@debbugs.gnu.org
Subject: bug#35925: perl-mode wrecks formats
Date: Sat, 30 Sep 2023 19:17:01 -0700	[thread overview]
Message-ID: <CADwFkmkDfbJHdRTrfF__gGeDhQ1uWEkZVr9fxcANi2dhubZ9zg@mail.gmail.com> (raw)
In-Reply-To: <08ea891e-55fc-145d-17fd-efd7c779f1d8@gmail.com> (Mauro Aranda's message of "Sat, 16 Sep 2023 20:03:14 -0300")

Version: 30.1

Mauro Aranda <maurooaranda@gmail.com> writes:

> 積丹尼 Dan Jacobson <jidanni@jidanni.org> writes:
>
>> In perl-mode,
>>
>> format FH =
>> @<< @# @<< @### @<<<<< @# @<<<< @#
>> (split)[0..5, 7..8]
>> .
>> write FH;
>>
>> becomes
>>
>> format FH =
>>     @<< @# @<< @### @<<<<< @# @<<<< @#
>>     (split)[0..5, 7..8]
>>     .
>>     write FH;
>>
>> wrecking output indentation and even introducing a syntax error on the "."
>  line.
>>
>> (See man perlform.)
>>
>> Seen with C-x h TAB, emacs-version "26.1".
>
> AFAICS, perl-mode doesn't recognize a format declaration when indenting.
> I attach a patch that adds a check, plus some tests.

Thanks, installed on master.

[1: 7caa3f5499b]: 2023-10-01 04:13:17 +0200
  Fix indentation in perl-mode (Bug#35925)
  https://git.savannah.gnu.org/cgit/emacs.git/commit/?id=7caa3f5499b1ca4b6d66c1655a4e0d6903755679





      reply	other threads:[~2023-10-01  2:17 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-27 13:11 bug#35925: perl-mode wrecks formats 積丹尼 Dan Jacobson
2019-07-09  2:11 ` Lars Ingebrigtsen
2019-07-09  9:06   ` 積丹尼 Dan Jacobson
2019-07-09 12:08     ` Lars Ingebrigtsen
2019-07-09 12:18       ` 積丹尼 Dan Jacobson
2019-07-09 15:11       ` Eli Zaretskii
2023-09-16 23:03 ` Mauro Aranda
2023-10-01  2:17   ` Stefan Kangas [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CADwFkmkDfbJHdRTrfF__gGeDhQ1uWEkZVr9fxcANi2dhubZ9zg@mail.gmail.com \
    --to=stefankangas@gmail.com \
    --cc=35925-done@debbugs.gnu.org \
    --cc=jidanni@jidanni.org \
    --cc=maurooaranda@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).