summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Andreas Benkard <matthias@benkard.de>2008-07-06 16:36:47 +0200
committerMatthias Andreas Benkard <matthias@benkard.de>2008-07-06 16:36:47 +0200
commit31a9d8c4a59a2128cf345c3a00b0966cb31a6201 (patch)
treeb4b98b40b94638f962c98fe93ccdf4970591d316
parent23e870e266b3b4838b98e18db516501c9dbef695 (diff)
Wrap CAR, CDR, and CONS in functions.
-rw-r--r--list-functions.lisp19
1 files changed, 19 insertions, 0 deletions
diff --git a/list-functions.lisp b/list-functions.lisp
index 4b4b7fe..1aac8f8 100644
--- a/list-functions.lisp
+++ b/list-functions.lisp
@@ -50,6 +50,11 @@
(%defun cadr args
(car (cdr (first args))))
+(shadow 'car)
+(export 'car)
+(%defun car args
+ (sys::car (first args)))
+
(%defun cdaaar args
(cdr (caaar (first args))))
@@ -92,6 +97,11 @@
(%defun cddr args
(cdr (cdr (first args))))
+(shadow 'cdr)
+(export 'cdr)
+(%defun cdr args
+ (sys::cdr (first args)))
+
;;;;-----------------------------------------------------------------
;;;; SECOND ... TENTH
@@ -122,3 +132,12 @@
(%defun tenth args
(car (cdddr (cdddr (cdddr (car args))))))
+
+
+;;;;-----------------------------------------------------------------
+;;;; CONS
+;;;;-----------------------------------------------------------------
+(shadow 'cons)
+(export 'cons)
+(%defun cons args
+ (sys::cons (first args) (second args)))