|
|
|
|
|
by kazinator
4061 days ago
|
|
Way too cumbersome, sorry. TXR Lisp: @(do
(macro-time
(defun abc-proc (n)
^(defun ,n () (pprinl ',n))))
(defmacro abc-procs (. n)
^(progn ,*[mapcar abc-proc n]))
(abc-procs a b c)
(defun exec (order callbacks)
(each ((i order))
[[callbacks i]]))
(exec '(0 0 1 2 1 2) '(a b c)))
$ txr test.txr
a
a
b
c
b
c
Variation on exec: (defun exec (order callbacks)
(mapdo (op [callbacks @1]) order))
|
|