The call to ecl_endp() ensures that the argument is a list.

This commit is contained in:
Juan Jose Garcia Ripoll 2009-02-28 13:41:35 +01:00
parent e758c7591a
commit 3da7384797

View file

@ -34,10 +34,10 @@ cl_object
cl_values_list(cl_object list)
{
VALUES(0) = Cnil;
for (NVALUES=0; !ecl_endp(list); list=CDR(list)) {
for (NVALUES=0; !ecl_endp(list); list=ECL_CONS_CDR(list)) {
if (NVALUES == ECL_MULTIPLE_VALUES_LIMIT)
FEerror("Too many values in VALUES-LIST",0);
VALUES(NVALUES++) = CAR(list);
VALUES(NVALUES++) = ECL_CONS_CAR(list);
}
returnn(VALUES(0));
}