diff options
| author | Karoly Lorentey | 2006-05-10 15:04:01 +0000 |
|---|---|---|
| committer | Karoly Lorentey | 2006-05-10 15:04:01 +0000 |
| commit | 8dadeb1e1f78c7be07db5ae78aa9eed58d272a4e (patch) | |
| tree | 6262988e87d6b347a8c90fcc3c5b49f9bb5b36e1 /lisp/progmodes | |
| parent | f6cf85ac95e469835a2643024f995b471a4c5d52 (diff) | |
| parent | 9a4d87c8d5f4503d67d5155eae6d543cc31f86d0 (diff) | |
| download | emacs-8dadeb1e1f78c7be07db5ae78aa9eed58d272a4e.tar.gz emacs-8dadeb1e1f78c7be07db5ae78aa9eed58d272a4e.zip | |
Merged from emacs@sv.gnu.org
Patches applied:
* emacs@sv.gnu.org/emacs--devo--0--patch-266
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-267
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-268
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-269
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-270
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-271
Rename "field-at-point" to "field-at-pos"
* emacs@sv.gnu.org/emacs--devo--0--patch-272
(comint-insert-input): Remove redundant calls to setq and goto-char
git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-556
Diffstat (limited to 'lisp/progmodes')
| -rw-r--r-- | lisp/progmodes/gdb-ui.el | 48 | ||||
| -rw-r--r-- | lisp/progmodes/grep.el | 44 | ||||
| -rw-r--r-- | lisp/progmodes/vhdl-mode.el | 3 | ||||
| -rw-r--r-- | lisp/progmodes/xscheme.el | 9 |
4 files changed, 50 insertions, 54 deletions
diff --git a/lisp/progmodes/gdb-ui.el b/lisp/progmodes/gdb-ui.el index 28fcb70bb8b..a20f11e0aa2 100644 --- a/lisp/progmodes/gdb-ui.el +++ b/lisp/progmodes/gdb-ui.el | |||
| @@ -694,6 +694,7 @@ With arg, enter name of variable to be watched in the minibuffer." | |||
| 694 | (if (and transient-mark-mode mark-active) | 694 | (if (and transient-mark-mode mark-active) |
| 695 | (buffer-substring (region-beginning) (region-end)) | 695 | (buffer-substring (region-beginning) (region-end)) |
| 696 | (tooltip-identifier-from-point (point)))))) | 696 | (tooltip-identifier-from-point (point)))))) |
| 697 | (speedbar 1) | ||
| 697 | (catch 'already-watched | 698 | (catch 'already-watched |
| 698 | (dolist (var gdb-var-list) | 699 | (dolist (var gdb-var-list) |
| 699 | (unless (string-match "\\." (car var)) | 700 | (unless (string-match "\\." (car var)) |
| @@ -725,7 +726,6 @@ With arg, enter name of variable to be watched in the minibuffer." | |||
| 725 | (match-string 3) | 726 | (match-string 3) |
| 726 | nil nil gdb-frame-address))) | 727 | nil nil gdb-frame-address))) |
| 727 | (push var gdb-var-list) | 728 | (push var gdb-var-list) |
| 728 | (speedbar 1) | ||
| 729 | (unless (string-equal | 729 | (unless (string-equal |
| 730 | speedbar-initial-expansion-list-name "GUD") | 730 | speedbar-initial-expansion-list-name "GUD") |
| 731 | (speedbar-change-initial-expansion-list "GUD")) | 731 | (speedbar-change-initial-expansion-list "GUD")) |
| @@ -741,13 +741,26 @@ With arg, enter name of variable to be watched in the minibuffer." | |||
| 741 | (message-box "Watching expressions requires gdb 6.0 onwards") | 741 | (message-box "Watching expressions requires gdb 6.0 onwards") |
| 742 | (message-box "No symbol \"%s\" in current context." expr)))) | 742 | (message-box "No symbol \"%s\" in current context." expr)))) |
| 743 | 743 | ||
| 744 | (defun gdb-speedbar-update () | ||
| 745 | (when (and (boundp 'speedbar-frame) (frame-live-p speedbar-frame)) | ||
| 746 | ;; Dummy command to update speedbar even when idle. | ||
| 747 | (gdb-enqueue-input (list "server pwd\n" 'gdb-speedbar-timer-fn)) | ||
| 748 | ;; Keep gdb-pending-triggers non-nil till end. | ||
| 749 | (push 'gdb-speedbar-timer gdb-pending-triggers))) | ||
| 750 | |||
| 751 | (defun gdb-speedbar-timer-fn () | ||
| 752 | (setq gdb-pending-triggers | ||
| 753 | (delq 'gdb-speedbar-timer gdb-pending-triggers)) | ||
| 754 | (speedbar-timer-fn)) | ||
| 755 | |||
| 744 | (defun gdb-var-evaluate-expression-handler (varnum changed) | 756 | (defun gdb-var-evaluate-expression-handler (varnum changed) |
| 745 | (goto-char (point-min)) | 757 | (goto-char (point-min)) |
| 746 | (re-search-forward ".*value=\\(\".*\"\\)" nil t) | 758 | (re-search-forward ".*value=\\(\".*\"\\)" nil t) |
| 747 | (let ((var (assoc varnum gdb-var-list))) | 759 | (let ((var (assoc varnum gdb-var-list))) |
| 748 | (when var | 760 | (when var |
| 749 | (if changed (setcar (nthcdr 5 var) 'changed)) | 761 | (if changed (setcar (nthcdr 5 var) 'changed)) |
| 750 | (setcar (nthcdr 4 var) (read (match-string 1)))))) | 762 | (setcar (nthcdr 4 var) (read (match-string 1))))) |
| 763 | (gdb-speedbar-update)) | ||
| 751 | 764 | ||
| 752 | (defun gdb-var-list-children (varnum) | 765 | (defun gdb-var-list-children (varnum) |
| 753 | (gdb-enqueue-input | 766 | (gdb-enqueue-input |
| @@ -811,21 +824,7 @@ type_changed=\".*?\".*?}") | |||
| 811 | varnum "\"\n") | 824 | varnum "\"\n") |
| 812 | `(lambda () (gdb-var-evaluate-expression-handler ,varnum t))))))) | 825 | `(lambda () (gdb-var-evaluate-expression-handler ,varnum t))))))) |
| 813 | (setq gdb-pending-triggers | 826 | (setq gdb-pending-triggers |
| 814 | (delq 'gdb-var-update gdb-pending-triggers)) | 827 | (delq 'gdb-var-update gdb-pending-triggers))) |
| 815 | (when (and (boundp 'speedbar-frame) (frame-live-p speedbar-frame)) | ||
| 816 | ;; Dummy command to update speedbar at right time. | ||
| 817 | (gdb-enqueue-input (list "server pwd\n" 'gdb-speedbar-refresh)) | ||
| 818 | ;; Keep gdb-pending-triggers non-nil till end. | ||
| 819 | (push 'gdb-speedbar-refresh gdb-pending-triggers))) | ||
| 820 | |||
| 821 | (defun gdb-speedbar-refresh () | ||
| 822 | (setq gdb-pending-triggers | ||
| 823 | (delq 'gdb-speedbar-refresh gdb-pending-triggers)) | ||
| 824 | (with-current-buffer gud-comint-buffer | ||
| 825 | (let ((speedbar-verbosity-level 0) | ||
| 826 | (speedbar-shown-directories nil)) | ||
| 827 | (save-excursion | ||
| 828 | (speedbar-refresh))))) | ||
| 829 | 828 | ||
| 830 | (defun gdb-var-delete () | 829 | (defun gdb-var-delete () |
| 831 | "Delete watch expression at point from the speedbar." | 830 | "Delete watch expression at point from the speedbar." |
| @@ -1912,7 +1911,7 @@ static char *magick[] = { | |||
| 1912 | (let* ((buffer (find-file-noselect | 1911 | (let* ((buffer (find-file-noselect |
| 1913 | (if (file-exists-p file) file | 1912 | (if (file-exists-p file) file |
| 1914 | (cdr (assoc bptno gdb-location-alist))))) | 1913 | (cdr (assoc bptno gdb-location-alist))))) |
| 1915 | (window (unless (gdb-display-source-buffer buffer) | 1914 | (window (or (gdb-display-source-buffer buffer) |
| 1916 | (display-buffer buffer)))) | 1915 | (display-buffer buffer)))) |
| 1917 | (setq gdb-source-window window) | 1916 | (setq gdb-source-window window) |
| 1918 | (with-current-buffer buffer | 1917 | (with-current-buffer buffer |
| @@ -2754,6 +2753,7 @@ corresponding to the mode line clicked." | |||
| 2754 | ;; Put buffer list in window if we | 2753 | ;; Put buffer list in window if we |
| 2755 | ;; can't find a source file. | 2754 | ;; can't find a source file. |
| 2756 | (list-buffers-noselect)))) | 2755 | (list-buffers-noselect)))) |
| 2756 | (setq gdb-source-window (selected-window)) | ||
| 2757 | (when gdb-use-separate-io-buffer | 2757 | (when gdb-use-separate-io-buffer |
| 2758 | (split-window-horizontally) | 2758 | (split-window-horizontally) |
| 2759 | (other-window 1) | 2759 | (other-window 1) |
| @@ -2781,6 +2781,7 @@ This arrangement depends on the value of `gdb-many-windows'." | |||
| 2781 | (if gud-last-last-frame | 2781 | (if gud-last-last-frame |
| 2782 | (gud-find-file (car gud-last-last-frame)) | 2782 | (gud-find-file (car gud-last-last-frame)) |
| 2783 | (gud-find-file gdb-main-file))) | 2783 | (gud-find-file gdb-main-file))) |
| 2784 | (setq gdb-source-window (selected-window)) | ||
| 2784 | (other-window 1)))) | 2785 | (other-window 1)))) |
| 2785 | 2786 | ||
| 2786 | (defun gdb-reset () | 2787 | (defun gdb-reset () |
| @@ -2802,8 +2803,6 @@ Kills the gdb buffers, and resets variables and the source buffers." | |||
| 2802 | (setq overlay-arrow-variable-list | 2803 | (setq overlay-arrow-variable-list |
| 2803 | (delq 'gdb-overlay-arrow-position overlay-arrow-variable-list)) | 2804 | (delq 'gdb-overlay-arrow-position overlay-arrow-variable-list)) |
| 2804 | (setq fringe-indicator-alist '((overlay-arrow . right-triangle))) | 2805 | (setq fringe-indicator-alist '((overlay-arrow . right-triangle))) |
| 2805 | (if (and (boundp 'speedbar-frame) (frame-live-p speedbar-frame)) | ||
| 2806 | (speedbar-refresh)) | ||
| 2807 | (setq gud-running nil) | 2806 | (setq gud-running nil) |
| 2808 | (setq gdb-active-process nil) | 2807 | (setq gdb-active-process nil) |
| 2809 | (setq gdb-var-list nil) | 2808 | (setq gdb-var-list nil) |
| @@ -3231,7 +3230,8 @@ numchild=\"\\(.+?\\)\",.*?value=\\(\".*?\"\\),.*?type=\"\\(.+?\\)\".*?}") | |||
| 3231 | (throw 'child-already-watched nil)) | 3230 | (throw 'child-already-watched nil)) |
| 3232 | (push varchild var-list)))) | 3231 | (push varchild var-list)))) |
| 3233 | (push var var-list))) | 3232 | (push var var-list))) |
| 3234 | (setq gdb-var-list (nreverse var-list))))) | 3233 | (setq gdb-var-list (nreverse var-list)))) |
| 3234 | (gdb-speedbar-update)) | ||
| 3235 | 3235 | ||
| 3236 | ; Uses "-var-update --all-values". Needs GDB 6.4 onwards. | 3236 | ; Uses "-var-update --all-values". Needs GDB 6.4 onwards. |
| 3237 | (defun gdb-var-update-1 () | 3237 | (defun gdb-var-update-1 () |
| @@ -3264,11 +3264,7 @@ in_scope=\"\\(.*?\\)\".*?}") | |||
| 3264 | (read (match-string 2))))))) | 3264 | (read (match-string 2))))))) |
| 3265 | (setq gdb-pending-triggers | 3265 | (setq gdb-pending-triggers |
| 3266 | (delq 'gdb-var-update gdb-pending-triggers)) | 3266 | (delq 'gdb-var-update gdb-pending-triggers)) |
| 3267 | (when (and (boundp 'speedbar-frame) (frame-live-p speedbar-frame)) | 3267 | (gdb-speedbar-update)) |
| 3268 | ;; dummy command to update speedbar at right time | ||
| 3269 | (gdb-enqueue-input (list "server pwd\n" 'gdb-speedbar-refresh)) | ||
| 3270 | ;; keep gdb-pending-triggers non-nil till end | ||
| 3271 | (push 'gdb-speedbar-refresh gdb-pending-triggers))) | ||
| 3272 | 3268 | ||
| 3273 | ;; Registers buffer. | 3269 | ;; Registers buffer. |
| 3274 | ;; | 3270 | ;; |
diff --git a/lisp/progmodes/grep.el b/lisp/progmodes/grep.el index c695272e92b..410a973d1b4 100644 --- a/lisp/progmodes/grep.el +++ b/lisp/progmodes/grep.el | |||
| @@ -639,9 +639,9 @@ The search is limited to file names matching shell pattern FILES. | |||
| 639 | FILES may use abbreviations defined in `grep-files-aliases', e.g. | 639 | FILES may use abbreviations defined in `grep-files-aliases', e.g. |
| 640 | entering `ch' is equivalent to `*.[ch]'. | 640 | entering `ch' is equivalent to `*.[ch]'. |
| 641 | 641 | ||
| 642 | With \\[universal-argument] prefix, allow user to edit the constructed | 642 | With \\[universal-argument] prefix, you can edit the constructed shell command line |
| 643 | shell command line before it is executed. | 643 | before it is executed. |
| 644 | With two \\[universal-argument] prefixes, edit and run grep shell command. | 644 | With two \\[universal-argument] prefixes, directly edit and run `grep-command'. |
| 645 | 645 | ||
| 646 | Collect output in a buffer. While grep runs asynchronously, you | 646 | Collect output in a buffer. While grep runs asynchronously, you |
| 647 | can use \\[next-error] (M-x next-error), or \\<grep-mode-map>\\[compile-goto-error] | 647 | can use \\[next-error] (M-x next-error), or \\<grep-mode-map>\\[compile-goto-error] |
| @@ -676,7 +676,7 @@ This command shares argument histories with \\[rgrep] and \\[grep]." | |||
| 676 | (setq command | 676 | (setq command |
| 677 | (read-from-minibuffer "Confirm: " | 677 | (read-from-minibuffer "Confirm: " |
| 678 | command nil nil 'grep-history)) | 678 | command nil nil 'grep-history)) |
| 679 | (push command grep-history)))) | 679 | (add-to-history 'grep-history command)))) |
| 680 | (when command | 680 | (when command |
| 681 | ;; Setting process-setup-function makes exit-message-function work | 681 | ;; Setting process-setup-function makes exit-message-function work |
| 682 | ;; even when async processes aren't supported. | 682 | ;; even when async processes aren't supported. |
| @@ -687,14 +687,14 @@ This command shares argument histories with \\[rgrep] and \\[grep]." | |||
| 687 | 687 | ||
| 688 | ;;;###autoload | 688 | ;;;###autoload |
| 689 | (defun rgrep (regexp &optional files dir) | 689 | (defun rgrep (regexp &optional files dir) |
| 690 | "Recusively grep for REGEXP in FILES in directory tree rooted at DIR. | 690 | "Recursively grep for REGEXP in FILES in directory tree rooted at DIR. |
| 691 | The search is limited to file names matching shell pattern FILES. | 691 | The search is limited to file names matching shell pattern FILES. |
| 692 | FILES may use abbreviations defined in `grep-files-aliases', e.g. | 692 | FILES may use abbreviations defined in `grep-files-aliases', e.g. |
| 693 | entering `ch' is equivalent to `*.[ch]'. | 693 | entering `ch' is equivalent to `*.[ch]'. |
| 694 | 694 | ||
| 695 | With \\[universal-argument] prefix, allow user to edit the constructed | 695 | With \\[universal-argument] prefix, you can edit the constructed shell command line |
| 696 | shell command line before it is executed. | 696 | before it is executed. |
| 697 | With two \\[universal-argument] prefixes, edit and run grep-find shell command. | 697 | With two \\[universal-argument] prefixes, directly edit and run `grep-find-command'. |
| 698 | 698 | ||
| 699 | Collect output in a buffer. While find runs asynchronously, you | 699 | Collect output in a buffer. While find runs asynchronously, you |
| 700 | can use \\[next-error] (M-x next-error), or \\<grep-mode-map>\\[compile-goto-error] | 700 | can use \\[next-error] (M-x next-error), or \\<grep-mode-map>\\[compile-goto-error] |
| @@ -721,16 +721,16 @@ This command shares argument histories with \\[lgrep] and \\[grep-find]." | |||
| 721 | (if (null files) | 721 | (if (null files) |
| 722 | (if (not (string= regexp grep-find-command)) | 722 | (if (not (string= regexp grep-find-command)) |
| 723 | (compilation-start regexp 'grep-mode)) | 723 | (compilation-start regexp 'grep-mode)) |
| 724 | (let* ((default-directory (file-name-as-directory (expand-file-name dir))) | 724 | (setq dir (file-name-as-directory (expand-file-name dir))) |
| 725 | (command (grep-expand-template | 725 | (let ((command (grep-expand-template |
| 726 | grep-find-template | 726 | grep-find-template |
| 727 | regexp | 727 | regexp |
| 728 | (concat "\\( -name " | 728 | (concat "\\( -name " |
| 729 | (mapconcat #'shell-quote-argument | 729 | (mapconcat #'shell-quote-argument |
| 730 | (split-string files) | 730 | (split-string files) |
| 731 | " -o -name ") | 731 | " -o -name ") |
| 732 | " \\)") | 732 | " \\)") |
| 733 | default-directory | 733 | dir |
| 734 | (and grep-find-ignored-directories | 734 | (and grep-find-ignored-directories |
| 735 | (concat "\\( -path '*/" | 735 | (concat "\\( -path '*/" |
| 736 | (mapconcat #'identity | 736 | (mapconcat #'identity |
| @@ -742,8 +742,12 @@ This command shares argument histories with \\[lgrep] and \\[grep-find]." | |||
| 742 | (setq command | 742 | (setq command |
| 743 | (read-from-minibuffer "Confirm: " | 743 | (read-from-minibuffer "Confirm: " |
| 744 | command nil nil 'grep-find-history)) | 744 | command nil nil 'grep-find-history)) |
| 745 | (push command grep-find-history)) | 745 | (add-to-history 'grep-find-history command)) |
| 746 | (compilation-start command 'grep-mode)))))) | 746 | (let ((default-directory dir)) |
| 747 | (compilation-start command 'grep-mode)) | ||
| 748 | ;; Set default-directory if we started rgrep in the *grep* buffer. | ||
| 749 | (if (eq next-error-last-buffer (current-buffer)) | ||
| 750 | (setq default-directory dir))))))) | ||
| 747 | 751 | ||
| 748 | 752 | ||
| 749 | (provide 'grep) | 753 | (provide 'grep) |
diff --git a/lisp/progmodes/vhdl-mode.el b/lisp/progmodes/vhdl-mode.el index d81a5fcf47b..987b37cf2c2 100644 --- a/lisp/progmodes/vhdl-mode.el +++ b/lisp/progmodes/vhdl-mode.el | |||
| @@ -16723,8 +16723,7 @@ specified by a target." | |||
| 16723 | (progn (save-buffer) | 16723 | (progn (save-buffer) |
| 16724 | (kill-buffer (current-buffer)) | 16724 | (kill-buffer (current-buffer)) |
| 16725 | (set-buffer orig-buffer) | 16725 | (set-buffer orig-buffer) |
| 16726 | (setq file-name-history | 16726 | (add-to-history 'file-name-history makefile-path-name)) |
| 16727 | (cons makefile-path-name file-name-history))) | ||
| 16728 | (vhdl-warning-when-idle | 16727 | (vhdl-warning-when-idle |
| 16729 | (format "File not writable: \"%s\"" | 16728 | (format "File not writable: \"%s\"" |
| 16730 | (abbreviate-file-name makefile-path-name))) | 16729 | (abbreviate-file-name makefile-path-name))) |
diff --git a/lisp/progmodes/xscheme.el b/lisp/progmodes/xscheme.el index 4f1cd37a9f7..0f55c71ac70 100644 --- a/lisp/progmodes/xscheme.el +++ b/lisp/progmodes/xscheme.el | |||
| @@ -580,12 +580,9 @@ The strings are concatenated and terminated by a newline." | |||
| 580 | ;;;; Scheme expressions ring | 580 | ;;;; Scheme expressions ring |
| 581 | 581 | ||
| 582 | (defun xscheme-insert-expression (string) | 582 | (defun xscheme-insert-expression (string) |
| 583 | (setq xscheme-expressions-ring (cons string xscheme-expressions-ring)) | 583 | (setq xscheme-expressions-ring-yank-pointer |
| 584 | (if (> (length xscheme-expressions-ring) xscheme-expressions-ring-max) | 584 | (add-to-history 'xscheme-expressions-ring string |
| 585 | (setcdr (nthcdr (1- xscheme-expressions-ring-max) | 585 | xscheme-expressions-ring-max))) |
| 586 | xscheme-expressions-ring) | ||
| 587 | nil)) | ||
| 588 | (setq xscheme-expressions-ring-yank-pointer xscheme-expressions-ring)) | ||
| 589 | 586 | ||
| 590 | (defun xscheme-rotate-yank-pointer (arg) | 587 | (defun xscheme-rotate-yank-pointer (arg) |
| 591 | "Rotate the yanking point in the kill ring." | 588 | "Rotate the yanking point in the kill ring." |