Skip to content

Commit

Permalink
fix: type error (#472)
Browse files Browse the repository at this point in the history
  • Loading branch information
BobTheBuidler authored Dec 12, 2024
1 parent 10643c4 commit d2f8bef
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions a_sync/_smart.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -79,14 +79,13 @@ class _SmartFutureMixin(Generic[T]):


cdef Py_ssize_t count_waiters(fut: Union["SmartFuture", "SmartTask"]):
cdef WeakSet waiters
if _is_done(fut):
return ZERO
try:
waiters = fut._waiters
except AttributeError:
return ONE
cdef Py_ssize_t count = 0
cdef Py_ssize_t count = ZERO
for waiter in waiters:
count += count_waiters(waiter)
return count
Expand Down

0 comments on commit d2f8bef

Please sign in to comment.