Browse Source

re-apply an orphaned anonymous lambda function

* lisp/ob-tangle.el (org-babel-tangle-collect-blocks): Re-apply an
  orphaned anonymous lambda function.
Eric Schulte 4 years ago
parent
commit
be3dad300f
1 changed files with 11 additions and 11 deletions
  1. 11 11
      lisp/ob-tangle.el

+ 11 - 11
lisp/ob-tangle.el

@@ -365,17 +365,17 @@ source code blocks by language.  Optional argument TANGLE-FILE
 can be used to limit the collected code blocks by target file."
   (let ((block-counter 1) (current-heading "") blocks by-lang)
     (org-babel-map-src-blocks (buffer-file-name)
-      (lambda (new-heading)
-	(if (not (string= new-heading current-heading))
-	    (progn
-	      (setq block-counter 1)
-	      (setq current-heading new-heading))
-	  (setq block-counter (+ 1 block-counter))))
-      (replace-regexp-in-string "[ \t]" "-"
-				(condition-case nil
-				    (or (nth 4 (org-heading-components))
-					"(dummy for heading without text)")
-				  (error (buffer-file-name))))
+      ((lambda (new-heading)
+	 (if (not (string= new-heading current-heading))
+	     (progn
+	       (setq block-counter 1)
+	       (setq current-heading new-heading))
+	   (setq block-counter (+ 1 block-counter))))
+       (replace-regexp-in-string "[ \t]" "-"
+				 (condition-case nil
+				     (or (nth 4 (org-heading-components))
+					 "(dummy for heading without text)")
+				   (error (buffer-file-name)))))
       (let* ((info (org-babel-get-src-block-info 'light))
 	     (src-lang (nth 0 info))
 	     (src-tfile (cdr (assoc :tangle (nth 2 info)))))