]> git.eshelyaron.com Git - emacs.git/commitdiff
Mark thread-alive-p as obsolete
authorMichael Albinus <michael.albinus@gmx.de>
Fri, 31 Aug 2018 09:45:37 +0000 (11:45 +0200)
committerMichael Albinus <michael.albinus@gmx.de>
Fri, 31 Aug 2018 09:45:37 +0000 (11:45 +0200)
* etc/NEWS (thread-alive-p):
* lisp/emacs-lisp/thread.el (thread-alive-p): Mark it as obsolete.

* test/src/thread-tests.el (threads-join-error)
(threads-signal-main-thread): Use `thread-live-p'.

etc/NEWS
lisp/emacs-lisp/thread.el
test/src/thread-tests.el

index d536faaa2d6ba99afa7571af3b396329b085f9be..1fe662ffffde43b5d2e76152cecdd4d17c96627f 100644 (file)
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -730,6 +730,9 @@ to signal the main thread, e.g., when they encounter an error.
 *** 'thread-signal' does not propagate errors to the main thread.
 Instead, error messages are just printed in the main thread.
 
+---
+*** 'thread-alive-p' is now obsolete, use 'thread-live-p' instead.
+
 ---
 ** thingatpt.el supports a new "thing" called 'uuid'.
 A symbol 'uuid' can be passed to thing-at-point and it returns the
index 02cf9b9e53f02c5ca693c0ec0d6dfdc13d2b12f5..5d7b90c26e91bc19482aef558a1e7a7a33ee4e7b 100644 (file)
@@ -38,5 +38,7 @@ An EVENT has the format
             (err (cddr event)))
         (message "Error %s: %S" thread err))))
 
+(make-obsolete 'thread-alive-p 'thread-live-p "27.1")
+
 (provide 'thread)
 ;;; thread.el ends here
index a87eb3e1591aa6fd5c90b0672155aa0a301c941c..109e71128abac4150ce543104a7332b6bac05d2b 100644 (file)
   :tags '(:unstable)
   (skip-unless (featurep 'threads))
   (let ((thread (make-thread #'threads-call-error)))
-    (while (thread-alive-p thread)
+    (while (thread-live-p thread)
       (thread-yield))
     (should-error (thread-join thread))))
 
       (erase-buffer))
     (let ((thread
            (make-thread #'(lambda () (thread-signal main-thread 'error nil)))))
-      (while (thread-alive-p thread)
+      (while (thread-live-p thread)
         (thread-yield))
       (read-event nil nil 0.1)
       ;; No error has been raised, which is part of the test.