diff --git a/lisp/ob-core.el b/lisp/ob-core.el index 7b7b3148e..da9fa31e0 100644 --- a/lisp/ob-core.el +++ b/lisp/ob-core.el @@ -3135,10 +3135,6 @@ Callers of this function will probably want to add an entry to (when (and sym (boundp sym)) (defvaralias (intern (concat "org-babel-" var ":" new)) sym))))) -(defun org-babel-strip-quotes (string) - "Strip \\\"s from around a string, if applicable." - (org-unbracket-string "\"" "\"" string)) - (provide 'ob-core) ;; Local variables: diff --git a/lisp/ob-haskell.el b/lisp/ob-haskell.el index 8fd61990d..ff975f7f9 100644 --- a/lisp/ob-haskell.el +++ b/lisp/ob-haskell.el @@ -74,17 +74,16 @@ (org-babel-variable-assignments:haskell params))) (session (org-babel-haskell-initiate-session session params)) (comint-preoutput-filter-functions - (cons 'ansi-color-filter-apply comint-preoutput-filter-functions)) + (cons 'ansi-color-filter-apply comint-preoutput-filter-functions)) (raw (org-babel-comint-with-output (session org-babel-haskell-eoe t full-body) (insert (org-trim full-body)) (comint-send-input nil t) (insert org-babel-haskell-eoe) (comint-send-input nil t))) - (results (mapcar - #'org-babel-strip-quotes - (cdr (member org-babel-haskell-eoe - (reverse (mapcar #'org-trim raw))))))) + (results (mapcar #'org-strip-quotes + (cdr (member org-babel-haskell-eoe + (reverse (mapcar #'org-trim raw))))))) (org-babel-reassemble-table (let ((result (pcase result-type diff --git a/lisp/ob-octave.el b/lisp/ob-octave.el index 61492c758..bc3dc4c2f 100644 --- a/lisp/ob-octave.el +++ b/lisp/ob-octave.el @@ -237,13 +237,11 @@ value of the last statement in BODY, as elisp." (`output (setq results (if matlabp - (cdr (reverse (delq "" (mapcar - #'org-babel-strip-quotes - (mapcar #'org-trim raw))))) + (cdr (reverse (delq "" (mapcar #'org-strip-quotes + (mapcar #'org-trim raw))))) (cdr (member org-babel-octave-eoe-output - (reverse (mapcar - #'org-babel-strip-quotes - (mapcar #'org-trim raw))))))) + (reverse (mapcar #'org-strip-quotes + (mapcar #'org-trim raw))))))) (mapconcat #'identity (reverse results) "\n"))))) (defun org-babel-octave-import-elisp-from-file (file-name) diff --git a/lisp/org-compat.el b/lisp/org-compat.el index a72627a61..2427c7da9 100644 --- a/lisp/org-compat.el +++ b/lisp/org-compat.el @@ -464,6 +464,9 @@ use of this function is for the stuck project list." (debug (body))) `(with-silent-modifications ,@body)) +(define-obsolete-function-alias 'org-babel-strip-quotes + 'org-strip-quotes "Org 9.2") + ;;;; Obsolete link types (eval-after-load 'org diff --git a/lisp/org-macs.el b/lisp/org-macs.el index 93c2140a0..fa052a9cf 100644 --- a/lisp/org-macs.el +++ b/lisp/org-macs.el @@ -882,6 +882,10 @@ removed." (substring string (length pre) (- (length post))) string)) +(defun org-strip-quotes (string) + "Strip double quotes from around a string, if applicable." + (org-unbracket-string "\"" "\"" string)) + (defsubst org-current-line-string (&optional to-here) (buffer-substring (point-at-bol) (if to-here (point) (point-at-eol))))