Browse Source

remove when-let which isn't a real Emacs macro

* lisp/ob-exp.el (org-babel-exp-code): Remove usage of a macro which
  is defined locally on my system, but not globally in Emacs.
Eric Schulte 14 years ago
parent
commit
120e621443
1 changed files with 5 additions and 4 deletions
  1. 5 4
      lisp/ob-exp.el

+ 5 - 4
lisp/ob-exp.el

@@ -245,10 +245,11 @@ The function respects the value of the :exports header argument."
 
 
 (defun org-babel-exp-code (info)
 (defun org-babel-exp-code (info)
   "Return the original code block formatted for export."
   "Return the original code block formatted for export."
-  (org-fill-template "#+BEGIN_SRC %lang%flags\n%body\n#+END_SRC\n"
-		     `(("lang"  . ,(nth 0 info))
-		       ("flags" . ,(when-let (f (nth 3 info)) (concat " " f)))
-		       ("body"  . ,(nth 1 info)))))
+  (org-fill-template
+   "#+BEGIN_SRC %lang%flags\n%body\n#+END_SRC\n"
+   `(("lang"  . ,(nth 0 info))
+     ("flags" . ,((lambda (f) (when f (concat " " f))) (nth 3 info)))
+     ("body"  . ,(nth 1 info)))))
 
 
 (defun org-babel-exp-results (info type &optional silent hash)
 (defun org-babel-exp-results (info type &optional silent hash)
   "Evaluate and return the results of the current code block for export.
   "Evaluate and return the results of the current code block for export.