Branch Coverage

lib/B/DeparseTree/TreeMain.pm
Criterion Covered Total %
branch 123 344 35.7


line true false branch
129 24 96 unless *{$_;}{'CODE'}
175 0 0 if ($arg eq '-d') { }
0 0 elsif ($arg =~ /^-f(.*)/) { }
0 0 elsif ($arg eq '-l') { }
0 0 elsif ($arg eq '-a') { }
0 0 elsif ($arg eq '-p') { }
0 0 elsif ($arg eq '-P') { }
0 0 elsif ($arg eq '-q') { }
0 0 elsif (substr($arg, 0, 2) eq '-s') { }
0 0 elsif ($arg =~ /^-x(\d)$/) { }
219 124 1278 defined $self->{'ambient_warnings'} ? :
222 0 1402 if $] < 5.009
249 0 1328 if ($gv->NAME eq 'main') { }
252 0 1328 unless UNIVERSAL::isa($coderef, 'CODE')
263 0 64 if ($func eq 'main::main') { }
266 0 64 unless UNIVERSAL::isa($func, 'CODE')
276 0 91 if ($self->{'use_dumper'})
279 0 91 if (class($sv) eq 'SPECIAL')
284 0 91 if (class($sv) eq 'NULL')
288 0 91 if ($sv->FLAGS & 8388608)
290 0 0 if ($mg->TYPE eq 'V')
297 62 29 if ($sv->FLAGS & 256) { }
0 29 elsif ($sv->FLAGS & 512) { }
0 29 elsif ($sv->FLAGS & 2048 and $sv->can('RV')) { }
29 0 elsif ($sv->FLAGS & 1024) { }
299 0 62 if $str < 0
303 0 0 if ($nv == 0) { }
0 0 elsif (1 / $nv == 0) { }
0 0 elsif ($nv != $nv) { }
304 0 0 if (pack('F', $nv) eq "\000\000\000\000\000\000\000\000") { }
316 0 0 if ($nv > 0) { }
329 0 0 if (pack('F', $nv) eq "\000\000\000\000\000\000\370\377") { }
0 0 elsif (pack('F', $nv) eq "\000\000\000\000\000\000\370\177") { }
345 0 0 if ($str != $nv)
349 0 0 if ($str != $nv)
357 0 0 if $nv < 0
361 0 0 if (class($ref) eq 'AV') { }
0 0 elsif (class($ref) eq 'HV') { }
0 0 elsif (class($ref) eq 'CV') { }
375 8 0 if ($] > 5.0150051)
380 0 0 if ($] > 5.0150051 and $self->{'curcv'} and $self->{'curcv'}->object_2svref == $ref->object_2svref)
390 0 0 if ($ref->FLAGS & 4194304)
392 0 0 if ($mg->TYPE eq 'r')
400 0 0 if ($self->{'in_subst_repl'} and $const =~ /^[0-9]/)
409 0 29 if ($str =~ /[[:^print:]]/) { }
428 0 0 if ($str =~ /^\$v/) { }
444 0 0 if B::Deparse::null($op->first)
462 0 0 if $parent
467 0 0 if (exists $info->{'other_ops'}) { }
483 4 2097 if ($addr and not exists $self->{'optree'}{$addr})
484 4 0 if $op
497 2087 1 if (B::Deparse::is_state($kids[$i]))
501 0 2087 if ($fix_cop)
505 0 2087 if ($i > $#kids)
509 0 2088 if (B::Deparse::is_for_loop($kids[$i]))
511 0 0 $kids[$i]->sibling->name eq 'unstack' ? :
522 759 1329 unless (exists $expr->{'prev_expr'})
526 0 2088 if ($fix_cop)
532 0 2088 if (B::class($op) eq 'COP' and not $expr->{'text'}) { }
555 14 1328 defined $out_cop ? :
557 1342 0 if (defined $root)
560 0 1342 if ${$root->sibling;}
561 1328 14 if not defined $limit_seq or defined $nseq and $nseq < $limit_seq
566 2 0 if defined $self->{'limit_seq'} and !defined($limit_seq) || $self->{'limit_seq'} < $limit_seq
572 0 4175 unless $info->{'type'}
575 4175 0 if ($parent)
576 0 4175 unless ref $parent
595 0 12558 unless $$startop
607 827 23883 if ($ppname eq 'padrange')
630 4 20 if (class($op) eq 'PMOP' and ref $op->pmreplroot and ${$op->pmreplroot;} and $op->pmreplroot->isa('B::OP'))
638 11224 13486 if ($op->flags & 4)
653 14 1455 unless $$startop
654 0 1455 if $$visited{$$startop}
657 121 12770 if $$visited{$$op}
664 116 12654 if ($ppname =~ /^((and|d?or)(assign)?|(map|grep)while|range|cond_expr|once)$/) { }
18 12636 elsif ($ppname eq 'subst') { }
5 12631 elsif ($ppname =~ /^(enter(loop|iter))$/) { }
708 0 0 if ($opt eq 'C') { }
0 0 elsif ($opt eq 'i') { }
0 0 elsif ($opt eq 'T') { }
0 0 elsif ($opt eq 'v') { }
732 0 0 if (defined $ar->[1]) { }
733 0 0 if (ref $ar->[1]) { }
762 0 0 if (defined $^I)
765 0 0 if ($^W)
768 0 0 if ($/ ne "\n" or defined $O::savebackslash)
773 0 0 B::begin_av()->isa('B::AV') ? :
774 0 0 B::unitcheck_av()->isa('B::AV') ? :
777 0 0 B::check_av()->isa('B::AV') ? :
778 0 0 B::init_av()->isa('B::AV') ? :
779 0 0 B::end_av()->isa('B::AV') ? :
780 0 0 if ($] < 5.02) { }
797 0 0 if ($self->{'curcop'})
814 0 0 if ($] < 5.021) { }
815 0 0 unless (B::Deparse::null($root))
821 0 0 unless (B::Deparse::null($root))
831 0 0 if ($root->name eq 'leave' and ($kid = $root->first)->name eq 'enter' and not B::Deparse::null($kid = $kid->sibling) and $kid->name eq 'stub' and not B::Deparse::null($kid = $kid->sibling) and $kid->name eq 'null' and class($kid) eq 'COP' and B::Deparse::null($kid->sibling)) { }
850 0 0 if @text
855 0 0 defined $self->{'curcop'} ? :
856 0 0 if (defined *{$laststash . '::DATA';}{'IO'})
858 0 0 unless $laststash eq $self->{'curstash'}
890 0 19281 unless $op->can('name')
894 0 19281 if $ENV{'DEBUG_DEPARSETREE'}
897 4092 15189 if (exists $B::DeparseTree::PP_MAPFNS{$name}) { }
899 1664 2428 if (ref $B::DeparseTree::PP_MAPFNS{$name} eq 'ARRAY') { }
902 231 1433 if ($meth eq 'maybe_targmy') { }
906 186 45 unless @args
907 4 227 if ($op->private & 16) { }
938 0 19281 unless ref $info
939 0 19281 unless $info->isa('B::DeparseTree::TreeNode')
941 19199 82 if $parent
944 19212 69 if ($got_op) { }
945 2679 16533 if ($got_op != $op)
954 4183 15098 if ($info->{'other_ops'})
956 0 8884 if (not ref $other) { }
5501 3383 elsif ($other->isa('B::DeparseTree::TreeNode')) { }
979 0 1330 if not defined $cv or $cv->isa('B::NULL')
980 0 1330 if $cv->isa('B::SPECIAL')
985 0 1330 if ($cv->FLAGS & 1024)
988 2 1328 if ($cv->CvFLAGS & 3)
990 1 1 if $cv->CvFLAGS & 2
991 0 2 if $cv->CvFLAGS & 0
992 1 1 if $cv->CvFLAGS & 1
1006 1330 0 if (not B::Deparse::null($root)) { }
1009 1330 0 if ($lineseq->name eq 'lineseq') { }
0 0 elsif ($start_op) { }
1033 0 0 if ($$sv) { }
1049 0 1330 if ($start_op)
1109 0 0 if ($is_form) { }
1117 0 0 if ($name eq 'BEGIN')
1119 0 0 if (defined $use_dec and $self->{'expand'} < 5)
1120 0 0 if (0 == length $use_dec) { }
1128 0 0 if ($self->{'linenums'})
1133 0 0 if (class($cv->STASH) ne 'SPECIAL')
1135 0 0 if ($stash ne $self->{'curstash'})
1138 0 0 unless $name =~ /::/
1201 2087 0 if ($] >= 5.016) { }
1210 0 67 if $ignored_hints{$key}
1212 13 54 if $is_feature and not $doing_features
1213 12 42 if (not exists $from->{$key} or $from->{$key} ne $to->{$key})
1214 0 12 if ($is_cperl)
1215 0 0 if $key eq 'feature_lexsubs'
1216 0 0 if $key eq 'feature_signatures'
1218 12 0 if $is_feature
1223 0 0 defined $to->{$key} ? :
1230 0 55 if $ignored_hints{$key}
1232 13 42 if $is_feature and not $doing_features
1233 0 42 unless (exists $to->{$key})
1234 0 0 if $is_feature
1239 3 2084 if (@features or @unfeatures)
1240 1 2 unless (%rev_feature)
1242 3 2084 if (@features)
1246 0 2087 if (@unfeatures)
1252 0 2087 if @decls
1267 0 0 if ($stash ne $self->{'curstash'})
1279 0 0 if ($warnings->isa('B::SPECIAL') and $$warnings == 4) { }
0 0 elsif ($warnings->isa('B::SPECIAL') and $$warnings == 5) { }
0 0 elsif ($warnings->isa('B::SPECIAL')) { }
1292 0 0 if (defined $warning_bits and !defined($self->{'warnings'}) || $self->{'warnings'} ne $warning_bits)
1299 0 0 $] < 5.008009 ? :
1301 0 0 if ($self->{'hints'} != $hints)
1307 0 0 if ($] > 5.009)
1311 0 0 if ($] >= 5.015006)
1315 0 0 if ($from != $to)
1316 0 0 if ($to == $feature::hint_mask) { }
1317 0 0 if ($self->{'hinthash'}) { }
1336 0 0 if ($] > 5.009)
1352 2 1264 if (($to & &WARN_MASK()) eq (warnings::bits('all') & &WARN_MASK())) { }
1264 0 elsif (($to & &WARN_MASK()) eq ("\000" x length($to) & &WARN_MASK())) { }
1374 0 2087 unless defined $seq
1384 0 0 if (not $lexical and $cv and ${\0 unless $cv->OUTSIDE;} != ${$self->{'curcv'};})
1385 0 0 unless $cv->OUTSIDE