Function: cider-repl-return

cider-repl-return is an interactive and byte-compiled function defined in cider-repl.el.

Signature

(cider-repl-return &optional END-OF-INPUT)

Documentation

Evaluate the current input string, or insert a newline.

Send the current input only if a whole expression has been entered, i.e. the parenthesis are matched. When END-OF-INPUT is non-nil, send the input even if the parentheses are not balanced.

Key Bindings

Source Code

;; Defined in ~/.emacs.d/elpa/cider-20260414.1619/cider-repl.el
(defun cider-repl-return (&optional end-of-input)
  "Evaluate the current input string, or insert a newline.
Send the current input only if a whole expression has been entered,
i.e. the parenthesis are matched.
When END-OF-INPUT is non-nil, send the input even if the parentheses
are not balanced."
  (interactive "P")
  (cond
   (end-of-input
    (cider-repl--send-input))
   ((and (get-text-property (point) 'cider-old-input)
         (< (point) cider-repl-input-start-mark))
    (cider-repl--grab-old-input end-of-input))
   ((cider-repl--input-complete-p cider-repl-input-start-mark (point-max))
    (cider-repl--send-input t))
   (t
    (cider-repl-newline-and-indent)
    (message "[input not complete]"))))