emacs-elpa-diffs
[Top][All Lists]
Advanced

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

[nongnu] elpa/sly 3278819 3/3: Delete sly-timer-call, remnant from pre-l


From: ELPA Syncer
Subject: [nongnu] elpa/sly 3278819 3/3: Delete sly-timer-call, remnant from pre-lexical binding times
Date: Sun, 7 Feb 2021 04:57:09 -0500 (EST)

branch: elpa/sly
commit 3278819ddf71d16444e6cea293dd41ca83ea9bae
Author: João Távora <joaotavora@gmail.com>
Commit: João Távora <joaotavora@gmail.com>

    Delete sly-timer-call, remnant from pre-lexical binding times
    
    It just complicates debugging, as seen in #410.
    
    * sly.el (sly-timer-call): Delete.
    (sly-attempt-connection): Call from timer lambda.
---
 sly.el | 23 +++++------------------
 1 file changed, 5 insertions(+), 18 deletions(-)

diff --git a/sly.el b/sly.el
index 04f4716..37567c3 100644
--- a/sly.el
+++ b/sly.el
@@ -1434,24 +1434,11 @@ Fall back to `sly-init-using-slynk-loader' if ASDF 
fails."
            (setq sly-connect-retry-timer
                  (run-with-timer
                   sly-connection-poll-interval nil
-                  #'sly-timer-call #'sly-attempt-connection
-                  `((sly-ignore-protocol-mismatches . 
,sly-ignore-protocol-mismatches))
-                  process (and retries (1- retries))
-                  (1+ attempt)))))))
-
-(defun sly-timer-call (fun env &rest args)
-  "Call function FUN with ARGS, reporting all errors.
-
-FUN is called with the overriding dynamic environment in ENV, an
-alist of bindings.
-
-The default condition handler for timer functions (see
-`timer-event-handler') ignores errors."
-  (condition-case data
-      (cl-progv (mapcar #'car env) (mapcar #'cdr env)
-        (apply fun args))
-    ((debug error)
-     (debug nil (list "Error in timer" fun args data)))))
+                  (lambda ()
+                    (let ((sly-ignore-protocol-mismatches
+                           sly-ignore-protocol-mismatches))
+                      (sly-attempt-connection process (and retries (1- 
retries))
+                                              (1+ attempt))))))))))
 
 (defun sly-cancel-connect-retry-timer ()
   (when sly-connect-retry-timer



reply via email to

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