Branch Coverage

lib/B/DeparseTree/PP.pm
Criterion Covered Total %
branch 102 210 48.5


line true false branch
175 8 8 unless *{$_;}{'CODE'}
188 6 21 if ($hints and $hints != $feature::hint_mask) { }
7 14 elsif ($hints) { }
246 0 1 if $op->flags & 128
250 0 1 $quoted ? :
252 0 1 if $i > 127
270 3 0 $op->first->sibling->isa('B::NULL') ? :
272 0 3 if ($self->pure_string($child))
287 0 3 if ($code =~ s/^((?:CORE::)?do) \{/$1({/)
296 0 0 if $glob->name eq 'rv2gv'
300 0 0 $scope ? :
328 27 0 if ($cx <= 4) { }
339 0 0 if (not B::Deparse::null($op->first) and $op->first->name eq 'null' and $op->first->targ == 157) { }
354 0 4 unless (B::Deparse::null($kid->sibling))
363 0 0 if ($op->flags & 128) { }
384 0 2 if ($op->flags & 128) { }
389 0 2 if not $parens and substr($fh, 0, 1) eq '('
394 2 0 if ($parens) { }
410 0 2 $op->flags & 128 ? :
413 2 0 if ($keyword =~ /^CORE::/ or $kid->name ne 'const')
417 2 0 if ($text =~ /^\$?(\w|::|\`)+$/ or $text =~ /[<>]/) { }
423 0 2 if ($cx >= 5 or $self->{'parens'}) { }
453 0 0 if ($op->private & 64) { }
454 0 0 if ($op->flags & 128)
460 0 0 if ($op->flags & 128) { }
479 0 0 if ($op->private & 64) { }
0 0 elsif ($op->flags & 128) { }
521 1 3242 if (class($kid) eq 'NULL')
537 2586 3164 if (not $lop->private & 192 || $lop->name eq 'undef' or $lop->name =~ /^(?:entersub|exit|open|split)\z/)
544 3141 23 if ($lop->name =~ /^pad[ash]v$/) { }
12 11 elsif ($lop->name =~ /^(gv|rv2)[ash]v$/ and $lop->private & 64 or $lop->name eq 'null' and $lop->first->name eq 'gvsv' and $lop->first->private & 64) { }
2 18 elsif ($lop->name ne 'undef' and not $lop->name eq 'sort' && $lop->flags & 4) { }
545 10 3131 if ($lop->private & 64) { }
546 0 10 if $local =~ /^(?:local|our|my)$/
549 0 3131 if $local =~ /^(?:local|our|state)$/
556 0 12 if $local =~ /^(?:my|local|state)$/
564 0 2 if $local =~ /^(?:my|our|state)$/
568 8 3234 if $local eq 'either'
569 2566 676 if (B::Deparse::null($kid->sibling) and not $local)
576 3156 85 if ($local) { }
577 14 3142 if (class($kid) eq 'UNOP' and $kid->first->name eq 'gvsv') { }
592 648 28 if ($local) { }
615 2 0 if ($kid->name eq 'null')
618 0 2 if ($anoncode->name eq 'anonconst')
621 2 0 if ($anoncode->name eq 'anoncode' or not B::Deparse::null($anoncode = $kid->sibling) and $anoncode->name eq 'anoncode') { }
0 0 elsif ($kid->name eq 'pushmark') { }
627 0 0 if ($sib_name =~ /^enter(xs)?sub/)
631 0 0 if ($self->{'parens'} or $kid->sibling->private & 8)
647 0 2 $op->flags & 128 ? :
648 0 2 if (class($op) eq 'UNOP' and $op->first->name eq 'const' and $op->first->private & 64) { }
657 0 2 $op->first->name eq 'const' && $op->first->private & 2 ? :
682 0 0 unless ($cx < 1 and (B::Deparse::is_scope($true) and $true->name ne 'null') and B::Deparse::is_scope($false) || B::Deparse::is_ifelse_cont($false) and $self->{'expand'} < 7)
707 0 0 if ($newcond->name eq 'lineseq')
719 0 0 if $i
721 0 0 unless (B::Deparse::null($false))
734 0 86 if ($op->private & 0)
749 2 574 unless B::Deparse::null($op->first->sibling)
754 0 574 if ($op->flags & 128 and not $op->flags & 32) { }
0 574 elsif ($op->private & 8) { }
771 0 574 if (B::Deparse::is_scope($kid)) { }
574 0 elsif ($kid->first->name eq 'gv') { }
0 0 elsif (B::Deparse::is_scalar($kid->first) and $kid->first->name ne 'rv2cv') { }
779 540 34 if (class($gv) eq 'GV' and class($cv = $gv->CV) ne 'SPECIAL' or $gv->FLAGS & 2048 and class($cv = $gv->RV) eq 'CV')
781 1 539 if $cv->FLAGS & 1024
787 0 574 if ($self->lex_in_scope("&$kid") or $self->lex_in_scope("&$kid", 1)) { }
574 0 elsif (not $amper) { }
792 0 574 if ($subname_info->{'text'} eq 'main::') { }
795 0 574 if (not $kid =~ /::/ and $kid ne 'x')
800 0 0 if (exists $feature_keywords{$kid}) { }
0 0 elsif (do { local $@; local $SIG{'__DIE__'}; eval { do { () = prototype "CORE::$kid"; 1 } } }) { }
801 0 0 if $self->feature_enabled($kid)
808 0 574 unless ($subname_info->{'text'} =~ /^(?:\w|::)(?:[\w\d]|::(?!\z))*\z/)
817 0 0 B::Deparse::is_subscriptable($kid->first) || $kid->first->name eq 'padcv' ? :
837 0 574 if (not $declared and defined $proto)
845 1 573 if ($declared and defined $proto and not $amper) { }
848 0 1 if ($amper eq '&') { }
851 1 0 if @$args
858 0 574 if ($prefix or $amper) { }
859 0 0 if ($sub_name eq '&')
864 0 0 if ($op->flags & 64) { }
876 1 573 defined $proto ? :
877 573 1 if (not $declared) { }
0 1 elsif ($dproto =~ /^\s*\z/) { }
0 1 elsif ($dproto eq '$' and B::Deparse::is_scalar($exprs[0])) { }
1 0 elsif ($dproto ne '$' and defined $proto || $simple) { }
880 379 194 @nodes > 0 ? :
882 0 573 if ($self->dedup_func_parens(\@nodes)) { }
896 573 0 if ($subname_info and $other_ops)
941 0 0 if ($subname_info and $other_ops)
956 4 8 $_[1]->private & 8 ? :
967 0 0 $flip->flags & 128 ? :
992 0 5255 $] < 5.022 ? :
1028 0 6 if ($first_kid->name eq 'rv2gv')
1032 0 4 if (B::Deparse::is_scalar($kid) and $] < 5.021 || $op->flags & 128)
1036 0 0 if ($kid_node->{'text'} eq 'ARGV') { }
1037 0 0 if (@other_ops) { }
1063 0 0 $] < 5.022 ? :
1067 0 18 $] < 5.022 ? :
1075 0 6 if ($op->private & 16)
1098 6 0 if ($class eq 'PVOP') { }
0 0 elsif ($class eq 'PADOP') { }
1107 1 5 if $priv_flags & 32
1108 1 5 if $priv_flags & 128
1109 4 2 if $from eq $to and $flags eq ''
1110 1 5 if $priv_flags & 8