From deea79321e2b92cba37d383a24b6e9ce54c41f66 Mon Sep 17 00:00:00 2001 From: Joseph Corneli Date: Sun, 25 Jun 2017 09:37:14 +0100 Subject: [PATCH] fix quoting for lambdas, see https://stackoverflow.com/questions/16801396/when-should-emacs-function-syntax-be-used --- elisp/sch-prog.el | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/elisp/sch-prog.el b/elisp/sch-prog.el index d3e90ed..27cd2bd 100644 --- a/elisp/sch-prog.el +++ b/elisp/sch-prog.el @@ -10,19 +10,19 @@ (append '(progn) ; Produce a list of commands to produce temporary bindings. - (mapcar '(lambda (x) - `(fset ',(car x) - (node-fun ,(cdr x) - ',get-code - ',get-links))) + (mapcar '#(lambda (x) + `(fset ',(car x) + (node-fun ,(cdr x) + ',get-code + ',get-links))) links) (cdr code)) ;Produce a list of commands to reset function values. - (mapcar '(lambda (x) - (if (fboundp (car x)) - `(fset ',(car x) - ',(symbol-function (car x))) - `(fmakunbound ',(car x)))) + (mapcar '#(lambda (x) + (if (fboundp (car x)) + `(fset ',(car x) + ',(symbol-function (car x))) + `(fmakunbound ',(car x)))) links)))))) ;; Recursively replace the chunks to recover executable code. @@ -30,11 +30,11 @@ (defun tangle-module (node get-cont ins-links) (insert-chunk (funcall get-cont node) - (mapcar '(lambda (x) - (cons (car x) - (tangle-module (cdr x) - get-cont - ins-links))) + (mapcar '#(lambda (x) + (cons (car x) + (tangle-module (cdr x) + get-cont + ins-links))) (funcall ins-links node)))) ;; Given a node and an association list of replacement texts, insert @@ -46,4 +46,4 @@ ((equal (car body) '*insert*) (cdr (assoc (cadr body) chunks))) (t (cons (insert-chunk (car body) chunks) - (insert-chunk (cdr body) chunks))))) \ No newline at end of file + (insert-chunk (cdr body) chunks))))) -- 2.11.4.GIT