[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/org 58db28d 2/2: ob-R: Tidy up bits of the async implem
From: |
ELPA Syncer |
Subject: |
[elpa] externals/org 58db28d 2/2: ob-R: Tidy up bits of the async implementation |
Date: |
Thu, 18 Nov 2021 05:57:29 -0500 (EST) |
branch: externals/org
commit 58db28db04d580d2757c6c96d8da1b3f8a943d2a
Author: Jeremie Juste <jeremiejuste@gmail.com>
Commit: TEC <tec@tecosaur.com>
ob-R: Tidy up bits of the async implementation
* ob-R.el (ob-session-async-org-babel-R-evaluate-session): Use
defvaralias for `ess-eval-visibly-p' instead of modifying user-defined
variable. Remove temporary declaration that silences the byte-compiler.
* ob-R.el (org-babel-R-evaluate,
ob-session-async-org-babel-R-evaluate-session, org-babel-R-evaluate):
Remove mentions of unused argument `result-params'.
---
lisp/ob-R.el | 22 +++++-----------------
1 file changed, 5 insertions(+), 17 deletions(-)
diff --git a/lisp/ob-R.el b/lisp/ob-R.el
index 4925604..66f3f9f 100644
--- a/lisp/ob-R.el
+++ b/lisp/ob-R.el
@@ -40,13 +40,6 @@
(declare-function ess-wait-for-process "ext:ess-inf"
(&optional proc sec-prompt wait force-redisplay))
-;; FIXME: Temporary declaration to silence the byte-compiler
-(defvar user-inject-src-param)
-(defvar ess-eval-visibly-tmp)
-(defvar ess-eval-visibly)
-(defvar ess-inject-source)
-(defvar user-inject-src-param)
-
(defconst org-babel-header-args:R
'((width . :any)
(height . :any)
@@ -385,7 +378,7 @@ Has four %s escapes to be filled in:
(if session
(if async
(ob-session-async-org-babel-R-evaluate-session
- session body result-type result-params column-names-p row-names-p)
+ session body result-type column-names-p row-names-p)
(org-babel-R-evaluate-session
session body result-type result-params column-names-p row-names-p))
(org-babel-R-evaluate-external-process
@@ -486,7 +479,7 @@ Insert hline if column names in output have been requested."
(defconst ob-session-async-R-indicator "'ob_comint_async_R_%s_%s'")
(defun ob-session-async-org-babel-R-evaluate-session
- (session body result-type _ column-names-p row-names-p)
+ (session body result-type column-names-p row-names-p)
"Asynchronously evaluate BODY in SESSION.
Returns a placeholder string for insertion, to later be replaced
by `org-babel-comint-async-filter'."
@@ -525,7 +518,8 @@ by `org-babel-comint-async-filter'."
(output
(let ((uuid (md5 (number-to-string (random 100000000))))
(ess-local-process-name
- (process-name (get-buffer-process session))))
+ (process-name (get-buffer-process session)))
+ (ess-eval-visibly-p nil))
(with-temp-buffer
(insert (format ob-session-async-R-indicator
"start" uuid))
@@ -534,13 +528,7 @@ by `org-babel-comint-async-filter'."
(insert "\n")
(insert (format ob-session-async-R-indicator
"end" uuid))
- (setq ess-eval-visibly-tmp ess-eval-visibly)
- (setq user-inject-src-param ess-inject-source)
- (setq ess-eval-visibly nil)
- (setq ess-inject-source 'function-and-buffer)
- (ess-eval-buffer nil))
- (setq ess-eval-visibly ess-eval-visibly-tmp)
- (setq ess-inject-source user-inject-src-param)
+ (ess-eval-buffer nil ))
uuid))))
(defun ob-session-async-R-value-callback (params tmp-file)