From 2d675630e76d0ae00059fe9972e4c606dda2f42d Mon Sep 17 00:00:00 2001 From: Juan Jose Garcia Ripoll Date: Sun, 15 Nov 2009 10:49:33 +0100 Subject: [PATCH] src/c/list.d: in APPEND, add back error detection for non proper lists. --- src/c/list.d | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/c/list.d b/src/c/list.d index a1258c5ec..099ce972b 100644 --- a/src/c/list.d +++ b/src/c/list.d @@ -210,6 +210,10 @@ append_into(cl_object head, cl_object *tail, cl_object l) tail = append_into(head, tail, other); } if (narg) { + if (!Null(*tail)) { + /* (APPEND '(1 . 2) 3) */ + FEtype_error_proper_list(head); + } *tail = cl_va_arg(rest); } @(return head) @@ -223,6 +227,10 @@ ecl_append(cl_object x, cl_object y) if (!Null(x)) { tail = append_into(head, tail, x); } + if (!Null(*tail)) { + /* (APPEND '(1 . 2) 3) */ + FEtype_error_proper_list(head); + } *tail = y; return head; }