Condition Coverage

blib/lib/ExtUtils/ParseXS/Node.pm
Criterion Covered Total %
condition 258 299 86.2


and 3 conditions

line !l l&&!r l&&r condition
298 152 380 646 @fields and $fields[0] eq "-parent"
421 908 838 323 $flags & $keywords_flag_MODULE and ExtUtils::ParseXS::Utilities::looks_like_MODULE_line($line)
929 27 2 $flags & $keywords_flag_NOT_IMPLEMENTED_YET and $line =~ s/^(\s*)(NOT_IMPLEMENTED_YET)/$1/
452 930 0 160 defined $max and $max >= $n
1138 313 1261 3 $pxs->{'line'} and @{$pxs->{'line'};}
1142 867 0 342 not defined $self->{'line_no'} and defined $pxs->{'line_no'}[0]
1199 0 1 23 defined $last and $last->isa("ExtUtils::ParseXS::Node::global_cpp_line")
1 0 23 defined $last and $last->isa("ExtUtils::ParseXS::Node::global_cpp_line") and $last->{'is_cond'}
0 0 23 defined $last and $last->isa("ExtUtils::ParseXS::Node::global_cpp_line") and $last->{'is_cond'} and not $last->{'is_if'}
1295 776 366 0 @{$pxs->{'line'};} and not $pxs->{'line'}[0] =~ /\S/
1455 0 0 1 $pxs->{'config_WantLineNumbers'} and @{$self->{'lines'};}
0 0 1 $pxs->{'config_WantLineNumbers'} and @{$self->{'lines'};} and not $self->{'lines'}[0] =~ /^\s*#\s*line\b/
1958 17 20 2 $num > 1 and not $case_had_cond
1998 338 0 17 $self->{'map_alias_name_to_value'} and keys %{$$self{"map_alias_name_to_value"};}
2191 335 0 17 $self->{'map_alias_name_to_value'} and keys %{$$self{"map_alias_name_to_value"};}
2328 357 5 1 defined $const and not defined $class
2333 357 4 2 $return_type->{'static'} and not defined $class
2449 1 325 40 $pxs->{'config_allow_argtypes'} and $type =~ s/^(.*?\w.*?) \s* \b (\w+\s*\(.*)/$1/sx
2470 0 4 206 $pxs->{'config_optimize'} and $outputmap
4 27 179 $pxs->{'config_optimize'} and $outputmap and $outputmap->targetable_legacy
2573 154 0 292 length $type and $type =~ /\S/
2583 7 4 18 $name eq "RETVAL" and $old_param->{'is_synthetic'}
4 2 16 $name eq "RETVAL" and $old_param->{'is_synthetic'} and not defined $old_param->{'arg_num'}
2623 147 285 1 defined $type and not $pxs->{'config_allow_argtypes'}
2700 0 375 4 defined $p and length $p
2840 312 37 12 $xstype eq "T_PV" and $self->{'has_length'}
3087 11 243 8 not defined $output_code and $expr =~ /\bDO_ARRAY_ELEM\b/
3207 574 58 12 defined $xsub->{'decl'}{'class'} && $var eq 'CLASS'
3241 601 2 23 defined $default and not defined $init
603 2 21 defined $default and not defined $init and not $no_init
3464 178 41 33 $var ne "RETVAL" and not defined $out_num
3503 211 0 8 defined $output_code and not defined $out_num
3641 0 16 186 $pxs->{'config_optimize'} and "ExtUtils::Typemaps::OutputMap"->targetable($evalexpr)
16 16 170 $pxs->{'config_optimize'} and "ExtUtils::Typemaps::OutputMap"->targetable($evalexpr) and not $xbody->{'output_part'}{'targ_used'}
3687 41 152 18 $retvar eq "TARG" and not $xsub->{'decl'}{'return_type'}{'use_early_targ'}
3950 381 23 33 defined $param->{'in_out'} and $param->{'in_out'} eq "OUTLIST"
4013 27 132 2 $param->{'var'} eq 'RETVAL' && defined $param->{'arg_num'}
269 2 159 $param->{'is_synthetic'} and not $param->{'var'} eq 'RETVAL' && defined $param->{'arg_num'}
4059 26 0 77 defined $_->{'arg_num'} && $_->{'arg_num'} > 0
4221 0 285 100 $input->parse($pxs, $xsub, $xbody) and $input->{'kids'}
285 0 100 $input->parse($pxs, $xsub, $xbody) and $input->{'kids'} and @{$input->{'kids'};}
4277 411 10 2 defined $proto and $proto ne $ioproto
4519 628 45 15 defined $ioparam->{'in_out'} and $ioparam->{'in_out'} =~ /OUT$/
673 0 15 defined $ioparam->{'in_out'} and $ioparam->{'in_out'} =~ /OUT$/ and not $ioparam->{'in_output'}
443 85 145 $ioparam->{'var'} eq "RETVAL" and $ioparam->{'in_output'} || $xbody->{'seen_autocall'} && $xsub->{'decl'}{'return_type'}{'type'} ne 'void' && !$xsub->{'decl'}{'return_type'}{'no_output'}
464 0 23 $ioparam->{'in_output'} and $ioparam->{'var'} ne "RETVAL"
4531 628 16 44 defined $ioparam->{'in_out'} and $ioparam->{'in_out'} =~ /OUTLIST$/
4561 1 3 36 $retval && $retval->{'in_output'}
334 36 4 $xbody->{'seen_RETVAL_in_CODE'} and not $retval && $retval->{'in_output'}
370 1 3 $xbody->{'seen_RETVAL_in_CODE'} and not $retval && $retval->{'in_output'} and $xsub->{'decl'}{'return_type'}{'type'} ne "void"
4577 622 45 15 defined $_->{'in_out'} and $_->{'in_out'} =~ /OUT$/
4605 146 184 44 $retval and $retval->{'in_output'}
81 105 144 $xbody->{'seen_autocall'} and $xsub->{'decl'}{'return_type'}{'type'} ne "void"
186 4 140 $xbody->{'seen_autocall'} and $xsub->{'decl'}{'return_type'}{'type'} ne "void" and not $xsub->{'decl'}{'return_type'}{'no_output'}
4840 21 0 16 $param && defined $param->{'type'}
4867 227 26 1 defined $class and $name eq "DESTROY"
5048 1 0 0 $f =~ /\|\s*$/ and $f =~ /^\s*perl\s/
5136 1 1 0 $isPipe and $?
5419 98 88 390 @{$pxs->{'line'};} and not $pxs->{'line'}[0] =~ /^$ExtUtils::ParseXS::BLOCK_regexp/o
5456 1 32 6 @lines and not $lines[0] =~ /\S/
5742 6 128 0 @lines and not $lines[0] =~ /\S/
5748 6 114 0 defined $line0 && ($line0 =~ /^\s*#\s*line\b/ || $line0 =~ /^#if XSubPPtmp/)
14 0 120 $pxs->{'config_WantLineNumbers'} and not defined $line0 && ($line0 =~ /^\s*#\s*line\b/ || $line0 =~ /^#if XSubPPtmp/)
5794 68 4 40 $code =~ /\bRETVAL\b/ && !($code =~ /\bPERL_UNUSED_VAR\(RETVAL\)/)
5830 101 10 1 defined $xsub->{'CODE_sets_ST0'} and $xsub->{'CODE_sets_ST0'} ne $st0
5965 255 212 358 @{$pxs->{'line'};} and not $pxs->{'line'}[0] =~ /^$ExtUtils::ParseXS::BLOCK_regexp/o
6124 11 46 1 not $is_symbolic and $value =~ /:/
6169 41 2 4 $value eq 0 and not defined $xsub->{'map_alias_name_to_value'}{$fname}
6170 35 5 7 @keys and $pxs->{'config_author_warnings'}
6351 19 109 3 not $ioparam->{'is_synthetic'} and defined $ioparam->{'type'}
6359 114 3 11 $var_name eq "RETVAL" and $ioparam->{'is_synthetic'}
6398 1 119 20 not $no_init and defined $init_op
6402 3 16 1 $init_op =~ /^[=;]$/ and $var_init =~ /^NO_INIT\s*;?\s*$/
6422 3 0 3 $init_op eq '+' && !$is_alien
6548 2 71 2 $ioparam and $ioparam->{'in_output'}
6553 25 45 3 $outarg eq "RETVAL" and $xsub->{'decl'}{'return_type'}{'no_output'}
6561 44 23 1 $outarg ne "RETVAL" and not $ioparam->{'arg_num'}

or 2 conditions

line l !l condition
1506 145 0 $pxs->current_line_number || 0
2834 0 1 0 $xstype =~ s/OBJ$/REF/ or $xstype =~ s/^T_REF_IV_PTR$/T_PTRREF/

or 3 conditions

line l !l&&r !l&&!r condition
421 788 0 958 $line =~ s/^(\s*)($pat)\s*:\s*(?:#.*)?/$1/s or $flags & $keywords_flag_NOT_IMPLEMENTED_YET and $line =~ s/^(\s*)(NOT_IMPLEMENTED_YET)/$1/
1138 3 1286 288 $pxs->{'line'} and @{$pxs->{'line'};} or $pxs->fetch_para
2191 9 0 322 $self->{'seen_INTERFACE'} or $self->{'seen_INTERFACE_MACRO'}
2652 285 2 146 defined $type or $is_length
2672 19 0 10 defined $type || $is_length
3241 1 279 325 $xsub->{'SCOPE_enabled'} or not $init_code =~ /^\s*\Q$var\E =/
3496 11 19 3 not $self->{'in_output'} or $do_setmagic
3875 4 8 15 $xsub->{'decl'}{'return_type'}{'static'} || $xsub->{'decl'}{'name'} eq 'new'
3950 33 14 390 defined $param->{'in_out'} and $param->{'in_out'} eq "OUTLIST" or $param->{'is_length'}
4033 217 28 12 defined $param->{'arg_num'} or $io eq "OUTLIST"
4036 2 44 199 $param->{'is_addr'} or $io =~ /OUT/
4489 3 211 165 $xsub->{'CODE_sets_ST0'} || $xsub->{'decl'}{'return_type'}{'type'} ne 'void' && !$xsub->{'decl'}{'return_type'}{'no_output'}
4519 44 142 44 $ioparam->{'in_output'} || $xbody->{'seen_autocall'} && $xsub->{'decl'}{'return_type'}{'type'} ne 'void' && !$xsub->{'decl'}{'return_type'}{'no_output'}
15 145 528 defined $ioparam->{'in_out'} and $ioparam->{'in_out'} =~ /OUT$/ and not $ioparam->{'in_output'} or $ioparam->{'var'} eq "RETVAL" and $ioparam->{'in_output'} || $xbody->{'seen_autocall'} && $xsub->{'decl'}{'return_type'}{'type'} ne 'void' && !$xsub->{'decl'}{'return_type'}{'no_output'}
142 308 179 defined $ioparam->{'in_out'} and $ioparam->{'in_out'} =~ /OUT$/ and not $ioparam->{'in_output'} or $ioparam->{'var'} eq "RETVAL" and $ioparam->{'in_output'} || $xbody->{'seen_autocall'} && $xsub->{'decl'}{'return_type'}{'type'} ne 'void' && !$xsub->{'decl'}{'return_type'}{'no_output'} or $ioparam->{'in_output'} and $ioparam->{'var'} ne "RETVAL"
4605 44 313 17 $retval and $retval->{'in_output'} or $xbody->{'seen_autocall'} and $xsub->{'decl'}{'return_type'}{'type'} ne "void" and not $xsub->{'decl'}{'return_type'}{'no_output'}
4914 9 0 244 $xsub->{'seen_INTERFACE'} or $xsub->{'seen_INTERFACE_MACRO'}
5032 0 0 1 $f =~ /^\s*\|/ or $f =~ /\|\s*$/
5066 1 0 1 $is_cmd || $pxs->{'in_filename'} =~ /\|\s*$/
6351 5 3 128 $ioparam->{'in_input'} or not $ioparam->{'is_synthetic'} and defined $ioparam->{'type'}
6561 2 3 65 not $ioparam or $outarg ne "RETVAL" and not $ioparam->{'arg_num'}