GNU logs - #54017, boring messages


Message sent to bug-gnu-emacs@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: bug#54017: add regexp translation option to read-regexp
Resent-From: emacsq <laszlomail@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: bug-gnu-emacs@HIDDEN
Resent-Date: Tue, 15 Feb 2022 20:22:01 +0000
Resent-Message-ID: <handler.54017.B.164495651122662 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: report 54017
X-GNU-PR-Package: emacs
X-GNU-PR-Keywords: 
To: 54017 <at> debbugs.gnu.org
X-Debbugs-Original-To: "Bug reports for GNU Emacs, the Swiss army knife of text editors" <bug-gnu-emacs@HIDDEN>
Reply-To: emacsq <laszlomail@HIDDEN>
Received: via spool by submit <at> debbugs.gnu.org id=B.164495651122662
          (code B ref -1); Tue, 15 Feb 2022 20:22:01 +0000
Received: (at submit) by debbugs.gnu.org; 15 Feb 2022 20:21:51 +0000
Received: from localhost ([127.0.0.1]:46570 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nK4Kd-0005tS-4i
	for submit <at> debbugs.gnu.org; Tue, 15 Feb 2022 15:21:51 -0500
Received: from lists.gnu.org ([209.51.188.17]:42420)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <laszlomail@HIDDEN>) id 1nK4Kb-0005tI-Ge
 for submit <at> debbugs.gnu.org; Tue, 15 Feb 2022 15:21:49 -0500
Received: from eggs.gnu.org ([209.51.188.92]:51652)
 by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <laszlomail@HIDDEN>)
 id 1nK4Kb-000523-Be
 for bug-gnu-emacs@HIDDEN; Tue, 15 Feb 2022 15:21:49 -0500
Received: from mail-40141.protonmail.ch ([185.70.40.141]:50569)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <laszlomail@HIDDEN>)
 id 1nK4KY-0006iy-70
 for bug-gnu-emacs@HIDDEN; Tue, 15 Feb 2022 15:21:48 -0500
Date: Tue, 15 Feb 2022 20:21:35 +0000
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com;
 s=protonmail3; t=1644956497;
 bh=Om/cl0wbt/ort2HVtAua49TrBpp/Rrt4nDfJi+x91EU=;
 h=Date:To:From:Reply-To:Subject:Message-ID:From:To:Cc:Date:Subject:
 Reply-To:Feedback-ID:Message-ID;
 b=nTVC05XDDUeUFg8ga9ch3k3MYiTEq1Ly+Kw33tTMrpL2wtmYWzOuIbd7GHlC9VCiD
 o279UuFQxqc8y427ovGv+OMyn6Tk4E/YkcgTzYnuHaLGNi3oxceWJVI+dop9SmxSnD
 m7AAv7tB1ZX0LbxfWMe1TdbbYcOs9s08z46SCJYlGLse/MlEIr/ngz4VesD6pF5e1D
 JtzQGbqi5hcB0G3+rHe///nek3rC2hKaxaxl3N2IfzzcyJ4+Tm5ynioacR2inQJ3tQ
 uNftJkhPSoGCjzAKFg3i2Tlcud4LTIaL0ueyGwkAAdsTTNHdIJ72LPHp0WHUSFYJCu
 g2E3phBGn6MBA==
From: emacsq <laszlomail@HIDDEN>
Message-ID: <pml_I1y3BHYiUQCE1X45lx3leJ8mMRTwOclJd1qV7BDsVLjchfTfiqBFA4VwpHZACnp5pQmyPcD2biU-MEeM1tm9rURQhGuslCqCt3bWZAg=@protonmail.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
X-Spam-Status: No, score=-1.2 required=10.0 tests=ALL_TRUSTED,DKIM_SIGNED,
 DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,
 T_SCC_BODY_TEXT_LINE shortcircuit=no autolearn=disabled version=3.4.4
X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on
 mailout.protonmail.ch
Received-SPF: pass client-ip=185.70.40.141;
 envelope-from=laszlomail@HIDDEN; helo=mail-40141.protonmail.ch
X-Spam_score_int: -20
X-Spam_score: -2.1
X-Spam_bar: --
X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1,
 DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001,
 SPF_HELO_PASS=-0.001, SPF_PASS=-0.001,
 T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no
X-Spam_action: no action
X-Spam-Score: 0.2 (/)
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -2.3 (--)

Suppose, the user wants to use ( ) for capturing and
\( \) for matching parens. He provides a function
which does this translation.

If this new option is set and is a function which does
the translation then read-regexp will

- accept the format which the user prefers, in this case
( ... ) for capturing.

- store regexps in this format in history, so the user
can work with the user's preferred format even when
retrieving history entries.

- return the elisp format regexp by calling the function
provided by the user which does the translation.




Message sent:


Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable
MIME-Version: 1.0
X-Mailer: MIME-tools 5.505 (Entity 5.505)
Content-Type: text/plain; charset=utf-8
X-Loop: help-debbugs@HIDDEN
From: help-debbugs@HIDDEN (GNU bug Tracking System)
To: emacsq <laszlomail@HIDDEN>
Subject: bug#54017: Acknowledgement (add regexp translation option to
 read-regexp)
Message-ID: <handler.54017.B.164495651122662.ack <at> debbugs.gnu.org>
References: <pml_I1y3BHYiUQCE1X45lx3leJ8mMRTwOclJd1qV7BDsVLjchfTfiqBFA4VwpHZACnp5pQmyPcD2biU-MEeM1tm9rURQhGuslCqCt3bWZAg=@protonmail.com>
X-Gnu-PR-Message: ack 54017
X-Gnu-PR-Package: emacs
Reply-To: 54017 <at> debbugs.gnu.org
Date: Tue, 15 Feb 2022 20:22:01 +0000

Thank you for filing a new bug report with debbugs.gnu.org.

This is an automatically generated reply to let you know your message
has been received.

Your message is being forwarded to the package maintainers and other
interested parties for their attention; they will reply in due course.

Your message has been sent to the package maintainer(s):
 bug-gnu-emacs@HIDDEN

If you wish to submit further information on this problem, please
send it to 54017 <at> debbugs.gnu.org.

Please do not send mail to help-debbugs@HIDDEN unless you wish
to report a problem with the Bug-tracking system.

--=20
54017: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D54017
GNU Bug Tracking System
Contact help-debbugs@HIDDEN with problems


Message sent to bug-gnu-emacs@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: bug#54017: add regexp translation option to read-regexp
Resent-From: Juri Linkov <juri@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: bug-gnu-emacs@HIDDEN
Resent-Date: Wed, 16 Feb 2022 18:45:04 +0000
Resent-Message-ID: <handler.54017.B54017.164503708623261 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: followup 54017
X-GNU-PR-Package: emacs
X-GNU-PR-Keywords: 
To: emacsq <laszlomail@HIDDEN>
Cc: 54017 <at> debbugs.gnu.org
Received: via spool by 54017-submit <at> debbugs.gnu.org id=B54017.164503708623261
          (code B ref 54017); Wed, 16 Feb 2022 18:45:04 +0000
Received: (at 54017) by debbugs.gnu.org; 16 Feb 2022 18:44:46 +0000
Received: from localhost ([127.0.0.1]:49431 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nKPIE-000637-Jt
	for submit <at> debbugs.gnu.org; Wed, 16 Feb 2022 13:44:46 -0500
Received: from relay11.mail.gandi.net ([217.70.178.231]:49709)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <juri@HIDDEN>) id 1nKPID-00062f-0f
 for 54017 <at> debbugs.gnu.org; Wed, 16 Feb 2022 13:44:45 -0500
Received: (Authenticated sender: juri@HIDDEN)
 by mail.gandi.net (Postfix) with ESMTPSA id 9DD0C100004;
 Wed, 16 Feb 2022 18:44:37 +0000 (UTC)
From: Juri Linkov <juri@HIDDEN>
Organization: LINKOV.NET
References: <pml_I1y3BHYiUQCE1X45lx3leJ8mMRTwOclJd1qV7BDsVLjchfTfiqBFA4VwpHZACnp5pQmyPcD2biU-MEeM1tm9rURQhGuslCqCt3bWZAg=@protonmail.com>
Date: Wed, 16 Feb 2022 20:25:43 +0200
In-Reply-To: <pml_I1y3BHYiUQCE1X45lx3leJ8mMRTwOclJd1qV7BDsVLjchfTfiqBFA4VwpHZACnp5pQmyPcD2biU-MEeM1tm9rURQhGuslCqCt3bWZAg=@protonmail.com>
 (emacsq via's message of "Tue, 15 Feb 2022 20:21:35 +0000")
Message-ID: <8635kj2h7s.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Score: -0.7 (/)
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.7 (-)

> Suppose, the user wants to use ( ) for capturing and
> \( \) for matching parens. He provides a function
> which does this translation.
>
> If this new option is set and is a function which does
> the translation then read-regexp will
>
> - accept the format which the user prefers, in this case
> ( ... ) for capturing.
>
> - store regexps in this format in history, so the user
> can work with the user's preferred format even when
> retrieving history entries.
>
> - return the elisp format regexp by calling the function
> provided by the user which does the translation.

This user option already exists.  It's name is 'search-default-mode'.
For stand-alone query-replace it's called 'replace-regexp-function'.

So we just need someone to write these regexp translation functions.




Message sent to bug-gnu-emacs@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: bug#54017: add regexp translation option to read-regexp
Resent-From: emacsq <laszlomail@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: bug-gnu-emacs@HIDDEN
Resent-Date: Wed, 16 Feb 2022 19:29:01 +0000
Resent-Message-ID: <handler.54017.B54017.164503970527673 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: followup 54017
X-GNU-PR-Package: emacs
X-GNU-PR-Keywords: 
To: Juri Linkov <juri@HIDDEN>
Cc: 54017 <at> debbugs.gnu.org
Reply-To: emacsq <laszlomail@HIDDEN>
Received: via spool by 54017-submit <at> debbugs.gnu.org id=B54017.164503970527673
          (code B ref 54017); Wed, 16 Feb 2022 19:29:01 +0000
Received: (at 54017) by debbugs.gnu.org; 16 Feb 2022 19:28:25 +0000
Received: from localhost ([127.0.0.1]:49513 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nKPyT-0007CG-Ee
	for submit <at> debbugs.gnu.org; Wed, 16 Feb 2022 14:28:25 -0500
Received: from mail-4325.protonmail.ch ([185.70.43.25]:32187)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <laszlomail@HIDDEN>) id 1nKPyR-0007C3-2E
 for 54017 <at> debbugs.gnu.org; Wed, 16 Feb 2022 14:28:23 -0500
Date: Wed, 16 Feb 2022 19:28:14 +0000
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com;
 s=protonmail3; t=1645039696;
 bh=hzqZ9TLaqDqEEf3SQd5EuiGNkFrRxB0n3zGdmdKMe08=;
 h=Date:To:From:Cc:Reply-To:Subject:Message-ID:In-Reply-To:
 References:From:To:Cc:Date:Subject:Reply-To:Feedback-ID:
 Message-ID;
 b=VRlMBhhLEGR9ryjdCatF3p+uO0d2SvUsaNdCbo3cvOGIhj3kgferQZKMV4DL0QdeC
 vpHNRW1Pjy2EEMKFATwGy28pgUq8So4S6/W5pH4Zb4s0hFt0gRDz7L8vOInzA3YwDv
 vjufwdAK6JPKsQ7UZlbj5eseoh5kvFVA7FM/ryn1/odf8b4ZBwf9I59ZOCpKbKyIOb
 SujvYu8RIBsD9RQr+ntPlTjjHeXmgF7HZKvcdB8us2GOjj7kCyceUx3gHbdLobKOTf
 DeE2CqTbH2bWnbWZ3Ead+hEjm/8BBijY8Yc6Es8kk9kEdATase7X7fADb87uw5JhMX
 DtsHt6JxqEH9g==
From: emacsq <laszlomail@HIDDEN>
Message-ID: <LGUyh2fUS4Ytjp-GoIyY7nxUy-0G1fk163TDxRNFKcqNthT9HRzBCBsDYYO6IMfaD7VMxCNL049F0JJHPQ6CgRrSunT9w-s0ZoiELyorKRQ=@protonmail.com>
In-Reply-To: <8635kj2h7s.fsf@HIDDEN>
References: <pml_I1y3BHYiUQCE1X45lx3leJ8mMRTwOclJd1qV7BDsVLjchfTfiqBFA4VwpHZACnp5pQmyPcD2biU-MEeM1tm9rURQhGuslCqCt3bWZAg=@protonmail.com>
 <8635kj2h7s.fsf@HIDDEN>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
X-Spam-Status: No, score=-1.2 required=10.0 tests=ALL_TRUSTED,DKIM_SIGNED,
 DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,
 T_SCC_BODY_TEXT_LINE shortcircuit=no autolearn=disabled version=3.4.4
X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on
 mailout.protonmail.ch
X-Spam-Score: -0.0 (/)
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

> This user option already exists. It's name is 'search-default-mode'.

Does that option affect every command where read regexp is used?
Because this bug is about that.

So regexp translation for occur, flush/keep-lines, highlight-regexp,
dired-mark-files-regexp, etc., so anywhere where read-regexp is used.





Message sent to bug-gnu-emacs@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: bug#54017: add regexp translation option to read-regexp
Resent-From: Juri Linkov <juri@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: bug-gnu-emacs@HIDDEN
Resent-Date: Thu, 17 Feb 2022 08:31:01 +0000
Resent-Message-ID: <handler.54017.B54017.1645086618579 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: followup 54017
X-GNU-PR-Package: emacs
X-GNU-PR-Keywords: 
To: emacsq <laszlomail@HIDDEN>
Cc: 54017 <at> debbugs.gnu.org
Received: via spool by 54017-submit <at> debbugs.gnu.org id=B54017.1645086618579
          (code B ref 54017); Thu, 17 Feb 2022 08:31:01 +0000
Received: (at 54017) by debbugs.gnu.org; 17 Feb 2022 08:30:18 +0000
Received: from localhost ([127.0.0.1]:50067 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nKcB8-00009G-1F
	for submit <at> debbugs.gnu.org; Thu, 17 Feb 2022 03:30:18 -0500
Received: from relay3-d.mail.gandi.net ([217.70.183.195]:48203)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <juri@HIDDEN>) id 1nKcB6-00008x-Jg
 for 54017 <at> debbugs.gnu.org; Thu, 17 Feb 2022 03:30:17 -0500
Received: (Authenticated sender: juri@HIDDEN)
 by mail.gandi.net (Postfix) with ESMTPSA id 644EC60007;
 Thu, 17 Feb 2022 08:30:07 +0000 (UTC)
From: Juri Linkov <juri@HIDDEN>
Organization: LINKOV.NET
References: <pml_I1y3BHYiUQCE1X45lx3leJ8mMRTwOclJd1qV7BDsVLjchfTfiqBFA4VwpHZACnp5pQmyPcD2biU-MEeM1tm9rURQhGuslCqCt3bWZAg=@protonmail.com>
 <8635kj2h7s.fsf@HIDDEN>
 <LGUyh2fUS4Ytjp-GoIyY7nxUy-0G1fk163TDxRNFKcqNthT9HRzBCBsDYYO6IMfaD7VMxCNL049F0JJHPQ6CgRrSunT9w-s0ZoiELyorKRQ=@protonmail.com>
Date: Thu, 17 Feb 2022 10:24:14 +0200
In-Reply-To: <LGUyh2fUS4Ytjp-GoIyY7nxUy-0G1fk163TDxRNFKcqNthT9HRzBCBsDYYO6IMfaD7VMxCNL049F0JJHPQ6CgRrSunT9w-s0ZoiELyorKRQ=@protonmail.com>
 (emacsq's message of "Wed, 16 Feb 2022 19:28:14 +0000")
Message-ID: <86pmnlew9d.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Score: -0.7 (/)
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.7 (-)

>> This user option already exists. It's name is 'search-default-mode'.
>
> Does that option affect every command where read regexp is used?
> Because this bug is about that.
>
> So regexp translation for occur, flush/keep-lines, highlight-regexp,
> dired-mark-files-regexp, etc., so anywhere where read-regexp is used.

Sorry, I misread your feature request, I thought it's continuation
of adding custom regexp types to search/replace.  You are right
that read-regexp misses support for custom regexp formats.

It's easy to add regexp translation to the return value of read-regexp.
But there is one complication: the default value returned by
read-regexp-defaults-function might be a function like
find-tag-default-as-regexp that returns a regexp in the
default format created by regexp-quote.

Do you agree that a pair of two translation functions should be provided:
one to translate a custom regexp syntax to the default regexp syntax
(to be used on the return value of read-regexp), and another translation
from the default regexp syntax to the custom regexp syntax (to be used
to translate the default regexp value added to the minibuffer)?




Message sent to bug-gnu-emacs@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: bug#54017: add regexp translation option to read-regexp
Resent-From: Juri Linkov <juri@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: bug-gnu-emacs@HIDDEN
Resent-Date: Thu, 17 Feb 2022 09:12:02 +0000
Resent-Message-ID: <handler.54017.B54017.16450890724615 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: followup 54017
X-GNU-PR-Package: emacs
X-GNU-PR-Keywords: 
To: emacsq <laszlomail@HIDDEN>
Cc: 54017 <at> debbugs.gnu.org
Received: via spool by 54017-submit <at> debbugs.gnu.org id=B54017.16450890724615
          (code B ref 54017); Thu, 17 Feb 2022 09:12:02 +0000
Received: (at 54017) by debbugs.gnu.org; 17 Feb 2022 09:11:12 +0000
Received: from localhost ([127.0.0.1]:50102 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nKcoi-0001CN-2y
	for submit <at> debbugs.gnu.org; Thu, 17 Feb 2022 04:11:12 -0500
Received: from relay5-d.mail.gandi.net ([217.70.183.197]:38587)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <juri@HIDDEN>) id 1nKcog-0001C7-1M
 for 54017 <at> debbugs.gnu.org; Thu, 17 Feb 2022 04:11:10 -0500
Received: (Authenticated sender: juri@HIDDEN)
 by mail.gandi.net (Postfix) with ESMTPSA id C45901C000F;
 Thu, 17 Feb 2022 09:11:02 +0000 (UTC)
From: Juri Linkov <juri@HIDDEN>
Organization: LINKOV.NET
References: <pml_I1y3BHYiUQCE1X45lx3leJ8mMRTwOclJd1qV7BDsVLjchfTfiqBFA4VwpHZACnp5pQmyPcD2biU-MEeM1tm9rURQhGuslCqCt3bWZAg=@protonmail.com>
 <8635kj2h7s.fsf@HIDDEN>
 <LGUyh2fUS4Ytjp-GoIyY7nxUy-0G1fk163TDxRNFKcqNthT9HRzBCBsDYYO6IMfaD7VMxCNL049F0JJHPQ6CgRrSunT9w-s0ZoiELyorKRQ=@protonmail.com>
 <86pmnlew9d.fsf@HIDDEN>
Date: Thu, 17 Feb 2022 11:09:21 +0200
In-Reply-To: <86pmnlew9d.fsf@HIDDEN> (Juri Linkov's message of "Thu, 
 17 Feb 2022 10:24:14 +0200")
Message-ID: <86fsoheu66.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu)
MIME-Version: 1.0
Content-Type: multipart/mixed; boundary="=-=-="
X-Spam-Score: -0.7 (/)
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.7 (-)

--=-=-=
Content-Type: text/plain

> It's easy to add regexp translation to the return value of read-regexp.

This patch allows using Rx syntax, so for example, after running 'occur',
you can type an Rx expression:

  List lines matching regexp: (rx (or "e.g." "i.e.") " ")


--=-=-=
Content-Type: text/x-diff
Content-Disposition: inline; filename=regexp-from-function.patch

diff --git a/lisp/emacs-lisp/rx.el b/lisp/emacs-lisp/rx.el
index aa2486b47e..b1e726d025 100644
--- a/lisp/emacs-lisp/rx.el
+++ b/lisp/emacs-lisp/rx.el
@@ -1479,6 +1479,10 @@ rx
 ;; Obsolete internal symbol, used in old versions of the `flycheck' package.
 (define-obsolete-function-alias 'rx-submatch-n 'rx-to-string "27.1")
 
+(defun regexp-from-rx (string)
+  "This translation function can be used by `regexp-from-function'."
+  (rx--to-expr (cons 'seq (cdr (read string)))))
+
 (provide 'rx)
 
 ;;; rx.el ends here
diff --git a/lisp/replace.el b/lisp/replace.el
index 06be597855..a8b850a9ed 100644
--- a/lisp/replace.el
+++ b/lisp/replace.el
@@ -819,6 +819,15 @@ occur-highlight-overlays
 (defvar occur-collect-regexp-history '("\\1")
   "History of regexp for occur's collect operation.")
 
+(defcustom regexp-from-function nil
+  "Function to translate from a custom regexp to the default regexp syntax."
+  :type '(choice
+          (const :tag "No translation" nil)
+          (function-item :tag "RX" regexp-from-rx)
+          (function :tag "Your choice of function"))
+  :group 'matching
+  :version "29.1")
+
 (defcustom read-regexp-defaults-function nil
   "Function that provides default regexp(s) for `read-regexp'.
 This function should take no arguments and return one of: nil, a
@@ -923,7 +932,9 @@ read-regexp
 	  (when default
 	    (add-to-history (or history 'regexp-history) default)))
       ;; Otherwise, add non-empty input to the history and return input.
-      (prog1 input
+      (prog1 (if (functionp regexp-from-function)
+                 (funcall regexp-from-function input)
+               input)
 	(add-to-history (or history 'regexp-history) input)))))
 
 

--=-=-=--




Message sent to bug-gnu-emacs@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: bug#54017: add regexp translation option to read-regexp
Resent-From: Eli Zaretskii <eliz@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: bug-gnu-emacs@HIDDEN
Resent-Date: Thu, 17 Feb 2022 09:19:01 +0000
Resent-Message-ID: <handler.54017.B54017.16450895325442 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: followup 54017
X-GNU-PR-Package: emacs
X-GNU-PR-Keywords: 
To: Juri Linkov <juri@HIDDEN>
Cc: laszlomail@HIDDEN, 54017 <at> debbugs.gnu.org
Received: via spool by 54017-submit <at> debbugs.gnu.org id=B54017.16450895325442
          (code B ref 54017); Thu, 17 Feb 2022 09:19:01 +0000
Received: (at 54017) by debbugs.gnu.org; 17 Feb 2022 09:18:52 +0000
Received: from localhost ([127.0.0.1]:50128 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nKcvv-0001PV-Pt
	for submit <at> debbugs.gnu.org; Thu, 17 Feb 2022 04:18:52 -0500
Received: from eggs.gnu.org ([209.51.188.92]:54090)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1nKcvt-0001PH-Su
 for 54017 <at> debbugs.gnu.org; Thu, 17 Feb 2022 04:18:38 -0500
Received: from [2001:470:142:3::e] (port=45386 helo=fencepost.gnu.org)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1nKcvo-0000zo-6X; Thu, 17 Feb 2022 04:18:32 -0500
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date:
 mime-version; bh=AFknawXOeXkit+RiTLDVnSu0nx9P7ZgQSOrQgd/iLUI=; b=OJ5EjQZilB4T
 f+lmboPyUi7MbfT5ey7rjXIO3hM0l8eg/GuKpCTA8Pa4O0zpxHq6yeZwY7tmrp+u2+jlc67Eb94LH
 sYAJAX/FcYFudweYAzuhwJklfO1YuK6KzZQt+lnOfg3vBQgsI7rTTCS10LZBEGSwOvTX4n1mdNpBd
 b8fm3uie9xPJhXOZrDU/L3St3KYWP3e4Pujft1RyOioP/CGDsd+e9epniGJ4KXnJTF955c8iAK5Rz
 BE3M5jf6TwAUl7OBuZMqoMnSy3I7ekjYYpFWkkaIyNosxQCHvLgxjEBhEjMqDy32KCVUd1DK9IpyN
 R00eXHcLQUrdDFC3th+xxQ==;
Received: from [87.69.77.57] (port=1479 helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1nKcvM-000510-6l; Thu, 17 Feb 2022 04:18:26 -0500
Date: Thu, 17 Feb 2022 11:18:10 +0200
Message-Id: <83ee4126nh.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
In-Reply-To: <86pmnlew9d.fsf@HIDDEN> (message from Juri Linkov on
 Thu, 17 Feb 2022 10:24:14 +0200)
References: <pml_I1y3BHYiUQCE1X45lx3leJ8mMRTwOclJd1qV7BDsVLjchfTfiqBFA4VwpHZACnp5pQmyPcD2biU-MEeM1tm9rURQhGuslCqCt3bWZAg=@protonmail.com>
 <8635kj2h7s.fsf@HIDDEN>
 <LGUyh2fUS4Ytjp-GoIyY7nxUy-0G1fk163TDxRNFKcqNthT9HRzBCBsDYYO6IMfaD7VMxCNL049F0JJHPQ6CgRrSunT9w-s0ZoiELyorKRQ=@protonmail.com>
 <86pmnlew9d.fsf@HIDDEN>
X-Spam-Score: -2.3 (--)
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

> From: Juri Linkov <juri@HIDDEN>
> Date: Thu, 17 Feb 2022 10:24:14 +0200
> Cc: 54017 <at> debbugs.gnu.org
> 
> It's easy to add regexp translation to the return value of read-regexp.
> But there is one complication: the default value returned by
> read-regexp-defaults-function might be a function like
> find-tag-default-as-regexp that returns a regexp in the
> default format created by regexp-quote.
> 
> Do you agree that a pair of two translation functions should be provided:
> one to translate a custom regexp syntax to the default regexp syntax
> (to be used on the return value of read-regexp), and another translation
> from the default regexp syntax to the custom regexp syntax (to be used
> to translate the default regexp value added to the minibuffer)?

Before we install something like this, we need to discuss the relevant
use cases and agree that it makes sense for us to support them.

I originally interpreted the OP's request as asking for a feature
where the user could use one of the regexp styles used by other
programs, such as BRE or ERE or maybe PCRE.  If this is indeed the
intent, then I'd rather we implemented support for only those specific
styles (or some subset of them).  It doesn't make sense to me to
support arbitrary translations of regular expressions, because I see
no valid use cases for such a general feature, and am unaware of any
other applications which support regular expressions that allow such
arbitrary translations.




Message sent to bug-gnu-emacs@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: bug#54017: add regexp translation option to read-regexp
Resent-From: emacsq <laszlomail@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: bug-gnu-emacs@HIDDEN
Resent-Date: Thu, 17 Feb 2022 10:05:01 +0000
Resent-Message-ID: <handler.54017.B54017.164509228710164 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: followup 54017
X-GNU-PR-Package: emacs
X-GNU-PR-Keywords: 
To: Eli Zaretskii <eliz@HIDDEN>
Cc: 54017 <at> debbugs.gnu.org, Juri Linkov <juri@HIDDEN>
Reply-To: emacsq <laszlomail@HIDDEN>
Received: via spool by 54017-submit <at> debbugs.gnu.org id=B54017.164509228710164
          (code B ref 54017); Thu, 17 Feb 2022 10:05:01 +0000
Received: (at 54017) by debbugs.gnu.org; 17 Feb 2022 10:04:47 +0000
Received: from localhost ([127.0.0.1]:50206 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nKdeZ-0002ds-0X
	for submit <at> debbugs.gnu.org; Thu, 17 Feb 2022 05:04:47 -0500
Received: from mail-4325.protonmail.ch ([185.70.43.25]:20641)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <laszlomail@HIDDEN>) id 1nKdeX-0002dZ-FY
 for 54017 <at> debbugs.gnu.org; Thu, 17 Feb 2022 05:04:46 -0500
Date: Thu, 17 Feb 2022 10:04:38 +0000
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com;
 s=protonmail3; t=1645092279;
 bh=VydMM+Uts0Zdt4qWKqXe54ywXPUhf7Ftv6l7T8PUZy4=;
 h=Date:To:From:Cc:Reply-To:Subject:Message-ID:In-Reply-To:
 References:From:To:Cc:Date:Subject:Reply-To:Feedback-ID:
 Message-ID;
 b=KN3NTHoa9xRl6C6mWXDQN29ASs1dU7R1cTbMud6w7BZFEVEuRV+iXjG8WWPaK8dXN
 bN2Uhzru85Wa6lwgDTclUHwXqR2fe0XdPFS0dV3Qwap3FOtu8J0BGk3gmHH0p5Uh5o
 bGM3qf8DTyLcSxgIe+5sGGN85zrDoqtYig6HiNYr8/1TNRwX0GwGiPyltW4P0EUvEV
 b0w56kT7O7+5p/w2I73QFwcad5MI06aqjZTIy0KzDuXM6PkcyDH7TW68BlXg/kvVxH
 HRah9+bk0fsQBt3uptM2RZ/X/b+PIBdEcL6rT3j+Z/JduCm17b3jasnQ2m/w1Y5/Kt
 HN1QZ1SQS6WXQ==
From: emacsq <laszlomail@HIDDEN>
Message-ID: <hXofOEB2AAbwiIcCU6KM9w3wDQEziNRQFjrmwRBOdTUxhqtvEnX9xkuTnm4RfbLcl2NlQXque5VXsZ7DDDy63VCGConaoQ3rKrizooeQZxU=@protonmail.com>
In-Reply-To: <83ee4126nh.fsf@HIDDEN>
References: <pml_I1y3BHYiUQCE1X45lx3leJ8mMRTwOclJd1qV7BDsVLjchfTfiqBFA4VwpHZACnp5pQmyPcD2biU-MEeM1tm9rURQhGuslCqCt3bWZAg=@protonmail.com>
 <8635kj2h7s.fsf@HIDDEN>
 <LGUyh2fUS4Ytjp-GoIyY7nxUy-0G1fk163TDxRNFKcqNthT9HRzBCBsDYYO6IMfaD7VMxCNL049F0JJHPQ6CgRrSunT9w-s0ZoiELyorKRQ=@protonmail.com>
 <86pmnlew9d.fsf@HIDDEN> <83ee4126nh.fsf@HIDDEN>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
X-Spam-Status: No, score=-1.2 required=10.0 tests=ALL_TRUSTED,DKIM_SIGNED,
 DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,
 T_SCC_BODY_TEXT_LINE shortcircuit=no autolearn=disabled version=3.4.4
X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on
 mailout.protonmail.ch
X-Spam-Score: -0.0 (/)
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

> I originally interpreted the OP's request as asking for a feature
> where the user could use one of the regexp styles used by other
> programs, such as BRE or ERE or maybe PCRE.

If it provides me a more friendly regexp syntax where I don't have to
qoute parens, alternations then I'm OK with it, though I guess
providing a full translation for certain styles is much more work,
so giving an option for translation and letting the user write his
own function according to his taste may be the simpler solution which
can even support different custom regexp styles later.





Message sent to bug-gnu-emacs@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: bug#54017: add regexp translation option to read-regexp
Resent-From: emacsq <laszlomail@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: bug-gnu-emacs@HIDDEN
Resent-Date: Thu, 17 Feb 2022 10:56:02 +0000
Resent-Message-ID: <handler.54017.B54017.164509533215398 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: followup 54017
X-GNU-PR-Package: emacs
X-GNU-PR-Keywords: 
To: Juri Linkov <juri@HIDDEN>
Cc: 54017 <at> debbugs.gnu.org
Reply-To: emacsq <laszlomail@HIDDEN>
Received: via spool by 54017-submit <at> debbugs.gnu.org id=B54017.164509533215398
          (code B ref 54017); Thu, 17 Feb 2022 10:56:02 +0000
Received: (at 54017) by debbugs.gnu.org; 17 Feb 2022 10:55:32 +0000
Received: from localhost ([127.0.0.1]:50283 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nKeRf-00040I-U7
	for submit <at> debbugs.gnu.org; Thu, 17 Feb 2022 05:55:32 -0500
Received: from mail-4318.protonmail.ch ([185.70.43.18]:53807)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <laszlomail@HIDDEN>) id 1nKeRd-000403-KD
 for 54017 <at> debbugs.gnu.org; Thu, 17 Feb 2022 05:55:30 -0500
Date: Thu, 17 Feb 2022 10:55:22 +0000
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com;
 s=protonmail3; t=1645095322;
 bh=CUa5DM1V7t8YE96CpseXvx3BcR2gjWKwXpanfZXP6Ac=;
 h=Date:To:From:Cc:Reply-To:Subject:Message-ID:In-Reply-To:
 References:From:To:Cc:Date:Subject:Reply-To:Feedback-ID:
 Message-ID;
 b=c/hOXmOPrfmtw6/kwayQL52g7Qwkt1DrWxFESIhQrCAog2eKKodbFKOqAdBdAdT3c
 oDm/7L21mti4SS5B11lbYgp/udqwg+TIMU0KkVJOvyBCscPEkg1LbUYFXM8LheclIC
 O+6S1FUwoe61fCoYBAOBLULTSpV1H57W27pqZ1W3dLwS/ReNNpPKDyQNtFccUtM9DU
 loxnGAyogzJmZxzTAVxqPl5WPZLM6lEWNSluF3kNRuLObe8UVEMzjPIubtkdpwfrhY
 4/9edc/WOXmi1HhfiuwRja1TnmR1tK1ObrhiBzPLkxb6dGgbQiZqckybwoMVzuxiRf
 i3XHXy9+qhKCg==
From: emacsq <laszlomail@HIDDEN>
Message-ID: <9LWah4VVitpa2lng3EOUtAFaCtAdV_OJKWGiRVz5TmrajnJ3gWDmhpqy4_Ac-1F4Qv2xmVGckjS35Ity5cq9M4BFd5DJxH2JklOkKR5r6c0=@protonmail.com>
In-Reply-To: <86pmnlew9d.fsf@HIDDEN>
References: <pml_I1y3BHYiUQCE1X45lx3leJ8mMRTwOclJd1qV7BDsVLjchfTfiqBFA4VwpHZACnp5pQmyPcD2biU-MEeM1tm9rURQhGuslCqCt3bWZAg=@protonmail.com>
 <8635kj2h7s.fsf@HIDDEN>
 <LGUyh2fUS4Ytjp-GoIyY7nxUy-0G1fk163TDxRNFKcqNthT9HRzBCBsDYYO6IMfaD7VMxCNL049F0JJHPQ6CgRrSunT9w-s0ZoiELyorKRQ=@protonmail.com>
 <86pmnlew9d.fsf@HIDDEN>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
X-Spam-Status: No, score=-1.2 required=10.0 tests=ALL_TRUSTED,DKIM_SIGNED,
 DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,
 T_SCC_BODY_TEXT_LINE shortcircuit=no autolearn=disabled version=3.4.4
X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on
 mailout.protonmail.ch
X-Spam-Score: -0.0 (/)
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

> a pair of two translation functions should be provided:
> one to translate a custom regexp syntax to the default regexp syntax
>(to be used on the return value of read-regexp), and another translation
> from the default regexp syntax to the custom regexp syntax (to be used
> to translate the default regexp value added to the minibuffer)?

The purpose of regexp translation is that all user facing regexps by
read-regexp should use the translated format, so if there is a need
for a function which converts to the convenient format then the
user should provide that as well. Maybe there should be one function only
with  an argument specifying the direction of the translation.

BTW, ideally the variables you mentioned ('search-default-mode' and
'replace-regexp-function') should be merged with this option, because
it's unlikely the user wants one regexp syntax for one command and a
different syntax for an other one, so there should be a single
translation function which works everywhere where user facing
regexps occur.





Message sent to bug-gnu-emacs@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: bug#54017: add regexp translation option to read-regexp
Resent-From: Juri Linkov <juri@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: bug-gnu-emacs@HIDDEN
Resent-Date: Thu, 17 Feb 2022 17:49:02 +0000
Resent-Message-ID: <handler.54017.B54017.164512011628766 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: followup 54017
X-GNU-PR-Package: emacs
X-GNU-PR-Keywords: 
To: Eli Zaretskii <eliz@HIDDEN>
Cc: laszlomail@HIDDEN, 54017 <at> debbugs.gnu.org
Received: via spool by 54017-submit <at> debbugs.gnu.org id=B54017.164512011628766
          (code B ref 54017); Thu, 17 Feb 2022 17:49:02 +0000
Received: (at 54017) by debbugs.gnu.org; 17 Feb 2022 17:48:36 +0000
Received: from localhost ([127.0.0.1]:52641 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nKktP-0007Tu-QS
	for submit <at> debbugs.gnu.org; Thu, 17 Feb 2022 12:48:35 -0500
Received: from relay10.mail.gandi.net ([217.70.178.230]:58065)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <juri@HIDDEN>) id 1nKktM-0007TF-RA
 for 54017 <at> debbugs.gnu.org; Thu, 17 Feb 2022 12:48:35 -0500
Received: (Authenticated sender: juri@HIDDEN)
 by mail.gandi.net (Postfix) with ESMTPSA id 0C642240006;
 Thu, 17 Feb 2022 17:48:23 +0000 (UTC)
From: Juri Linkov <juri@HIDDEN>
Organization: LINKOV.NET
References: <pml_I1y3BHYiUQCE1X45lx3leJ8mMRTwOclJd1qV7BDsVLjchfTfiqBFA4VwpHZACnp5pQmyPcD2biU-MEeM1tm9rURQhGuslCqCt3bWZAg=@protonmail.com>
 <8635kj2h7s.fsf@HIDDEN>
 <LGUyh2fUS4Ytjp-GoIyY7nxUy-0G1fk163TDxRNFKcqNthT9HRzBCBsDYYO6IMfaD7VMxCNL049F0JJHPQ6CgRrSunT9w-s0ZoiELyorKRQ=@protonmail.com>
 <86pmnlew9d.fsf@HIDDEN> <83ee4126nh.fsf@HIDDEN>
Date: Thu, 17 Feb 2022 19:40:43 +0200
In-Reply-To: <83ee4126nh.fsf@HIDDEN> (Eli Zaretskii's message of "Thu, 17 Feb
 2022 11:18:10 +0200")
Message-ID: <86r181lb1g.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Score: -0.7 (/)
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.7 (-)

> Before we install something like this, we need to discuss the relevant
> use cases and agree that it makes sense for us to support them.
>
> I originally interpreted the OP's request as asking for a feature
> where the user could use one of the regexp styles used by other
> programs, such as BRE or ERE or maybe PCRE.  If this is indeed the
> intent, then I'd rather we implemented support for only those specific
> styles (or some subset of them).  It doesn't make sense to me to
> support arbitrary translations of regular expressions, because I see
> no valid use cases for such a general feature, and am unaware of any
> other applications which support regular expressions that allow such
> arbitrary translations.

Then need to wait when someone will step forward to write these
BRE/ERE/PCRE translation functions.




Message sent to bug-gnu-emacs@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: bug#54017: add regexp translation option to read-regexp
Resent-From: emacsq <laszlomail@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: bug-gnu-emacs@HIDDEN
Resent-Date: Sun, 20 Feb 2022 19:08:01 +0000
Resent-Message-ID: <handler.54017.B54017.164538402419471 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: followup 54017
X-GNU-PR-Package: emacs
X-GNU-PR-Keywords: 
To: Juri Linkov <juri@HIDDEN>
Cc: Eli Zaretskii <eliz@HIDDEN>, 54017 <at> debbugs.gnu.org
Reply-To: emacsq <laszlomail@HIDDEN>
Received: via spool by 54017-submit <at> debbugs.gnu.org id=B54017.164538402419471
          (code B ref 54017); Sun, 20 Feb 2022 19:08:01 +0000
Received: (at 54017) by debbugs.gnu.org; 20 Feb 2022 19:07:04 +0000
Received: from localhost ([127.0.0.1]:33766 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nLrXz-00053y-UN
	for submit <at> debbugs.gnu.org; Sun, 20 Feb 2022 14:07:04 -0500
Received: from mail-40137.protonmail.ch ([185.70.40.137]:11424)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <laszlomail@HIDDEN>) id 1nLrXy-00053A-DX
 for 54017 <at> debbugs.gnu.org; Sun, 20 Feb 2022 14:07:02 -0500
Date: Sun, 20 Feb 2022 19:06:53 +0000
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com;
 s=protonmail3; t=1645384016;
 bh=PqaIo1nbL/wVYGNIhq78t/9EbGqqnAH7Z1iAtvJKLsU=;
 h=Date:To:From:Cc:Reply-To:Subject:Message-ID:In-Reply-To:
 References:From:To:Cc:Date:Subject:Reply-To:Feedback-ID:
 Message-ID;
 b=o1xynrncwnkcScLsTFRiGKjPlPNUCU5HMZK1Z49nDzn2qhtG+XScLKkGgupLPTWly
 EkMHHUh2R2KhQJweTkFb6OtAxzU8WfY4i/IV54R28YQSKTGAzrw1GFBsARin6jtPNB
 5qXLKO8bQY32FY1OCfvsI1asixpPBjqOpPTWG9/WRF6Uo4/p0DlNKu7XegdiQQsuxr
 fWc7vUez7+kMuIDTt9zwFajEMBykVFyOVkYaJB5QsH+v6V2gWfJFoyHwSBXX9KaLA/
 x9O7mWW35haKnHRtpT1srySLeGU6C3mBE0WC7cSTrmtKkGl/f6VrMmUJEwC01WHJoa
 /r4DkJh1VsPhg==
From: emacsq <laszlomail@HIDDEN>
Message-ID: <Ye-sTBsBQ_V1mhMei3gAUe9obgszsnMbjNBs0VNYzPYusPbWon36ObiXpreX3dwOg1CKsTLFw4Y9iSoZFeyXcd-prJ5G1E3_rcxpIuypNy4=@protonmail.com>
In-Reply-To: <86r181lb1g.fsf@HIDDEN>
References: <pml_I1y3BHYiUQCE1X45lx3leJ8mMRTwOclJd1qV7BDsVLjchfTfiqBFA4VwpHZACnp5pQmyPcD2biU-MEeM1tm9rURQhGuslCqCt3bWZAg=@protonmail.com>
 <8635kj2h7s.fsf@HIDDEN>
 <LGUyh2fUS4Ytjp-GoIyY7nxUy-0G1fk163TDxRNFKcqNthT9HRzBCBsDYYO6IMfaD7VMxCNL049F0JJHPQ6CgRrSunT9w-s0ZoiELyorKRQ=@protonmail.com>
 <86pmnlew9d.fsf@HIDDEN> <83ee4126nh.fsf@HIDDEN>
 <86r181lb1g.fsf@HIDDEN>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
X-Spam-Status: No, score=-1.2 required=10.0 tests=ALL_TRUSTED,DKIM_SIGNED,
 DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,
 T_SCC_BODY_TEXT_LINE shortcircuit=no autolearn=disabled version=3.4.4
X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on
 mailout.protonmail.ch
X-Spam-Score: -0.0 (/)
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

> Then need to wait when someone will step forward to write these
> BRE/ERE/PCRE translation functions.

This is a bigger job and is there a current need for it?

People just want to make their life easier and change the way
how the syntax of some of the symbols often used by them works
in interactive input (e.g. grouping).

If we wait for those complete translation functions then we
might have to wait for a long time, unless there are people
who want complete translations right now, but there were no
such volunteers in this thread for that task.

Adding an option for a custom translation function solves the
problem right know, everyone can change the symbols they are
most annoyed by and this function can be the base mechanism
for complete translations later if someone ever wants to do
those.




Message sent to bug-gnu-emacs@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: bug#54017: add regexp translation option to read-regexp
Resent-From: Eli Zaretskii <eliz@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: bug-gnu-emacs@HIDDEN
Resent-Date: Sun, 20 Feb 2022 20:03:02 +0000
Resent-Message-ID: <handler.54017.B54017.164538735318437 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: followup 54017
X-GNU-PR-Package: emacs
X-GNU-PR-Keywords: 
To: emacsq <laszlomail@HIDDEN>
Cc: 54017 <at> debbugs.gnu.org, juri@HIDDEN
Received: via spool by 54017-submit <at> debbugs.gnu.org id=B54017.164538735318437
          (code B ref 54017); Sun, 20 Feb 2022 20:03:02 +0000
Received: (at 54017) by debbugs.gnu.org; 20 Feb 2022 20:02:33 +0000
Received: from localhost ([127.0.0.1]:33928 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nLsPg-0004n9-VN
	for submit <at> debbugs.gnu.org; Sun, 20 Feb 2022 15:02:33 -0500
Received: from eggs.gnu.org ([209.51.188.92]:58960)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1nLsPg-0004j7-7v
 for 54017 <at> debbugs.gnu.org; Sun, 20 Feb 2022 15:02:32 -0500
Received: from [2001:470:142:3::e] (port=33238 helo=fencepost.gnu.org)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1nLsPZ-0003re-Ki; Sun, 20 Feb 2022 15:02:26 -0500
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date:
 mime-version; bh=tureIlNBncJQfneU6uJGCxuQMNhG4Uwineiwr7OV2T8=; b=gWOiIGFCKUUz
 jR6jjULWjy2FrpKFsUo06aw0ck2BaveG4Wk54Fvis3dNs1e9DgqvvI7RiQ4HXFOI1OPaJQd157mvO
 aCBhPEmbG5m8VEJwSiTX8zU795ghUbRh9UpQcFUb8u1s6BzViLEmCSOy78S96rf1H8LgaNk/FJLuJ
 vC3kcE80JXCBWv+0unibW8HhrU9fwT+YRRoziIJ8OFwy2xGoewbZgozlozyaVZqoYbvJMT8HM8rAY
 d+M59Bl/Ocm8O7iQEcxYDjUbbzIbE9VZGtz8TNSoKfsuZa45j/x6gERNAJ+q1nDI83YZYpdGebYGj
 wLB2XyCfhoQ/9VW/N4bz3Q==;
Received: from [87.69.77.57] (port=2877 helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1nLsPY-0007oj-Us; Sun, 20 Feb 2022 15:02:25 -0500
Date: Sun, 20 Feb 2022 22:02:27 +0200
Message-Id: <837d9pwbl8.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
In-Reply-To: <Ye-sTBsBQ_V1mhMei3gAUe9obgszsnMbjNBs0VNYzPYusPbWon36ObiXpreX3dwOg1CKsTLFw4Y9iSoZFeyXcd-prJ5G1E3_rcxpIuypNy4=@protonmail.com>
 (message from emacsq on Sun, 20 Feb 2022 19:06:53 +0000)
References: <pml_I1y3BHYiUQCE1X45lx3leJ8mMRTwOclJd1qV7BDsVLjchfTfiqBFA4VwpHZACnp5pQmyPcD2biU-MEeM1tm9rURQhGuslCqCt3bWZAg=@protonmail.com>
 <8635kj2h7s.fsf@HIDDEN>
 <LGUyh2fUS4Ytjp-GoIyY7nxUy-0G1fk163TDxRNFKcqNthT9HRzBCBsDYYO6IMfaD7VMxCNL049F0JJHPQ6CgRrSunT9w-s0ZoiELyorKRQ=@protonmail.com>
 <86pmnlew9d.fsf@HIDDEN> <83ee4126nh.fsf@HIDDEN>
 <86r181lb1g.fsf@HIDDEN>
 <Ye-sTBsBQ_V1mhMei3gAUe9obgszsnMbjNBs0VNYzPYusPbWon36ObiXpreX3dwOg1CKsTLFw4Y9iSoZFeyXcd-prJ5G1E3_rcxpIuypNy4=@protonmail.com>
X-Spam-Score: -2.3 (--)
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

> Date: Sun, 20 Feb 2022 19:06:53 +0000
> From: emacsq <laszlomail@HIDDEN>
> Cc: Eli Zaretskii <eliz@HIDDEN>, 54017 <at> debbugs.gnu.org
> 
> > Then need to wait when someone will step forward to write these
> > BRE/ERE/PCRE translation functions.
> 
> This is a bigger job and is there a current need for it?
> 
> People just want to make their life easier and change the way
> how the syntax of some of the symbols often used by them works
> in interactive input (e.g. grouping).

Like I said: I don't think we should support arbitrary
transformations of regular expressions' syntax.  It makes no sense to
me.


And we don't need to support _all_ of the above syntaxes, we could
support just the BRE or just the ERE.





Last modified: Sun, 20 Feb 2022 20:15:01 UTC

GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997 nCipher Corporation Ltd, 1994-97 Ian Jackson.