| line |
true |
false |
branch |
|
56
|
451 |
0 |
if defined $cb |
|
66
|
8 |
686 |
$Future::TIMES ? : |
|
79
|
8 |
0 |
unless defined $self->{'label'} |
|
88
|
0 |
8 |
if $GLOBAL_END |
|
89
|
5 |
1 |
if $self->{'ready'} and $self->{'reported'} || !$self->{'failure'} |
|
97
|
1 |
2 |
if ($self->{'ready'} and $self->{'failure'}) { } |
|
|
2 |
0 |
elsif (not $self->{'ready'}) { } |
|
137
|
1 |
1 |
$self->{'cancelled'} ? : |
|
|
1 |
2 |
$self->{'failure'} ? : |
|
|
1 |
3 |
!$self->{'ready'} ? : |
|
147
|
4 |
535 |
if ($Future::TIMES) |
|
155
|
5 |
534 |
unless my $callbacks = delete $self->{'callbacks'} |
|
162
|
96 |
107 |
$fail ? : |
|
|
331 |
203 |
$done ? : |
|
169
|
40 |
294 |
if $done and not $flags & 1 |
|
170
|
3 |
291 |
if $fail and not $flags & 2 |
|
171
|
32 |
259 |
if $cancelled and not $flags & 4 |
|
173
|
46 |
213 |
if $fail |
|
175
|
23 |
236 |
if ($is_future) { } |
|
|
60 |
176 |
elsif ($flags & 96) { } |
|
176
|
6 |
1 |
$fail ? : |
|
|
16 |
7 |
$done ? : |
|
182
|
2 |
58 |
unless ($fseq) |
|
192
|
52 |
6 |
if ($done and $flags & 32 or $fail and $flags & 64) { } |
|
195
|
2 |
50 |
if ($flags & 128) { } |
|
|
2 |
48 |
elsif ($flags & 256) { } |
|
204
|
22 |
26 |
$flags & 8 ? : |
|
|
28 |
20 |
$flags & 16 ? : |
|
209
|
4 |
44 |
unless (eval {
do {
$f2 = &$code(@args);
1
}
}) |
|
214
|
3 |
41 |
unless (&blessed($f2) and $f2->isa("Future")) |
|
216
|
0 |
3 |
if ($flags & 512) |
|
229
|
30 |
20 |
if ($f2->is_ready) { } |
|
230
|
30 |
0 |
unless $f2->{'cancelled'} |
|
238
|
119 |
57 |
$flags & 8 ? : |
|
|
57 |
119 |
$flags & 16 ? : |
|
250
|
306 |
90 |
if (ref $self) { } |
|
251
|
3 |
303 |
if $self->{'cancelled'} |
|
252
|
0 |
303 |
if $self->{'ready'} |
|
253
|
0 |
303 |
if $self->{'subs'} |
|
262
|
1 |
89 |
if ($Future::TIMES) |
|
275
|
2 |
135 |
if (ref $exception eq "Future::Exception") |
|
280
|
0 |
137 |
unless $exception |
|
282
|
80 |
57 |
if (ref $self) { } |
|
283
|
1 |
79 |
if $self->{'cancelled'} |
|
284
|
0 |
79 |
if $self->{'ready'} |
|
285
|
0 |
79 |
if $self->{'subs'} |
|
294
|
1 |
56 |
if ($Future::TIMES) |
|
308
|
0 |
326 |
unless $is_future or _callable($code) |
|
311
|
23 |
303 |
if $self->{'ready'} |
|
314
|
219 |
84 |
if ($is_future) |
|
351
|
20 |
172 |
unless my $on_cancel = $self->{'on_cancel'} |
|
354
|
3 |
169 |
if (@$on_cancel >= 8 and $self->{'empty_on_cancel_slots'} >= "0.5" * @$on_cancel) |
|
358
|
87 |
88 |
if defined $on_cancel->[$idx] |
|
371
|
0 |
162 |
unless $is_future or _callable($code) |
|
374
|
37 |
125 |
if ($self->{'ready'}) { } |
|
378
|
10 |
27 |
if $fail |
|
381
|
8 |
1 |
$fail ? : |
|
|
24 |
9 |
$done ? : |
|
|
33 |
4 |
$is_future ? : |
|
404
|
1 |
89 |
unless $self->{'ready'} |
|
405
|
9 |
80 |
if (my $failure = $self->{'failure'}) |
|
408
|
2 |
7 |
if @$failure > 1 |
|
409
|
3 |
6 |
!ref($exception) && $exception =~ /\n$/ ? : |
|
411
|
2 |
78 |
if $self->{'cancelled'} |
|
412
|
41 |
37 |
unless wantarray |
|
419
|
5 |
5 |
unless $self->{'ready'} |
|
426
|
3 |
1 |
if $self->{'ready'} |
|
436
|
0 |
89 |
unless $is_future or _callable($code) |
|
439
|
27 |
62 |
if ($self->{'ready'}) { } |
|
440
|
12 |
15 |
if $self->{'failure'} or $self->{'cancelled'} |
|
443
|
14 |
1 |
$is_future ? : |
|
455
|
2 |
142 |
unless $self->{'ready'} |
|
456
|
58 |
86 |
unless $self->{'failure'} |
|
458
|
70 |
16 |
unless wantarray |
|
468
|
0 |
88 |
unless $is_future or _callable($code) |
|
471
|
30 |
58 |
if ($self->{'ready'}) { } |
|
472
|
18 |
12 |
unless $self->{'failure'} |
|
476
|
10 |
2 |
$is_future ? : |
|
489
|
8 |
108 |
if $self->{'ready'} |
|
493
|
39 |
69 |
$on_cancel ? : |
|
494
|
13 |
42 |
unless defined $code |
|
496
|
20 |
22 |
$is_future ? : |
|
552
|
0 |
111 |
unless $flags & 384 or _callable($code) |
|
555
|
4 |
107 |
unless (defined wantarray) |
|
559
|
38 |
73 |
if ($f1->is_ready) |
|
562
|
3 |
35 |
if $f1->is_done and not $flags & 32 or $f1->{'failure'} and not $flags & 64 |
|
564
|
2 |
33 |
if ($flags & 128) { } |
|
|
2 |
31 |
elsif ($flags & 256) { } |
|
574
|
13 |
18 |
$flags & 8 ? : |
|
|
4 |
0 |
$f1->{'failure'} ? : |
|
|
16 |
4 |
$f1->is_done ? : |
|
|
20 |
11 |
$flags & 16 ? : |
|
579
|
2 |
29 |
unless (eval {
do {
$fseq = &$code(@args);
1
}
}) |
|
583
|
8 |
21 |
unless (&blessed($fseq) and $fseq->isa("Future")) |
|
585
|
0 |
8 |
if $flags & 512 |
|
599
|
65 |
8 |
unless $flags & 384 |
|
611
|
4 |
45 |
@_ % 2 ? : |
|
614
|
43 |
4 |
if ($done_code and not @catch_list and not $fail_code) |
|
663
|
1 |
3 |
@_ % 2 ? : |
|
675
|
7 |
4 |
@_ % 2 ? : |
|
678
|
3 |
8 |
if ($done_code and not @catch_list and not $fail_code) |
|
698
|
0 |
1 |
@_ % 2 ? : |
|
721
|
1 |
2 |
if ($self->{'cancelled'}) { } |
|
|
0 |
2 |
elsif ($self->{'failure'}) { } |
|
744
|
0 |
89 |
unless &blessed($sub) and $sub->isa("Future") |
|
760
|
5 |
3 |
if $sub and not $sub->{'ready'} |
|
772
|
2 |
11 |
unless (@subs) |
|
784
|
1 |
10 |
unless ($pending) |
|
792
|
0 |
15 |
unless my $self = $weakself |
|
795
|
5 |
10 |
if $pending |
|
802
|
15 |
3 |
unless $sub->{'ready'} |
|
813
|
2 |
13 |
unless (@subs) |
|
824
|
2 |
20 |
if $sub->{'ready'} and not $sub->{'cancelled'} |
|
827
|
2 |
11 |
if ($immediate_ready) |
|
829
|
0 |
3 |
unless $sub->{'ready'} |
|
832
|
0 |
2 |
if ($immediate_ready->{'failure'}) { } |
|
846
|
0 |
19 |
unless my $self = $weakself |
|
847
|
6 |
13 |
if $self->{'result'} or $self->{'failure'} |
|
849
|
2 |
6 |
if --$pending and $_[0]{'cancelled'} |
|
851
|
2 |
9 |
if ($_[0]{'cancelled'}) { } |
|
|
2 |
7 |
elsif ($_[0]{'failure'}) { } |
|
862
|
6 |
14 |
unless $sub->{'ready'} |
|
870
|
1 |
19 |
if $sub->{'cancelled'} |
|
883
|
2 |
14 |
unless (@subs) |
|
894
|
1 |
26 |
if $sub->{'cancelled'} |
|
895
|
1 |
1 |
if $sub->{'ready'} and $sub->{'failure'} |
|
898
|
2 |
12 |
if ($immediate_failure) |
|
900
|
1 |
3 |
unless $sub->{'ready'} |
|
912
|
1 |
11 |
unless ($pending) |
|
920
|
0 |
23 |
unless my $self = $weakself |
|
921
|
5 |
18 |
if $self->{'result'} or $self->{'failure'} |
|
923
|
4 |
14 |
if ($_[0]{'cancelled'}) { } |
|
|
3 |
11 |
elsif ($_[0]{'failure'}) { } |
|
926
|
2 |
5 |
unless $sub->{'ready'} |
|
933
|
3 |
3 |
unless $sub->{'ready'} |
|
939
|
7 |
4 |
if $pending |
|
947
|
23 |
0 |
unless $sub->{'ready'} |
|
958
|
2 |
11 |
unless (@subs) |
|
970
|
1 |
3 |
if $sub->{'ready'} and not $sub->{'failure'} and not $sub->{'cancelled'} |
|
971
|
15 |
3 |
unless $sub->{'ready'} |
|
974
|
1 |
10 |
if ($immediate_done) |
|
976
|
2 |
0 |
$sub->{'ready'} ? : |
|
987
|
9 |
1 |
unless $sub->{'ready'} |
|
990
|
1 |
9 |
if ($immediate_fail) |
|
1000
|
0 |
15 |
unless my $self = $weakself |
|
1001
|
2 |
13 |
if $self->{'result'} or $self->{'failure'} |
|
1003
|
2 |
4 |
if --$pending and $_[0]{'cancelled'} |
|
1005
|
2 |
9 |
if ($_[0]{'cancelled'}) { } |
|
|
3 |
6 |
elsif ($_[0]{'failure'}) { } |
|
1010
|
2 |
1 |
if $pending |
|
1018
|
2 |
10 |
unless $sub->{'ready'} |
|
1025
|
15 |
1 |
unless $sub->{'ready'} |
|
1034
|
0 |
7 |
unless $self->{'subs'} |
|
1041
|
0 |
7 |
unless $self->{'subs'} |
|
1048
|
0 |
9 |
unless $self->{'subs'} |
|
1049
|
15 |
3 |
if $_->{'ready'} and not $_->{'failure'} |
|
1055
|
0 |
4 |
unless $self->{'subs'} |
|
1056
|
8 |
0 |
if $_->{'ready'} |
|
1062
|
0 |
6 |
unless $self->{'subs'} |
|
1063
|
12 |
0 |
if $_->{'ready'} |