Some more functions

This commit is contained in:
2026-09-07 19:27:01 -07:00
parent 3d7b80691c
commit 6ddf45d68b
5 changed files with 77 additions and 16 deletions
-9
View File
@@ -53,15 +53,6 @@ DEFUN(cdr, "cdr", (LispVal * list), "(list)", "") {
return NILP(list) ? Qnil : XCDR(list);
}
DEFUN(length, "length", (LispVal * list), "(list)", "") {
CHECK_LISTP(list);
intptr_t len = list_length(list);
if (len == -1) {
lisp_signal(Qcircular_list_error, Qnil);
}
return MAKE_FIXNUM(len);
}
DEFUN(length_eq, "length=", (LispVal * list, LispVal *length), "(list length)",
"Return non-nil if LIST's length is LENGTH.") {
CHECK_LISTP(list);