unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Lars Ingebrigtsen <larsi@gnus.org>
To: "Harald Jörg" <haj@posteo.de>
Cc: 10483@debbugs.gnu.org
Subject: bug#10483: [PATCH] cperl-mode: Avoid endless loop
Date: Fri, 04 Sep 2020 05:17:45 +0200	[thread overview]
Message-ID: <87k0xafcx2.fsf@gnus.org> (raw)
In-Reply-To: <922046dc-34fa-487d-4695-6597f8db148e@posteo.de> ("Harald Jörg"'s message of "Tue, 1 Sep 2020 18:12:31 +0200")

Harald Jörg <haj@posteo.de> writes:

> So be it: My attempt to do this is attached, together with tests
> to verify that my loop termination isn't harmful to the function.

Great; I've applied your fix (along with the test) to Emacs 28.

> As always, a review is welcome. I still haven't much experience
> in Elisp.

Looks good to me.  The only detail is that we normally want the first
line of a doc string to be a complete sentence, and in one case it
wasn't:

+(ert-deftest cperl-mode-test-bug-10483 ()
+  "Verifies that a piece of code which ends in a paren without a
+statement terminato ron tne same line does not loop forever.  The

But this is in the test harness, so I don't think we really have much of
a style convention going here, so I didn't fix that up before applying.

> I haven't found examples to steal from, and also missed the
> fork/waitpid stuff which I use for such tasks in Perl.

Yeah...  Perhaps Emacs should grow some convenience functions for this
stuff?

Anyway, the patch fixes the reported bug here, so I'm closing this bug
report.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





  reply	other threads:[~2020-09-04  3:17 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-01-12  0:02 bug#10483: 24.0.92; cperl-indent-exp hangs Eric Hanchrow
2020-08-31 17:06 ` bug#10483: [PATCH] cperl-mode: Avoid endless loop Harald Jörg
2020-08-31 17:24   ` Eli Zaretskii
2020-08-31 18:08     ` Harald Jörg
2020-08-31 18:49       ` Eli Zaretskii
2020-08-31 21:23         ` Stefan Kangas
2020-09-01 16:12         ` Harald Jörg
2020-09-04  3:17           ` Lars Ingebrigtsen [this message]
2020-09-04  7:15             ` Eli Zaretskii
2020-09-04 10:41               ` Lars Ingebrigtsen
2020-09-04 10:51                 ` Andreas Schwab
2020-09-04 10:55                   ` Lars Ingebrigtsen
2020-09-04 11:36                     ` Eli Zaretskii
2020-09-04 12:00                       ` Lars Ingebrigtsen
2020-09-04 12:05                     ` Andreas Schwab
2020-09-04 11:34                 ` Eli Zaretskii
2020-09-04 11:59                   ` Lars Ingebrigtsen
2020-09-04 12:28                     ` Eli Zaretskii
2020-09-04 12:36                       ` Lars Ingebrigtsen
2020-09-04 12:09                   ` Andreas Schwab
2020-10-05 18:30 ` bug#10483: [PATCH] Fix a bogus test introduced by treating (Bug#10483) Harald Jörg
2020-10-06  1:40   ` Lars Ingebrigtsen

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=87k0xafcx2.fsf@gnus.org \
    --to=larsi@gnus.org \
    --cc=10483@debbugs.gnu.org \
    --cc=haj@posteo.de \
    /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).