Apply and read errors
This commit is contained in:
+23
-4
@@ -1,6 +1,25 @@
|
||||
;; -*- mode: lisp-data -*-
|
||||
|
||||
(prin1 (let ((l (block 'c (lambda () (return-from 'd 3)))))
|
||||
(block 'c
|
||||
(funcall l))))
|
||||
(write-byte ?\n)
|
||||
(fset 'defmacro (cons 'macro
|
||||
(lambda (name lambda-list &rest body)
|
||||
"Define NAME to be a macro."
|
||||
(declare (name defmacro))
|
||||
(list 'fset (list 'quote name)
|
||||
(list 'cons
|
||||
(quote 'macro)
|
||||
(list* 'lambda lambda-list
|
||||
(list 'declare (list 'name name))
|
||||
body))))))
|
||||
|
||||
(defmacro defun (name lambda-list &rest body)
|
||||
"Define NAME to be a function."
|
||||
(list 'fset (list 'quote name)
|
||||
(list* 'lambda lambda-list
|
||||
(list 'declare (list 'name name))
|
||||
body)))
|
||||
|
||||
(defun princln (datum &optional print-char-fun)
|
||||
(princ datum print-char-fun)
|
||||
(funcall (or print-char-fun 'write-byte) ?\n))
|
||||
|
||||
(princln (apply 'cons '(a b)))
|
||||
|
||||
Reference in New Issue
Block a user