[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Is it valid to call isearch-filter-predicate outside isearch?
From: |
Eli Zaretskii |
Subject: |
Re: Is it valid to call isearch-filter-predicate outside isearch? |
Date: |
Thu, 01 Jun 2023 08:55:35 +0300 |
> From: Michael Heerdegen <michael_heerdegen@web.de>
> Cc: emacs-devel@gnu.org
> Date: Thu, 01 Jun 2023 01:17:57 +0200
>
> Ihor Radchenko <yantar92@posteo.net> writes:
>
> > The documentation for `isearch-filter-visible' sounds like no side
> > effects are expected:
> >
> > Predicate to filter hits of Isearch and replace commands.
> >
> > Isearch hits that don't satisfy the predicate will be skipped.
> > The value should be a function of two arguments; it will be
> > called with the positions of the start and the end of the text
> > matched by Isearch and replace commands. If this function
> > returns nil, Isearch and replace commands will continue searching
> > without stopping at resp. replacing this match.
> > This function is expected to be careful not to clobber the match data.
> >
> > Either the docstring is not accurate or the implementation of
> > `isearch-range-invisible' is not safe.
> >
> > Am I missing something?
>
> No. It has does have side effects that are not documented.
The question is: why do we have to document every possible nit of the
internals? I still don't think I understand the rationale. People
who want to know _everything_ about the code should consult the source
code; it's the power of Free Software that they can do it.
- Re: Is it valid to call isearch-filter-predicate outside isearch?,
Eli Zaretskii <=