| line |
true |
false |
branch |
|
55
|
483 |
0 |
if defined $cb |
|
65
|
8 |
720 |
$Future::TIMES ? : |
|
79
|
3 |
9 |
if defined $self->{'label'} |
|
80
|
4 |
8 |
if defined $self->{'constructed_at'} |
|
89
|
0 |
8 |
if $GLOBAL_END |
|
90
|
5 |
1 |
if $self->{'ready'} and $self->{'reported'} || !$self->{'failure'} |
|
98
|
1 |
2 |
if ($self->{'ready'} and $self->{'failure'}) { } |
|
|
2 |
0 |
elsif (not $self->{'ready'}) { } |
|
138
|
1 |
3 |
$self->{'cancelled'} ? : |
|
|
3 |
4 |
$self->{'failure'} ? : |
|
|
1 |
7 |
!$self->{'ready'} ? : |
|
148
|
4 |
561 |
if ($Future::TIMES) |
|
156
|
5 |
560 |
unless my $callbacks = delete $self->{'callbacks'} |
|
163
|
104 |
115 |
$fail ? : |
|
|
341 |
219 |
$done ? : |
|
170
|
40 |
299 |
if $done and not $flags & 1 |
|
171
|
3 |
296 |
if $fail and not $flags & 2 |
|
172
|
32 |
264 |
if $cancelled and not $flags & 4 |
|
174
|
48 |
216 |
if $fail |
|
176
|
23 |
241 |
if ($is_future) { } |
|
|
60 |
181 |
elsif ($flags & 96) { } |
|
177
|
6 |
1 |
$fail ? : |
|
|
16 |
7 |
if ($done) { } |
|
183
|
2 |
58 |
unless ($fseq) |
|
191
|
52 |
6 |
if ($done and $flags & 32 or $fail and $flags & 64) { } |
|
194
|
2 |
50 |
if ($flags & 128) { } |
|
|
2 |
48 |
elsif ($flags & 256) { } |
|
203
|
22 |
26 |
$flags & 8 ? : |
|
|
28 |
20 |
$flags & 16 ? : |
|
208
|
4 |
44 |
unless (eval {
do {
$f2 = &$code(@args);
1
}
}) |
|
213
|
3 |
41 |
unless (builtin::blessed($f2) and $f2->isa("Future")) |
|
215
|
0 |
3 |
if ($flags & 512) |
|
228
|
30 |
20 |
if ($f2->is_ready) { } |
|
229
|
30 |
0 |
unless $f2->{'cancelled'} |
|
237
|
124 |
57 |
$flags & 8 ? : |
|
|
57 |
124 |
$flags & 16 ? : |
|
249
|
316 |
93 |
if (ref $self) { } |
|
250
|
3 |
313 |
if $self->{'cancelled'} |
|
251
|
2 |
311 |
if $self->{'ready'} |
|
252
|
0 |
311 |
if $self->{'subs'} |
|
261
|
1 |
92 |
if ($Future::TIMES) |
|
274
|
2 |
143 |
if (ref $exception eq "Future::Exception") |
|
279
|
0 |
145 |
unless $exception |
|
281
|
88 |
57 |
if (ref $self) { } |
|
282
|
1 |
87 |
if $self->{'cancelled'} |
|
283
|
2 |
85 |
if $self->{'ready'} |
|
284
|
0 |
85 |
if $self->{'subs'} |
|
293
|
1 |
56 |
if ($Future::TIMES) |
|
307
|
0 |
338 |
unless $is_future or _callable($code) |
|
310
|
23 |
315 |
if $self->{'ready'} |
|
313
|
219 |
96 |
if ($is_future) |
|
350
|
21 |
172 |
unless my $on_cancel = $self->{'on_cancel'} |
|
353
|
3 |
169 |
if (@$on_cancel >= 8 and $self->{'empty_on_cancel_slots'} >= "0.5" * @$on_cancel) |
|
357
|
87 |
88 |
if defined $on_cancel->[$idx] |
|
370
|
0 |
177 |
unless $is_future or _callable($code) |
|
373
|
40 |
137 |
if ($self->{'ready'}) { } |
|
377
|
11 |
29 |
if $fail |
|
380
|
8 |
1 |
$fail ? : |
|
|
24 |
9 |
$done ? : |
|
|
33 |
7 |
$is_future ? : |
|
403
|
1 |
96 |
unless $self->{'ready'} |
|
404
|
11 |
85 |
if (my $failure = $self->{'failure'}) |
|
407
|
2 |
9 |
if @$failure > 1 |
|
408
|
3 |
8 |
!ref($exception) && $exception =~ /\n$/u ? : |
|
410
|
2 |
83 |
if $self->{'cancelled'} |
|
411
|
44 |
39 |
unless wantarray |
|
418
|
5 |
5 |
unless $self->{'ready'} |
|
425
|
3 |
1 |
if $self->{'ready'} |
|
435
|
0 |
89 |
unless $is_future or _callable($code) |
|
438
|
27 |
62 |
if ($self->{'ready'}) { } |
|
439
|
12 |
15 |
if $self->{'failure'} or $self->{'cancelled'} |
|
442
|
14 |
1 |
$is_future ? : |
|
454
|
2 |
142 |
unless $self->{'ready'} |
|
455
|
58 |
86 |
unless $self->{'failure'} |
|
457
|
70 |
16 |
unless wantarray |
|
467
|
0 |
88 |
unless $is_future or _callable($code) |
|
470
|
30 |
58 |
if ($self->{'ready'}) { } |
|
471
|
18 |
12 |
unless $self->{'failure'} |
|
475
|
10 |
2 |
$is_future ? : |
|
488
|
8 |
116 |
if $self->{'ready'} |
|
492
|
45 |
71 |
$on_cancel ? : |
|
493
|
13 |
48 |
unless defined $code |
|
495
|
21 |
27 |
$is_future ? : |
|
551
|
0 |
113 |
unless $flags & 384 or _callable($code) |
|
554
|
4 |
109 |
unless (defined wantarray) |
|
558
|
40 |
73 |
if ($f1->is_ready) |
|
561
|
3 |
37 |
if $f1->is_done and not $flags & 32 or $f1->{'failure'} and not $flags & 64 |
|
563
|
2 |
35 |
if ($flags & 128) { } |
|
|
2 |
33 |
elsif ($flags & 256) { } |
|
573
|
15 |
18 |
$flags & 8 ? : |
|
|
4 |
0 |
$f1->{'failure'} ? : |
|
|
16 |
4 |
$f1->is_done ? : |
|
|
20 |
13 |
$flags & 16 ? : |
|
578
|
2 |
31 |
unless (eval {
do {
$fseq = &$code(@args);
1
}
}) |
|
582
|
8 |
23 |
unless (builtin::blessed($fseq) and $fseq->isa("Future")) |
|
584
|
0 |
8 |
if $flags & 512 |
|
598
|
65 |
8 |
unless $flags & 384 |
|
610
|
5 |
45 |
@_ % 2 ? : |
|
613
|
43 |
5 |
if ($done_code and not @catch_list and not $fail_code) |
|
662
|
1 |
4 |
@_ % 2 ? : |
|
674
|
7 |
4 |
@_ % 2 ? : |
|
677
|
3 |
8 |
if ($done_code and not @catch_list and not $fail_code) |
|
697
|
0 |
1 |
@_ % 2 ? : |
|
720
|
1 |
2 |
if ($self->{'cancelled'}) { } |
|
|
0 |
2 |
elsif ($self->{'failure'}) { } |
|
753
|
8 |
93 |
if not builtin::blessed($subs->[$i]) and $subs->[$i] eq "also" |
|
756
|
0 |
101 |
unless builtin::blessed($sub) and $sub->isa("Future") |
|
782
|
0 |
41 |
unless my $subs = $self->{'subs'} |
|
786
|
19 |
45 |
if not $flags & 1 and $sub and not $sub->{'ready'} |
|
795
|
2 |
12 |
unless (@subs) |
|
807
|
1 |
11 |
unless ($pending) |
|
815
|
0 |
15 |
unless my $self = $weakself |
|
818
|
5 |
10 |
if $pending |
|
825
|
16 |
3 |
unless $sub->{'ready'} |
|
836
|
2 |
16 |
unless (@subs) |
|
847
|
2 |
25 |
if $sub->{'ready'} and not $sub->{'cancelled'} |
|
850
|
2 |
14 |
if ($immediate_ready) |
|
853
|
0 |
2 |
if ($immediate_ready->{'failure'}) { } |
|
867
|
0 |
21 |
unless my $self = $weakself |
|
868
|
6 |
15 |
if $self->{'result'} or $self->{'failure'} |
|
870
|
2 |
8 |
if --$pending and $_[0]{'cancelled'} |
|
872
|
2 |
11 |
if ($_[0]{'cancelled'}) { } |
|
|
3 |
8 |
elsif ($_[0]{'failure'}) { } |
|
889
|
1 |
24 |
if $sub->{'cancelled'} |
|
902
|
2 |
16 |
unless (@subs) |
|
913
|
1 |
29 |
if $sub->{'cancelled'} |
|
914
|
1 |
1 |
if $sub->{'ready'} and $sub->{'failure'} |
|
917
|
2 |
14 |
if ($immediate_failure) |
|
929
|
1 |
13 |
unless ($pending) |
|
937
|
0 |
24 |
unless my $self = $weakself |
|
938
|
5 |
19 |
if $self->{'result'} or $self->{'failure'} |
|
940
|
4 |
15 |
if ($_[0]{'cancelled'}) { } |
|
|
4 |
11 |
elsif ($_[0]{'failure'}) { } |
|
952
|
7 |
4 |
if $pending |
|
960
|
26 |
0 |
unless $sub->{'ready'} |
|
971
|
2 |
13 |
unless (@subs) |
|
983
|
1 |
3 |
if $sub->{'ready'} and not $sub->{'failure'} and not $sub->{'cancelled'} |
|
984
|
18 |
3 |
unless $sub->{'ready'} |
|
987
|
1 |
12 |
if ($immediate_done) |
|
989
|
2 |
0 |
$sub->{'ready'} ? : |
|
1000
|
11 |
1 |
unless $sub->{'ready'} |
|
1003
|
1 |
11 |
if ($immediate_fail) |
|
1013
|
0 |
16 |
unless my $self = $weakself |
|
1014
|
2 |
14 |
if $self->{'result'} or $self->{'failure'} |
|
1016
|
2 |
5 |
if --$pending and $_[0]{'cancelled'} |
|
1018
|
2 |
10 |
if ($_[0]{'cancelled'}) { } |
|
|
3 |
7 |
elsif ($_[0]{'failure'}) { } |
|
1023
|
2 |
1 |
if $pending |
|
1036
|
18 |
1 |
unless $sub->{'ready'} |
|
1045
|
0 |
7 |
unless $self->{'subs'} |
|
1052
|
0 |
7 |
unless $self->{'subs'} |
|
1059
|
0 |
9 |
unless $self->{'subs'} |
|
1060
|
15 |
3 |
if $_->{'ready'} and not $_->{'failure'} |
|
1066
|
0 |
4 |
unless $self->{'subs'} |
|
1067
|
8 |
0 |
if $_->{'ready'} |
|
1073
|
0 |
6 |
unless $self->{'subs'} |
|
1074
|
12 |
0 |
if $_->{'ready'} |