emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] master b074335: Edebug: Allow "S" to work during trace mod


From: Alan Mackenzie
Subject: [Emacs-diffs] master b074335: Edebug: Allow "S" to work during trace mode. Fixes debbugs #20074.
Date: Mon, 16 Mar 2015 22:12:22 +0000

branch: master
commit b0743354e5502395f9a64b534a5ff5579c64ed42
Author: Alan Mackenzie <address@hidden>
Commit: Alan Mackenzie <address@hidden>

    Edebug: Allow "S" to work during trace mode.  Fixes debbugs #20074.
    
    Also display the overlay arrow in go and go-nonstop modes.
    
    * emacs-lisp/edebug.el (edebug--display-1): Move the
    `input-pending' test to after trace mode's `sit-for'.
    (edebug--recursive-edit): Insert "(sit-for 0)" after
    "(edebug-overlay-arrow)".
---
 lisp/ChangeLog            |   10 ++++++++++
 lisp/emacs-lisp/edebug.el |   28 ++++++++++++----------------
 2 files changed, 22 insertions(+), 16 deletions(-)

diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 41898be..cbd1bce 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,13 @@
+2015-03-16  Alan Mackenzie  <address@hidden>
+
+       Edebug: Allow "S" to work during trace mode.  Fixes debbugs #20074.
+       Also display the overlay arrow in go and go-nonstop modes.
+
+       * emacs-lisp/edebug.el (edebug--display-1): Move the
+       `input-pending' test to after trace mode's `sit-for'.
+       (edebug--recursive-edit): Insert "(sit-for 0)" after
+       "(edebug-overlay-arrow)".
+
 2015-03-16  Stefan Monnier  <address@hidden>
 
        * emacs-lisp/cl-macs.el (cl--transform-lambda): Rework to avoid
diff --git a/lisp/emacs-lisp/edebug.el b/lisp/emacs-lisp/edebug.el
index 333f028..aa7cdf9 100644
--- a/lisp/emacs-lisp/edebug.el
+++ b/lisp/emacs-lisp/edebug.el
@@ -2446,15 +2446,6 @@ MSG is printed after `::::} '."
                               edebug-function)
                 ))
 
-         ;; Test if there is input, not including keyboard macros.
-         (if (input-pending-p)
-             (progn
-               (setq edebug-execution-mode 'step
-                     edebug-stop t)
-               (edebug-stop)
-               ;;          (discard-input)             ; is this unfriendly??
-               ))
-
           ;; Make sure we bind those in the right buffer (bug#16410).
           (let ((overlay-arrow-position overlay-arrow-position)
                 (overlay-arrow-string overlay-arrow-string))
@@ -2507,14 +2498,18 @@ MSG is printed after `::::} '."
              ((eq edebug-execution-mode 'Trace-fast)
               (sit-for 0)))            ; Force update and continue.
 
+            (when (input-pending-p)
+             (setq edebug-stop t)
+             (setq edebug-execution-mode 'step) ; for `edebug-overlay-arrow'
+             (edebug-stop))
+
+           (edebug-overlay-arrow)
+
             (unwind-protect
                 (if (or edebug-stop
                         (memq edebug-execution-mode '(step next))
                         (eq arg-mode 'error))
-                    (progn
-                      ;; (setq edebug-execution-mode 'step)
-                      ;; (edebug-overlay-arrow)        ; This doesn't always 
show up.
-                      (edebug--recursive-edit arg-mode))) ; <--- Recursive edit
+                   (edebug--recursive-edit arg-mode)) ; <--- Recursive edit
 
               ;; Reset the edebug-window-data to whatever it is now.
               (let ((window (if (eq (window-buffer) edebug-buffer)
@@ -2702,8 +2697,9 @@ MSG is printed after `::::} '."
            (if (buffer-name edebug-buffer) ; if it still exists
                (progn
                  (set-buffer edebug-buffer)
-                 (if (memq edebug-execution-mode '(go Go-nonstop))
-                     (edebug-overlay-arrow))
+                 (when (memq edebug-execution-mode '(go Go-nonstop))
+                   (edebug-overlay-arrow)
+                   (sit-for 0))
                   (edebug-mode -1))
              ;; gotta have a buffer to let its buffer local variables be set
              (get-buffer-create " bogus edebug buffer"))
@@ -2721,7 +2717,7 @@ MSG is printed after `::::} '."
     (step . "=>")
     (next . "=>")
     (go . "<>")
-    (Go-nonstop . "..")  ; not used
+    (Go-nonstop . "..")
     )
   "Association list of arrows for each edebug mode.")
 



reply via email to

[Prev in Thread] Current Thread [Next in Thread]