diff options
| -rw-r--r-- | lisp/progmodes/gud.el | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/lisp/progmodes/gud.el b/lisp/progmodes/gud.el index a9ccdf38442..e99262dd670 100644 --- a/lisp/progmodes/gud.el +++ b/lisp/progmodes/gud.el | |||
| @@ -2735,6 +2735,7 @@ Obeying it means displaying in another window the specified file and line." | |||
| 2735 | (window (and buffer (or (get-buffer-window buffer) | 2735 | (window (and buffer (or (get-buffer-window buffer) |
| 2736 | (display-buffer buffer)))) | 2736 | (display-buffer buffer)))) |
| 2737 | (pos)) | 2737 | (pos)) |
| 2738 | (message "%s %s" (current-buffer) buffer) | ||
| 2738 | (if buffer | 2739 | (if buffer |
| 2739 | (progn | 2740 | (progn |
| 2740 | (with-current-buffer buffer | 2741 | (with-current-buffer buffer |
| @@ -2750,7 +2751,15 @@ Obeying it means displaying in another window the specified file and line." | |||
| 2750 | (setq pos (point)) | 2751 | (setq pos (point)) |
| 2751 | (or gud-overlay-arrow-position | 2752 | (or gud-overlay-arrow-position |
| 2752 | (setq gud-overlay-arrow-position (make-marker))) | 2753 | (setq gud-overlay-arrow-position (make-marker))) |
| 2753 | (set-marker gud-overlay-arrow-position (point) (current-buffer))) | 2754 | (set-marker gud-overlay-arrow-position (point) (current-buffer)) |
| 2755 | ;; If they turned on hl-line, move the hl-line highlight to | ||
| 2756 | ;; the arrow's line. | ||
| 2757 | (when (featurep 'hl-line) | ||
| 2758 | (cond | ||
| 2759 | (global-hl-line-mode | ||
| 2760 | (global-hl-line-highlight)) | ||
| 2761 | ((and hl-line-mode hl-line-sticky-flag) | ||
| 2762 | (hl-line-highlight))))) | ||
| 2754 | (cond ((or (< pos (point-min)) (> pos (point-max))) | 2763 | (cond ((or (< pos (point-min)) (> pos (point-max))) |
| 2755 | (widen) | 2764 | (widen) |
| 2756 | (goto-char pos)))) | 2765 | (goto-char pos)))) |