Branch Coverage

blib/lib/PDLA/PP.pm
Criterion Covered Total %
branch 148 386 38.3


line true false branch
147 120 85 if ('PDLA::PP::Rule' eq $str) { }
154 60 145 exists $self->{'doc'} ? :
160 0 619 if $main::PP_VERBOSE
182 0 270 if $nargs < 0 or $nargs > 3
185 248 22 unless ref $targets eq 'ARRAY'
188 236 34 if ($#_ != -1)
189 200 36 if (ref $_[-1] eq 'CODE')
195 234 2 if (defined $conditions) { }
196 64 170 unless ref $conditions eq 'ARRAY'
201 58 178 if defined $doc
221 8 218 if (exists $pars->{$target})
245 38 365 if substr($condition, 0, 1) eq '_'
247 61 304 unless (exists $pars->{$condition})
266 8 201 if $self->check_if_targets_exist($pars)
267 61 140 unless $self->check_if_conditions_exist($pars)
306 0 146 unless exists $self->{'ref'}
316 48 98 unless $self->is_valid($pars)
326 0 97 unless $#retval == $#$targets
334 0 109 if exists $pars->{$target}
340 0 109 if (defined $result and $result eq 'DO NOT SET!!') { }
360 0 4 unless @_ == 3
370 0 4 if $self->is_valid($pars)
397 0 50 unless $#$targets == 0
408 0 44 unless exists $self->{'returns.value'}
416 16 28 unless $self->is_valid($pars)
508 16 0 unless (exists $self->{'doc'})
514 0 16 unless $#$targets == 0
530 0 15 unless exists $self->{'insertname.value'}
536 1 14 unless $self->is_valid($pars)
570 15 1 ref $src ? :
589 15 1 ref $src ? :
594 109 0 if defined $syms{$1} or confess("$1 not defined in '${ret}'!")
602 0 32 unless $#_ == 1
608 0 32 if ref $target
609 0 32 if ref $condition
731 0 0 $co->{$_}->need_malloc ? :
732 1 2 $cn ? :
1 2 $which eq 'PRIV' ? :
744 0 10 unless $#_ == 2
751 0 10 if ref $target
752 0 10 if ref $symbol
810 0 2 unless $PDLA::PP::done
827 0 2 if $packname =~ m[/]
831 0 2 defined $callpack ? :
859 0 0 if $#_ > -1
881 0 3 if (ref $pm) { }
885 0 0 unless defined $opt->{'At'} and $opt->{'At'} =~ /^(Top|Bot|Middle)$/
901 0 0 if ($cmd =~ /^\s*BOOT\s*$/) { }
966 4 17 if /%\{/ or /%}/
968 10 11 if /\n/
980 0 1 if $PDLA::PP::done
982 1 0 $main::DOCUMENTED ? :
984 0 1 if $main::PP_VERBOSE
985 0 1 if nopm()
986 0 1 unless my $fh = 'FileHandle'->new(">$main::PDLAPREF.xs")
1064 1 0 unless (nopm())
1066 0 1 unless $main::PDLABEGIN =~ /^\s*$/
1068 0 1 unless $fh = 'FileHandle'->new(">$main::PDLAPREF.pm")
1112 0 2 if $main::PP_VERBOSE
1116 0 2 if ($name =~ /\n/)
1120 0 0 if ($fulldoc =~ s/^(\w+)//) { }
0 0 elsif ($fulldoc =~ /=head2 (\w+)/) { }
1136 0 0 if exists $obj{'Dump'} and $obj{'Dump'} and $main::PP_VERBOSE
1139 0 1 unless exists $obj{'FreeFunc'}
1152 1 0 if $obj{'PdlDoc'}
1156 0 1 if $main::PP_VERBOSE
1164 0 0 if (ref $_[0] eq 'HASH') { }
1169 0 0 if ($options and ref $options eq 'HASH' and $options->{'infavor'})
1180 0 0 if $infavor
1237 0 0 if ($string =~ /^$proto_re+$/)
1376 0 0 unless -f $typemap
1378 0 0 unless -T $typemap
1381 0 0 unless open TYPEMAP, $typemap
1387 0 0 if /^\s*#/
1389 0 0 if (/^INPUT\s*$/)
1390 0 0 if (/^OUTPUT\s*$/)
1391 0 0 if (/^TYPEMAP\s*$/)
1392 0 0 if ($mode eq 'Typemap') { }
0 0 elsif (/^\s/) { }
0 0 elsif ($mode eq 'Input') { }
1397 0 0 if /^$/ or /^#/
1398 0 0 unless my($t_type, $kind, $proto) = /^\s*(.*?\S)\s+(\S+)\s*($proto_re*)\s*$/
1403 0 0 unless $proto
1404 0 0 unless &ValidProtoString($proto)
1424 0 0 unless $foundtm
1432 0 0 unless exists $type_kind{$full_type}
1521 1 3 /^\s*$/ ? :
1528 0 3 if (/^\s*([^=]+)\s*=>\s*(\S+)\s*$/) { }
0 3 elsif (/^\s*pdl\s+\*\s*(\w+)$/) { }
1531 0 0 if $main::PP_VERBOSE
1534 0 0 unless defined $dimobjs->{$dim}
1543 0 3 if ($name =~ /$INVALID_OTHERPARS_RE/)
1609 1 0 $affine_ok ? :
1612 0 1 $$pobjs{$pnames->[$_]}{'FlagPhys'} ? :
1613 0 1 if ($PDLA::PP::Config{'cc'} eq 'cl')
1614 0 0 if $join_flags eq ''
1629 2 0 unless $pobjs->{$_}{'FlagW'}
1630 0 2 if $pobjs->{$_}{'FlagW'}
1639 1 3 $name eq 'copy' ? :
1641 0 4 $name eq 'foo' ? :
1646 0 4 if ($p2child)
1649 0 0 if ($name eq 'redodims')
1716 0 0 if ($glb) { }
1731 0 1 if ($glb) { }
1759 0 2 $nopdlthread ? :
1794 4 0 $#_ > -1 ? :
1798 0 0 if (not $callcopy) { }
1860 0 2 if $pmcode
1864 0 2 if $globalnew
1898 2 0 unless $out{$_} or $outca{$_}
1909 0 2 if ($other{$x}) { }
0 2 elsif ($outca{$x}) { }
1927 2 0 if ($nmaxonstack == $ninout) { }
1936 0 0 if ($other{$x}) { }
0 0 elsif ($tmp{$x} or $outca{$x}) { }
1960 0 2 if ($other{$x}) { }
0 2 elsif ($out{$x} or $tmp{$x} or $outca{$x}) { }
2030 0 2 if $globalnew
2040 0 2 if exists $parobjs->{$x} and exists $parobjs->{$x}{'FlagOut'}
2117 0 1 unless $bvalflag
2119 0 1 if defined $badcode
2152 1 0 unless ($other{$x} or $out{$x} or $tmp{$x} or $outca{$x})
2153 0 1 if ($add) { }
2166 1 0 if ($add != 0) { }
2169 0 0 if $main::PP_VERBOSE
2172 0 1 if (defined $badflag and $badflag == 0)
2178 0 0 if $main::PP_VERBOSE
2198 0 1 unless $bvalflag
2200 0 1 if (defined $badcode)
2208 0 0 if ($badcode =~ /\$PRIV(bvalflag)/)
2223 0 1 if exists $parobjs->{$x} and exists $parobjs->{$x}{'FlagOut'}
2261 2 0 unless defined $arg
2267 0 0 if (exists $parobjs->{$name})
2268 0 0 if (exists $parobjs->{$name}{'FlagOut'}) { }
0 0 elsif (not exists $parobjs->{$name}{'FlagTemp'}) { }
2280 0 0 if $#in == 0
2281 0 0 if $#out == 0
2283 0 0 if (ref $arg eq 'ARRAY') { }
0 0 elsif (ref $arg eq '') { }
2285 0 0 if ($narg > -1)
2287 0 0 if $narg > 0
2290 0 0 unless $arg
2296 0 0 unless defined $in
2298 0 0 unless defined $out
2360 0 0 if (defined $bflag and $bflag)
2387 0 0 if (defined $bflag and $bflag)
2404 0 0 if $doc eq '' and not defined $doc and $doc == undef
2405 0 2 if $doc =~ /^\s*internal\s*$/i
2408 0 2 unless $bvalflag
2414 0 2 if scalar(@splitRes = split(/ /, $doc, 0)) <= 1
2417 0 2 unless $pars
2420 0 2 if $otherpars
2421 0 2 $otherpars ? :
2424 2 0 if (defined $baddoc)
2453 0 0 if ($rev eq '1') { }
2478 0 2 if ($hasp2child)
2480 0 0 if $ignore->{$child}
2483 0 0 unless $parobjs->{$child}{'FlagCreateAlways'}
2485 0 0 if $hasp2child
2490 0 2 if $ignore->{$_}
2495 0 2 if ($po->{'FlagTyped'}) { }
2498 0 0 if $po->{'FlagTplus'}
2503 0 2 if ($po->{'FlagCreateAlways'}) { }
2510 0 2 if $po->{'FlagCreat'}
2536 0 2 if $hasp2child and $#$gentypes != $ntypes
2539 0 2 if $hasp2child
2545 0 2 if $ignore->{$_} or $po->{'FlagTyped'} or $po->{'FlagCreateAlways'}
2550 0 2 if $po->{'FlagCreat'}
2573 1 1 if $opts->{'ToPtrs'}
2584 1 0 if $opts->{'ToPtrs'}
2596 2 0 if $opts->{'ToPtrs'}
2613 1 0 $havethreading ? :
2624 1 0 $havethreading ? :
2631 1 0 $havethreading ? :
2642 0 1 if ($PDLA::PP::Config{'cc'} eq 'cl')
2643 0 0 if $join__parnames eq ''
2644 0 0 if $join__realdims eq ''
2701 0 1 $$pobjs{$pnames->[$_]}{'FlagCreat'} ? :
2764 0 1 if $$pobjs{$pnames->[$_]}{'FlagCreat'}
2782 1 0 unless defined $noPthreadFlag
2786 1 0 $npdls ? :
2795 0 1 if ($$pobjs{$pnames->[$_]}{'FlagCreat'}) { }
2842 0 0 if ($fulldoc =~ /=for sig\n\n Signature: \(([^\n]*)\n/g)
2875 0 0 unless my $sig = extract_signature_from_fulldoc($fulldoc)
2883 0 0 if $switched_to_other_pars and $arg =~ /$pars_re/
2885 0 0 if ($arg =~ /$pars_re/) { }
2894 0 0 if @pars == 0
2915 0 0 unless my $sig = extract_signature_from_fulldoc($fulldoc)
2922 0 0 if @otherpars > 0 and $arg =~ /$pars_re/
2924 0 0 unless ($arg =~ /$pars_re/)
2930 0 0 if @otherpars == 0
3557 0 0 if $main::PP_VERBOSE
3569 0 1 if $main::PP_VERBOSE