Skip to content

Commit 0334a49

Browse files
author
KDr2
committed
fix: isempty hangs forever on a channel under Julia 1.3
1 parent 510ed2d commit 0334a49

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/tapedtask.jl

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,10 @@ function TapedTask(tf::TapedFunction, args...)
2424
# @error "TapedTask Error: " exception=(e, catch_backtrace())
2525
rethrow()
2626
finally
27-
while !isempty(produce_ch)
28-
yield()
27+
@static if VERSION >= v"1.4"
28+
while !isempty(produce_ch)
29+
yield()
30+
end
2931
end
3032
close(produce_ch)
3133
close(consume_ch)

0 commit comments

Comments
 (0)