summaryrefslogtreecommitdiff
path: root/elisp
diff options
context:
space:
mode:
Diffstat (limited to 'elisp')
-rw-r--r--elisp/geiser-repl.el12
1 files changed, 4 insertions, 8 deletions
diff --git a/elisp/geiser-repl.el b/elisp/geiser-repl.el
index babebf8..8720a68 100644
--- a/elisp/geiser-repl.el
+++ b/elisp/geiser-repl.el
@@ -602,11 +602,8 @@ If SAVE-HISTORY is non-nil, save CMD in the REPL history."
(narrow-to-region (geiser-repl--last-prompt-end) (point-max))
(geiser-syntax--nesting-level)))
-(defun geiser-repl--mark-input-bounds (beg end)
- (add-text-properties beg end '(field t)))
-
-(defun geiser-repl--is-history-input ()
- (get-text-property (if (eolp) (save-excursion (comint-bol)) (point)) 'field))
+(defun geiser-repl--is-input ()
+ (not (eq (field-at-pos (point)) 'output)))
(defun geiser-repl--grab-input ()
(let ((pos (comint-bol)))
@@ -623,7 +620,6 @@ If SAVE-HISTORY is non-nil, save CMD in the REPL history."
(not (geiser-repl--is-debugging))
(compilation-forget-errors))
(geiser-repl--prepare-send)
- (geiser-repl--mark-input-bounds pmark eob)
(comint-send-input)
(when (string-match "^\\s-*$" intxt)
(comint-send-string proc (geiser-eval--scheme-str '(:ge no-values)))
@@ -633,7 +629,7 @@ If SAVE-HISTORY is non-nil, save CMD in the REPL history."
(interactive)
(let ((p (point)))
(cond ((< p (geiser-repl--last-prompt-start))
- (if (geiser-repl--is-history-input)
+ (if (geiser-repl--is-input)
(geiser-repl--grab-input)
(ignore-errors (compile-goto-error))))
((let ((inhibit-field-text-motion t))
@@ -677,7 +673,7 @@ buffer."
'((comint-highlight-prompt geiser-font-lock-repl-prompt)
(comint-highlight-input geiser-font-lock-repl-input)))
(set (make-local-variable 'mode-line-process) nil)
- (set (make-local-variable 'comint-use-prompt-regexp) t)
+ (set (make-local-variable 'comint-use-prompt-regexp) nil)
(set (make-local-variable 'comint-prompt-read-only)
geiser-repl-read-only-prompt-p)
(setq comint-process-echoes nil)