# HG changeset patch # User Dave Love # Date 943543403 0 # Node ID f908261703d393b9869fb8cfda0a623e93f4d2bf # Parent 829102550ebe0cc6606d95b54a727f9fa32613b0 (Fnthcdr, Fnreverse): Inline cdr. (Fmember, Fdelq, Fdelete): Inline car. (Fy_or_n_p): Doc fix. diff -r 829102550ebe -r f908261703d3 src/fns.c --- a/src/fns.c Thu Nov 25 15:01:15 1999 +0000 +++ b/src/fns.c Thu Nov 25 15:23:23 1999 +0000 @@ -1273,7 +1273,9 @@ for (i = 0; i < num && !NILP (list); i++) { QUIT; - list = Fcdr (list); + if (! CONSP (list)) + wrong_type_argument (Qlistp, list); + list = XCDR (list); } return list; } @@ -1316,7 +1318,9 @@ for (tail = list; !NILP (tail); tail = XCDR (tail)) { register Lisp_Object tem; - tem = Fcar (tail); + if (! CONSP (tail)) + wrong_type_argument (Qlistp, list); + tem = XCAR (tail); if (! NILP (Fequal (elt, tem))) return tail; QUIT; @@ -1558,7 +1562,9 @@ prev = Qnil; while (!NILP (tail)) { - tem = Fcar (tail); + if (! CONSP (tail)) + wrong_type_argument (Qlistp, list); + tem = XCAR (tail); if (EQ (elt, tem)) { if (NILP (prev)) @@ -1592,7 +1598,9 @@ prev = Qnil; while (!NILP (tail)) { - tem = Fcar (tail); + if (! CONSP (tail)) + wrong_type_argument (Qlistp, list); + tem = XCAR (tail); if (! NILP (Fequal (elt, tem))) { if (NILP (prev)) @@ -1622,7 +1630,9 @@ while (!NILP (tail)) { QUIT; - next = Fcdr (tail); + if (! CONSP (tail)) + wrong_type_argument (Qlistp, list); + next = XCDR (tail); Fsetcdr (tail, prev); prev = tail; tail = next; @@ -2551,7 +2561,7 @@ It should end in a space; `y-or-n-p' adds `(y or n) ' to it.\n\ No confirmation of the answer is requested; a single character is enough.\n\ Also accepts Space to mean yes, or Delete to mean no. \(Actually, it uses\n\ -the bindings in query-replace-map; see the documentation of that variable\n\ +the bindings in `query-replace-map'; see the documentation of that variable\n\ for more information. In this case, the useful bindings are `act', `skip',\n\ `recenter', and `quit'.\)\n\ \n\