]> granicus.if.org Git - python/commitdiff
SF 1676321: empty() returned wrong result
authorRaymond Hettinger <python@rcn.com>
Thu, 8 Mar 2007 19:23:25 +0000 (19:23 +0000)
committerRaymond Hettinger <python@rcn.com>
Thu, 8 Mar 2007 19:23:25 +0000 (19:23 +0000)
Lib/sched.py
Misc/NEWS

index 2f8df056488bb914927f2ad1d042a865e61ac533..7c3235e9f6784c7ee011a450d43523f8bfac55b2 100644 (file)
@@ -72,7 +72,7 @@ class scheduler:
 
     def empty(self):
         """Check whether the queue is empty."""
-        return not not self.queue
+        return not self.queue
 
     def run(self):
         """Execute events until the queue is empty.
index 01bcb663a721c3bb4806445b9055005c56b32d87..4eb4020be91875f832bf71316d99bc983809ea7b 100644 (file)
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -197,6 +197,8 @@ Extension Modules
 Library
 -------
 
+- Bugs #1676321:  the empty() function in sched.py returned the wrong result
+
 - unittest now verifies more of its assumptions. In particular, TestCase
   and TestSuite subclasses (not instances) are no longer accepted in
   TestSuite.addTest(). This should cause no incompatibility since it