diff --git a/doc/ref/scheme-compound.texi b/doc/ref/scheme-compound.texi index 6064c8c52..b2fb11e42 100644 --- a/doc/ref/scheme-compound.texi +++ b/doc/ref/scheme-compound.texi @@ -461,6 +461,16 @@ Like @code{delete!}, but only deletes the first occurrence of @code{equal?}. See also @code{delq1!} and @code{delv1!}. @end deffn +@deffn {Scheme Procedure} filter pred lst +@deffnx {Scheme Procedure} filter! pred lst +Return a list containing all elements from @var{lst} which satisfy the +predicate @var{pred}. The elements in the result list have the same +order as in @var{lst}. The order in which @var{pred} is applied to +the list elements is not specified. + +@code{filter!} is allowed, but not required to modify the structure of +@end deffn + @node List Searching @subsection List Searching diff --git a/doc/ref/srfi-modules.texi b/doc/ref/srfi-modules.texi index 0e0eb0917..82209ffe7 100644 --- a/doc/ref/srfi-modules.texi +++ b/doc/ref/srfi-modules.texi @@ -594,15 +594,8 @@ specific condition. Partitioning a list means to make two groups of list elements, one which contains the elements satisfying a condition, and the other for the elements which don't. -@deffn {Scheme Procedure} filter pred lst -@deffnx {Scheme Procedure} filter! pred lst -Return a list containing all elements from @var{lst} which satisfy the -predicate @var{pred}. The elements in the result list have the same -order as in @var{lst}. The order in which @var{pred} is applied to -the list elements is not specified. - -@code{filter!} is allowed, but not required to modify the structure of -@end deffn +The @code{filter} and @code{filter!} functions are implemented in the +Guile core, @xref{List Modification}. @deffn {Scheme Procedure} partition pred lst @deffnx {Scheme Procedure} partition! pred lst