+2000-08-19 Miles Bader <miles@gnu.org>
+
+ * emacs-lisp/bytecomp.el (byte-compile-beginning-of-line):
+ Compiler macro removed; beginning-of-line is no longer always
+ equivalent to forward-line, in the presence of fields.
+
+ * comint.el (comint-output-filter): Remove ad-hoc saving of
+ restriction, and just use save-restriction, now that it works
+ correctly. Don't adjust comint-last-input-start to account for
+ our insertion; it shouldn't have moved because we don't use
+ insert-before-markers anymore. Comment out call to
+ `force-mode-line-update'; why is it here?
+
+ * gud.el (gud-basic-call): Temporarily widen gud comint buffer
+ while checking for prompt to delete. Use `forward-line 0'
+ instead of beginning-of-line.
+ (gud-filter): Temporarily widen gud comint buffer while
+ examining output.
+
2000-08-18 Stefan Monnier <monnier@cs.yale.edu>
* textmodes/ispell.el (ispell-menu-map-needed): Put back the boundp
(with-current-buffer (process-buffer proc)
;; If we have been so requested, delete the debugger prompt.
- (if (marker-buffer gud-delete-prompt-marker)
- (progn
- (delete-region (process-mark proc) gud-delete-prompt-marker)
- (set-marker gud-delete-prompt-marker nil)))
- ;; Save the process output, checking for source file markers.
- (setq output (gud-marker-filter string))
- ;; Check for a filename-and-line number.
- ;; Don't display the specified file
- ;; unless (1) point is at or after the position where output appears
- ;; and (2) this buffer is on the screen.
- (setq process-window
- (and gud-last-frame
- (>= (point) (process-mark proc))
- (get-buffer-window (current-buffer))))
+ (save-restriction
+ (widen)
+ (if (marker-buffer gud-delete-prompt-marker)
+ (progn
+ (delete-region (process-mark proc)
+ gud-delete-prompt-marker)
+ (set-marker gud-delete-prompt-marker nil)))
+ ;; Save the process output, checking for source file markers.
+ (setq output (gud-marker-filter string))
+ ;; Check for a filename-and-line number.
+ ;; Don't display the specified file
+ ;; unless (1) point is at or after the position where output appears
+ ;; and (2) this buffer is on the screen.
+ (setq process-window
+ (and gud-last-frame
+ (>= (point) (process-mark proc))
+ (get-buffer-window (current-buffer)))))
;; Let the comint filter do the actual insertion.
;; That lets us inherit various comint features.
;; Arrange for the current prompt to get deleted.
(save-excursion
(set-buffer gud-comint-buffer)
- (goto-char (process-mark proc))
- (beginning-of-line)
- (if (looking-at comint-prompt-regexp)
- (set-marker gud-delete-prompt-marker (point))))
+ (save-restriction
+ (widen)
+ (goto-char (process-mark proc))
+ (forward-line 0)
+ (if (looking-at comint-prompt-regexp)
+ (set-marker gud-delete-prompt-marker (point)))))
(process-send-string proc command)))
(defun gud-refresh (&optional arg)