Skip to content

Commit e8dd98d

Browse files
matthuszaghyantar92
authored andcommitted
ob-core.el: Fix behavior of lambda default header arg vars
* lisp/ob-core.el (org-babel-merge-params): Permit multiple :var default header arguments when using closures.
1 parent e0e016c commit e8dd98d

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

lisp/ob-core.el

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2749,6 +2749,11 @@ parameters when merging lists."
27492749
(pcase pair
27502750
(`(:var . ,value)
27512751
(let ((name (cond
2752+
;; Default header arguments can accept lambda
2753+
;; functions. We uniquely identify the var
2754+
;; according to the full string contents of
2755+
;; the lambda function.
2756+
((functionp value) value)
27522757
((listp value) (car value))
27532758
((string-match "^\\([^= \f\t\n\r\v]+\\)[ \t]*=" value)
27542759
(intern (match-string 1 value)))

0 commit comments

Comments
 (0)