| line | % | coverage | branch |
| 1342 | 50 | T | F | unless exists $params->{'input_file'} |
| 1358 | 100 | T | F | unless (-f $self->{'input_file'}) |
| 1447 | 50 | T | F | unless my $document = "PPI::Document"->new($self->{'input_file'}) |
| 1469 | 100 | T | F | unless $params->{'no_write'} |
| 1500 | 100 | T | F | unless (defined $document) |
| 1504 | 100 | T | F | if (@$pkgs == 0) |
| 1506 | 50 | T | F | $package_stmt ? : |
| 1508 | 50 | T | F | if @$pkgs > 1 |
| 1552 | 50 | T | F | unless defined $name |
| 1553 | 100 | T | F | if $name =~ /^(BEGIN|END|DESTROY|AUTOLOAD|CHECK|INIT|UNITCHECK)$/ |
| 1556 | 100 | T | F | if ($name =~ /^_/ and not $name =~ /^_(new|init|build)/) |
| 1557 | 100 | T | F | unless $self->{'include_private'} |
| 1574 | 100 | T | F | if ($content =~ /\bclass\b/) |
| 1582 | 50 | T | F | if ($content =~ /^\s*(before|after|around)\s+['"]?(\w+)['"]?\b/) |
| 1592 | 0 | T | F | if ($next_sib and $next_sib->isa("PPI::Statement::Sub")) |
| 1612 | 100 | T | F | if ($seen{$n}++) { } |
| 1666 | 50 | T | F | unless defined $extracted |
| 1680 | 50 | T | F | if ($method_name =~ /^_/ and not $method_name =~ /^_(new|init|build)/) |
| 1681 | 0 | T | F | unless $self->{'include_private'} |
| 1746 | 100 | T | F | if ($current->isa('PPI::Token::Pod')) { } |
| 100 | T | F | elsif ($current->isa('PPI::Token::Comment')) { } |
| 100 | T | F | elsif ($current->isa('PPI::Token::Whitespace') or $current->isa('PPI::Token::Separator')) { } |
| 100 | T | F | elsif ($current->isa('PPI::Statement::Include')) { } |
| 1752 | 50 | T | F | if ($comment =~ /#\s*(?:param|arg|input)\s+\$(\w+)\s*:\s*(.+)/i) |
| 1818 | 50 | T | F | if ($method->{'fields'} and keys %{$$method{"fields"};}) |
| 1841 | 100 | T | F | if ($self->{'strict_pod'} and $pod) |
| 1852 | 100 | T | F | if (@validation_errors) |
| 1860 | 100 | T | F | if ($self->{'strict_pod'} == 2) { } |
| 1873 | 100 | T | F | if ($validator_params) { } |
| 1882 | 100 | T | F | if (keys %$fields) |
| 1910 | 100 | T | F | if ($method->{'name'} ne "new" and $needs_object) |
| 1917 | 50 | T | F | unless (ref $input_confidence) |
| 1938 | 50 | T | F | if ($input_confidence->{'per_parameter'}) |
| 1957 | 100 | T | F | $level_rank{$input_level} < $level_rank{$output_level} ? : |
| 1963 | 100 | T | F | if ($relationships and @{$relationships;}) |
| 1969 | 100 | T | F | if keys %$attributes |
| 1970 | 100 | T | F | if keys %$postfix_derefs |
| 1971 | 100 | T | F | if keys %$fields |
| 1974 | 100 | T | F | if ($method->{'class'}) |
| 1984 | 50 | T | F | defined $_ ? : |
| 1992 | 100 | T | F | if ($self->_method_has_numeric_intent($schema)) |
| 1998 | 0 | T | F | defined $_ ? : |
| 2002 | 100 | T | F | defined $v ? : |
| 2003 | 50 | T | F | unless $seen{$key}++ |
| 2009 | 50 | T | F | if (keys %$hints) |
| 2013 | 100 | T | F | unless exists $schema->{'_yamltest_hints'}{$k} |
| 2017 | 100 | T | F | if ($level_rank{$overall} < $level_rank{$LEVEL_MEDIUM} and $level_rank{$overall} < $self->{'confidence_threshold'} * 4) |
| 2035 | 50 | T | F | if ($schema->{'output'}) |
| 2104 | 100 | T | F | if $schema->{'output'} and $schema->{'output'}{'type'} and $schema->{'output'}{'type'} =~ /^(number|integer)$/ |
| 2107 | 100 | T | F | unless $schema->{'input'} |
| 2108 | 100 | T | F | if $p->{'optional'} |
| 2109 | 100 | T | F | if $p->{'type'} and $p->{'type'} =~ /^(number|integer)$/ |
| 2180 | 100 | T | F | if (keys %fields_seen > 1) |
| 2188 | 50 | T | F | if ($code =~ /\$self\s*->\s*\{\s*['"]?([^}'"]+)['"]?\s*\}\s*=\s*shift\s*;/ and $code =~ /return\s+\$self\s*->\s*\{\s*['"]?\Q$1\E['"]?\s*\}\s*;/ and $code =~ /if\s*\(\s*\@_/) { } |
| 100 | T | F | elsif ($code =~ /if\s*\(\s*(?:\@_|[\$]\w+)/ and $code =~ /\$self\s*->\s*\{\s*['"]?([^}'"]+)['"]?\s*\}\s*=\s*(?:shift|\@_|\$_\[\d+\]|\$\w+)\b/x and $code =~ /return\b/) { } |
| 100 | T | F | elsif ($code =~ /return\s+\$self\s*->\s*\{\s*['"]?([^}'"]+)['"]?\s*\}\s*;/) { } |
| 100 | T | F | elsif ($code =~ /return\s+\$self\b/ and $code =~ /\$self\s*->\s*\{\s*['"]?([^}'"]+)['"]?\s*\}\s*=\s*\$(\w+)\s*;/) { } |
| 2196 | 0 | T | F | unless (defined $property) |
| 2197 | 0 | T | F | if ($code =~ /\$self\s*->\s*\{\s*['"]?([^}'"]+)['"]?\s*\}\s*=\s*shift\s*;/) |
| 2217 | 0 | T | F | if (my $pod = $method->{'pod'}) |
| 2218 | 0 | T | F | if ($pod =~ /\b(LWP::UserAgent(::\w+)*)\b/) |
| 2245 | 50 | T | F | unless (defined $property) |
| 2246 | 50 | T | F | if ($code =~ /\$self\s*->\s*\{\s*['"]?([^}'"]+)['"]?\s*\}\s*=/) |
| 2250 | 100 | T | F | if ($code =~ /validate_strict/) { } |
| 2256 | 50 | T | F | if ($code =~ /blessed\s*\(\s*\$(\w+)\s*\)/) { } |
| 2285 | 100 | T | F | if (my $pod = $method->{'pod'}) |
| 2286 | 50 | T | F | if ($pod =~ /\b(LWP::UserAgent(::\w+)*)\b/) |
| 2304 | 50 | T | F | if (ref $schema->{'input'} eq "HASH") |
| 2305 | 50 | T | F | if (scalar keys %{$$schema{"input"};} > 1) |
| 2323 | 100 | T | F | unless ($code =~ /\$self\s*->\s*\{\s*['"]?\Q$property\E['"]?\s*\}\s*=\s*(?:shift|\$\w+\s*=\s*shift|\@_|\$_\[\d+\])/) |
| 2327 | 100 | T | F | if (scalar @returns == scalar @self_returns) |
| 2369 | 100 | T | F | if ($schema->{'output'}{'_returns_self'}) { } |
| 50 | T | F | elsif (scalar keys %{$$schema{'output'};} != 0) { } |
| 2370 | 50 | T | F | if ($schema->{'output'}{'type'} ne "object") |
| 2373 | 50 | T | F | if ($schema->{'output'}{'isa'} ne $self->{'_package_name'}) |
| 2384 | 100 | T | F | if (exists $schema->{'accessor'}) |
| 2385 | 50 | T | F | if ($schema->{'accessor'}{'type'} and $schema->{'accessor'}{'type'} =~ /setter|getset/ and $schema->{'input'}) |
| 2389 | 100 | T | F | if ($in->{'type'} and $in->{'type'} eq "object") |
| 2392 | 50 | T | F | $in->{'isa'} ? : |
| 2403 | 100 | T | F | if ($schema->{'accessor'}{'type'} and $schema->{'accessor'}{'property'} and $schema->{'accessor'}{'type'} =~ /getter|getset/ and !defined($schema->{'output'}{'type'}) || $schema->{'output'}{'type'} eq 'string') |
| 2405 | 100 | T | F | if (my $pod = $method->{'pod'}) |
| 2407 | 100 | T | F | if ($pod =~ /\bUser[- ]?Agent\b.*\bobject\b/i) |
| 2482 | 50 | T | F | unless $res->{'input'} |
| 50 | T | F | if $res and ref $res eq "HASH" and keys %{{} unless $res->{'input'};} |
| 2516 | 50 | T | F | if ($child->isa("PPI::Statement") or $child->isa("PPI::Statement::Expression")) |
| 2525 | 0 | T | F | if ($tokens[$i]->isa('PPI::Token::Word') || $tokens[$i]->isa('PPI::Token::Quote') and $tokens[$i + 1]->isa("PPI::Structure::Constructor")) |
| 2534 | 0 | T | F | unless $key and $val |
| 2538 | 0 | T | F | unless $inner->isa("PPI::Statement") or $inner->isa("PPI::Statement::Expression") |
| 2545 | 0 | T | F | unless $k and $v |
| 2548 | 0 | T | F | $v->can('content') ? : |
| 2549 | 0 | T | F | if defined $value |
| 2551 | 0 | T | F | if ($keyname eq 'type') { } |
| 0 | T | F | elsif ($keyname eq 'optional') { } |
| 0 | T | F | elsif ($keyname =~ /^(min|max)$/ and &looks_like_number($value)) { } |
| 0 | T | F | elsif ($keyname eq 'matches') { } |
| 2554 | 0 | T | F | $value ? : |
| 2604 | 100 | T | F | if ref $code and $code->can("find") |
| 2630 | 100 | T | F | unless $code =~ /\bvalidate_strict\s*\(/ |
| 2632 | 50 | T | F | unless my $doc = $self->_ppi($code) |
| 2635 | 100 | T | F | if $_[1]->isa("PPI::Token::Word") |
| 2636 | 50 | T | F | unless my $calls = $doc->find(sub {
$_[1]->content eq "validate_strict" or $_[1]->content eq "Params::Validate::Strict::validate_strict" if $_[1]->isa("PPI::Token::Word");
}
) |
| 2643 | 50 | T | F | unless (defined $list) |
| 2645 | 50 | T | F | unless defined $next |
| 2646 | 100 | T | F | if ($next->content =~ /schema\s*=>\s*(\{(?:[^{}]|\{(?:[^{}]|\{[^{}]*\})*\})*\})/s) |
| 2653 | 50 | T | F | if (scalar keys %{$schema;}) |
| 2662 | 50 | T | F | unless $list |
| 2666 | 0 | T | F | unless $schema_block |
| 2669 | 0 | T | F | if $schema |
| 2694 | 100 | T | F | unless $code =~ /\bvalidate\s*\(/ |
| 2696 | 50 | T | F | unless my $doc = $self->_ppi($code) |
| 2699 | 100 | T | F | if $_[1]->isa("PPI::Token::Word") |
| 2700 | 50 | T | F | unless my $calls = $doc->find(sub {
$_[1]->content eq "validate" or $_[1]->content eq "Params::Validate::validate" if $_[1]->isa("PPI::Token::Word");
}
) |
| 2707 | 50 | T | F | unless (defined $list) |
| 2711 | 50 | T | F | if ($schema_text) |
| 2718 | 100 | T | F | if (scalar keys %{$schema;}) |
| 2721 | 50 | T | F | if (my $type = $field->{'type'}) |
| 2722 | 100 | T | F | if ($type eq 'ARRAYREF') { } |
| 50 | T | F | elsif ($type eq 'SCALAR') { } |
| 2739 | 50 | T | F | unless $list |
| 2743 | 0 | T | F | unless $schema_block |
| 2746 | 0 | T | F | if $schema |
| 2787 | 100 | T | F | if (substr($rest, 0, 1) eq "{") |
| 2791 | 50 | T | F | unless defined $extracted |
| 2795 | 100 | T | F | if (substr($rest, 0, 1) eq ",") |
| 2803 | 100 | T | F | unless $found_comma |
| 2836 | 100 | T | F | unless $code =~ /\bvalidated_hash\s*\(/ |
| 2838 | 50 | T | F | unless my $doc = $self->_ppi($code) |
| 2841 | 100 | T | F | if $_[1]->isa("PPI::Token::Word") |
| 2842 | 50 | T | F | unless my $calls = $doc->find(sub {
$_[1]->content eq "validated_hash" if $_[1]->isa("PPI::Token::Word");
}
) |
| 2849 | 50 | T | F | unless (defined $list) |
| 2853 | 50 | T | F | if ($schema_text) |
| 2861 | 50 | T | F | if (scalar keys %{$schema;}) |
| 2864 | 50 | T | F | if (my $isa = delete $field->{'isa'}) |
| 2867 | 100 | T | F | if (exists $field->{'required'}) { } |
| 2869 | 100 | T | F | $required ? : |
| 2873 | 100 | T | F | if (ref $field->{'default'} eq "CODE") |
| 2880 | 50 | T | F | if (my $type = $field->{'type'}) |
| 2881 | 50 | T | F | if ($type eq 'ARRAYREF') { } |
| 50 | T | F | elsif ($type eq 'SCALAR') { } |
| 2898 | 0 | T | F | unless $list |
| 2902 | 0 | T | F | unless $schema_block |
| 2905 | 0 | T | F | if $schema |
| 2934 | 50 | T | F | unless $block and $block->can("children") |
| 2938 | 0 | T | F | unless $result and ref $result eq "HASH" and $result->{'input'} |
| 2975 | 100 | T | F | exists $spec->{'optional'} ? : |
| 3010 | 100 | T | F | unless my $function = $self->_extract_function_name($code) |
| 3012 | 100 | T | F | unless my $doc = $self->{'_document'} |
| 3013 | 100 | T | F | unless my $stmt = $self->_find_signature_statement($doc, $function) |
| 3015 | 50 | T | F | unless my $signature_expr = $self->_extract_signature_expression($stmt, $function) |
| 3017 | 100 | T | F | unless my $meta = $self->_compile_signature_isolated($function, $signature_expr) |
| 3039 | 100 | T | F | if $code =~ /^\s*sub\s+([a-zA-Z0-9_]+)/ |
| 3063 | 100 | T | F | if $_[1]->isa("PPI::Statement") |
| 3065 | 100 | T | F | unless my $statements = $doc->find(sub {
$_[1]->content =~ /^\s*signature_for\b/ if $_[1]->isa("PPI::Statement");
}
) |
| 3069 | 50 | T | F | if ($content =~ /^\s*signature_for\s+\Q$function\E\b/) |
| 3099 | 100 | T | F | if ($content =~ /^\s*signature_for\s+\Q$function\E\s*=>\s*(.+?);?\s*$/s) |
| 3166 | 50 | T | F | unless ($self->{'allow_signature_exec'}) |
| 3170 | 50 | T | F | if $self->{'verbose'} |
| 3183 | 0 | T | F | if ($signature_expr =~ /\b(?:system|exec|open|fork|require|do|eval|qx)\b/) |
| 3187 | 0 | T | F | if ($signature_expr =~ /[`{};]/) |
| 3284 | 0 | T | F | if ($stderr and length $stderr) |
| 3333 | 50 | T | F | unless $meta->{'parameters'} |
| 3336 | 100 | T | F | unless (exists $type_map{$p->{'type'}}) |
| 3344 | 100 | T | F | $p->{'optional'} ? : |
| 3352 | 100 | T | F | if (my $ret = $meta->{'returns'}) |
| 3355 | 50 | T | F | unless (exists $type_map{$ret->{'type'}}) |
| 3412 | 100 | T | F | unless $pod |
| 3419 | 100 | T | F | if ($pod =~ /=head2\s+\w+\s*\(([^)]+)\)/s) |
| 3425 | 50 | T | F | if @sig_params and $sig_params[0] =~ /^(self|class)$/i |
| 3440 | 100 | T | F | if ($pod =~ /(?:Parameters?|Arguments?|Inputs?):?\s*\n((?:\s*\$.*\n)+)/is) { } |
| 100 | T | F | elsif ($pod =~ /^=head\d+\s+(?:Parameters?|Arguments?|Inputs?)\b.*?\n(.*?)(?=^=head|\Z)/ism) { } |
| 3445 | 100 | T | F | if ($param_section) |
| 3451 | 50 | T | F | if ($line =~ /C<\$(\w+)>\s*\((Required|Mandatory)\)/i) |
| 3459 | 100 | T | F | if ($line =~ /^\s*\$(\w+)\s*-\s*(\w+)(?:\s*\(([^)]+)\))?\s*,?\s*(.*)$/i or $line =~ /^\s*C<\$(\w+)>\s*-\s*(\w+)(?:\s*\(([^)]+)\))?\s*,?\s*(.*)$/i) |
| 3464 | 100 | T | F | if $desc |
| 3467 | 100 | T | F | if $name =~ /^(self|class|return|returns?)$/i |
| 3472 | 100 | T | F | unless (exists $params{$name}{'position'}) |
| 3478 | 50 | T | F | if $type eq "int" |
| 3479 | 50 | T | F | if $type eq "num" or $type eq "float" |
| 3480 | 50 | T | F | if $type eq "bool" |
| 3481 | 50 | T | F | if $type eq "array" |
| 3482 | 50 | T | F | if $type eq "hash" |
| 3487 | 100 | T | F | if ($constraint) |
| 3494 | 100 | T | F | if ($full_text =~ /\boptional\b/i) { } |
| 100 | T | F | elsif ($full_text =~ /required|mandatory/i) { } |
| 3503 | 100 | T | F | if ($desc =~ /\b(email|url|uri|path|filename)\b/i) |
| 3510 | 100 | T | F | if ($desc and $desc =~ m[matches?\s+(/[^/]+/|qr/.+?/)]i) |
| 3514 | 100 | T | F | $constraint ? : |
| 100 | T | F | $desc ? : |
| 3526 | 100 | T | F | if exists $params{$name} |
| 3529 | 50 | T | F | if $desc |
| 3532 | 100 | T | F | if $name =~ /^(self|class|return|returns?)$/i |
| 3537 | 50 | T | F | if $type eq "int" |
| 3538 | 50 | T | F | if $type eq "num" or $type eq "float" |
| 3539 | 50 | T | F | if $type eq "bool" |
| 3540 | 50 | T | F | if $type eq "array" |
| 3541 | 50 | T | F | if $type eq "hash" |
| 3546 | 50 | T | F | if ($constraint) |
| 3552 | 50 | T | F | if ($desc) |
| 3553 | 50 | T | F | if ($desc =~ /\boptional\b/i) { } |
| 50 | T | F | elsif ($desc =~ /required|mandatory/i) { } |
| 3560 | 50 | T | F | if ($desc =~ m[matches?\s+(/[^/]+/|qr/.+?/)]i) |
| 3565 | 50 | T | F | $constraint ? : |
| 3575 | 50 | T | F | unless defined $name and length $name |
| 3580 | 50 | T | F | if $name =~ /^(self|class|return|returns?)$/i |
| 3586 | 50 | T | F | if ($desc =~ /^\s*(string|integer|int|number|num|float|boolean|bool|array|arrayref|hash|hashref|any)\b(?:\s*\(([^)]+)\))?/i) { } |
| 3591 | 0 | T | F | if $type eq "int" |
| 3592 | 0 | T | F | if $type eq "num" or $type eq "float" |
| 3593 | 0 | T | F | if $type eq "bool" |
| 3594 | 0 | T | F | if $type eq "array" |
| 3595 | 0 | T | F | if $type eq "hash" |
| 3599 | 0 | T | F | if ($constraint) |
| 3606 | 50 | T | F | if ($desc =~ /\bstring\b/i) { } |
| 50 | T | F | elsif ($desc =~ /\b(int|integer)\b/i) { } |
| 50 | T | F | elsif ($desc =~ /\b(num|number|float)\b/i) { } |
| 50 | T | F | elsif ($desc =~ /\b(bool|boolean)\b/i) { } |
| 3619 | 50 | T | F | if ($desc =~ /\boptional\b/i) { } |
| 100 | T | F | elsif ($desc =~ /required|mandatory/i) { } |
| 3626 | 50 | T | F | if ($desc =~ m[matches?\s+(/[^/]+/|qr/.+?/)]i) |
| 3636 | 50 | T | F | if (exists $params{$param}) |
| 3638 | 100 | T | F | unless defined $params{$param}{'optional'} |
| 3641 | 100 | T | F | defined $pod_defaults->{$param} ? : |
| 3648 | 50 | T | F | if $name =~ /^(self|class)$/i |
| 3662 | 100 | T | F | if ($pod =~ /=head[34]\s+Input\b(.*?)(?==head|\z)/is) |
| 3666 | 100 | T | F | if ($block =~ /\A\[/) { } |
| 100 | T | F | elsif ($block =~ /\A\{/) { } |
| 3673 | 100 | T | F | if (defined $name) |
| 3675 | 50 | T | F | if (my $t = $self->_map_formal_input_type($spec)) |
| 3679 | 50 | T | F | if ($spec =~ /\boptional\s*=>\s*(0|1)/i) |
| 3689 | 50 | T | F | if $name =~ /^(self|class)$/i |
| 3692 | 50 | T | F | if (my $t = $self->_map_formal_input_type($spec)) |
| 3696 | 100 | T | F | if ($spec =~ /\boptional\s*=>\s*(0|1)/i) |
| 3729 | 100 | T | F | unless $spec =~ /\btype\s*=>\s*['"]([^'"]+)['"]/i |
| 3756 | 100 | T | F | if exists $map{$t} |
| 3800 | 100 | T | F | if keys %output |
| 3803 | 100 | T | F | keys %output ? : |
| 3834 | 100 | T | F | if ($pod) |
| 3840 | 100 | T | F | if ($pod =~ /=head4\s+Output\b(.*?)(?==head|\z)/is) |
| 3843 | 100 | T | F | if ($block =~ /^\(/) { } |
| 50 | T | F | elsif ($block =~ /^\[/) { } |
| 50 | T | F | elsif ($block =~ /^\{/) { } |
| 3847 | 0 | T | F | unless ($block =~ /^\[\s*\]/) |
| 3852 | 50 | T | F | if ($block =~ /type\s*=>\s*['"]?(\w[\w:]*?)['"]?\s*[,}]/i) { } |
| 0 | T | F | elsif ($block =~ /\bisa\s*=>/) { } |
| 3854 | 50 | T | F | if $type eq "hash" |
| 3855 | 50 | T | F | if $type eq "array" |
| 3856 | 50 | T | F | if ($VALID_OUTPUT_TYPES{$type}) { } |
| 0 | T | F | elsif ($block =~ /\bisa\s*=>/) { } |
| 3872 | 100 | T | F | if ($pod =~ /Returns?:\s+([^\n]+(?:\n[^\n]+){0,2})/is) |
| 3879 | 100 | T | F | if (not $output->{'type'} and $returns_desc =~ /\b(string|text)\b/i) { } |
| 100 | T | F | elsif (not $output->{'type'} and $returns_desc =~ /\b(integer|int|count)\b/i) { } |
| 50 | T | F | elsif (not $output->{'type'} and $returns_desc =~ /\b(float|decimal|number)\b/i) { } |
| 100 | T | F | elsif (not $output->{'type'} and $returns_desc =~ /\b(boolean|true|false)\b/i) { } |
| 50 | T | F | elsif (not $output->{'type'} and $returns_desc =~ /\b(array|list)\b/i) { } |
| 50 | T | F | elsif (not $output->{'type'} and $returns_desc =~ /\b(hash|hashref|dictionary)\b/i) { } |
| 100 | T | F | elsif (not $output->{'type'} and $returns_desc =~ /\b(object|instance)\b/i) { } |
| 50 | T | F | elsif (not $output->{'type'} and $returns_desc =~ /\bundef\b/i) { } |
| 3898 | 100 | T | F | if ($returns_desc =~ /\b1\s+(?:on\s+success|if\s+successful)\b/i) { } |
| 50 | T | F | elsif ($returns_desc =~ /\b0\s+(?:on\s+failure|if\s+fail)\b/i) { } |
| 50 | T | F | elsif ($returns_desc =~ /dies\s+on\s+(?:error|failure)/i) { } |
| 3900 | 50 | T | F | if (defined $output->{'type'} and $output->{'type'} eq 'scalar') { } |
| 3912 | 100 | T | F | if ($returns_desc =~ /\b(true|false)\b/i) |
| 3915 | 50 | T | F | if ($returns_desc =~ /\bundef\b/i) |
| 3921 | 100 | T | F | if (not $output->{'type'} and $pod =~ /returns?\s+(?:an?\s+)?(\w+)/i) |
| 3924 | 100 | T | F | if $type =~ /^(true|false|bool)$/ |
| 3926 | 50 | T | F | if $type eq "int" |
| 3927 | 50 | T | F | if $type =~ /^(num|float)$/ |
| 3928 | 50 | T | F | if $type eq "array" |
| 3929 | 50 | T | F | if $type eq "hash" |
| 3931 | 50 | T | F | if ($type =~ /^\d+$/) |
| 3932 | 0 | T | F | if ($type eq '1' or $type eq '0') { } |
| 3934 | 0 | T | F | if ($pod =~ /1 on success.+0 (on|if) /i) { } |
| 0 | T | F | elsif ($pod =~ /return 0 .+ 1 on success/) { } |
| 3946 | 50 | T | F | if not $type and $pod =~ /returns?\s+.+\slist\b/i |
| 3948 | 100 | T | F | if ($VALID_OUTPUT_TYPES{$type}) { } |
| 3986 | 100 | T | F | unless $pod |
| 3999 | 50 | T | F | if @param_matches |
| 4001 | 50 | T | F | if ($param) |
| 4003 | 50 | T | F | if ($default_text =~ /(\w+)\s*=\s*(.+)$/) { } |
| 4023 | 50 | T | F | if (@param_matches) |
| 4061 | 50 | T | F | if ($code) |
| 4064 | 100 | T | F | if (@all_returns) |
| 4071 | 100 | T | F | if $ret =~ /^(?:0|1)(?:\s|$)/ |
| 4075 | 100 | T | F | if ($boolean_count >= 2 and $boolean_count >= $total_count * "0.8") |
| 4076 | 50 | T | F | unless ($output->{'type'}) |
| 4085 | 100 | T | F | if ($code =~ /return\s+bless\s*\{[^}]*\}\s*,\s*['"]?(\w+)['"]?/s) { } |
| 100 | T | F | elsif ($code =~ /return\s+bless/s) { } |
| 100 | T | F | elsif ($code =~ /return\s*\(\s*[^)]+\s*,\s*[^)]+\s*\)\s*;/) { } |
| 50 | T | F | elsif ($code =~ /return\s+bless[^,]+,\s*__PACKAGE__/) { } |
| 100 | T | F | elsif ($code =~ /return\s*\(([^)]+)\)/) { } |
| 100 | T | F | elsif ($code =~ /return\s+\$self\s*;/ and $code =~ /\$self\s*->\s*\{[^}]+\}\s*=/) { } |
| 4088 | 50 | T | F | if ($method_name eq 'new') { } |
| 4090 | 0 | T | F | if ($self->{'_document'} and my $package_stmt = $self->{'_document'}->find_first("PPI::Statement::Package")) |
| 4100 | 100 | T | F | if ($method_name eq 'new') { } |
| 4114 | 0 | T | F | if ($self->{'_document'}) |
| 4116 | 0 | T | F | $pkg ? : |
| 4122 | 50 | T | F | if ($content =~ /,/) |
| 4128 | 50 | T | F | if ($self->{'_document'}) |
| 4130 | 50 | T | F | $pkg ? : |
| 4142 | 100 | T | F | if (@return_statements) { } |
| 4148 | 100 | T | F | if ($output->{'type'}) |
| 4156 | 100 | T | F | if ($ret eq '1' or $ret eq '0') { } |
| 100 | T | F | elsif ($ret =~ /^['"]/) { } |
| 100 | T | F | elsif ($ret =~ /^-?\d+$/) { } |
| 50 | T | F | elsif ($ret =~ /^-?\d+\.\d+$/) { } |
| 100 | T | F | elsif ($ret eq 'undef') { } |
| 50 | T | F | elsif ($ret =~ /^\[/) { } |
| 100 | T | F | elsif ($ret =~ /^\{/) { } |
| 100 | T | F | elsif ($ret =~ m[
# Numeric expressions (heuristic, medium confidence)
# Don't match ->
(?:
\+ | -\b | \* | / | %
| \+\+ | --
)
]x) { } |
| 50 | T | F | elsif ($ret =~ /\|\|\s*\d+\b/) { } |
| 50 | T | F | elsif ($ret =~ /^length[\s\(]/) { } |
| 50 | T | F | elsif ($ret =~ /^pos[\s\(]/) { } |
| 50 | T | F | elsif ($ret =~ /^index[\s\(]/) { } |
| 50 | T | F | elsif ($ret =~ /^rindex[\s\(]/) { } |
| 50 | T | F | elsif ($ret =~ /^ord[\s\(]/) { } |
| 100 | T | F | elsif ($ret =~ /=/ and $ret =~ /\$\w+/) { } |
| 100 | T | F | elsif ($ret =~ /\$\w+/) { } |
| 4201 | 50 | T | F | if ($ret =~ /\b\d+\b/) { } |
| 4210 | 50 | T | F | if ($ret =~ /\\\@/) { } |
| 50 | T | F | elsif ($ret =~ /\\\%/) { } |
| 100 | T | F | elsif ($ret =~ /bless/) { } |
| 50 | T | F | elsif ($ret =~ /^\{[^}]*\}$/) { } |
| 50 | T | F | elsif ($ret =~ /^\[[^\]]*\]$/) { } |
| 4227 | 100 | T | F | if (keys %return_types) |
| 4230 | 100 | T | F | if ($return_types{'integer'} and not $return_types{'string'}) |
| 4231 | 50 | T | F | if (not $output->{'type'} or $output->{'type'} eq "scalar") |
| 4235 | 50 | T | F | if (defined $min) |
| 4240 | 100 | T | F | unless ($output->{'type'}) |
| 4244 | 100 | T | F | if ($most_common eq "number") |
| 4246 | 50 | T | F | if (defined $min) |
| 4256 | 100 | T | F | if (@return_statements == 1 and $return_statements[0] eq 1) |
| 4258 | 50 | T | F | if not $output->{'type'} or $output->{'type'} eq "scalar" |
| 4259 | 50 | T | F | if $output->{'type'} |
| 4300 | 100 | T | F | unless not $output->{'type'} or $output->{'type'} eq "unknown" |
| 4303 | 100 | T | F | if ($pod and not $output->{'type'}) |
| 4305 | 50 | T | F | if ($pod =~ /returns?\s+(true|false|true|false|1|0)\s+(?:on|for|upon)\s+(success|failure|error|valid|invalid)/i) |
| 4311 | 50 | T | F | if ($pod =~ /(?:method|sub)\s+(\w+)/) |
| 4313 | 0 | T | F | if ($inferred_method_name =~ /^(is_|has_|can_|should_|contains_|exists_)/) |
| 4321 | 50 | T | F | if ($code) |
| 4326 | 50 | T | F | if ($true_returns + $false_returns >= 2) { } |
| 100 | T | F | elsif ($true_returns + $false_returns == 1) { } |
| 4335 | 50 | T | F | if ($code =~ /return\s+(?:\w+\s*[!=]=\s*\w+|\w+\s*>\s*\w+|\w+\s*<\s*\w+)\s*\?\s*(?:1|0)\s*:\s*(?:1|0)/) |
| 4341 | 50 | T | F | if ($code =~ /return\s+[!\$\@\%]/) |
| 4349 | 50 | T | F | if ($method_name) |
| 4350 | 100 | T | F | if ($method_name =~ /^(is_|has_|can_|should_|contains_|exists_|check_|verify_|validate_)/) |
| 4354 | 50 | T | F | if ($method_name =~ /_ok$/) |
| 4362 | 100 | T | F | if ($boolean_score >= $BOOLEAN_SCORE_THRESHOLD) |
| 4363 | 50 | T | F | if (not $output->{'type'} or $output->{'type'} eq "scalar" or $output->{'type'} eq "array" or $output->{'type'} eq "undef") |
| 4393 | 50 | T | F | unless $code |
| 4396 | 100 | T | F | if ($code =~ /wantarray/) |
| 4401 | 100 | T | F | if ($code =~ /(wantarray[^;]+;)/s) |
| 4405 | 100 | T | F | if ($code =~ /wantarray\s*\?\s*\(([^)]+)\)\s*:\s*([^;]+)/s) { } |
| 100 | T | F | elsif ($code =~ /wantarray\s*\?\s*([^:]+?)\s*:\s*([^;]+)/s) { } |
| 50 | T | F | elsif ($code =~ /return[^;]*unless\s+wantarray.*?return\s*\(([^)]+)\)/s) { } |
| 4434 | 100 | T | F | if ($code =~ /return\s*\(\s*([^)]+)\s*\)\s*;/) |
| 4443 | 100 | T | F | if (substr($rest, 0, 1) =~ /[(\[{]/) |
| 4445 | 50 | T | F | unless defined $extracted |
| 4448 | 100 | T | F | if substr($rest, 0, 1) eq "," |
| 4452 | 100 | T | F | if ($comma_count > 0 and not $content =~ /\b(?:bless|new)\b/) |
| 4454 | 50 | T | F | unless ($output->{'type'} and $output->{'type'} eq "boolean") |
| 4487 | 50 | T | F | unless $code |
| 4501 | 100 | T | F | if ($method_name =~ /$void_patterns->{$type}/) |
| 4521 | 100 | T | F | if $ret eq "" |
| 4522 | 100 | T | F | if $ret =~ /^(if|unless)\s/ |
| 4523 | 100 | T | F | if $ret eq 1 |
| 4524 | 100 | T | F | if $ret eq "\$self" |
| 4525 | 100 | T | F | if ($ret =~ /\?\s*1\s*:\s*0\b/) |
| 4538 | 100 | T | F | if ($no_value_returns > 0 and $no_value_returns == $total_returns) { } |
| 100 | T | F | elsif ($true_returns > 0 and $true_returns == $total_returns and $total_returns >= 1) { } |
| 4546 | 100 | T | F | unless ($output->{'type'} and $output->{'type'} eq "boolean") |
| 4576 | 50 | T | F | unless $code |
| 4586 | 100 | T | F | if $ret eq "\$self" |
| 4590 | 100 | T | F | if ($self_returns > 0 and $total_returns > 0) |
| 4593 | 100 | T | F | if ($ratio >= "0.8") |
| 4598 | 100 | T | F | if ($self->{'_document'}) |
| 4600 | 50 | T | F | $pkg ? : |
| 4634 | 50 | T | F | unless $code |
| 4653 | 100 | T | F | if ($code =~ /return\s*\(\s*\)\s*(?:if|unless|;)/) |
| 4663 | 100 | T | F | if ($1 eq '0') { } |
| 4670 | 100 | T | F | if ($zero_returns > 0 and $one_returns > 0) |
| 4676 | 100 | T | F | if ($code =~ /eval\s*\{/) |
| 4678 | 50 | T | F | if ($code =~ /eval\s*\{.*?\}[^}]*(?:if\s*\(\s*\$\@|catch|return\s+undef)/s) |
| 4689 | 50 | T | F | if ($has_undef and $has_value and scalar @all_returns >= 2) |
| 4695 | 100 | T | F | if (scalar keys %error_patterns) { } |
| 4699 | 100 | T | F | if ($error_patterns{'undef_on_error'}) { } |
| 100 | T | F | elsif ($error_patterns{'implicit_undef'}) { } |
| 100 | T | F | elsif ($error_patterns{'empty_list'}) { } |
| 100 | T | F | elsif ($error_patterns{'zero_on_error'}) { } |
| 4713 | 100 | T | F | if ($error_patterns{'exception_handling'}) |
| 4745 | 100 | T | F | unless defined $expr |
| 4750 | 100 | T | F | if ($expr =~ /,/) |
| 4755 | 100 | T | F | if (substr($rest, 0, 1) =~ /[(\[{]/) |
| 4757 | 50 | T | F | unless defined $extracted |
| 4760 | 100 | T | F | if substr($rest, 0, 1) eq "," |
| 4764 | 100 | T | F | if ($comma_count > 0) |
| 4770 | 100 | T | F | if ($expr =~ /^\@\w+/ or $expr =~ /^qw\(/ or $expr =~ /^\@\{/) |
| 4775 | 100 | T | F | if ($expr =~ /scalar\s*\(/) |
| 4780 | 100 | T | F | if ($expr =~ /^\[/ or $expr =~ /^\\\@/) |
| 4785 | 100 | T | F | if ($expr =~ /^\{/ or $expr =~ /^\\\%/) |
| 4790 | 50 | T | F | if ($expr =~ /^\%\w+/ or $expr =~ /^\%\{/) |
| 4795 | 100 | T | F | if ($expr =~ /^['"]/ or $expr =~ /['"]$/) |
| 4801 | 100 | T | F | if ($expr =~ /^[01]$/) |
| 4806 | 100 | T | F | if ($expr =~ /^-?\d+$/) |
| 4810 | 100 | T | F | if ($expr =~ /^-?\d+\.\d+$/) |
| 4815 | 50 | T | F | if ($expr =~ /bless/) |
| 4819 | 100 | T | F | if ($expr =~ /\blength\s*\(/) |
| 4847 | 100 | T | F | unless $pod |
| 4850 | 100 | T | F | if ($pod =~ /returns?\s+(?:\$)?self\b/i or $pod =~ /chainable/i or $pod =~ /fluent\s+interface/i or $pod =~ /method\s+chaining/i) |
| 4882 | 100 | T | F | if (defined $output->{'type'} and $output->{'type'} eq "boolean" and not defined $output->{'value'}) |
| 4885 | 50 | T | F | if ($output->{'value'} and defined $output->{'type'} and $output->{'type'} ne "boolean") |
| 4889 | 100 | T | F | if (exists $output->{'type'}) |
| 4890 | 100 | T | F | if (not $valid_types{$output->{'type'}}) |
| 4922 | 100 | T | F | if ($constraint =~ /(\d+)\s*-\s*(\d+)/) { } |
| 100 | T | F | elsif ($constraint =~ /(\d+)\s*\.\.\s*(\d+)/) { } |
| 100 | T | F | elsif ($constraint =~ /(?:min|minimum|at least)\s*(\d+)/i) { } |
| 100 | T | F | elsif ($constraint =~ /(?:max|maximum|up to)\s*(\d+)/i) { } |
| 100 | T | F | elsif ($constraint =~ /positive/i) { } |
| 100 | T | F | elsif ($constraint =~ /non-negative/i) { } |
| 50 | T | F | elsif ($constraint =~ /(.+)?\s(.+)/) { } |
| 4941 | 100 | T | F | if $param->{'type'} and $param->{'type'} eq "integer" |
| 4942 | 100 | T | F | if $param->{'type'} and $param->{'type'} eq "number" |
| 4949 | 0 | T | F | if (&looks_like_number($val)) |
| 4950 | 0 | T | F | if ($op eq '<') { } |
| 0 | T | F | elsif ($op eq '<=') { } |
| 0 | T | F | elsif ($op eq '>') { } |
| 0 | T | F | elsif ($op eq '>=') { } |
| 4962 | 100 | T | F | if (defined $param->{'max'}) |
| 4965 | 100 | T | F | if (defined $param->{'min'}) |
| 5013 | 100 | T | F | if ($code =~ /Params::Get/) |
| 5017 | 50 | T | F | if $name =~ /^(self|class)$/i |
| 5027 | 100 | T | F | if ($params{$param}{'_default'} and not $params{$param}{'type'}) |
| 5029 | 100 | T | F | if (ref $default eq 'HASH') { } |
| 100 | T | F | elsif (ref $default eq 'ARRAY') { } |
| 5039 | 50 | T | F | if ($code =~ /(croak|die)\(.*\)\s+if\s*\(\s*scalar\(\@_\)\s*<\s*(\d+)\s*\)/s) { } |
| 50 | T | F | elsif ($code =~ /(croak|die)\(.*\)\s+if\s*\(\s*scalar\(\@_\)\s*==\s*(0)\s*\)/s) { } |
| 5055 | 50 | T | F | if ($param_count++ > $self->{'max_parameters'}) |
| 5068 | 100 | T | F | if ($code =~ /defined\s*\(\s*\$$param\s*\)/) |
| 5074 | 100 | T | F | if ($code =~ m[\s*\$$param\s*(?://|\|\|)=]) { } |
| 100 | T | F | elsif ($code =~ m[\s*\$$param\s*(?:[\+\-\*\%]|/(?!/)|(?:\+\+)|(?:--)|(?:[\+\-\*\%]=|/(?!/)=)|\+\$|\$[+-])]) { } |
| 50 | T | F | elsif ($code =~ /\$\b$param\b\s*(?:\+0|\*1)/) { } |
| 5094 | 50 | T | F | if ($code =~ /if\s*\(\s*!\s*defined\s*\(\s*\$$param\s*\)\s*\)\s*\{([^}]+)\}/s) |
| 5096 | 0 | T | F | if ($block =~ /\b(croak|die|confess)\b/) |
| 5103 | 50 | T | F | if ($code =~ /\b(croak|die|confess)\b[^;]*\bunless\s+defined\s*\(\s*\$$param\s*\)/) |
| 5109 | 50 | T | F | if ($code =~ /exists\s*\(\s*\$$param\s*\)/) |
| 5115 | 50 | T | F | if ($code =~ /scalar\s*\(\s*\@?\$$param\s*\)/) |
| 5152 | 100 | T | F | if ($code =~ /ref\s*\(\s*\$$param\s*\)\s*eq\s*['"](ARRAY|HASH|SCALAR)['"]/gi) { } |
| 100 | T | F | elsif ($code =~ /\$$param\s*->\s*isa\s*\(\s*['"]([^'"]+)['"]\s*\)/i) { } |
| 50 | T | F | elsif ($code =~ /bless\s+.*\$$param/) { } |
| 5154 | 50 | T | F | $reftype eq 'hash' ? : |
| 100 | T | F | $reftype eq 'array' ? : |
| 5171 | 100 | T | F | unless ($p->{'type'}) |
| 5172 | 50 | T | F | if ($code =~ /\@\{\s*\$$param\s*\}/ or $code =~ /push\s*\(\s*\@?\$$param/) { } |
| 50 | T | F | elsif ($code =~ /\%\{\s*\$$param\s*\}/ or $code =~ /\$$param\s*->\s*\{/) { } |
| 5180 | 100 | T | F | if (not $p->{'type'} and exists $p->{'_default'}) |
| 5182 | 50 | T | F | if (ref $default eq 'HASH') { } |
| 50 | T | F | elsif (ref $default eq 'ARRAY') { } |
| 5194 | 100 | T | F | if (not $p->{'type'}) |
| 5201 | 100 | T | F | if ($code =~ /\blooks_like_number\s*\(\s*\$$param\s*\)/) { } |
| 100 | T | F | elsif ($code =~ m[\$$param\s*(?:[\+\-\*\%]|/(?!/))] or $code =~ m[(?:[\+\-\*\%]|/(?!/))\s*\$$param] or $code =~ /\bint\s*\(\s*\$$param\s*\)/ or $code =~ /\babs\s*\(\s*\$$param\s*\)/) { } |
| 100 | T | F | elsif ($code =~ /\$$param\s*(?:==|!=|<=|>=|<|>)/ or $code =~ /(?:==|!=|<=|>=|<|>)\s*\$$param/) { } |
| 5300 | 50 | T | F | unless defined $param and $param =~ /^\w+$/ |
| 5303 | 100 | T | F | if ($code =~ /\$$param\s*->\s*isa\s*\(\s*['"]DateTime['"]\s*\)/i) |
| 5312 | 100 | T | F | if ($code =~ /\$$param\s*->\s*(ymd|dmy|mdy|hms|iso8601|epoch|strftime)/) |
| 5321 | 50 | T | F | if ($code =~ /\$$param\s*->\s*isa\s*\(\s*['"]Time::Piece['"]\s*\)/i or $code =~ /\$$param\s*->\s*(strftime|epoch|year|mon|mday)/) |
| 5331 | 100 | T | F | if ($code =~ m[\$$param\s*=~\s*/.*?\\d\{4\}.*?\\d\{2\}.*?\\d\{2\}]) |
| 5340 | 100 | T | F | if ($code =~ m[\$$param\s*=~\s*/.*?[Tt].*?[Zz].*?/]) |
| 5349 | 50 | T | F | if ($code =~ /\$$param\s*>\s*\d{9,}/ or $code =~ /time\(\s*\)\s*-\s*\$$param/ or $code =~ /\$$param\s*-\s*time\(\s*\)/) |
| 5360 | 50 | T | F | if ($code =~ /strptime\s*\(\s*\$$param/ or $code =~ /DateTime::Format::\w+\s*->\s*parse_datetime\s*\(\s*\$$param/) |
| 5393 | 50 | T | F | unless defined $param and $param =~ /^\w+$/ |
| 5396 | 100 | T | F | if ($code =~ /(?:open|close|read|print|say|sysread|syswrite)\s*\(?\s*\$$param/) |
| 5405 | 100 | T | F | if ($code =~ /\$$param\s*->\s*(readline|getline|print|say|close|flush|autoflush)/) |
| 5414 | 100 | T | F | if ($code =~ /(?:-[frwxoOeszlpSbctugkTBMAC])\s+\$$param/) |
| 5422 | 50 | T | F | if ($code =~ /File::(?:Spec|Basename)::\w+\s*\(\s*\$$param/ or $code =~ /(?:basename|dirname|fileparse)\s*\(\s*\$$param/) |
| 5432 | 50 | T | F | if (defined $p->{'_default'} and $p->{'_default'} =~ m[^([A-Za-z]:\\|/|\./|\.\./)]) |
| 5440 | 50 | T | F | if ($code =~ /\$$param\s*->\s*isa\s*\(\s*['"]IO::File['"]\s*\)/ or $code =~ /IO::File\s*->\s*new\s*\(\s*\$$param/) |
| 5473 | 50 | T | F | unless defined $param and $param =~ /^\w+$/ |
| 5476 | 100 | T | F | if ($code =~ /ref\s*\(\s*\$$param\s*\)\s*eq\s*['"]CODE['"]/i) |
| 5484 | 50 | T | F | if ($code =~ /\$$param\s*->\s*\(/ or $code =~ /\$$param\s*->\s*\(\s*\@_\s*\)/ or $code =~ /&\s*\{\s*\$$param\s*\}/) |
| 5494 | 100 | T | F | if ($param =~ /^(?:callback|cb|handler|sub|code|fn|func|on_\w+)$/i) |
| 5502 | 50 | T | F | if ($code =~ /blessed\s*\(\s*\$$param\s*\)/ and $code =~ /ref\s*\(\s*\$$param\s*\)\s*eq\s*['"]CODE['"]/i) |
| 5541 | 50 | T | F | unless defined $param and $param =~ /^\w+$/ |
| 5545 | 100 | T | F | if ($code =~ m[unless\s+\$$param\s*=~\s*/\^?\(([^)]+)\)]) |
| 5548 | 50 | T | F | unless $p->{'type'} |
| 5558 | 100 | T | F | if ($code =~ /\%(\w+)\s*=.*?qw\s*[\(\[<{]([^)\]>}]+)[\)\]>}]/) |
| 5561 | 100 | T | F | if (defined $values_str and $code =~ /\$$hash_name\s*\{\s*\$$param\s*\}/) |
| 5563 | 50 | T | F | unless $p->{'type'} |
| 5573 | 100 | T | F | if ($code =~ /grep\s*\{[^}]*\$${param}[^}]*\}\s*qw\s*[\(\[<{]([^)\]>}]+)[\)\]>}]/) |
| 5576 | 50 | T | F | unless $p->{'type'} |
| 5584 | 50 | T | F | if ($code =~ /given\s*\(\s*\$$param\s*\)/) |
| 5589 | 0 | T | F | if (@enum_values >= 2) |
| 5590 | 0 | T | F | unless $p->{'type'} |
| 5607 | 100 | T | F | if (@if_values >= 3) |
| 5608 | 50 | T | F | unless $p->{'type'} |
| 5617 | 50 | T | F | if ($code =~ /\$$param\s*~~\s*\[([^\]]+)\]/ or $code =~ /\$$param\s*~~\s*qw\s*[\(\[<{]([^)\]>}]+)[\)\]>}]/) |
| 5621 | 0 | T | F | if ($values_str =~ /['"]/) { } |
| 5626 | 0 | T | F | if (@enum_values) |
| 5627 | 0 | T | F | unless $p->{'type'} |
| 5680 | 100 | T | F | unless $condition =~ /\$$param\b/ |
| 5697 | 100 | T | F | if ($condition =~ /\$$param\s*([!<>=]=?|eq|ne|lt|gt|le|ge)\s*(.+)/) { } |
| 100 | T | F | elsif ($condition =~ /length\s*\(\s*\$$param\s*\)\s*([<>=!]+)\s*(\d+)/) { } |
| 50 | T | F | elsif ($condition =~ /\$$param\s*==\s*0/) { } |
| 5708 | 100 | T | F | if $constraint |
| 5709 | 100 | T | F | if defined $message |
| 5711 | 100 | T | F | defined $message ? : |
| 5718 | 100 | T | F | if ($code =~ /\b\Q$param\E\s*(<=|<|>=|>)\s*(-?\d+)/) |
| 5724 | 100 | T | F | if ($op eq '<=') { } |
| 100 | T | F | elsif ($op eq '<') { } |
| 100 | T | F | elsif ($op eq '>=') { } |
| 50 | T | F | elsif ($op eq '>') { } |
| 5778 | 100 | T | F | if ($code =~ /sub\s+\w+\s*(?::\w+(?:\([^)]*\))?\s*)*\(((?:[^()]|\([^)]*\))*)\)\s*\{/s) |
| 5782 | 100 | T | F | if ($potential_sig =~ /[\$\%\@]/) |
| 5792 | 100 | T | F | if ($code =~ /my\s+\$(?:self|class)\s*=\s*\$_\[0\]/) |
| 5796 | 50 | T | F | if $name =~ /^(self|class)$/i |
| 5804 | 100 | T | F | if ($code =~ /my\s*\(\s*([^)]+)\)\s*=\s*\@_/s) { } |
| 100 | T | F | elsif ($code =~ /my\s+\$self\s*=\s*shift/) { } |
| 5811 | 100 | T | F | if $name =~ /^(self|class)$/i |
| 5818 | 50 | T | F | unless exists $params->{$name}{'position'} |
| 5829 | 50 | T | F | if @shifts and $shifts[0] =~ /^(self|class)$/i |
| 5838 | 50 | T | F | if ($code =~ /my\s*\(\s*([^)]+)\)\s*=\s*\@_/s) |
| 5843 | 0 | T | F | if $param =~ /^(self|class)$/i |
| 5851 | 0 | T | F | if ($seen{$param}++) |
| 5889 | 100 | T | F | if (substr($rest, 0, 1) =~ /[(\[{]/) |
| 5893 | 50 | T | F | unless defined $extracted |
| 5897 | 100 | T | F | if (substr($rest, 0, 1) eq ",") |
| 5906 | 50 | T | F | if $current =~ /\S/ |
| 5914 | 50 | T | F | unless $part |
| 5919 | 50 | T | F | if ($param_info) |
| 5923 | 100 | T | F | if ($name =~ /^(self|class)$/i) |
| 5930 | 100 | T | F | $param_info->{'optional'} ? : |
| 100 | T | F | $param_info->{'_default'} ? : |
| 5975 | 100 | T | F | if ($part =~ /^\$(\w+)\s*:\s*(\w+)\s*=\s*(.+)$/s) { } |
| 100 | T | F | elsif ($part =~ /^\$(\w+)\s*:\s*(\w+)\s*$/s) { } |
| 100 | T | F | elsif ($part =~ /^\$(\w+)\s*=\s*(.+)$/s) { } |
| 100 | T | F | elsif ($part =~ /^\$(\w+)$/s) { } |
| 100 | T | F | elsif ($part =~ /^\@(\w+)$/s) { } |
| 100 | T | F | elsif ($part =~ /^\%(\w+)$/s) { } |
| 5984 | 100 | T | F | if ($constraint =~ /^(Int|Integer)$/i) { } |
| 100 | T | F | elsif ($constraint =~ /^(Num|Number)$/i) { } |
| 50 | T | F | elsif ($constraint =~ /^(Str|String)$/i) { } |
| 0 | T | F | elsif ($constraint =~ /^(Bool|Boolean)$/i) { } |
| 0 | T | F | elsif ($constraint =~ /^(Array|ArrayRef)$/i) { } |
| 0 | T | F | elsif ($constraint =~ /^(Hash|HashRef)$/i) { } |
| 6009 | 100 | T | F | if ($constraint =~ /^(Int|Integer)$/i) { } |
| 100 | T | F | elsif ($constraint =~ /^(Num|Number)$/i) { } |
| 100 | T | F | elsif ($constraint =~ /^(Str|String)$/i) { } |
| 100 | T | F | elsif ($constraint =~ /^(Bool|Boolean)$/i) { } |
| 100 | T | F | elsif ($constraint =~ /^(Array|ArrayRef)$/i) { } |
| 50 | T | F | elsif ($constraint =~ /^(Hash|HashRef)$/i) { } |
| 6035 | 50 | T | F | if $self->can("_infer_type_from_default") |
| 6089 | 100 | T | F | unless defined $default |
| 6091 | 100 | T | F | if (ref $default eq 'HASH') { } |
| 100 | T | F | elsif (ref $default eq 'ARRAY') { } |
| 100 | T | F | elsif ($default =~ /^-?\d+$/) { } |
| 100 | T | F | elsif ($default =~ /^-?\d+\.\d+$/) { } |
| 50 | T | F | elsif ($default eq '1' or $default eq '0') { } |
| 6138 | 100 | T | F | if ($code =~ /sub\s+\w+\s+((?::\w+(?:\([^)]*\))?\s*)+)/s) |
| 6143 | 100 | T | F | if ($attr_section) |
| 6147 | 100 | T | F | if (defined $value and $value ne '') { } |
| 6158 | 100 | T | F | if ($attributes{'Returns'}) |
| 6160 | 50 | T | F | if ($return_type ne 1) |
| 6165 | 100 | T | F | if ($attributes{'lvalue'}) |
| 6169 | 100 | T | F | if ($attributes{'method'}) |
| 6203 | 100 | T | F | if ($code =~ /\$\w+\s*->\s*\@\*/) |
| 6209 | 100 | T | F | if ($code =~ /\$\w+\s*->\s*\%\*/) |
| 6215 | 100 | T | F | if ($code =~ /\$\w+\s*->\s*\$\*/) |
| 6221 | 100 | T | F | if ($code =~ /\$\w+\s*->\s*\&\*/) |
| 6227 | 100 | T | F | if ($code =~ /\$\w+\s*->\s*\@\[/) |
| 6233 | 100 | T | F | if ($code =~ /\$\w+\s*->\s*\%\{/) |
| 6282 | 100 | T | F | if ($modifiers =~ /:param(?:\(([^)]+)\))?/) |
| 6285 | 100 | T | F | if (defined $1) { } |
| 6297 | 100 | T | F | if ($modifiers =~ /=\s*([^:;]+)(?::|;|$)/) |
| 6302 | 50 | T | F | defined $field_info{'_default'} ? : |
| 6306 | 100 | T | F | if ($modifiers =~ /:isa\(([^)]+)\)/) |
| 6353 | 100 | T | F | unless $field->{'is_param'} |
| 6362 | 50 | T | F | unless $p->{'_source'} |
| 6363 | 100 | T | F | if $field_name ne $param_name |
| 6365 | 100 | T | F | if ($field->{'_default'}) |
| 6370 | 100 | T | F | if ($field->{'isa'}) |
| 6415 | 100 | T | F | unless exists $params->{$param} |
| 6416 | 50 | T | F | if $value =~ /->/ |
| 6426 | 50 | T | F | unless exists $params->{$param} |
| 6436 | 50 | T | F | unless exists $params->{$param} |
| 6446 | 50 | T | F | unless exists $params->{$param} |
| 6456 | 50 | T | F | unless exists $params->{$param} |
| 6466 | 100 | T | F | unless exists $params->{$param} |
| 6491 | 0 | T | F | unless exists $params->{$param} |
| 6501 | 50 | T | F | unless exists $params->{$param} |
| 6515 | 100 | T | F | if (not keys %{$params;} || $code =~ /my\s+\$(?:self|class)\s*=\s*\$_\[0\]/) |
| 6522 | 100 | T | F | if ($var eq 'class' and $position == 0 and $method->{'name'} eq 'new') { } |
| 50 | T | F | elsif ($var eq 'self' and $position == 0 and $method->{'name'} ne 'new') { } |
| 6538 | 50 | T | F | if ($var eq 'class' and $position == 0 and $method->{'name'} eq 'new') { } |
| 50 | T | F | elsif ($var eq 'self' and $position == 0 and $method->{'name'} ne 'new') { } |
| 6553 | 0 | T | F | if ($var ne "class" or $position > 0 or $method->{'name'} ne "new") |
| 6581 | 100 | T | F | unless defined $default |
| 6582 | 100 | T | F | if ref $default |
| 6618 | 100 | T | F | if ($code =~ /(die|croak|confess)\b[^{;]*\bif\b[^{;]*\$$param\b/s) |
| 6623 | 100 | T | F | if ($code =~ /length\s*\(\s*\$$param\s*\)\s*([<>]=?)\s*(\d+)/) |
| 6626 | 100 | T | F | if ($op eq '<') { } |
| 50 | T | F | elsif ($op eq '<=') { } |
| 100 | T | F | elsif ($op eq '>') { } |
| 50 | T | F | elsif ($op eq '>=') { } |
| 6639 | 100 | T | F | if (not $guarded and $code =~ /\$$param\s*([<>]=?)\s*([+-]?(?:\d+\.?\d*|\.\d+))/) |
| 6644 | 0 | T | F | &looks_like_number($val) ? : |
| 6646 | 100 | T | F | if ($op eq '<' or $op eq '<=') { } |
| 50 | T | F | elsif ($op eq '>' or $op eq '>=') { } |
| 6648 | 50 | T | F | $op eq '<' ? : |
| 6649 | 50 | T | F | if not defined $p->{'max'} or $max < $p->{'max'} |
| 6651 | 100 | T | F | $op eq '>' ? : |
| 6652 | 50 | T | F | if not defined $p->{'min'} or $min > $p->{'min'} |
| 6657 | 100 | T | F | if ($code =~ m[\$$param\s*=~\s*((?:qr?/[^/]+/|\$[\w:]+|\$\{\w+\}))]) |
| 6662 | 50 | T | F | if ($pattern =~ m[^qr?/([^/]+)/$]) { } |
| 6703 | 100 | T | F | if ($code =~ /(?:die|croak|confess)\s+[^;]*unless\s+(?:defined\s+)?\$$param/s) |
| 6709 | 100 | T | F | if (defined $default_value and not exists $p->{'_default'}) |
| 6714 | 50 | T | F | unless ($p->{'type'}) |
| 6715 | 50 | T | F | if (&looks_like_number($default_value)) { } |
| 0 | T | F | elsif (ref $default_value eq 'ARRAY') { } |
| 0 | T | F | elsif (ref $default_value eq 'HASH') { } |
| 0 | T | F | elsif ($default_value eq 'undef') { } |
| 0 | T | F | elsif (defined $default_value and not ref $default_value) { } |
| 6716 | 50 | T | F | $default_value =~ /\./ ? : |
| 6728 | 50 | T | F | ref $default_value ? : |
| 6733 | 100 | T | F | if (not $default_value || exists $p->{'_default'} and $code =~ /\$$param\s*=\s*([^;{}]+?)(?:\s*[;}])/s) |
| 6736 | 50 | T | F | unless ($assignment =~ /\$$param/ or $assignment =~ /^shift/) |
| 6740 | 50 | T | F | if (defined $possible_default) |
| 6749 | 100 | T | F | if ($is_required) |
| 6751 | 100 | T | F | if exists $p->{'_default'} |
| 6803 | 100 | T | F | if $pod->{$param} and defined $pod->{$param}{'position'} |
| 6804 | 50 | T | F | if $sig->{$param} and defined $sig->{$param}{'position'} |
| 6805 | 100 | T | F | if $code->{$param} and defined $code->{$param}{'position'} |
| 6808 | 100 | T | F | if (@positions) |
| 6811 | 0 | T | F | unless $pos_count{$b} <=> $pos_count{$a} |
| 6812 | 50 | T | F | unless exists $p->{'position'} |
| 6816 | 100 | T | F | if ($pod->{$param}) |
| 6821 | 100 | T | F | if ($code->{$param}) |
| 6823 | 100 | T | F | if $key eq "_source" |
| 6824 | 100 | T | F | if $key eq "position" |
| 6828 | 100 | T | F | if (not exists $p->{$key} or $key eq "type" and $from_pod and $p->{'type'} eq "string" and $code->{$param}{$key} ne "string") |
| 6837 | 50 | T | F | if ($sig->{$param}) |
| 6839 | 0 | T | F | if $key eq "_source" |
| 6840 | 0 | T | F | if $key eq "position" |
| 6853 | 100 | T | F | if ($self->{'verbose'}) |
| 6859 | 50 | T | F | defined $p->{'optional'} ? : |
| 6890 | 100 | T | F | $pod_param ? : |
| 6891 | 100 | T | F | $code_param ? : |
| 6894 | 100 | T | F | if (defined $pod_optional) { } |
| 100 | T | F | elsif (defined $code_optional) { } |
| 100 | T | F | elsif (keys %$merged_param > 0) { } |
| 6944 | 100 | T | F | unless keys %$params |
| 6956 | 100 | T | F | if ($p->{'type'}) { } |
| 6957 | 100 | T | F | if ($p->{'type'} eq 'string' and $p->{'min'} || $p->{'max'} || $p->{'matches'}) { } |
| 100 | T | F | elsif ($p->{'type'} eq 'string') { } |
| 6972 | 100 | T | F | if (defined $p->{'min'}) |
| 6976 | 100 | T | F | if (defined $p->{'max'}) |
| 6980 | 100 | T | F | if (defined $p->{'optional'}) |
| 6984 | 100 | T | F | if ($p->{'matches'}) |
| 6988 | 100 | T | F | if ($p->{'isa'}) |
| 6994 | 100 | T | F | if (defined $p->{'position'}) |
| 7000 | 100 | T | F | if (exists $p->{'_default'}) |
| 7006 | 100 | T | F | if ($p->{'semantic'}) |
| 7020 | 50 | T | F | $count ? : |
| 7023 | 100 | T | F | $count == 1 ? : |
| 7029 | 50 | T | F | if (@sorted_params) |
| 7034 | 100 | T | F | if (@sorted_params > 1) |
| 7043 | 100 | T | F | if ($avg >= $CONFIDENCE_HIGH_THRESHOLD) { } |
| 100 | T | F | elsif ($avg >= $CONFIDENCE_MEDIUM_THRESHOLD) { } |
| 100 | T | F | elsif ($avg >= $CONFIDENCE_LOW_THRESHOLD) { } |
| 7092 | 100 | T | F | unless keys %$output |
| 7097 | 100 | T | F | if ($output->{'type'}) { } |
| 7105 | 100 | T | F | if (defined $output->{'value'}) |
| 7111 | 100 | T | F | if ($output->{'isa'}) |
| 7117 | 100 | T | F | if ($output->{'_context_aware'}) |
| 7121 | 50 | T | F | if ($output->{'_list_context'}) |
| 7124 | 100 | T | F | if ($output->{'_scalar_context'}) |
| 7130 | 100 | T | F | if ($output->{'_error_return'}) |
| 7136 | 100 | T | F | if ($output->{'_success_failure_pattern'}) |
| 7142 | 100 | T | F | if ($output->{'_returns_self'}) |
| 7148 | 100 | T | F | if ($output->{'_void_context'}) |
| 7154 | 100 | T | F | if ($output->{'_error_handling'} and $output->{'_error_handling'}{'exception_handling'}) |
| 7163 | 100 | T | F | if ($score >= $CONFIDENCE_HIGH_THRESHOLD) { } |
| 100 | T | F | elsif ($score >= $CONFIDENCE_MEDIUM_THRESHOLD) { } |
| 100 | T | F | elsif ($score >= $CONFIDENCE_LOW_THRESHOLD) { } |
| 7205 | 100 | T | F | unless $schema->{'_analysis'} |
| 7217 | 50 | T | F | if ($analysis->{'confidence_factors'}{'input'}) |
| 7228 | 50 | T | F | if ($analysis->{'confidence_factors'}{'output'}) |
| 7237 | 50 | T | F | if ($analysis->{'per_parameter_scores'}) |
| 7278 | 100 | T | F | unless ($p->{'type'}) |
| 7282 | 100 | T | F | unless (defined $p->{'optional'}) |
| 7324 | 100 | T | F | unless ref $p eq "HASH" |
| 7325 | 100 | T | F | unless ($p->{'type'}) |
| 7376 | 100 | T | F | unless @param_names |
| 7424 | 100 | T | F | if ($rel->{'type'} eq 'mutually_exclusive') { } |
| 100 | T | F | elsif ($rel->{'type'} eq 'required_group') { } |
| 100 | T | F | elsif ($rel->{'type'} eq 'conditional_requirement') { } |
| 100 | T | F | elsif ($rel->{'type'} eq 'dependency') { } |
| 100 | T | F | elsif ($rel->{'type'} eq 'value_constraint') { } |
| 50 | T | F | elsif ($rel->{'type'} eq 'value_conditional') { } |
| 7440 | 100 | T | F | unless ($seen{$sig}++) |
| 7476 | 100 | T | F | if $param1 eq $param2 |
| 7479 | 100 | T | F | if ($code =~ /(?:die|croak|confess)[^;]*if\s+\$$param1\s+&&\s+\$$param2/ or $code =~ /(?:die|croak|confess)[^;]*if\s+\$$param2\s+&&\s+\$$param1/) |
| 7485 | 100 | T | F | if ($rel->{'type'} eq "mutually_exclusive" and ($rel->{'params'}[0] eq $param2 and $rel->{'params'}[1] eq $param1)) |
| 7492 | 100 | T | F | if $found_reverse |
| 7504 | 100 | T | F | if ($code =~ /(?:die|croak|confess)\s+['"](Cannot|Can't)[^'"]*both[^'"]*${param1}[^'"]*$param2/i or $code =~ /(?:die|croak|confess)\s+['"](Cannot|Can't)[^'"]*both[^'"]*${param2}[^'"]*$param1/i) |
| 7509 | 50 | T | F | if ($rel->{'type'} eq "mutually_exclusive" and ($rel->{'params'}[0] eq $param2 and $rel->{'params'}[1] eq $param1)) |
| 7516 | 50 | T | F | if $found_reverse |
| 7560 | 100 | T | F | if $param1 eq $param2 |
| 7562 | 100 | T | F | if ($code =~ /(?:die|croak|confess)[^;]*unless\s+\$$param1\s+\|\|\s+\$$param2/ or $code =~ /(?:die|croak|confess)[^;]*unless\s+\$$param2\s+\|\|\s+\$$param1/) |
| 7568 | 50 | T | F | if ($rel->{'type'} eq "required_group" and ($rel->{'params'}[0] eq $param2 and $rel->{'params'}[1] eq $param1)) |
| 7575 | 100 | T | F | if $found_reverse |
| 7588 | 100 | T | F | if ($code =~ /(?:die|croak|confess)\s+['"]Must\s+specify\s+either[^'"]*${param1}[^'"]*or[^'"]*$param2/i or $code =~ /(?:die|croak|confess)\s+['"]Must\s+specify\s+either[^'"]*${param2}[^'"]*or[^'"]*$param1/i) |
| 7593 | 50 | T | F | if ($rel->{'type'} eq "required_group" and ($rel->{'params'}[0] eq $param2 and $rel->{'params'}[1] eq $param1)) |
| 7600 | 50 | T | F | if $found_reverse |
| 7645 | 100 | T | F | if $param1 eq $param2 |
| 7648 | 100 | T | F | if ($code =~ /(?:die|croak|confess)[^;]*if\s+\$$param1\s+&&\s+!\$$param2/) |
| 7660 | 50 | T | F | if ($code =~ /(?:die|croak|confess)[^;]*if\s+\$$param1\s+&&\s+!defined\s*\(\s*\$$param2\s*\)/) |
| 7672 | 100 | T | F | if ($code =~ /(?:die|croak|confess)\s+['"]\w*${param1}[^'"]*requires[^'"]*$param2/i) |
| 7715 | 100 | T | F | if $param1 eq $param2 |
| 7719 | 100 | T | F | if ($code =~ /(?:die|croak|confess)\s+['"]\w*${param1}[^'"]*requires[^'"]*$param2/i and $code =~ /if\s+\$$param1\s+&&\s+!\$$param2/) |
| 7764 | 100 | T | F | if $param1 eq $param2 |
| 7767 | 100 | T | F | if ($code =~ /(?:die|croak|confess)[^;]*if\s+\$$param1\s+&&\s+\$$param2\s*!=\s*(\d+)/) |
| 7782 | 50 | T | F | if ($code =~ /(?:die|croak|confess)[^;]*if\s+\$$param1\s+&&\s+\$$param2\s*<\s*(\d+)/) |
| 7797 | 100 | T | F | if ($code =~ /(?:die|croak|confess)[^;]*if\s+\$$param1\s+eq\s+['"]([^'"]+)['"]\s+&&\s+!\$$param2/) |
| 7827 | 100 | T | F | unless defined $self->{'output_dir'} |
| 7829 | 100 | T | F | unless -d $self->{'output_dir'} |
| 7838 | 100 | T | F | if ($self->{'_document'}) |
| 7840 | 100 | T | F | $package_stmt ? : |
| 7860 | 100 | T | F | if ($schema->{'input'}) |
| 7861 | 100 | T | F | if (scalar keys %{$$schema{'input'};}) { } |
| 7866 | 100 | T | F | if ($param->{'name'}) |
| 7868 | 50 | T | F | if ($name ne $param_name) |
| 7884 | 50 | T | F | if (@with_pos and @without_pos) |
| 7893 | 50 | T | F | if ($schema->{'output'} and scalar keys %{$$schema{"output"};}) |
| 7894 | 100 | T | F | if (ref $schema->{'output'}{'_error_handling'} eq "HASH" and scalar keys %{$$schema{"output"}{"_error_handling"};} == 0) |
| 7900 | 50 | T | F | if ($schema->{'output'}{'type'} and $schema->{'output'}{'type'} eq "scalar") |
| 7906 | 100 | T | F | if ($schema->{'new'}) |
| 7908 | 100 | T | F | if (ref $schema->{'new'} or $schema->{'new'} eq $package_name) { } |
| 7909 | 50 | T | F | $schema->{'new'} eq $package_name ? : |
| 7917 | 100 | T | F | unless (defined $schema->{'_confidence'}{'input'}{'level'}) |
| 7920 | 100 | T | F | unless (defined $schema->{'_confidence'}{'output'}{'level'}) |
| 7925 | 100 | T | F | if ($schema->{'relationships'} and @{$schema->{'relationships'};}) |
| 7929 | 50 | T | F | if ($schema->{'accessor'} and scalar keys %{$$schema{"accessor"};}) |
| 7939 | 100 | T | F | $schema->{'relationships'} ? : |
| 7941 | 100 | T | F | $schema->{'new'} ? : |
| 7980 | 100 | T | F | if ($schema->{'input'}) |
| 7985 | 100 | T | F | if ($p->{'semantic'}) |
| 7989 | 100 | T | F | if ($p->{'enum'}) |
| 7993 | 100 | T | F | if ($p->{'isa'}) |
| 7998 | 100 | T | F | if (@param_notes) |
| 8008 | 100 | T | F | if ($schema->{'relationships'} and @{$schema->{'relationships'};}) |
| 8020 | 100 | T | F | if ($schema->{'_notes'} and scalar @{$schema->{'_notes'};}) |
| 8028 | 100 | T | F | if ($schema->{'_analysis'}) |
| 8048 | 100 | T | F | if ($schema->{'input'}) |
| 8052 | 100 | T | F | if ($p->{'type'} and $p->{'type'} eq "coderef") |
| 8056 | 100 | T | F | if ($p->{'semantic'} and $p->{'semantic'} eq "filehandle") |
| 8060 | 100 | T | F | if ($p->{'isa'} and $p->{'isa'} =~ /DateTime/) |
| 8066 | 100 | T | F | if (@warnings) |
| 8113 | 100 | T | F | if defined $param->{$field} |
| 8117 | 100 | T | F | if (my $semantic = $param->{'semantic'}) |
| 8118 | 100 | T | F | if ($semantic eq 'datetime_object') { } |
| 50 | T | F | elsif ($semantic eq 'timepiece_object') { } |
| 100 | T | F | elsif ($semantic eq 'date_string') { } |
| 100 | T | F | elsif ($semantic eq 'iso8601_string') { } |
| 100 | T | F | elsif ($semantic eq 'unix_timestamp') { } |
| 50 | T | F | elsif ($semantic eq 'datetime_parseable') { } |
| 100 | T | F | elsif ($semantic eq 'filehandle') { } |
| 100 | T | F | elsif ($semantic eq 'filepath') { } |
| 100 | T | F | elsif ($semantic eq 'callback') { } |
| 100 | T | F | elsif ($semantic eq 'enum') { } |
| 8161 | 50 | T | F | if ($param->{'enum'} and ref $param->{'enum'} eq "ARRAY") |
| 8171 | 100 | T | F | if ($param->{'enum'} and ref $param->{'enum'} eq "ARRAY" and not $cleaned{'enum'}) |
| 8174 | 50 | T | F | if ($param->{'memberof'} and ref $param->{'memberof'} eq "ARRAY") |
| 8179 | 100 | T | F | if ($param->{'isa'} and not $cleaned{'isa'}) |
| 8184 | 100 | T | F | if ($param->{'format'}) |
| 8216 | 100 | T | F | if ($rel->{'type'} eq 'mutually_exclusive') { } |
| 100 | T | F | elsif ($rel->{'type'} eq 'required_group') { } |
| 100 | T | F | elsif ($rel->{'type'} eq 'conditional_requirement') { } |
| 100 | T | F | elsif ($rel->{'type'} eq 'dependency') { } |
| 100 | T | F | elsif ($rel->{'type'} eq 'value_constraint') { } |
| 100 | T | F | elsif ($rel->{'type'} eq 'value_conditional') { } |
| 8269 | 50 | T | F | unless $doc |
| 8273 | 100 | T | F | $package_stmt ? : |
| 8289 | 100 | T | F | if ($method_name eq "new") |
| 8293 | 50 | T | F | if ($method_name =~ /^(create|build|construct|init|DESTROY)$/i) |
| 8304 | 100 | T | F | if ($is_singleton) |
| 8316 | 0 | T | F | if ($is_instance_method and $is_instance_method->{'explicit_self'} || $is_instance_method->{'shift_self'} || $is_instance_method->{'accesses_object_data'} || $is_instance_method->{'calls_instance_methods'} && scalar @{$is_instance_method->{'calls_instance_methods'};}) |
| 8324 | 100 | T | F | if ($is_factory) |
| 8338 | 50 | T | F | if ($inheritance_info and $inheritance_info->{'use_parent_constructor'}) |
| 8350 | 100 | T | F | if ($constructor_needs) |
| 8364 | 50 | T | F | if ($needs_other_object) |
| 8368 | 0 | T | F | if $needs_other_object->{'package'} |
| 8374 | 0 | T | F | if $result->{'package'} |
| 8378 | 100 | T | F | if ($is_factory and not $skip_object) |
| 8384 | 50 | T | F | if $is_factory->{'returns_class'} |
| 8420 | 100 | T | F | if ($method_name =~ /^(create_|make_|build_|get_)/i) |
| 8425 | 50 | T | F | if ($method_body) |
| 8427 | 100 | T | F | if ($method_body =~ /return\s+bless\s*\{[^}]*\},\s*['"]?(\w+(?:::\w+)*|\$\w+)['"]?/s or $method_body =~ /bless\s*\{[^}]*\},\s*['"]?(\w+(?:::\w+)*|\$\w+)['"]?.*return/s) |
| 8432 | 100 | T | F | if ($class_name =~ /^\$(class|self|package)$/) { } |
| 50 | T | F | elsif ($class_name =~ /^\$/) { } |
| 8446 | 100 | T | F | if ($method_body =~ /return\s+([\$\w:]+)->new\(/s or $method_body =~ /([\$\w:]+)->new\(.*return/s) |
| 8451 | 50 | T | F | if ($target eq '$self' or $target eq 'shift' or $target =~ /^\$/) { } |
| 100 | T | F | elsif ($target =~ /::/) { } |
| 8467 | 50 | T | F | if ($method_body =~ /return\s+([\$\w:]+)->(create_|make_|build_|get_)/i or $method_body =~ /([\$\w:]+)->(create_|make_|build_|get_).*return/is) |
| 8476 | 100 | T | F | if ($method_info and ref $method_info eq "HASH" and $method_info->{'pod'}) |
| 8478 | 50 | T | F | if ($pod =~ /returns?\s+(?:an?\s+)?(object|instance|new\s+\w+)/i) |
| 8518 | 100 | T | F | unless $method_name =~ /^(instance|get_instance|singleton|shared_instance)$/i |
| 8525 | 50 | T | F | if ($method_body) |
| 8527 | 100 | T | F | if ($method_body =~ /(?:my\s+)?(?:our\s+)?\$(?:instance|_instance|singleton)\b/s or $method_body =~ /state\s+\$(?:instance|_instance|singleton)\b/s) |
| 8534 | 100 | T | F | if ($method_body =~ /return\s+\$instance\s+if\s+(?:defined\s+)?\$instance/ or $method_body =~ /unless\s+\$instance.*?=\s*.*?new/) |
| 8541 | 100 | T | F | if ($method_body =~ /\$instance\s*\|\|=\s*.*?new/ or $method_body =~ /\$instance\s*=\s*.*?new\s+unless\s+(?:defined\s+)?\$instance/) |
| 8548 | 100 | T | F | if ($method_body =~ /return\s+\$instance;/) |
| 8550 | 50 | T | F | unless $singleton_info{'confidence'} |
| 8554 | 50 | T | F | if keys %singleton_info > 0 |
| 8589 | 100 | T | F | if ($method_body =~ /my\s*\(\s*\$self\s*[,)]/) { } |
| 100 | T | F | elsif ($method_body =~ /my\s+\$self\s*=\s*\$_\[0\]/) { } |
| 100 | T | F | elsif ($method_body =~ /my\s+\$self\s*=\s*shift/) { } |
| 100 | T | F | elsif ($method_body =~ /\$self\s*->\s*(\w+|[\{\[])/) { } |
| 8614 | 100 | T | F | if ($method_body =~ /\$self\s*->\s*[\{\[]/) |
| 8616 | 100 | T | F | unless $instance_info{'confidence'} eq "high" |
| 8620 | 100 | T | F | if ($method_body =~ /\$self\s*->\s*(\w+)\s*\(/s) |
| 8625 | 50 | T | F | if @{$instance_info{'calls_instance_methods'};} |
| 8629 | 100 | T | F | if ($method_name =~ /^_/ and not $method_name =~ /^_new/) |
| 8632 | 50 | T | F | unless exists $instance_info{'confidence'} |
| 8635 | 100 | T | F | if keys %instance_info |
| 8668 | 100 | T | F | unless $doc |
| 8679 | 100 | T | F | if ($content =~ /use\s+(parent|base)\s+['"]?([\w:]+)['"]?/) |
| 8684 | 50 | T | F | if ($content =~ /use\s+(parent|base)\s+qw?[\(\[]?(.+?)[\)\]]?;/) |
| 8697 | 50 | T | F | if ($content =~ /(?:our\s+)?\@ISA\s*=\s*qw?[\(\[]?(.+?)[\)\]]?/) |
| 8709 | 100 | T | F | if ($content =~ /\@ISA\s*=\s*qw?[\(\[]?(.+?)[\)\]]?/) |
| 8718 | 100 | T | F | if ($method_body and $method_body =~ /SUPER::/) |
| 8720 | 50 | T | F | if ($method_body =~ /SUPER::new/) |
| 8727 | 100 | T | F | if $_[1]->isa("PPI::Statement::Sub") |
| 8731 | 100 | T | F | if ($has_own_new) { } |
| 100 | T | F | elsif (@parent_classes) { } |
| 8739 | 100 | T | F | if keys %inheritance_info |
| 8773 | 50 | T | F | unless $doc |
| 8777 | 100 | T | F | if ($target_package ne $current_package) |
| 8787 | 100 | T | F | if $_[1]->isa("PPI::Statement::Sub") |
| 8791 | 100 | T | F | unless $new_method |
| 8799 | 100 | T | F | if ($body =~ /my\s*\(\s*\$(self|class)\s*,\s*(.+?)\)\s*=\s*\@_/s) |
| 8803 | 100 | T | F | if (@param_names) |
| 8817 | 50 | T | F | if (@shift_params) |
| 8825 | 100 | T | F | if ($body =~ /croak.*unless.*(?:defined\s+)?\$(\w+)/g) |
| 8828 | 100 | T | F | if ($body =~ /die.*unless.*(?:defined\s+)?\$(\w+)/g) |
| 8832 | 100 | T | F | if (@required_params) |
| 8842 | 100 | T | F | if ($requirements{'parameters'}) |
| 8845 | 100 | T | F | if (defined $default) |
| 8852 | 100 | T | F | if (@optional_params) |
| 8857 | 100 | T | F | if keys %requirements |
| 8888 | 100 | T | F | unless $method_body |
| 8897 | 100 | T | F | if $class eq "main" or $class eq "__PACKAGE__" or $class =~ /^\$/ |
| 8901 | 100 | T | F | if ($dependency_info{'creates_objects'}) |
| 8909 | 100 | T | F | if ($method_body =~ /\$(\w+)->\w+\(/) |
| 8923 | 100 | T | F | if ($method_body =~ /my\s+\$$var\s*=\s*(\w+(?:::\w+)+)->(?:new|create)/) { } |
| 50 | T | F | elsif ($method_body =~ /my\s+\$$var\s*=\s*(\w+(?:::\w+)+)->/) { } |
| 8930 | 50 | T | F | if (@object_classes) |
| 8932 | 100 | T | F | unless $dependency_info{'package'} |
| 8939 | 100 | T | F | if keys %dependency_info |
| 8962 | 50 | T | F | unless $doc |
| 8966 | 50 | T | F | if $_[1]->isa("PPI::Statement::Include") and $_[1]->type eq "use" and $_[1]->module =~ /^(parent|base)$/ |
| 8971 | 50 | T | F | if ($parent_stmt) |
| 8978 | 100 | T | F | if $_[1]->isa("PPI::Statement") |
| 8981 | 50 | T | F | if ($isa_stmt and $isa_stmt->content =~ /['"](\w+(?:::\w+)*)['"]/) |
| 9015 | 100 | T | F | unless $package_stmt |
| 9021 | 100 | T | F | if $_[1]->isa("PPI::Statement::Sub") |
| 9024 | 50 | T | F | if ($has_new) |
| 9030 | 0 | T | F | if $parent |
| 9066 | 100 | T | F | unless $param and $code |
| 9076 | 100 | T | F | if ($clean_code =~ /\$$param\s*=\s*(?:\$$param|\$[a-zA-Z_]\w*)\s*\|\|\s*([^;]+)/) |
| 9080 | 50 | T | F | if defined $default |
| 9084 | 100 | T | F | if ($clean_code =~ m[\$$param\s*//=\s*([^;]+)]) |
| 9088 | 100 | T | F | if defined $default |
| 9093 | 100 | T | F | if ($clean_code =~ /\$$param\s*=\s*defined\s+(?:\$$param|\$[a-zA-Z_]\w*)\s*\?\s*(?:\$$param|\$[a-zA-Z_]\w*)\s*:\s*([^;]+)/) |
| 9097 | 50 | T | F | if defined $default |
| 9101 | 100 | T | F | if ($clean_code =~ /\$$param\s*=\s*([^;]+?)\s+unless\s+defined\s+(?:\$$param|\$[a-zA-Z_]\w*)/) |
| 9104 | 50 | T | F | if defined $default |
| 9108 | 100 | T | F | if ($clean_code =~ /\$$param\s*\|\|=\s*([^;]+)/) |
| 9112 | 50 | T | F | if defined $default |
| 9116 | 100 | T | F | if ($clean_code =~ m[\$$param\s*=\s*(?:\$$param|\$[a-zA-Z_]\w*)\s*//\s*([^;]+)]) |
| 9120 | 100 | T | F | if defined $default |
| 9124 | 100 | T | F | if ($clean_code =~ /if\s*\(\s*!defined\s+\$$param\s*\)\s*\{[^}]*\$$param\s*=\s*([^;]+)/s) |
| 9128 | 50 | T | F | if defined $default |
| 9132 | 100 | T | F | if ($clean_code =~ /unless\s*\(\s*defined\s+\$$param\s*\)\s*\{[^}]*\$$param\s*=\s*([^;]+)/s) |
| 9136 | 50 | T | F | if defined $default |
| 9173 | 100 | T | F | unless $code |
| 9180 | 100 | T | F | unless @{$hints{$k};} |
| 9207 | 100 | T | F | if ($code =~ /defined\s*\(\s*\$/) |
| 9212 | 100 | T | F | if ($code =~ /\beq\s*''/ or $code =~ /\blength\s*\(/) |
| 9217 | 100 | T | F | if ($code =~ /\$\w+\s*<\s*0/) |
| 9245 | 100 | T | F | if ($op eq '<') { } |
| 100 | T | F | elsif ($op eq '<=') { } |
| 100 | T | F | elsif ($op eq '>') { } |
| 50 | T | F | elsif ($op eq '>=') { } |
| 9282 | 100 | T | F | unless $pod |
| 9287 | 100 | T | F | unless $pod =~ /=head2\s+SYNOPSIS\s*(.+?)(?=\n=head|\z)/s |
| 9297 | 50 | T | F | defined $3 ? : |
| 100 | T | F | defined $2 ? : |
| 9301 | 100 | T | F | if %kv |
| 9309 | 100 | T | F | unless (scalar @examples) |
| 9318 | 50 | T | F | unless @args |
| 9329 | 50 | T | F | if (scalar @examples) |
| 9374 | 100 | T | F | unless defined $value |
| 9384 | 100 | T | F | if ($value =~ m[\|\||/{2}]) |
| 9394 | 100 | T | F | if ($value =~ /^qq?\{(.*?)\}$/s) { } |
| 50 | T | F | elsif ($value =~ /^qw\{(.*?)\}$/s) { } |
| 50 | T | F | elsif ($value =~ /^q[qwx]?\s*([^a-zA-Z0-9\{\[])(.*?)\1$/s) { } |
| 9403 | 100 | T | F | if ($value =~ /^(['"])(.*)\1$/s) |
| 9406 | 100 | T | F | if ($from_code) |
| 9417 | 100 | T | F | unless ($from_code) |
| 9426 | 100 | T | F | unless ($value =~ /^\(/) |
| 9431 | 100 | T | F | if ($value =~ /^\{\s*\}$/) |
| 9436 | 100 | T | F | if ($value =~ /^\[\s*\]$/) |
| 9441 | 100 | T | F | if ($value =~ /^-?\d+(?:\.\d+)?$/) |
| 9442 | 100 | T | F | if ($value =~ /\./) { } |
| 9450 | 100 | T | F | if ($value =~ /^(true|false)$/i) |
| 9451 | 100 | T | F | lc $1 eq 'true' ? : |
| 9455 | 50 | T | F | if ($value eq '1') { } |
| 50 | T | F | elsif ($value eq '0') { } |
| 9462 | 100 | T | F | if ($value eq "undef") |
| 9467 | 100 | T | F | if ($value eq "__PACKAGE__") |
| 9475 | 100 | T | F | if ($value =~ /^\$[a-zA-Z_]/ or $value =~ /\(.*\)/) |
| 9476 | 50 | T | F | if $value =~ /^\$|\@|\%/ |
| 9528 | 50 | T | F | if $pod->{'_from_input_spec'} |
| 9531 | 100 | T | F | if (exists $pod_params->{$param} and not exists $code_params->{$param}) |
| 9536 | 50 | T | F | if (not exists $pod_params->{$param} and exists $code_params->{$param}) |
| 9537 | 100 | T | F | if ($param eq "class") |
| 9541 | 100 | T | F | if ($param eq "self") |
| 9550 | 100 | T | F | if ($pod->{'type'} and $code->{'type'} and $pod->{'type'} ne $code->{'type'}) |
| 9551 | 100 | T | F | if (not $self->_types_are_compatible($pod->{'type'}, $code->{'type'})) { } |
| 9559 | 50 | T | F | if (exists $pod->{'optional'} and exists $code->{'optional'} and $pod->{'optional'} != $code->{'optional'}) |
| 9561 | 0 | T | F | $pod->{'optional'} ? : |
| 9562 | 0 | T | F | $code->{'optional'} ? : |
| 9567 | 0 | T | F | if (defined $pod->{'min'} and defined $code->{'min'} and $pod->{'min'} != $code->{'min'}) |
| 9571 | 0 | T | F | if (defined $pod->{'max'} and defined $code->{'max'} and $pod->{'max'} != $code->{'max'}) |
| 9576 | 0 | T | F | if ($pod->{'matches'} and $code->{'matches'} and $pod->{'matches'} ne $code->{'matches'}) |
| 9605 | 100 | T | F | unless defined $val |
| 9608 | 100 | T | F | if $val =~ /^(0|off|none)$/i |
| 9609 | 100 | T | F | if $val =~ /^(1|warn|warning)$/i |
| 9610 | 100 | T | F | if $val =~ /^(2|fatal|die|error)$/i |
| 9636 | 100 | T | F | if $pod_type eq $code_type |
| 9649 | 100 | T | F | if (my $allowed = $compatible_types{$pod_type}) |
| 9654 | 50 | T | F | if (my $allowed = $compatible_types{$code_type}) |
| 9719 | 100 | T | F | if (my $errors = $schema->{'_pod_validation_errors'}) |
| 9721 | 100 | T | F | $schema->{'_pod_disagreement'} ? : |
| 9728 | 100 | T | F | if (@reports) { } |
| 9744 | 100 | T | F | if $self->{'verbose'} |