help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Is there equivalent internal function for this list-has-elements?


From: Jean Louis
Subject: Re: Is there equivalent internal function for this list-has-elements?
Date: Mon, 19 Oct 2020 21:08:23 +0300
User-agent: Mutt/1.10.1 (2018-07-13)

* Joost Kremers <joostkremers@fastmail.fm> [2020-10-19 00:22]:
> 
> On Sun, Oct 18 2020, tomas@tuxteam.de wrote:
> > If I understand this one correctly, it can be expressed as:
> >
> >   (seq-filter
> >     (lambda (elt) (string-match needle elt))
> >     haystack)
> 
> Small nit-pick, but it's generally better to use `string-match-p` if you're 
> just
> testing whether a string matches a regexp. `string-match` modifies the match
> data, `string-match-p` doesn't.

Thanks.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]