comparison lisp/gud.el @ 2594:e1277aec1738

(gud-format-command): Fix %f expansuuin to send ondly the basename of files to gdb.
author Eric S. Raymond <esr@snark.thyrsus.com>
date Tue, 27 Apr 1993 21:59:46 +0000
parents 839d67a1dc58
children 372386917f03
comparison
equal deleted inserted replaced
2593:5457416cd817 2594:e1277aec1738
580 (let ((insource (not (eq (current-buffer) gud-comint-buffer)))) 580 (let ((insource (not (eq (current-buffer) gud-comint-buffer))))
581 (if (string-match "\\(.*\\)%f\\(.*\\)" str) 581 (if (string-match "\\(.*\\)%f\\(.*\\)" str)
582 (progn 582 (progn
583 (setq str (concat 583 (setq str (concat
584 (substring str (match-beginning 1) (match-end 1)) 584 (substring str (match-beginning 1) (match-end 1))
585 (if insource 585 (file-name-nondirectory (if insource
586 (buffer-file-name) 586 (buffer-file-name)
587 (car gud-last-frame)) 587 (car gud-last-frame)))
588 (substring str (match-beginning 2) (match-end 2)))))) 588 (substring str (match-beginning 2) (match-end 2))))))
589 (if (string-match "\\(.*\\)%l\\(.*\\)" str) 589 (if (string-match "\\(.*\\)%l\\(.*\\)" str)
590 (progn 590 (progn
591 (setq str (concat 591 (setq str (concat
592 (substring str (match-beginning 1) (match-end 1)) 592 (substring str (match-beginning 1) (match-end 1))