Article View: comp.lang.lisp.x
Article #103Two minor bug fixes for version 2.x
From: Tom Almy
Date: Tue, 08 May 1990 14:35
Date: Tue, 08 May 1990 14:35
46 lines
1528 bytes
1528 bytes
Bug: APPEND does not signal an error if any of its arguments (except for the
last argument) is not a true list.
Repair: In xllist.c, xappend()
while (xlargc > 1) {
/* append each element of this list to the result list */
for (list = nextarg(); consp(list); list = cdr(list)) {
next = consa(car(list));
if (val) rplacd(last,next);
else val = next;
last = next;
}
if (list != NIL) xlbadtype(*--xlargv); /*ADDED LINE*/
}
Bug: NCONC does not signal an error if any of its arguments (except for the
last argument) is not a list.
In xllist.c, xnconc()
/* ignore everything except lists */
/* Delete this comment ^^^^^^^^^^^^^^^^^^^^ */
if (((next = nextarg()) != NIL) && consp(next)) {
/* change ^ was 0 */
/* concatenate this list to the result list */
if (val) rplacd(last,next);
else val = next;
/* find the end of the list */
while (consp(cdr(next)))
next = cdr(next);
last = next;
}
else xlbadtype(*--xlargv); /* ADDED LINE */
}
Tom Almy
toma@tekgvs.labs.tek.com
Standard Disclaimers Apply
Technical Details
Message-ID:
<7464@tekgvs.LABS.TEK.COM>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!uunet!zephyr.ens.tek.com!tekcrl!tekgvs!tomaShow Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!uunet!zephyr.ens.tek.com!tekcrl!tekgvs!toma From: toma@tekgvs.LABS.TEK.COM (Tom Almy) Newsgroups: comp.lang.lisp.x Subject: Two minor bug fixes for version 2.x Message-ID: <7464@tekgvs.LABS.TEK.COM> Date: 8 May 90 14:35:05 GMT Reply-To: toma@tekgvs.LABS.TEK.COM (Tom Almy) Organization: Tektronix, Inc., Beaverton, OR. Lines: 46