Branch Coverage

blib/lib/Convert/ASN1/_decode.pm
Criterion Covered Total %
branch 155 234 66.2


line true false branch
12 23 0 if require bytes
55 724 174 if (length $op->[0]) { }
59 25 818 unless (my($tag, $len, $npos, $indef) = _decode_tl($buf, $pos, $end, $larr))
60 23 0 if $pos == $end and $seqof || defined $op->[5]
64 752 66 if ($tag eq $op->[0])
73 16 48 ref $stash eq 'SCALAR' ? :
448 64 defined $var ? :
240 512 $seqof ? :
79 119 633 if $seqof and $pos < $end
83 1 65 if ($tag eq ($op->[0] | " ") and my $ctr = $ctr[$op->[1]])
104 0 0 ref $stash eq 'SCALAR' ? :
1 0 defined $var ? :
0 1 $seqof ? :
108 0 1 if $seqof and $pos < $end
113 65 0 if ($seqof or defined $op->[5])
122 33 141 if ($op->[1] == 14) { }
137 4 elsif ($op->[1] == 15) { }
4 0 elsif ($op->[1] == 18) { }
127 2 32 unless (my($tag, $len, $npos, $indef) = _decode_tl($buf, $pos, $end, $larr))
128 2 0 if $pos == $end and $seqof || defined $op->[5]
135 2 30 if ($op->[7])
140 1 29 ref $stash eq 'SCALAR' ? :
2 30 $seqof ? :
2 30 $handler ? :
145 1 31 if $seqof and $pos < $end
152 0 140 unless (my($tag, $len, $npos, $indef) = _decode_tl($buf, $pos, $end, $larr))
153 0 0 if $pos == $end and $seqof || defined $op->[5]
159 137 136 if ($tag eq $cop->[0])
164 5 7 ref $stash eq 'SCALAR' ? :
117 12 defined $var ? :
8 129 $seqof ? :
172 137 0 $cop->[2] ? :
178 2 135 if $seqof and $pos < $end
182 2 134 if ($cop->[1] == 18)
187 2 132 unless (length $cop->[0])
188 0 2 unless eval { do { _decode($optn, [$cop], \my %tmp_stash, $pos, $npos + $len + $indef, undef, $larr, $buf); my $nstash = $seqof ? $$seqof[$idx++] = {} : (defined $var ? $stash->{$var} = {} : (ref $stash eq "SCALAR" ? $$stash = {} : $stash)); @{$nstash;}{keys %tmp_stash} = values %tmp_stash } }
203 0 0 ref $stash eq 'SCALAR' ? :
0 0 defined $var ? :
2 0 $seqof ? :
213 1 1 if $seqof and $pos < $end
217 0 132 if ($tag eq ($cop->[0] | " ") and my $ctr = $ctr[$cop->[1]])
223 0 0 ref $stash eq 'SCALAR' ? :
0 0 defined $var ? :
0 0 $seqof ? :
241 0 0 if $seqof and $pos < $end
246 1 0 if ($pos < $end and $extensions)
249 0 1 if $seqof and $pos < $end
253 0 0 unless $op->[5]
264 1 513 unless $pos == $end
272 10 16 unpack('C', substr($_[4], $_[5], 1)) ? :
282 16 73 unpack('C', $buf) & 128 ? :
283 16 73 if ($_[6] > 4) { }
315 0 2 exists $_[0]{'decode_null'} ? :
325 159 3 if ($_[1][1] == 6 and @data > 1)
326 4 155 if ($data[0] < 40) { }
36 119 elsif ($data[0] < 80) { }
347 1 6 unless $_[6]
350 4 2 if ($first & 128) { }
2 0 elsif ($first & 64) { }
0 0 elsif (substr($_[4], $_[5], $_[6]) =~ /^.([-+]?)0*(\d+(?:\.\d+(?:[Ee][-+]?\d+)?)?)$/s) { }
359 0 4 if ($expLen == 3) { }
374 1 3 if $first & 64
380 1 1 if $first == 64
381 1 0 if $first == 65
396 4 16 unless $_[1][6][0][2]
414 361 0 if (defined(my $ch = $_[1][6])) { }
415 152 209 defined $_[3] || $_[1][3] ? :
439 0 8 if $_[1][3] or not defined $ch
442 8 0 defined $_[3] ? :
448 0 26 unless my($tag, $len, $npos, $indef) = _decode_tl($_[4], $pos, $end, $larr)
456 55 14 if (length $op->[0]) { }
0 14 elsif ($op->[1] == 14) { }
0 14 elsif ($op->[1] == 15) { }
14 0 elsif ($op->[1] == 18) { }
457 25 30 if ($tag eq $op->[0])
466 25 0 defined $var ? :
472 0 30 if ($tag eq ($op->[0] | " ") and my $ctr = $ctr[$op->[1]])
486 0 0 if defined $op->[2]
499 0 0 if ($tag eq $cop->[0])
500 0 0 defined $var ? :
512 0 0 if ($tag eq ($cop->[0] | " ") and my $ctr = $ctr[$cop->[1]])
515 0 0 defined $var ? :
542 0 26 if (not defined $done and defined $any)
544 0 0 if defined $var
548 1 25 if (not defined $done and defined $extensions)
552 0 26 if not defined $done or $done[$done]++
557 0 8 unless $end == $pos
560 0 4 unless $done[$idx] or $ch->[$idx][5] or $ch->[$idx][1] == 18
575 0 24 if ($mode == 2 or $_[6] == 0)
580 0 24 unless my(@bits) = substr($_[4], $_[5], $_[6]) =~ /^((?:\d\d)?\d\d)(\d\d)(\d\d)(\d\d)(\d\d)(\d\d)((?:\.\d{1,3})?)(([-+])(\d\d)(\d\d)|Z)/
584 19 5 if ($bits[0] < 100) { }
585 18 1 if $bits[0] < 50
593 1 23 if length $bits[6]
595 5 19 if ($bits[7] ne "Z")
597 1 4 if $bits[8] eq "-"
600 0 24 $mode ? :
630 25 1018 if $pos >= $end
636 1 1017 if ((unpack("C", $tag) & 31) == 31)
640 1 4 if $pos >= $end
645 0 1017 if $pos >= $end
649 112 905 if ($len & 128)
652 102 10 if ($len) { }
653 0 102 if $pos + $len > $end
655 102 0 $len < 4 ? :
659 5 5 unless (exists $larr->{$pos})
660 1 4 unless _scan_indef($_[0], $pos, $end, $larr)
667 0 1016 if $pos + $len + $indef > $end
680 0 27 if $pos + 2 > $end
682 10 17 if (substr($_[0], $pos, 2) eq "\0\0")
690 0 17 if $pos >= $end
694 1 16 if ((unpack("C", $tag) & 31) == 31)
697 1 2 if $pos >= $end
702 0 16 if $pos >= $end
706 6 10 if ($len & 128) { }
707 0 6 if ($len &= 127) { }
708 0 0 if $pos + $len > $end
710 0 0 $len < 4 ? :