summaryrefslogtreecommitdiff
path: root/lisp/subr.el
diff options
context:
space:
mode:
authorChong Yidong <cyd@stupidchicken.com>2009-04-29 04:46:15 +0000
committerChong Yidong <cyd@stupidchicken.com>2009-04-29 04:46:15 +0000
commit753bc4f6500383c347daa5d85c7023eee370d45c (patch)
tree593e90ad9db069db059f1e5b7aa465e98e5dfad5 /lisp/subr.el
parentc3c963a026f57b20c7798f552aa40b7fbb1027c9 (diff)
downloademacs-753bc4f6500383c347daa5d85c7023eee370d45c.tar.gz
* subr.el (assoc-default): Doc fix.
Diffstat (limited to 'lisp/subr.el')
-rw-r--r--lisp/subr.el12
1 files changed, 7 insertions, 5 deletions
diff --git a/lisp/subr.el b/lisp/subr.el
index 5372adb510c..aa60ab7ca80 100644
--- a/lisp/subr.el
+++ b/lisp/subr.el
@@ -371,11 +371,13 @@ argument VECP, this copies vectors as well as conses."
(defun assoc-default (key alist &optional test default)
"Find object KEY in a pseudo-alist ALIST.
-ALIST is a list of conses or objects. Each element (or the element's car,
-if it is a cons) is compared with KEY by evaluating (TEST (car elt) KEY).
-If that is non-nil, the element matches;
-then `assoc-default' returns the element's cdr, if it is a cons,
-or DEFAULT if the element is not a cons.
+ALIST is a list of conses or objects. Each element
+ (or the element's car, if it is a cons) is compared with KEY by
+ calling TEST, with two arguments: (i) the element or its car,
+ and (ii) KEY.
+If that is non-nil, the element matches; then `assoc-default'
+ returns the element's cdr, if it is a cons, or DEFAULT if the
+ element is not a cons.
If no element matches, the value is nil.
If TEST is omitted or nil, `equal' is used."