Mercurial > emacs
comparison lisp/emacs-lisp/edebug.el @ 72344:79197e6c8618
* emacs-lisp/edebug.el (edebug-recursive-edit): Don't save and
restore unread-command-events here.
(edebug-display): Do it here, to detect sit-for interruptions.
author | Chong Yidong <cyd@stupidchicken.com> |
---|---|
date | Thu, 10 Aug 2006 15:27:41 +0000 |
parents | 81b8b2bb63de |
children | 494f2c627b5b |
comparison
equal
deleted
inserted
replaced
72343:2ae29d562915 | 72344:79197e6c8618 |
---|---|
2554 (edebug-window-data (nth 3 edebug-data)) | 2554 (edebug-window-data (nth 3 edebug-data)) |
2555 (edebug-outside-window (selected-window)) | 2555 (edebug-outside-window (selected-window)) |
2556 (edebug-outside-buffer (current-buffer)) | 2556 (edebug-outside-buffer (current-buffer)) |
2557 (edebug-outside-point (point)) | 2557 (edebug-outside-point (point)) |
2558 (edebug-outside-mark (edebug-mark)) | 2558 (edebug-outside-mark (edebug-mark)) |
2559 (edebug-outside-unread-command-events unread-command-events) | |
2559 edebug-outside-windows ; window or screen configuration | 2560 edebug-outside-windows ; window or screen configuration |
2560 edebug-buffer-points | 2561 edebug-buffer-points |
2561 | 2562 |
2562 edebug-eval-buffer ; declared here so we can kill it below | 2563 edebug-eval-buffer ; declared here so we can kill it below |
2563 (edebug-eval-result-list (and edebug-eval-list | 2564 (edebug-eval-result-list (and edebug-eval-list |
2572 (unwind-protect | 2573 (unwind-protect |
2573 (let ((overlay-arrow-position overlay-arrow-position) | 2574 (let ((overlay-arrow-position overlay-arrow-position) |
2574 (overlay-arrow-string overlay-arrow-string) | 2575 (overlay-arrow-string overlay-arrow-string) |
2575 (cursor-in-echo-area nil) | 2576 (cursor-in-echo-area nil) |
2576 (default-cursor-in-non-selected-windows t) | 2577 (default-cursor-in-non-selected-windows t) |
2578 (unread-command-events nil) | |
2577 ;; any others?? | 2579 ;; any others?? |
2578 ) | 2580 ) |
2579 (if (not (buffer-name edebug-buffer)) | 2581 (if (not (buffer-name edebug-buffer)) |
2580 (let ((debug-on-error nil)) | 2582 (let ((debug-on-error nil)) |
2581 (error "Buffer defining %s not found" edebug-function))) | 2583 (error "Buffer defining %s not found" edebug-function))) |
2679 (t (setq edebug-stop t)))) | 2681 (t (setq edebug-stop t)))) |
2680 ;; not edebug-break | 2682 ;; not edebug-break |
2681 ((eq edebug-execution-mode 'trace) | 2683 ((eq edebug-execution-mode 'trace) |
2682 (edebug-sit-for edebug-sit-for-seconds)) ; Force update and pause. | 2684 (edebug-sit-for edebug-sit-for-seconds)) ; Force update and pause. |
2683 ((eq edebug-execution-mode 'Trace-fast) | 2685 ((eq edebug-execution-mode 'Trace-fast) |
2684 (edebug-sit-for 0)) ; Force update and continue. | 2686 (edebug-sit-for 0))) ; Force update and continue. |
2685 ) | |
2686 | 2687 |
2687 (unwind-protect | 2688 (unwind-protect |
2688 (if (or edebug-stop | 2689 (if (or edebug-stop |
2689 (memq edebug-execution-mode '(step next)) | 2690 (memq edebug-execution-mode '(step next)) |
2690 (eq edebug-arg-mode 'error)) | 2691 (eq edebug-arg-mode 'error)) |
2776 ;; ... nothing more. | 2777 ;; ... nothing more. |
2777 ) | 2778 ) |
2778 (with-timeout-unsuspend edebug-with-timeout-suspend) | 2779 (with-timeout-unsuspend edebug-with-timeout-suspend) |
2779 ;; Reset global variables to outside values in case they were changed. | 2780 ;; Reset global variables to outside values in case they were changed. |
2780 (setq | 2781 (setq |
2782 unread-command-events edebug-outside-unread-command-events | |
2781 overlay-arrow-position edebug-outside-o-a-p | 2783 overlay-arrow-position edebug-outside-o-a-p |
2782 overlay-arrow-string edebug-outside-o-a-s | 2784 overlay-arrow-string edebug-outside-o-a-s |
2783 cursor-in-echo-area edebug-outside-c-i-e-a | 2785 cursor-in-echo-area edebug-outside-c-i-e-a |
2784 default-cursor-in-non-selected-windows edebug-outside-d-c-i-n-s-w) | 2786 default-cursor-in-non-selected-windows edebug-outside-d-c-i-n-s-w) |
2785 ))) | 2787 ))) |
2866 (edebug-outside-unread-command-char unread-command-char) | 2868 (edebug-outside-unread-command-char unread-command-char) |
2867 (edebug-outside-current-prefix-arg current-prefix-arg) | 2869 (edebug-outside-current-prefix-arg current-prefix-arg) |
2868 | 2870 |
2869 (edebug-outside-last-input-event last-input-event) | 2871 (edebug-outside-last-input-event last-input-event) |
2870 (edebug-outside-last-command-event last-command-event) | 2872 (edebug-outside-last-command-event last-command-event) |
2871 (edebug-outside-unread-command-events unread-command-events) | |
2872 (edebug-outside-last-event-frame last-event-frame) | 2873 (edebug-outside-last-event-frame last-event-frame) |
2873 (edebug-outside-last-nonmenu-event last-nonmenu-event) | 2874 (edebug-outside-last-nonmenu-event last-nonmenu-event) |
2874 (edebug-outside-track-mouse track-mouse) | 2875 (edebug-outside-track-mouse track-mouse) |
2875 ) | 2876 ) |
2876 | 2877 |
2888 (current-prefix-arg nil) | 2889 (current-prefix-arg nil) |
2889 | 2890 |
2890 ;; More for Emacs 19 | 2891 ;; More for Emacs 19 |
2891 (last-input-event nil) | 2892 (last-input-event nil) |
2892 (last-command-event nil) | 2893 (last-command-event nil) |
2893 (unread-command-events nil) | |
2894 (last-event-frame nil) | 2894 (last-event-frame nil) |
2895 (last-nonmenu-event nil) | 2895 (last-nonmenu-event nil) |
2896 (track-mouse nil) | 2896 (track-mouse nil) |
2897 | 2897 |
2898 ;; Bind again to outside values. | 2898 ;; Bind again to outside values. |
2948 last-command-char edebug-outside-last-command-char | 2948 last-command-char edebug-outside-last-command-char |
2949 last-command-event edebug-outside-last-command-event | 2949 last-command-event edebug-outside-last-command-event |
2950 last-command edebug-outside-last-command | 2950 last-command edebug-outside-last-command |
2951 this-command edebug-outside-this-command | 2951 this-command edebug-outside-this-command |
2952 unread-command-char edebug-outside-unread-command-char | 2952 unread-command-char edebug-outside-unread-command-char |
2953 unread-command-events edebug-outside-unread-command-events | |
2954 current-prefix-arg edebug-outside-current-prefix-arg | 2953 current-prefix-arg edebug-outside-current-prefix-arg |
2955 last-input-char edebug-outside-last-input-char | 2954 last-input-char edebug-outside-last-input-char |
2956 last-input-event edebug-outside-last-input-event | 2955 last-input-event edebug-outside-last-input-event |
2957 last-event-frame edebug-outside-last-event-frame | 2956 last-event-frame edebug-outside-last-event-frame |
2958 last-nonmenu-event edebug-outside-last-nonmenu-event | 2957 last-nonmenu-event edebug-outside-last-nonmenu-event |