From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: "Daniel R. Grayson" Newsgroups: gmane.emacs.bugs Subject: bug#55744: infinite loop Date: Mon, 6 Jun 2022 15:46:02 -0700 Message-ID: References: <878rqh4g1z.fsf@gnus.org> <874k154fbj.fsf@gnus.org> <87v8tl2k18.fsf@gnus.org> <87a6aw4ct3.fsf@gnus.org> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="00000000000083fcee05e0cf3da8" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="13945"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Lars Ingebrigtsen , 55744@debbugs.gnu.org To: rms@gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Jun 07 00:47:27 2022 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nyLVP-0003Ja-2q for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 07 Jun 2022 00:47:27 +0200 Original-Received: from localhost ([::1]:39162 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nyLVN-0005xj-II for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 06 Jun 2022 18:47:25 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:59212) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nyLV0-0005ww-Ts for bug-gnu-emacs@gnu.org; Mon, 06 Jun 2022 18:47:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:43159) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nyLV0-00009h-Ky for bug-gnu-emacs@gnu.org; Mon, 06 Jun 2022 18:47:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1nyLV0-0000cZ-HO for bug-gnu-emacs@gnu.org; Mon, 06 Jun 2022 18:47:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: "Daniel R. Grayson" Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 06 Jun 2022 22:47:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 55744 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: notabug moreinfo Original-Received: via spool by 55744-submit@debbugs.gnu.org id=B55744.16545555902344 (code B ref 55744); Mon, 06 Jun 2022 22:47:02 +0000 Original-Received: (at 55744) by debbugs.gnu.org; 6 Jun 2022 22:46:30 +0000 Original-Received: from localhost ([127.0.0.1]:37056 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nyLUT-0000bk-L8 for submit@debbugs.gnu.org; Mon, 06 Jun 2022 18:46:29 -0400 Original-Received: from mail-lf1-f51.google.com ([209.85.167.51]:36384) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nyLUO-0000bT-To for 55744@debbugs.gnu.org; Mon, 06 Jun 2022 18:46:28 -0400 Original-Received: by mail-lf1-f51.google.com with SMTP id i29so8793536lfp.3 for <55744@debbugs.gnu.org>; Mon, 06 Jun 2022 15:46:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=aLMKEhkMs9NDXV4ZEu4AZQKyJd4mcjup/614dD6wGzk=; b=bIoGw9dyxpVa7Ixpn37RUF2DSG106vYuUdn9jav07d4tREdLqXzcWyS7K+adP2UrO9 xanYKZE2E4yve5GmyPiBFkn9cOkIlZB9QvVXzXzcejdSTVuVNwQ0TBltlFHcl9Vs2Qh4 BIraOxWXSr1oOKq3OZq0yO+gqLw7v/R7hOHPUkWnbyofcUaqAPYpg1oMIvliPKylBQU3 x42kiTD0cOqj2yJkKWpUxavQtPzXWO5JaUGAPEhh5tLCrM5LODus9JohUJp4pCF3t0Cu oK6e3fIbpbbPDJ+bhmwQFmsLeyDO6hfxfxuYx3FaX18oU78hB8NWd8Q9ycFwCeEjYh5U 5JBQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=aLMKEhkMs9NDXV4ZEu4AZQKyJd4mcjup/614dD6wGzk=; b=0sQz+Y4TmSwcycn7ySOr7WJMxS4VaGuXg+GAzoC/BCxf6LHAmgaAQYDf7tPcc+9oZh 6GAX6luftwV4zCphAK7OGvQujFJva4dTTyq5dYKYVMc1M0sQl7fqaiGiQNeNceCaYmxS 15Z+shepecC8o2D7bBLNeTBy+UDHlKHmK5ftruF1DeJifOfGzfguADlERc78KMwukicM JPIxuBM7NUsqkFCrlU9jP8XfNNYzxQJpT5oloCeHYUWe/mclNYI8S0a/ERxO7fsdi8Q3 cnTzR1OiP1OHK/fUXd4ifh7dE+Nv5lRDFUAgQRosUdbyJAZ+7Wh1lXhXBozaVNZXgPnd 7MGQ== X-Gm-Message-State: AOAM532Cc/ygqQVUBERs1HCLIEC0KkjYFr6g2CNsGa+HnIWxu9y+1nn3 rvh59JJ9EV6uUxeJ5zWABPKD/TYA/oQ77ul/aQU= X-Google-Smtp-Source: ABdhPJyzglUolZmE+XCEkwWoWN5uRuD6H+O1iDHiueblD9OP/pYEFL6h2Z2ESghmisXuXm9EfhV0dmiYwdMrNZq4CHo= X-Received: by 2002:a05:6512:32b0:b0:478:f5d3:9a98 with SMTP id q16-20020a05651232b000b00478f5d39a98mr23057754lfe.589.1654555578463; Mon, 06 Jun 2022 15:46:18 -0700 (PDT) In-Reply-To: X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:233826 Archived-At: --00000000000083fcee05e0cf3da8 Content-Type: text/plain; charset="UTF-8" Conceivably, although I wasn't referring to the manual, even after I isolated the offending regexp. On Mon, Jun 6, 2022 at 3:15 PM Richard Stallman wrote: > [[[ To any NSA and FBI agents reading my email: please consider ]]] > [[[ whether defending the US Constitution against all enemies, ]]] > [[[ foreign or domestic, requires you to follow Snowden's example. ]]] > > > That's a regexp with a lot of backtracking, I think (i.e., elements > that > > can be matched both by the ?'s as well as the two *'s). So matching > > this will be slow, which results in the hangs you're seeing when Emacs > > is trying to match that to the text in the buffer. > > Would it make sense to say more about this point in the Emacs Lisp Manual > where it describes regexps? > > -- > Dr Richard Stallman (https://stallman.org) > Chief GNUisance of the GNU Project (https://gnu.org) > Founder, Free Software Foundation (https://fsf.org) > Internet Hall-of-Famer (https://internethalloffame.org) > > > --00000000000083fcee05e0cf3da8 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Conceivably, although I wasn't referring to the manual= , even after I isolated the offending
regexp.=C2=A0=C2=A0
On Mon, = Jun 6, 2022 at 3:15 PM Richard Stallman <= rms@gnu.org> wrote:
[[[ To any NSA and FBI agents reading my email: please consider= =C2=A0 =C2=A0 ]]]
[[[ whether defending the US Constitution against all enemies,=C2=A0 =C2=A0= =C2=A0]]]
[[[ foreign or domestic, requires you to follow Snowden's example. ]]]<= br>
=C2=A0 > That's a regexp with a lot of backtracking, I think (i.e., = elements that
=C2=A0 > can be matched both by the ?'s as well as the two *'s).= =C2=A0 So matching
=C2=A0 > this will be slow, which results in the hangs you're seeing= when Emacs
=C2=A0 > is trying to match that to the text in the buffer.

Would it make sense to say more about this point in the Emacs Lisp Manual where it describes regexps?

--
Dr Richard Stallman (https://stallman.org)
Chief GNUisance of the GNU Project (https://gnu.org)
Founder, Free Software Foundation (https://fsf.org)
Internet Hall-of-Famer (https://internethalloffame.org)


--00000000000083fcee05e0cf3da8--