From: Dmitry Gutov <dgutov@yandex.ru>
To: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: Juri Linkov <juri@linkov.net>, emacs-devel@gnu.org
Subject: Re: Looking at function
Date: Wed, 17 Aug 2022 03:23:42 +0300 [thread overview]
Message-ID: <875a0e53-6bb6-563b-f21c-492a04781a37@yandex.ru> (raw)
In-Reply-To: <jwv35f75g3k.fsf-monnier+emacs@gnu.org>
On 12.07.2022 03:29, Stefan Monnier wrote:
> Dmitry Gutov [2022-07-12 03:19:42] wrote:
>> On 11.07.2022 22:14, Juri Linkov wrote:
>>>>> 1. Replace ‘looking-at’ with a call to the search function,
>>>>> but keep it at point by prepending ‘\\=’ to the regexp.
>>>>> Can it break a complex regexp?
>>>> I suppose it can. Even a simple one (that has \\| inside without
>>>> a grouping).
>>> This is what the fix for xref successfully uses in bug#53758
>>> with changes in perform-replace from bug#14013. (However,
>>> none of these variants is suitable for replacing another call
>>> of looking-at in isearch-search-and-update.)
>> Right. Because xref basically uses literal matching, no alternations.
>> But it will break more complex cases.
> I can't see why "\\=\\(?:...\\)" would break anything, personally.
Right.
But I suppose this approach could be problematic when
isearch-regexp-function or isearch-search-fun-function have non-default
and some distinctly weird values/specialized behaviors.
next prev parent reply other threads:[~2022-08-17 0:23 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-06-28 18:01 Looking at function Juri Linkov
2022-06-28 19:22 ` Stefan Monnier
2022-07-01 15:49 ` Juri Linkov
2022-07-11 1:26 ` Dmitry Gutov
2022-07-11 19:14 ` Juri Linkov
2022-07-12 0:19 ` Dmitry Gutov
2022-07-12 0:29 ` Stefan Monnier
2022-08-17 0:23 ` Dmitry Gutov [this message]
2022-07-12 7:50 ` Juri Linkov
2022-08-17 0:27 ` Dmitry Gutov
2022-08-21 16:09 ` Juri Linkov
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=875a0e53-6bb6-563b-f21c-492a04781a37@yandex.ru \
--to=dgutov@yandex.ru \
--cc=emacs-devel@gnu.org \
--cc=juri@linkov.net \
--cc=monnier@iro.umontreal.ca \
/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).