File tree Expand file tree Collapse file tree 1 file changed +8
-7
lines changed Expand file tree Collapse file tree 1 file changed +8
-7
lines changed Original file line number Diff line number Diff line change @@ -1712,14 +1712,15 @@ the command `cider-debug-defun-at-point'."
1712
1712
(defun cider-insert-in-repl (form eval )
1713
1713
" Insert FORM in the REPL buffer and switch to it.
1714
1714
If EVAL is non-nil the form will also be evaluated."
1715
- (let ((start-pos (point )))
1716
- (while (string-match " \\ `[ \t\n\r ]+\\ |[ \t\n\r ]+\\ '" form)
1717
- (setq form (replace-match " " t t form)))
1718
- (with-current-buffer (cider-current-repl-buffer)
1715
+ (while (string-match " \\ `[ \t\n\r ]+\\ |[ \t\n\r ]+\\ '" form)
1716
+ (setq form (replace-match " " t t form)))
1717
+ (with-current-buffer (cider-current-repl-buffer)
1718
+ (goto-char (point-max ))
1719
+ (let ((beg (point )))
1719
1720
(insert form)
1720
- (indent-region start-pos (point ))
1721
- (when eval
1722
- (cider-repl-return) )))
1721
+ (indent-region beg (point ) ))
1722
+ (when eval
1723
+ (cider-repl-return)))
1723
1724
(cider-switch-to-repl-buffer))
1724
1725
1725
1726
(defun cider-insert-last-sexp-in-repl (&optional arg )
You can’t perform that action at this time.
0 commit comments