From 622a379126c9b2bca953a71c9eaa45f5ae36703d Mon Sep 17 00:00:00 2001 From: Ingo Rohloff Date: Sat, 23 Aug 2025 19:44:04 -0400 Subject: [PATCH] * doc/make.texi: [SV 67428] Clarify $(findstring ...) docs --- doc/make.texi | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) diff --git a/doc/make.texi b/doc/make.texi index 34a257f2..139a62d5 100644 --- a/doc/make.texi +++ b/doc/make.texi @@ -7753,26 +7753,25 @@ directive would make it more robust. @cindex searching for strings @cindex finding strings @cindex strings, searching for -Searches @var{in} for an occurrence of @var{find}. If it occurs, the -value is @var{find}; otherwise, the value is empty. You can use this -function in a conditional to test for the presence of a specific -substring in a given string. Thus, the two examples, +Searches the string @var{in} for an occurrence of the string @var{find}. If +it occurs, the result is @var{find}; otherwise, the result is the empty +string. You can use this function in a conditional to test for the presence +of a specific substring in a given string. These two examples: @example -$(findstring a,a b c) -$(findstring a,b c) +$(findstring lo Wo,Hello World!) +$(findstring lo Wo,World Hello!) @end example @noindent -produce the values @samp{a} and @samp{} (the empty string), -respectively. @xref{Testing Flags}, for a practical application of -@code{findstring}. +expand to @samp{lo Wo} and @samp{} (the empty string), respectively. +@xref{Testing Flags}, for a practical application of @code{findstring}. @need 750 +@item $(filter @var{pattern}@dots{},@var{text}) @findex filter @cindex filtering words @cindex words, filtering -@item $(filter @var{pattern}@dots{},@var{text}) Returns all whitespace-separated words in @var{text} that @emph{do} match any of the @var{pattern} words, removing any words that @emph{do not} match. Each word in @var{pattern} is compared to every word in @var{text} -- 2.47.3