@@ -170,9 +170,10 @@ nREPL connection."
170170(defun cider-nrepl-op-supported-p (op &optional connection skip-ensure )
171171 " Check whether the CONNECTION supports the nREPL middleware OP.
172172Skip check if repl is active if SKIP-ENSURE is non nil."
173- (nrepl-op-supported-p op (or connection (cider-current-repl nil (if skip-ensure
174- nil
175- 'ensure )))))
173+ (nrepl-op-supported-p op (or connection
174+ (cider-current-repl 'infer (if skip-ensure
175+ nil
176+ 'ensure )))))
176177
177178(defun cider-ensure-op-supported (op )
178179 " Check for support of middleware op OP.
@@ -187,7 +188,9 @@ REQUEST is a pair list of the form (\"op\" \"operation\" \"par1-name\"
187188If CONNECTION is provided dispatch to that connection instead of
188189the current connection. Return the id of the sent message.
189190If TOOLING is truthy then the tooling session is used."
190- (nrepl-send-request request callback (or connection (cider-current-repl 'any 'ensure )) tooling))
191+ (nrepl-send-request request callback (or connection
192+ (cider-current-repl 'infer 'ensure ))
193+ tooling))
191194
192195(defun cider-nrepl-send-sync-request (request &optional connection
193196 abort-on-input callback )
@@ -199,15 +202,15 @@ at the first sign of user input, so as not to hang the
199202interface.
200203if CALLBACK is non-nil, it will additionally be called on all received messages."
201204 (nrepl-send-sync-request request
202- (or connection (cider-current-repl 'any 'ensure ))
205+ (or connection (cider-current-repl 'infer 'ensure ))
203206 abort-on-input
204207 nil
205208 callback))
206209
207210(defun cider-nrepl-send-unhandled-request (request &optional connection )
208211 " Send REQUEST to the nREPL CONNECTION and ignore any responses.
209212Immediately mark the REQUEST as done. Return the id of the sent message."
210- (let* ((conn (or connection (cider-current-repl 'any 'ensure )))
213+ (let* ((conn (or connection (cider-current-repl 'infer 'ensure )))
211214 (id (nrepl-send-request request #'ignore conn)))
212215 (with-current-buffer conn
213216 (nrepl--mark-id-completed id))
@@ -219,7 +222,7 @@ If NS is non-nil, include it in the request. LINE and COLUMN, if non-nil,
219222define the position of INPUT in its buffer. ADDITIONAL-PARAMS is a plist
220223to be appended to the request message. CONNECTION is the connection
221224buffer, defaults to (cider-current-repl)."
222- (let ((connection (or connection (cider-current-repl nil 'ensure )))
225+ (let ((connection (or connection (cider-current-repl 'infer 'ensure )))
223226 (eval-buffer (current-buffer )))
224227 (run-hooks 'cider-before-eval-hook )
225228 (nrepl-request:eval input
@@ -238,7 +241,10 @@ buffer, defaults to (cider-current-repl)."
238241(defun cider-nrepl-sync-request:eval (input &optional connection ns )
239242 " Send the INPUT to the nREPL CONNECTION synchronously.
240243If NS is non-nil, include it in the eval request."
241- (nrepl-sync-request:eval input (or connection (cider-current-repl nil 'ensure )) ns))
244+ (nrepl-sync-request:eval input
245+ (or connection
246+ (cider-current-repl 'infer 'ensure ))
247+ ns))
242248
243249(defcustom cider-format-code-options nil
244250 " A map of options that will be passed to `cljfmt' to format code.
@@ -426,7 +432,7 @@ clobber *1/2/3)."
426432 ; ; namespace forms are always evaluated in the "user" namespace
427433 (nrepl-request:eval input
428434 callback
429- (or connection (cider-current-repl nil 'ensure ))
435+ (or connection (cider-current-repl 'infer 'ensure ))
430436 ns nil nil nil 'tooling ))
431437
432438(defun cider-sync-tooling-eval (input &optional ns connection )
@@ -437,7 +443,7 @@ bindings of the primary eval nREPL session (e.g. this is not going to
437443clobber *1/2/3)."
438444 ; ; namespace forms are always evaluated in the "user" namespace
439445 (nrepl-sync-request:eval input
440- (or connection (cider-current-repl nil 'ensure ))
446+ (or connection (cider-current-repl 'infer 'ensure ))
441447 ns
442448 'tooling ))
443449
@@ -458,7 +464,7 @@ itself is present."
458464 " Interrupt any pending evaluations."
459465 (interactive )
460466 ; ; FIXME: does this work correctly in cljc files?
461- (with-current-buffer (cider-current-repl nil 'ensure )
467+ (with-current-buffer (cider-current-repl 'infer 'ensure )
462468 (let ((pending-request-ids (cider-util--hash-keys nrepl-pending-requests)))
463469 (dolist (request-id pending-request-ids)
464470 (nrepl-request:interrupt
0 commit comments