branch: elpa/inf-clojure
commit f0e4727b5a39f6360a4418f9a04fa91be898b2d0
Author: Bozhidar Batsov <[email protected]>
Commit: Bozhidar Batsov <[email protected]>

    Fix prefix-arg vs current-prefix-arg in REPL startup
    
    prefix-arg is only set during command-execute and is not reliable
    when these functions are called programmatically. Use
    current-prefix-arg which is correctly set by the interactive spec.
---
 inf-clojure.el | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/inf-clojure.el b/inf-clojure.el
index 35c33f925e..2b2a7f3e7f 100644
--- a/inf-clojure.el
+++ b/inf-clojure.el
@@ -857,7 +857,7 @@ process buffer for a list of commands.)"
             (cmdlist (if (consp cmd)
                          (list cmd)
                        (split-string-and-unquote cmd)))
-            (repl-type (or (unless prefix-arg
+            (repl-type (or (unless current-prefix-arg
                              inf-clojure-custom-repl-type)
                            (car (rassoc cmd inf-clojure-startup-forms))
                            (inf-clojure--prompt-repl-type))))
@@ -959,7 +959,7 @@ defaults provided in 
`inf-clojure-socket-repl-startup-forms'."
   (let* ((host "localhost")
          (port (or inf-clojure-socket-repl-port (+ 5500 (random 500))))
          (project-dir (inf-clojure--project-dir))
-         (repl-type (or (unless prefix-arg
+         (repl-type (or (unless current-prefix-arg
                           inf-clojure-custom-repl-type)
                         (car (rassoc cmd 
inf-clojure-socket-repl-startup-forms))
                         (inf-clojure--prompt-repl-type)))

Reply via email to