summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNicolas Goaziou <mail@nicolasgoaziou.fr>2018-03-25 22:55:14 +0200
committerNicolas Goaziou <mail@nicolasgoaziou.fr>2018-03-25 22:55:14 +0200
commit9e70db6babcbfa457461bea3745410d372cc241a (patch)
treef20477b08cb44ab02bad2ad87cd42902f4cf7a32
parent6261bbd20b51fc38afd022fcb46370fd8d429553 (diff)
downloadorg-mode-9e70db6babcbfa457461bea3745410d372cc241a.tar.gz
Revert "ob-table: Fix org-sbe's handling of list arguments"
This reverts commit c9d617b32278c04e114bd7c6375ca53636a005ba.
-rw-r--r--lisp/ob-table.el17
-rw-r--r--testing/lisp/test-ob-table.el23
2 files changed, 6 insertions, 34 deletions
diff --git a/lisp/ob-table.el b/lisp/ob-table.el
index 17810dd..105aca5 100644
--- a/lisp/ob-table.el
+++ b/lisp/ob-table.el
@@ -132,17 +132,12 @@ as shown in the example below.
"("
(mapconcat
(lambda (var-spec)
- (cond
- ((> (length (cdr var-spec)) 1)
- (format "%S='%S"
- (car var-spec)
- (mapcar #'read (cdr var-spec))))
- ((stringp (cadr var-spec))
- (format "%S=%s"
- (car var-spec) (cadr var-spec)))
- (t
- (format "%S=%S"
- (car var-spec) (cadr var-spec)))))
+ (if (> (length (cdr var-spec)) 1)
+ (format "%S='%S"
+ (car var-spec)
+ (mapcar #'read (cdr var-spec)))
+ (format "%S=%s"
+ (car var-spec) (cadr var-spec))))
',variables ", ")
")")))))
(org-babel-execute-src-block
diff --git a/testing/lisp/test-ob-table.el b/testing/lisp/test-ob-table.el
index fb6d057..3d9b1d1 100644
--- a/testing/lisp/test-ob-table.el
+++ b/testing/lisp/test-ob-table.el
@@ -52,29 +52,6 @@
1
"#+TBLFM: $2 = '(org-sbe identity (x $$1))"))
-(ert-deftest test-ob-table/sbe-list ()
- "Test that `org-sbe' can correctly handle ranges as lists."
- (org-test-table-target-expect
- "
-#+name: concat
-#+begin_src emacs-lisp :eval yes
- (mapconcat #'identity x \"\")
-#+end_src
-
-| foo | bar | replace |
-"
- "
-#+name: concat
-#+begin_src emacs-lisp :eval yes
- (mapconcat #'identity x \"\")
-#+end_src
-
-| foo | bar | foobar |
-"
- 1
- "#+TBLFM: $3 = '(org-sbe concat (x (list $1..$2)))"
- "#+TBLFM: $3 = '(org-sbe concat (x $ (list $1..$2)))"))
-
(provide 'test-ob-table)
;;; test-ob-table.el ends here