Plaster
New
List
Login
common-lisp
default
anonymous
2021.01.28 18:29:26
CL-USER> (defun a () (print "foo")) A CL-USER> (defun b () (bt:make-thread (lambda () (defun a () (print "bar")))) (sleep 3)) B CL-USER> (defun f () (let ((old-a (fdefinition 'a))) (unwind-protect (progn (a) (b)) (funcall old-a)))) F CL-USER> (f) "foo" WARNING: redefining COMMON-LISP-USER::A in DEFUN "foo" NIL
Raw
Annotate
Repaste
Edit