diff options
author | Artur Malabarba <bruce.connor.am@gmail.com> | 2015-10-03 17:10:31 +0100 |
---|---|---|
committer | Artur Malabarba <bruce.connor.am@gmail.com> | 2015-10-03 17:10:31 +0100 |
commit | 61ff50e9b9c677be13c7efb187d27cd022fdbb7a (patch) | |
tree | 58db82ed1fa456b55a811125df7496ca3dbb5d1e /cider-debug.el | |
parent | a4fc1e990974a0dc17dcec8fbfd3ac2eea2f162a (diff) |
Fix lag in the debugger
The lag was happening because we waited for process-output twice: once
for the :done message and once for the next input request. Sadly,
a lot of times these two messages arrived together (as far as Emacs
could tell), so the second wait just did nothing until it timed out.
cider-nrepl no longer sends the :done message, and so we only need to
wait once now.
Diffstat (limited to 'cider-debug.el')
-rw-r--r-- | cider-debug.el | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/cider-debug.el b/cider-debug.el index c5a51204..49f20771 100644 --- a/cider-debug.el +++ b/cider-debug.el @@ -313,10 +313,7 @@ In order to work properly, this mode must be activated by ;; doesn't accidentally hit `n' between two messages (thus editing the code). (-when-let (proc (unless nrepl-ongoing-sync-request (get-buffer-process (cider-current-connection)))) - ;; This is for the `:done' sent in reply to the debug-input we provided. - (when (accept-process-output proc 0.2) - ;; This is for actually waiting for the next message. - (accept-process-output proc 0.5))) + (accept-process-output proc 0.5)) (unless cider--debug-mode (setq buffer-read-only nil) (cider--debug-remove-overlays (current-buffer))) |