Commit 9f081286 authored by Richard M. Stallman's avatar Richard M. Stallman
Browse files

(Building Lists): remq moved elsewhere.

(Sets And Lists): remq moved here.
(Association Lists): Refer to assoc-string.
parent 5b2279a3
......@@ -707,31 +707,6 @@ x
@end example
@end defun
@defun remq object list
This function returns a copy of @var{list}, with all elements removed
which are @code{eq} to @var{object}. The letter @samp{q} in @code{remq}
says that it uses @code{eq} to compare @var{object} against the elements
of @code{list}.
@example
@group
(setq sample-list '(a b c a b c))
@result{} (a b c a b c)
@end group
@group
(remq 'a sample-list)
@result{} (b c b c)
@end group
@group
sample-list
@result{} (a b c a b c)
@end group
@end example
@noindent
The function @code{delq} offers a way to perform this operation
destructively. See @ref{Sets And Lists}.
@end defun
@defun copy-tree tree &optional vecp
This function returns a copy the tree @code{tree}. If @var{tree} is a
cons cell, this makes a new cons cell with the same @sc{car} and
......@@ -1346,9 +1321,34 @@ and the @code{(4)} in the @code{sample-list} are not @code{eq}:
@end group
@end example
The following two functions are like @code{memq} and @code{delq} but use
@code{equal} rather than @code{eq} to compare elements. @xref{Equality
Predicates}.
@defun remq object list
This function returns a copy of @var{list}, with all elements removed
which are @code{eq} to @var{object}. The letter @samp{q} in @code{remq}
says that it uses @code{eq} to compare @var{object} against the elements
of @code{list}.
@example
@group
(setq sample-list '(a b c a b c))
@result{} (a b c a b c)
@end group
@group
(remq 'a sample-list)
@result{} (b c b c)
@end group
@group
sample-list
@result{} (a b c a b c)
@end group
@end example
@noindent
The function @code{delq} offers a way to perform this operation
destructively. See @ref{Sets And Lists}.
@end defun
The following three functions are like @code{memq}, @code{delq} and
@code{remq}, but use @code{equal} rather than @code{eq} to compare
elements. @xref{Equality Predicates}.
@defun member object list
The function @code{member} tests to see whether @var{object} is a member
......@@ -1541,9 +1541,9 @@ Here is another example, in which the keys and values are not symbols:
@end smallexample
@end defun
The functions @code{assoc-ignore-representation} and
@code{assoc-ignore-case} are much like @code{assoc} except using
@code{compare-strings} to do the comparison. @xref{Text Comparison}.
The function @code{assoc-string} is much like @code{assoc} except
that it ignores certain differences between strings. @xref{Text
Comparison}.
@defun rassoc value alist
This function returns the first association with value @var{value} in
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment