| line | % | coverage | branch |
| 1280 | 50 | T | F | unless exists $params->{'input_file'} |
| 1295 | 100 | T | F | unless (-f $self->{'input_file'}) |
| 1384 | 50 | T | F | unless my $document = "PPI::Document"->new($self->{'input_file'}) |
| 1406 | 100 | T | F | unless $params->{'no_write'} |
| 1437 | 100 | T | F | unless (defined $document) |
| 1441 | 100 | T | F | if (@$pkgs == 0) |
| 1443 | 50 | T | F | $package_stmt ? : |
| 1445 | 50 | T | F | if @$pkgs > 1 |
| 1489 | 50 | T | F | unless defined $name |
| 1492 | 100 | T | F | if ($name =~ /^_/ and not $name =~ /^_(new|init|build)/) |
| 1493 | 100 | T | F | unless $self->{'include_private'} |
| 1510 | 100 | T | F | if ($content =~ /\bclass\b/) |
| 1518 | 50 | T | F | if ($content =~ /^\s*(before|after|around)\s+['"]?(\w+)['"]?\b/) |
| 1528 | 0 | T | F | if ($next_sib and $next_sib->isa("PPI::Statement::Sub")) |
| 1548 | 50 | T | F | if ($seen{$n}++) { } |
| 1602 | 100 | T | F | if $char eq "{" |
| 1603 | 100 | T | F | if $char eq "}" |
| 1607 | 50 | T | F | if $depth != 0 |
| 1621 | 50 | T | F | if ($method_name =~ /^_/ and not $method_name =~ /^_(new|init|build)/) |
| 1622 | 0 | T | F | unless $self->{'include_private'} |
| 1685 | 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')) { } |
| 1690 | 50 | T | F | if ($comment =~ /#\s*(?:param|arg|input)\s+\$(\w+)\s*:\s*(.+)/i) |
| 1756 | 50 | T | F | if ($method->{'fields'} and keys %{$$method{"fields"};}) |
| 1777 | 100 | T | F | if ($self->{'strict_pod'}) |
| 1788 | 100 | T | F | if (@validation_errors) |
| 1796 | 50 | T | F | if ($self->{'strict_pod'} == 2) { } |
| 1809 | 100 | T | F | if ($validator_params) { } |
| 1818 | 100 | T | F | if (keys %$fields) |
| 1846 | 100 | T | F | if ($method->{'name'} ne "new" and $needs_object) |
| 1853 | 50 | T | F | unless (ref $input_confidence) |
| 1874 | 50 | T | F | if ($input_confidence->{'per_parameter'}) |
| 1893 | 100 | T | F | $level_rank{$input_level} < $level_rank{$output_level} ? : |
| 1899 | 100 | T | F | if ($relationships and @{$relationships;}) |
| 1905 | 100 | T | F | if keys %$attributes |
| 1906 | 100 | T | F | if keys %$postfix_derefs |
| 1907 | 100 | T | F | if keys %$fields |
| 1910 | 100 | T | F | if ($method->{'class'}) |
| 1920 | 50 | T | F | defined $_ ? : |
| 1928 | 100 | T | F | if ($self->_method_has_numeric_intent($schema)) |
| 1934 | 0 | T | F | defined $_ ? : |
| 1939 | 50 | T | F | unless $seen{$v}++ |
| 1941 | 50 | T | F | defined $v ? : |
| 1942 | 50 | T | F | unless $seen{$key}++ |
| 1948 | 50 | T | F | if (keys %$hints) |
| 1952 | 100 | T | F | unless exists $schema->{'_yamltest_hints'}{$k} |
| 1956 | 100 | T | F | if ($level_rank{$overall} < $level_rank{$LEVEL_MEDIUM} and $level_rank{$overall} < $self->{'confidence_threshold'} * 4) |
| 1974 | 50 | T | F | if ($schema->{'output'}) |
| 2043 | 100 | T | F | if $schema->{'output'} and $schema->{'output'}{'type'} and $schema->{'output'}{'type'} =~ /^(number|integer)$/ |
| 2046 | 100 | T | F | unless $schema->{'input'} |
| 2047 | 100 | T | F | if $p->{'optional'} |
| 2048 | 100 | T | F | if $p->{'type'} and $p->{'type'} =~ /^(number|integer)$/ |
| 2119 | 100 | T | F | if (keys %fields_seen > 1) |
| 2127 | 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*;/) { } |
| 2135 | 0 | T | F | unless (defined $property) |
| 2136 | 0 | T | F | if ($code =~ /\$self\s*->\s*\{\s*['"]?([^}'"]+)['"]?\s*\}\s*=\s*shift\s*;/) |
| 2156 | 0 | T | F | if (my $pod = $method->{'pod'}) |
| 2157 | 0 | T | F | if ($pod =~ /\b(LWP::UserAgent(::\w+)*)\b/) |
| 2184 | 50 | T | F | unless (defined $property) |
| 2185 | 50 | T | F | if ($code =~ /\$self\s*->\s*\{\s*['"]?([^}'"]+)['"]?\s*\}\s*=/) |
| 2189 | 100 | T | F | if ($code =~ /validate_strict/) { } |
| 2195 | 50 | T | F | if ($code =~ /blessed\s*\(\s*\$(\w+)\s*\)/) { } |
| 2224 | 100 | T | F | if (my $pod = $method->{'pod'}) |
| 2225 | 50 | T | F | if ($pod =~ /\b(LWP::UserAgent(::\w+)*)\b/) |
| 2243 | 50 | T | F | if (ref $schema->{'input'} eq "HASH") |
| 2244 | 50 | T | F | if (scalar keys %{$$schema{"input"};} > 1) |
| 2262 | 100 | T | F | unless ($code =~ /\$self\s*->\s*\{\s*['"]?\Q$property\E['"]?\s*\}\s*=\s*(?:shift|\$\w+\s*=\s*shift|\@_|\$_\[\d+\])/) |
| 2266 | 100 | T | F | if (scalar @returns == scalar @self_returns) |
| 2308 | 100 | T | F | if ($schema->{'output'}{'_returns_self'}) { } |
| 50 | T | F | elsif (scalar keys %{$$schema{'output'};} != 0) { } |
| 2309 | 50 | T | F | if ($schema->{'output'}{'type'} ne "object") |
| 2312 | 50 | T | F | if ($schema->{'output'}{'isa'} ne $self->{'_package_name'}) |
| 2323 | 100 | T | F | if (exists $schema->{'accessor'}) |
| 2324 | 50 | T | F | if ($schema->{'accessor'}{'type'} and $schema->{'accessor'}{'type'} =~ /setter|getset/ and $schema->{'input'}) |
| 2328 | 100 | T | F | if ($in->{'type'} and $in->{'type'} eq "object") |
| 2331 | 50 | T | F | $in->{'isa'} ? : |
| 2342 | 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') |
| 2344 | 100 | T | F | if (my $pod = $method->{'pod'}) |
| 2346 | 100 | T | F | if ($pod =~ /\bUser[- ]?Agent\b.*\bobject\b/i) |
| 2421 | 50 | T | F | unless $res->{'input'} |
| 50 | T | F | if $res and ref $res eq "HASH" and keys %{{} unless $res->{'input'};} |
| 2455 | 50 | T | F | if ($child->isa("PPI::Statement") or $child->isa("PPI::Statement::Expression")) |
| 2464 | 0 | T | F | if ($tokens[$i]->isa('PPI::Token::Word') || $tokens[$i]->isa('PPI::Token::Quote') and $tokens[$i + 1]->isa("PPI::Structure::Constructor")) |
| 2473 | 0 | T | F | unless $key and $val |
| 2477 | 0 | T | F | unless $inner->isa("PPI::Statement") or $inner->isa("PPI::Statement::Expression") |
| 2484 | 0 | T | F | unless $k and $v |
| 2487 | 0 | T | F | $v->can('content') ? : |
| 2488 | 0 | T | F | if defined $value |
| 2490 | 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') { } |
| 2493 | 0 | T | F | $value ? : |
| 2543 | 50 | T | F | if ref $code and $code->can("find") |
| 2569 | 100 | T | F | unless $code =~ /\bvalidate_strict\s*\(/ |
| 2571 | 50 | T | F | unless my $doc = $self->_ppi($code) |
| 2574 | 100 | T | F | if $_[1]->isa("PPI::Token::Word") |
| 2575 | 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");
}
) |
| 2582 | 50 | T | F | unless (defined $list) |
| 2584 | 50 | T | F | unless defined $next |
| 2585 | 100 | T | F | if ($next->content =~ /schema\s*=>\s*(\{(?:[^{}]|\{(?:[^{}]|\{[^{}]*\})*\})*\})/s) |
| 2592 | 50 | T | F | if (scalar keys %{$schema;}) |
| 2601 | 50 | T | F | unless $list |
| 2605 | 0 | T | F | unless $schema_block |
| 2608 | 0 | T | F | if $schema |
| 2633 | 100 | T | F | unless $code =~ /\bvalidate\s*\(/ |
| 2635 | 50 | T | F | unless my $doc = $self->_ppi($code) |
| 2638 | 100 | T | F | if $_[1]->isa("PPI::Token::Word") |
| 2639 | 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");
}
) |
| 2646 | 50 | T | F | unless (defined $list) |
| 2650 | 50 | T | F | if ($schema_text) |
| 2657 | 100 | T | F | if (scalar keys %{$schema;}) |
| 2660 | 50 | T | F | if (my $type = $field->{'type'}) |
| 2661 | 50 | T | F | if ($type eq 'ARRAYREF') { } |
| 50 | T | F | elsif ($type eq 'SCALAR') { } |
| 2678 | 50 | T | F | unless $list |
| 2682 | 0 | T | F | unless $schema_block |
| 2685 | 0 | T | F | if $schema |
| 2724 | 100 | T | F | if ($char eq '{') { } |
| 100 | T | F | elsif ($char eq '}') { } |
| 100 | T | F | elsif ($char eq ',' and $depth == 0) { } |
| 2728 | 50 | T | F | if $depth < 0 |
| 2735 | 100 | T | F | unless defined $comma_pos |
| 2768 | 100 | T | F | unless $code =~ /\bvalidated_hash\s*\(/ |
| 2770 | 50 | T | F | unless my $doc = $self->_ppi($code) |
| 2773 | 100 | T | F | if $_[1]->isa("PPI::Token::Word") |
| 2774 | 50 | T | F | unless my $calls = $doc->find(sub {
$_[1]->content eq "validated_hash" if $_[1]->isa("PPI::Token::Word");
}
) |
| 2781 | 50 | T | F | unless (defined $list) |
| 2785 | 50 | T | F | if ($schema_text) |
| 2793 | 50 | T | F | if (scalar keys %{$schema;}) |
| 2796 | 50 | T | F | if (my $isa = delete $field->{'isa'}) |
| 2799 | 100 | T | F | if (exists $field->{'required'}) { } |
| 2801 | 100 | T | F | $required ? : |
| 2805 | 100 | T | F | if (ref $field->{'default'} eq "CODE") |
| 2812 | 50 | T | F | if (my $type = $field->{'type'}) |
| 2813 | 50 | T | F | if ($type eq 'ARRAYREF') { } |
| 50 | T | F | elsif ($type eq 'SCALAR') { } |
| 2830 | 0 | T | F | unless $list |
| 2834 | 0 | T | F | unless $schema_block |
| 2837 | 0 | T | F | if $schema |
| 2866 | 50 | T | F | unless $block and $block->can("children") |
| 2870 | 0 | T | F | unless $result and ref $result eq "HASH" and $result->{'input'} |
| 2907 | 100 | T | F | exists $spec->{'optional'} ? : |
| 2942 | 100 | T | F | unless my $function = $self->_extract_function_name($code) |
| 2944 | 100 | T | F | unless my $doc = $self->{'_document'} |
| 2945 | 50 | T | F | unless my $stmt = $self->_find_signature_statement($doc, $function) |
| 2947 | 0 | T | F | unless my $signature_expr = $self->_extract_signature_expression($stmt, $function) |
| 2949 | 0 | T | F | unless my $meta = $self->_compile_signature_isolated($function, $signature_expr) |
| 2971 | 100 | T | F | if $code =~ /^\s*sub\s+([a-zA-Z0-9_]+)/ |
| 2995 | 100 | T | F | if $_[1]->isa("PPI::Statement") |
| 2997 | 100 | T | F | unless my $statements = $doc->find(sub {
$_[1]->content =~ /^\s*signature_for\b/ if $_[1]->isa("PPI::Statement");
}
) |
| 3001 | 50 | T | F | if ($content =~ /^\s*signature_for\s+\Q$function\E\b/) |
| 3031 | 100 | T | F | if ($content =~ /^\s*signature_for\s+\Q$function\E\s*=>\s*(.+?);?\s*$/s) |
| 3072 | 0 | T | F | if ($signature_expr =~ /\b(?:system|exec|open|fork|require|do|eval|qx)\b/) |
| 3076 | 0 | T | F | if ($signature_expr =~ /[`{};]/) |
| 3143 | 0 | T | F | if (my $sig = $compartment->reval($payload)) |
| 3179 | 0 | T | F | if ($stderr and length $stderr) |
| 3228 | 50 | T | F | unless $meta->{'parameters'} |
| 3231 | 100 | T | F | unless (exists $type_map{$p->{'type'}}) |
| 3239 | 100 | T | F | $p->{'optional'} ? : |
| 3247 | 100 | T | F | if (my $ret = $meta->{'returns'}) |
| 3250 | 50 | T | F | unless (exists $type_map{$ret->{'type'}}) |
| 3307 | 100 | T | F | unless $pod |
| 3314 | 100 | T | F | if ($pod =~ /=head2\s+\w+\s*\(([^)]+)\)/s) |
| 3320 | 50 | T | F | if @sig_params and $sig_params[0] =~ /^(self|class)$/i |
| 3335 | 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) { } |
| 3340 | 100 | T | F | if ($param_section) |
| 3346 | 50 | T | F | if ($line =~ /C<\$(\w+)>\s*\((Required|Mandatory)\)/i) |
| 3354 | 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) |
| 3359 | 100 | T | F | if $desc |
| 3362 | 100 | T | F | if $name =~ /^(self|class|return|returns?)$/i |
| 3367 | 100 | T | F | unless (exists $params{$name}{'position'}) |
| 3373 | 50 | T | F | if $type eq "int" |
| 3374 | 50 | T | F | if $type eq "num" or $type eq "float" |
| 3375 | 50 | T | F | if $type eq "bool" |
| 3376 | 50 | T | F | if $type eq "array" |
| 3377 | 50 | T | F | if $type eq "hash" |
| 3382 | 100 | T | F | if ($constraint) |
| 3388 | 100 | T | F | if ($full_text =~ /optional/i) { } |
| 100 | T | F | elsif ($full_text =~ /required|mandatory/i) { } |
| 3397 | 100 | T | F | if ($desc =~ /\b(email|url|uri|path|filename)\b/i) |
| 3404 | 100 | T | F | if ($desc and $desc =~ m[matches?\s+(/[^/]+/|qr/.+?/)]i) |
| 3408 | 100 | T | F | $constraint ? : |
| 100 | T | F | $desc ? : |
| 3420 | 100 | T | F | if exists $params{$name} |
| 3423 | 50 | T | F | if $desc |
| 3426 | 100 | T | F | if $name =~ /^(self|class|return|returns?)$/i |
| 3431 | 50 | T | F | if $type eq "int" |
| 3432 | 50 | T | F | if $type eq "num" or $type eq "float" |
| 3433 | 50 | T | F | if $type eq "bool" |
| 3434 | 50 | T | F | if $type eq "array" |
| 3435 | 50 | T | F | if $type eq "hash" |
| 3440 | 50 | T | F | if ($constraint) |
| 3445 | 50 | T | F | if ($desc) |
| 3446 | 50 | T | F | if ($desc =~ /optional/i) { } |
| 50 | T | F | elsif ($desc =~ /required|mandatory/i) { } |
| 3453 | 50 | T | F | if ($desc =~ m[matches?\s+(/[^/]+/|qr/.+?/)]i) |
| 3458 | 50 | T | F | $constraint ? : |
| 3468 | 50 | T | F | unless defined $name and length $name |
| 3473 | 50 | T | F | if $name =~ /^(self|class|return|returns?)$/i |
| 3479 | 50 | T | F | if ($desc =~ /^\s*(string|integer|int|number|num|float|boolean|bool|array|arrayref|hash|hashref)\b(?:\s*\(([^)]+)\))?/i) { } |
| 3484 | 0 | T | F | if $type eq "int" |
| 3485 | 0 | T | F | if $type eq "num" or $type eq "float" |
| 3486 | 0 | T | F | if $type eq "bool" |
| 3487 | 0 | T | F | if $type eq "array" |
| 3488 | 0 | T | F | if $type eq "hash" |
| 3492 | 0 | T | F | if ($constraint) |
| 3499 | 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) { } |
| 3511 | 50 | T | F | if ($desc =~ /optional/i) { } |
| 50 | T | F | elsif ($desc =~ /required|mandatory/i) { } |
| 3518 | 50 | T | F | if ($desc =~ m[matches?\s+(/[^/]+/|qr/.+?/)]i) |
| 3528 | 50 | T | F | if (exists $params{$param}) |
| 3530 | 100 | T | F | unless defined $params{$param}{'optional'} |
| 3533 | 100 | T | F | defined $pod_defaults->{$param} ? : |
| 3540 | 50 | T | F | if $name =~ /^(self|class)$/i |
| 3592 | 100 | T | F | if keys %output |
| 3595 | 100 | T | F | keys %output ? : |
| 3626 | 100 | T | F | if ($pod) |
| 3629 | 100 | T | F | if ($pod =~ /Returns?:\s+([^\n]+(?:\n[^\n]+){0,2})/is) |
| 3636 | 100 | T | F | if ($returns_desc =~ /\b(string|text)\b/i) { } |
| 100 | T | F | elsif ($returns_desc =~ /\b(integer|int|count)\b/i) { } |
| 50 | T | F | elsif ($returns_desc =~ /\b(float|decimal|number)\b/i) { } |
| 100 | T | F | elsif ($returns_desc =~ /\b(boolean|true|false)\b/i) { } |
| 50 | T | F | elsif ($returns_desc =~ /\b(array|list)\b/i) { } |
| 50 | T | F | elsif ($returns_desc =~ /\b(hash|hashref|dictionary)\b/i) { } |
| 100 | T | F | elsif ($returns_desc =~ /\b(object|instance)\b/i) { } |
| 50 | T | F | elsif ($returns_desc =~ /\bundef\b/i) { } |
| 3655 | 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) { } |
| 3657 | 50 | T | F | if (defined $output->{'type'} and $output->{'type'} eq 'scalar') { } |
| 3669 | 100 | T | F | if ($returns_desc =~ /\b(true|false)\b/i) |
| 3672 | 50 | T | F | if ($returns_desc =~ /\bundef\b/i) |
| 3678 | 100 | T | F | if (not $output->{'type'} and $pod =~ /returns?\s+(?:an?\s+)?(\w+)/i) |
| 3681 | 100 | T | F | if $type =~ /^(true|false|bool)$/ |
| 3683 | 50 | T | F | if $type eq "int" |
| 3684 | 50 | T | F | if $type =~ /^(num|float)$/ |
| 3685 | 50 | T | F | if $type eq "array" |
| 3686 | 50 | T | F | if $type eq "hash" |
| 3688 | 50 | T | F | if ($type =~ /^\d+$/) |
| 3689 | 0 | T | F | if ($type eq '1' or $type eq '0') { } |
| 3691 | 0 | T | F | if ($pod =~ /1 on success.+0 (on|if) /i) { } |
| 0 | T | F | elsif ($pod =~ /return 0 .+ 1 on success/) { } |
| 3703 | 50 | T | F | if not $type and $pod =~ /returns?\s+.+\slist\b/i |
| 3705 | 100 | T | F | if ($VALID_OUTPUT_TYPES{$type}) { } |
| 3743 | 50 | T | F | unless $pod |
| 3756 | 50 | T | F | if @param_matches |
| 3758 | 50 | T | F | if ($param) |
| 3760 | 50 | T | F | if ($default_text =~ /(\w+)\s*=\s*(.+)$/) { } |
| 3780 | 50 | T | F | if (@param_matches) |
| 3818 | 50 | T | F | if ($code) |
| 3821 | 100 | T | F | if (@all_returns) |
| 3828 | 100 | T | F | if $ret =~ /^(?:0|1)(?:\s|$)/ |
| 3832 | 100 | T | F | if ($boolean_count >= 2 and $boolean_count >= $total_count * "0.8") |
| 3833 | 50 | T | F | unless ($output->{'type'}) |
| 3842 | 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__/) { } |
| 50 | T | F | elsif ($code =~ /return\s*\(([^)]+)\)/) { } |
| 100 | T | F | elsif ($code =~ /return\s+\$self\s*;/ and $code =~ /\$self\s*->\s*\{[^}]+\}\s*=/) { } |
| 3845 | 50 | T | F | if ($method_name eq 'new') { } |
| 3847 | 0 | T | F | if ($self->{'_document'} and my $package_stmt = $self->{'_document'}->find_first("PPI::Statement::Package")) |
| 3857 | 100 | T | F | if ($method_name eq 'new') { } |
| 3871 | 0 | T | F | if ($self->{'_document'}) |
| 3873 | 0 | T | F | $pkg ? : |
| 3879 | 0 | T | F | if ($content =~ /,/) |
| 3885 | 50 | T | F | if ($self->{'_document'}) |
| 3887 | 50 | T | F | $pkg ? : |
| 3899 | 100 | T | F | if (@return_statements) { } |
| 3905 | 100 | T | F | if ($output->{'type'}) |
| 3913 | 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+/) { } |
| 3958 | 50 | T | F | if ($ret =~ /\b\d+\b/) { } |
| 3967 | 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 =~ /^\[[^\]]*\]$/) { } |
| 3984 | 100 | T | F | if (keys %return_types) |
| 3987 | 100 | T | F | if ($return_types{'integer'} and not $return_types{'string'}) |
| 3988 | 50 | T | F | if (not $output->{'type'} or $output->{'type'} eq "scalar") |
| 3992 | 50 | T | F | if (defined $min) |
| 3997 | 100 | T | F | unless ($output->{'type'}) |
| 4001 | 100 | T | F | if ($most_common eq "number") |
| 4003 | 50 | T | F | if (defined $min) |
| 4013 | 100 | T | F | if (@return_statements == 1 and $return_statements[0] eq 1) |
| 4015 | 50 | T | F | if not $output->{'type'} or $output->{'type'} eq "scalar" |
| 4016 | 50 | T | F | if $output->{'type'} |
| 4057 | 100 | T | F | unless not $output->{'type'} or $output->{'type'} eq "unknown" |
| 4060 | 100 | T | F | if ($pod and not $output->{'type'}) |
| 4062 | 50 | T | F | if ($pod =~ /returns?\s+(true|false|true|false|1|0)\s+(?:on|for|upon)\s+(success|failure|error|valid|invalid)/i) |
| 4068 | 50 | T | F | if ($pod =~ /(?:method|sub)\s+(\w+)/) |
| 4070 | 0 | T | F | if ($inferred_method_name =~ /^(is_|has_|can_|should_|contains_|exists_)/) |
| 4078 | 50 | T | F | if ($code) |
| 4083 | 50 | T | F | if ($true_returns + $false_returns >= 2) { } |
| 100 | T | F | elsif ($true_returns + $false_returns == 1) { } |
| 4092 | 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)/) |
| 4098 | 50 | T | F | if ($code =~ /return\s+[!\$\@\%]/) |
| 4106 | 50 | T | F | if ($method_name) |
| 4107 | 100 | T | F | if ($method_name =~ /^(is_|has_|can_|should_|contains_|exists_|check_|verify_|validate_)/) |
| 4111 | 50 | T | F | if ($method_name =~ /_ok$/) |
| 4119 | 100 | T | F | if ($boolean_score >= $BOOLEAN_SCORE_THRESHOLD) |
| 4120 | 50 | T | F | if (not $output->{'type'} or $output->{'type'} eq "scalar" or $output->{'type'} eq "array" or $output->{'type'} eq "undef") |
| 4150 | 50 | T | F | unless $code |
| 4153 | 100 | T | F | if ($code =~ /wantarray/) |
| 4158 | 100 | T | F | if ($code =~ /(wantarray[^;]+;)/s) |
| 4162 | 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) { } |
| 4191 | 100 | T | F | if ($code =~ /return\s*\(\s*([^)]+)\s*\)\s*;/) |
| 4197 | 100 | T | F | if $char eq "(" or $char eq "[" or $char eq "{" |
| 4198 | 100 | T | F | if $char eq ")" or $char eq "]" or $char eq "}" |
| 4199 | 100 | T | F | if $char eq "," and $depth == 0 |
| 4202 | 50 | T | F | if ($comma_count > 0 and not $content =~ /\b(?:bless|new)\b/) |
| 4204 | 50 | T | F | unless ($output->{'type'} and $output->{'type'} eq "boolean") |
| 4237 | 50 | T | F | unless $code |
| 4251 | 100 | T | F | if ($method_name =~ /$void_patterns->{$type}/) |
| 4271 | 100 | T | F | if $ret eq "" |
| 4272 | 100 | T | F | if $ret =~ /^(if|unless)\s/ |
| 4273 | 100 | T | F | if $ret eq 1 |
| 4274 | 100 | T | F | if $ret eq "\$self" |
| 4275 | 100 | T | F | if ($ret =~ /\?\s*1\s*:\s*0\b/) |
| 4288 | 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) { } |
| 4296 | 100 | T | F | unless ($output->{'type'} and $output->{'type'} eq "boolean") |
| 4326 | 50 | T | F | unless $code |
| 4336 | 100 | T | F | if $ret eq "\$self" |
| 4340 | 100 | T | F | if ($self_returns > 0 and $total_returns > 0) |
| 4343 | 100 | T | F | if ($ratio >= "0.8") |
| 4348 | 100 | T | F | if ($self->{'_document'}) |
| 4350 | 50 | T | F | $pkg ? : |
| 4384 | 50 | T | F | unless $code |
| 4403 | 100 | T | F | if ($code =~ /return\s*\(\s*\)\s*(?:if|unless|;)/) |
| 4413 | 100 | T | F | if ($1 eq '0') { } |
| 4420 | 100 | T | F | if ($zero_returns > 0 and $one_returns > 0) |
| 4426 | 100 | T | F | if ($code =~ /eval\s*\{/) |
| 4428 | 50 | T | F | if ($code =~ /eval\s*\{.*?\}[^}]*(?:if\s*\(\s*\$\@|catch|return\s+undef)/s) |
| 4439 | 50 | T | F | if ($has_undef and $has_value and scalar @all_returns >= 2) |
| 4445 | 100 | T | F | if (scalar keys %error_patterns) { } |
| 4449 | 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'}) { } |
| 4463 | 100 | T | F | if ($error_patterns{'exception_handling'}) |
| 4495 | 100 | T | F | unless defined $expr |
| 4500 | 100 | T | F | if ($expr =~ /,/) |
| 4504 | 100 | T | F | if $char =~ /[\(\[\{]/ |
| 4505 | 100 | T | F | if $char =~ /[\)\]\}]/ |
| 4506 | 100 | T | F | if $char eq "," and $depth == 0 |
| 4509 | 100 | T | F | if ($comma_count > 0) |
| 4515 | 100 | T | F | if ($expr =~ /^\@\w+/ or $expr =~ /^qw\(/ or $expr =~ /^\@\{/) |
| 4520 | 100 | T | F | if ($expr =~ /scalar\s*\(/) |
| 4525 | 100 | T | F | if ($expr =~ /^\[/ or $expr =~ /^\\\@/) |
| 4530 | 100 | T | F | if ($expr =~ /^\{/ or $expr =~ /^\\\%/) |
| 4535 | 50 | T | F | if ($expr =~ /^\%\w+/ or $expr =~ /^\%\{/) |
| 4540 | 100 | T | F | if ($expr =~ /^['"]/ or $expr =~ /['"]$/) |
| 4546 | 100 | T | F | if ($expr =~ /^[01]$/) |
| 4551 | 100 | T | F | if ($expr =~ /^-?\d+$/) |
| 4555 | 100 | T | F | if ($expr =~ /^-?\d+\.\d+$/) |
| 4560 | 50 | T | F | if ($expr =~ /bless/) |
| 4564 | 100 | T | F | if ($expr =~ /\blength\s*\(/) |
| 4592 | 100 | T | F | unless $pod |
| 4595 | 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) |
| 4627 | 100 | T | F | if (defined $output->{'type'} and $output->{'type'} eq "boolean" and not defined $output->{'value'}) |
| 4630 | 50 | T | F | if ($output->{'value'} and defined $output->{'type'} and $output->{'type'} ne "boolean") |
| 4634 | 100 | T | F | if (exists $output->{'type'}) |
| 4635 | 100 | T | F | if (not $valid_types{$output->{'type'}}) |
| 4667 | 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(.+)/) { } |
| 4686 | 100 | T | F | if $param->{'type'} and $param->{'type'} eq "integer" |
| 4687 | 100 | T | F | if $param->{'type'} and $param->{'type'} eq "number" |
| 4694 | 0 | T | F | if (&looks_like_number($val)) |
| 4695 | 0 | T | F | if ($op eq '<') { } |
| 0 | T | F | elsif ($op eq '<=') { } |
| 0 | T | F | elsif ($op eq '>') { } |
| 0 | T | F | elsif ($op eq '>=') { } |
| 4707 | 100 | T | F | if (defined $param->{'max'}) |
| 4710 | 100 | T | F | if (defined $param->{'min'}) |
| 4759 | 100 | T | F | if ($params{$param}{'_default'} and not $params{$param}{'type'}) |
| 4761 | 100 | T | F | if (ref $default eq 'HASH') { } |
| 100 | T | F | elsif (ref $default eq 'ARRAY') { } |
| 4771 | 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) { } |
| 4787 | 50 | T | F | if ($param_count++ > $self->{'max_parameters'}) |
| 4800 | 100 | T | F | if ($code =~ /defined\s*\(\s*\$$param\s*\)/) |
| 4806 | 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)/) { } |
| 4826 | 50 | T | F | if ($code =~ /if\s*\(\s*!\s*defined\s*\(\s*\$$param\s*\)\s*\)\s*\{([^}]+)\}/s) |
| 4828 | 0 | T | F | if ($block =~ /\b(croak|die|confess)\b/) |
| 4835 | 50 | T | F | if ($code =~ /\b(croak|die|confess)\b[^;]*\bunless\s+defined\s*\(\s*\$$param\s*\)/) |
| 4841 | 50 | T | F | if ($code =~ /exists\s*\(\s*\$$param\s*\)/) |
| 4847 | 50 | T | F | if ($code =~ /scalar\s*\(\s*\@?\$$param\s*\)/) |
| 4884 | 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/) { } |
| 4886 | 50 | T | F | $reftype eq 'hash' ? : |
| 100 | T | F | $reftype eq 'array' ? : |
| 4903 | 100 | T | F | unless ($p->{'type'}) |
| 4904 | 50 | T | F | if ($code =~ /\@\{\s*\$$param\s*\}/ or $code =~ /push\s*\(\s*\@?\$$param/) { } |
| 100 | T | F | elsif ($code =~ /\%\{\s*\$$param\s*\}/ or $code =~ /\$$param\s*->\s*\{/) { } |
| 4912 | 100 | T | F | if (not $p->{'type'} and exists $p->{'_default'}) |
| 4914 | 50 | T | F | if (ref $default eq 'HASH') { } |
| 50 | T | F | elsif (ref $default eq 'ARRAY') { } |
| 4926 | 100 | T | F | if (not $p->{'type'}) |
| 4928 | 100 | T | F | if ($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/) { } |
| 5020 | 50 | T | F | unless defined $param and $param =~ /^\w+$/ |
| 5023 | 100 | T | F | if ($code =~ /\$$param\s*->\s*isa\s*\(\s*['"]DateTime['"]\s*\)/i) |
| 5032 | 100 | T | F | if ($code =~ /\$$param\s*->\s*(ymd|dmy|mdy|hms|iso8601|epoch|strftime)/) |
| 5041 | 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)/) |
| 5051 | 100 | T | F | if ($code =~ m[\$$param\s*=~\s*/.*?\\d\{4\}.*?\\d\{2\}.*?\\d\{2\}]) |
| 5060 | 100 | T | F | if ($code =~ m[\$$param\s*=~\s*/.*?[Tt].*?[Zz].*?/]) |
| 5069 | 50 | T | F | if ($code =~ /\$$param\s*>\s*\d{9,}/ or $code =~ /time\(\s*\)\s*-\s*\$$param/ or $code =~ /\$$param\s*-\s*time\(\s*\)/) |
| 5080 | 50 | T | F | if ($code =~ /strptime\s*\(\s*\$$param/ or $code =~ /DateTime::Format::\w+\s*->\s*parse_datetime\s*\(\s*\$$param/) |
| 5113 | 50 | T | F | unless defined $param and $param =~ /^\w+$/ |
| 5116 | 100 | T | F | if ($code =~ /(?:open|close|read|print|say|sysread|syswrite)\s*\(?\s*\$$param/) |
| 5125 | 100 | T | F | if ($code =~ /\$$param\s*->\s*(readline|getline|print|say|close|flush|autoflush)/) |
| 5134 | 100 | T | F | if ($code =~ /(?:-[frwxoOeszlpSbctugkTBMAC])\s+\$$param/) |
| 5142 | 50 | T | F | if ($code =~ /File::(?:Spec|Basename)::\w+\s*\(\s*\$$param/ or $code =~ /(?:basename|dirname|fileparse)\s*\(\s*\$$param/) |
| 5152 | 50 | T | F | if (defined $p->{'_default'} and $p->{'_default'} =~ m[^([A-Za-z]:\\|/|\./|\.\./)]) |
| 5160 | 50 | T | F | if ($code =~ /\$$param\s*->\s*isa\s*\(\s*['"]IO::File['"]\s*\)/ or $code =~ /IO::File\s*->\s*new\s*\(\s*\$$param/) |
| 5193 | 50 | T | F | unless defined $param and $param =~ /^\w+$/ |
| 5196 | 100 | T | F | if ($code =~ /ref\s*\(\s*\$$param\s*\)\s*eq\s*['"]CODE['"]/i) |
| 5204 | 50 | T | F | if ($code =~ /\$$param\s*->\s*\(/ or $code =~ /\$$param\s*->\s*\(\s*\@_\s*\)/ or $code =~ /&\s*\{\s*\$$param\s*\}/) |
| 5214 | 100 | T | F | if ($param =~ /^(?:callback|cb|handler|sub|code|fn|func|on_\w+)$/i) |
| 5222 | 50 | T | F | if ($code =~ /blessed\s*\(\s*\$$param\s*\)/ and $code =~ /ref\s*\(\s*\$$param\s*\)\s*eq\s*['"]CODE['"]/i) |
| 5261 | 50 | T | F | unless defined $param and $param =~ /^\w+$/ |
| 5265 | 100 | T | F | if ($code =~ m[unless\s+\$$param\s*=~\s*/\^?\(([^)]+)\)]) |
| 5268 | 50 | T | F | unless $p->{'type'} |
| 5278 | 100 | T | F | if ($code =~ /\%(\w+)\s*=.*?qw\s*[\(\[<{]([^)\]>}]+)[\)\]>}]/) |
| 5281 | 100 | T | F | if (defined $values_str and $code =~ /\$$hash_name\s*\{\s*\$$param\s*\}/) |
| 5283 | 50 | T | F | unless $p->{'type'} |
| 5293 | 100 | T | F | if ($code =~ /grep\s*\{[^}]*\$${param}[^}]*\}\s*qw\s*[\(\[<{]([^)\]>}]+)[\)\]>}]/) |
| 5296 | 50 | T | F | unless $p->{'type'} |
| 5304 | 50 | T | F | if ($code =~ /given\s*\(\s*\$$param\s*\)/) |
| 5309 | 0 | T | F | if (@enum_values >= 2) |
| 5310 | 0 | T | F | unless $p->{'type'} |
| 5327 | 100 | T | F | if (@if_values >= 3) |
| 5328 | 50 | T | F | unless $p->{'type'} |
| 5337 | 50 | T | F | if ($code =~ /\$$param\s*~~\s*\[([^\]]+)\]/ or $code =~ /\$$param\s*~~\s*qw\s*[\(\[<{]([^)\]>}]+)[\)\]>}]/) |
| 5341 | 0 | T | F | if ($values_str =~ /['"]/) { } |
| 5346 | 0 | T | F | if (@enum_values) |
| 5347 | 0 | T | F | unless $p->{'type'} |
| 5400 | 100 | T | F | unless $condition =~ /\$$param\b/ |
| 5417 | 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/) { } |
| 5428 | 100 | T | F | if $constraint |
| 5429 | 100 | T | F | if defined $message |
| 5431 | 100 | T | F | defined $message ? : |
| 5438 | 100 | T | F | if ($code =~ /\b\Q$param\E\s*(<=|<|>=|>)\s*(-?\d+)/) |
| 5444 | 100 | T | F | if ($op eq '<=') { } |
| 100 | T | F | elsif ($op eq '<') { } |
| 100 | T | F | elsif ($op eq '>=') { } |
| 50 | T | F | elsif ($op eq '>') { } |
| 5498 | 100 | T | F | if ($code =~ /sub\s+\w+\s*(?::\w+(?:\([^)]*\))?\s*)*\(((?:[^()]|\([^)]*\))*)\)\s*\{/s) |
| 5502 | 100 | T | F | if ($potential_sig =~ /[\$\%\@]/) |
| 5510 | 100 | T | F | if ($code =~ /my\s*\(\s*([^)]+)\)\s*=\s*\@_/s) { } |
| 100 | T | F | elsif ($code =~ /my\s+\$self\s*=\s*shift/) { } |
| 5517 | 100 | T | F | if $name =~ /^(self|class)$/i |
| 5524 | 50 | T | F | unless exists $params->{$name}{'position'} |
| 5535 | 50 | T | F | if @shifts and $shifts[0] =~ /^(self|class)$/i |
| 5544 | 50 | T | F | if ($code =~ /my\s*\(\s*([^)]+)\)\s*=\s*\@_/s) |
| 5549 | 0 | T | F | if $param =~ /^(self|class)$/i |
| 5557 | 0 | T | F | if ($seen{$param}++) |
| 5593 | 50 | T | F | if ($char eq '(' or $char eq '[' or $char eq '{') { } |
| 50 | T | F | elsif ($char eq ')' or $char eq ']' or $char eq '}') { } |
| 100 | T | F | elsif ($char eq ',' and $depth == 0) { } |
| 5606 | 50 | T | F | if $current =~ /\S/ |
| 5614 | 50 | T | F | unless $part |
| 5619 | 50 | T | F | if ($param_info) |
| 5623 | 100 | T | F | if ($name =~ /^(self|class)$/i) |
| 5630 | 100 | T | F | $param_info->{'optional'} ? : |
| 100 | T | F | $param_info->{'_default'} ? : |
| 5675 | 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) { } |
| 5684 | 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) { } |
| 5709 | 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) { } |
| 5735 | 50 | T | F | if $self->can("_infer_type_from_default") |
| 5789 | 100 | T | F | unless defined $default |
| 5791 | 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') { } |
| 5838 | 100 | T | F | if ($code =~ /sub\s+\w+\s+((?::\w+(?:\([^)]*\))?\s*)+)/s) |
| 5843 | 100 | T | F | if ($attr_section) |
| 5847 | 100 | T | F | if (defined $value and $value ne '') { } |
| 5858 | 100 | T | F | if ($attributes{'Returns'}) |
| 5860 | 50 | T | F | if ($return_type ne 1) |
| 5865 | 100 | T | F | if ($attributes{'lvalue'}) |
| 5869 | 100 | T | F | if ($attributes{'method'}) |
| 5903 | 100 | T | F | if ($code =~ /\$\w+\s*->\s*\@\*/) |
| 5909 | 100 | T | F | if ($code =~ /\$\w+\s*->\s*\%\*/) |
| 5915 | 100 | T | F | if ($code =~ /\$\w+\s*->\s*\$\*/) |
| 5921 | 100 | T | F | if ($code =~ /\$\w+\s*->\s*\&\*/) |
| 5927 | 100 | T | F | if ($code =~ /\$\w+\s*->\s*\@\[/) |
| 5933 | 100 | T | F | if ($code =~ /\$\w+\s*->\s*\%\{/) |
| 5982 | 100 | T | F | if ($modifiers =~ /:param(?:\(([^)]+)\))?/) |
| 5985 | 100 | T | F | if (defined $1) { } |
| 5997 | 100 | T | F | if ($modifiers =~ /=\s*([^:;]+)(?::|;|$)/) |
| 6002 | 50 | T | F | defined $field_info{'_default'} ? : |
| 6006 | 100 | T | F | if ($modifiers =~ /:isa\(([^)]+)\)/) |
| 6053 | 100 | T | F | unless $field->{'is_param'} |
| 6062 | 50 | T | F | unless $p->{'_source'} |
| 6063 | 100 | T | F | if $field_name ne $param_name |
| 6065 | 100 | T | F | if ($field->{'_default'}) |
| 6070 | 100 | T | F | if ($field->{'isa'}) |
| 6115 | 100 | T | F | unless exists $params->{$param} |
| 6125 | 50 | T | F | unless exists $params->{$param} |
| 6135 | 50 | T | F | unless exists $params->{$param} |
| 6145 | 50 | T | F | unless exists $params->{$param} |
| 6155 | 50 | T | F | unless exists $params->{$param} |
| 6165 | 100 | T | F | unless exists $params->{$param} |
| 6190 | 0 | T | F | unless exists $params->{$param} |
| 6200 | 50 | T | F | unless exists $params->{$param} |
| 6211 | 100 | T | F | if (not keys %{$params;}) |
| 6218 | 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') { } |
| 6234 | 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') { } |
| 6249 | 0 | T | F | if ($var ne "class" or $position > 0 or $method->{'name'} ne "new") |
| 6277 | 100 | T | F | unless defined $default |
| 6278 | 100 | T | F | if ref $default |
| 6314 | 100 | T | F | if ($code =~ /(die|croak|confess)\b[^{;]*\bif\b[^{;]*\$$param\b/s) |
| 6319 | 100 | T | F | if ($code =~ /length\s*\(\s*\$$param\s*\)\s*([<>]=?)\s*(\d+)/) |
| 6322 | 100 | T | F | if ($op eq '<') { } |
| 50 | T | F | elsif ($op eq '<=') { } |
| 100 | T | F | elsif ($op eq '>') { } |
| 50 | T | F | elsif ($op eq '>=') { } |
| 6335 | 100 | T | F | if (not $guarded and $code =~ /\$$param\s*([<>]=?)\s*([+-]?(?:\d+\.?\d*|\.\d+))/) |
| 6340 | 0 | T | F | &looks_like_number($val) ? : |
| 6342 | 100 | T | F | if ($op eq '<' or $op eq '<=') { } |
| 50 | T | F | elsif ($op eq '>' or $op eq '>=') { } |
| 6344 | 50 | T | F | $op eq '<' ? : |
| 6345 | 50 | T | F | if not defined $p->{'max'} or $max < $p->{'max'} |
| 6347 | 100 | T | F | $op eq '>' ? : |
| 6348 | 50 | T | F | if not defined $p->{'min'} or $min > $p->{'min'} |
| 6353 | 100 | T | F | if ($code =~ m[\$$param\s*=~\s*((?:qr?/[^/]+/|\$[\w:]+|\$\{\w+\}))]) |
| 6358 | 50 | T | F | if ($pattern =~ m[^qr?/([^/]+)/$]) { } |
| 6399 | 100 | T | F | if ($code =~ /(?:die|croak|confess)\s+[^;]*unless\s+(?:defined\s+)?\$$param/s) |
| 6405 | 100 | T | F | if (defined $default_value and not exists $p->{'_default'}) |
| 6410 | 100 | T | F | unless ($p->{'type'}) |
| 6411 | 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) { } |
| 6412 | 50 | T | F | $default_value =~ /\./ ? : |
| 6424 | 50 | T | F | ref $default_value ? : |
| 6429 | 100 | T | F | if (not $default_value || exists $p->{'_default'} and $code =~ /\$$param\s*=\s*([^;{}]+?)(?:\s*[;}])/s) |
| 6432 | 50 | T | F | unless ($assignment =~ /\$$param/ or $assignment =~ /^shift/) |
| 6436 | 100 | T | F | if (defined $possible_default) |
| 6445 | 100 | T | F | if ($is_required) |
| 6447 | 100 | T | F | if exists $p->{'_default'} |
| 6499 | 100 | T | F | if $pod->{$param} and defined $pod->{$param}{'position'} |
| 6500 | 50 | T | F | if $sig->{$param} and defined $sig->{$param}{'position'} |
| 6501 | 100 | T | F | if $code->{$param} and defined $code->{$param}{'position'} |
| 6504 | 100 | T | F | if (@positions) |
| 6507 | 0 | T | F | unless $pos_count{$b} <=> $pos_count{$a} |
| 6508 | 50 | T | F | unless exists $p->{'position'} |
| 6512 | 100 | T | F | if ($pod->{$param}) |
| 6517 | 100 | T | F | if ($code->{$param}) |
| 6519 | 100 | T | F | if $key eq "_source" |
| 6520 | 100 | T | F | if $key eq "position" |
| 6524 | 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") |
| 6533 | 50 | T | F | if ($sig->{$param}) |
| 6535 | 0 | T | F | if $key eq "_source" |
| 6536 | 0 | T | F | if $key eq "position" |
| 6549 | 100 | T | F | if ($self->{'verbose'}) |
| 6555 | 50 | T | F | defined $p->{'optional'} ? : |
| 6586 | 100 | T | F | $pod_param ? : |
| 6587 | 100 | T | F | $code_param ? : |
| 6590 | 100 | T | F | if (defined $pod_optional) { } |
| 100 | T | F | elsif (defined $code_optional) { } |
| 100 | T | F | elsif (keys %$merged_param > 0) { } |
| 6640 | 100 | T | F | unless keys %$params |
| 6652 | 100 | T | F | if ($p->{'type'}) { } |
| 6653 | 100 | T | F | if ($p->{'type'} eq 'string' and $p->{'min'} || $p->{'max'} || $p->{'matches'}) { } |
| 100 | T | F | elsif ($p->{'type'} eq 'string') { } |
| 6668 | 100 | T | F | if (defined $p->{'min'}) |
| 6672 | 100 | T | F | if (defined $p->{'max'}) |
| 6676 | 100 | T | F | if (defined $p->{'optional'}) |
| 6680 | 100 | T | F | if ($p->{'matches'}) |
| 6684 | 100 | T | F | if ($p->{'isa'}) |
| 6690 | 100 | T | F | if (defined $p->{'position'}) |
| 6696 | 100 | T | F | if (exists $p->{'_default'}) |
| 6702 | 100 | T | F | if ($p->{'semantic'}) |
| 6716 | 50 | T | F | $count ? : |
| 6719 | 100 | T | F | $count == 1 ? : |
| 6725 | 50 | T | F | if (@sorted_params) |
| 6730 | 100 | T | F | if (@sorted_params > 1) |
| 6739 | 100 | T | F | if ($avg >= $CONFIDENCE_HIGH_THRESHOLD) { } |
| 100 | T | F | elsif ($avg >= $CONFIDENCE_MEDIUM_THRESHOLD) { } |
| 50 | T | F | elsif ($avg >= $CONFIDENCE_LOW_THRESHOLD) { } |
| 6788 | 100 | T | F | unless keys %$output |
| 6793 | 100 | T | F | if ($output->{'type'}) { } |
| 6801 | 100 | T | F | if (defined $output->{'value'}) |
| 6807 | 100 | T | F | if ($output->{'isa'}) |
| 6813 | 100 | T | F | if ($output->{'_context_aware'}) |
| 6817 | 50 | T | F | if ($output->{'_list_context'}) |
| 6820 | 100 | T | F | if ($output->{'_scalar_context'}) |
| 6826 | 100 | T | F | if ($output->{'_error_return'}) |
| 6832 | 100 | T | F | if ($output->{'_success_failure_pattern'}) |
| 6838 | 100 | T | F | if ($output->{'_returns_self'}) |
| 6844 | 100 | T | F | if ($output->{'_void_context'}) |
| 6850 | 100 | T | F | if ($output->{'_error_handling'} and $output->{'_error_handling'}{'exception_handling'}) |
| 6859 | 100 | T | F | if ($score >= $CONFIDENCE_HIGH_THRESHOLD) { } |
| 100 | T | F | elsif ($score >= $CONFIDENCE_MEDIUM_THRESHOLD) { } |
| 100 | T | F | elsif ($score >= $CONFIDENCE_LOW_THRESHOLD) { } |
| 6901 | 100 | T | F | unless $schema->{'_analysis'} |
| 6913 | 50 | T | F | if ($analysis->{'confidence_factors'}{'input'}) |
| 6924 | 50 | T | F | if ($analysis->{'confidence_factors'}{'output'}) |
| 6933 | 50 | T | F | if ($analysis->{'per_parameter_scores'}) |
| 6974 | 100 | T | F | unless ($p->{'type'}) |
| 6978 | 100 | T | F | unless (defined $p->{'optional'}) |
| 7020 | 100 | T | F | unless ref $p eq "HASH" |
| 7021 | 100 | T | F | unless ($p->{'type'}) |
| 7064 | 100 | T | F | if ($code =~ /my\s*\(\s*\$\w+\s*,\s*(.+?)\)\s*=\s*\@_/s) |
| 7069 | 100 | T | F | unless @param_names |
| 7117 | 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') { } |
| 50 | 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') { } |
| 7133 | 100 | T | F | unless ($seen{$sig}++) |
| 7169 | 100 | T | F | if $param1 eq $param2 |
| 7172 | 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/) |
| 7178 | 100 | T | F | if ($rel->{'type'} eq "mutually_exclusive" and ($rel->{'params'}[0] eq $param2 and $rel->{'params'}[1] eq $param1)) |
| 7185 | 100 | T | F | if $found_reverse |
| 7197 | 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) |
| 7202 | 50 | T | F | if ($rel->{'type'} eq "mutually_exclusive" and ($rel->{'params'}[0] eq $param2 and $rel->{'params'}[1] eq $param1)) |
| 7209 | 50 | T | F | if $found_reverse |
| 7253 | 100 | T | F | if $param1 eq $param2 |
| 7255 | 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/) |
| 7261 | 50 | T | F | if ($rel->{'type'} eq "required_group" and ($rel->{'params'}[0] eq $param2 and $rel->{'params'}[1] eq $param1)) |
| 7268 | 100 | T | F | if $found_reverse |
| 7281 | 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) |
| 7286 | 50 | T | F | if ($rel->{'type'} eq "required_group" and ($rel->{'params'}[0] eq $param2 and $rel->{'params'}[1] eq $param1)) |
| 7293 | 50 | T | F | if $found_reverse |
| 7338 | 100 | T | F | if $param1 eq $param2 |
| 7341 | 100 | T | F | if ($code =~ /(?:die|croak|confess)[^;]*if\s+\$$param1\s+&&\s+!\$$param2/) |
| 7353 | 50 | T | F | if ($code =~ /(?:die|croak|confess)[^;]*if\s+\$$param1\s+&&\s+!defined\s*\(\s*\$$param2\s*\)/) |
| 7365 | 100 | T | F | if ($code =~ /(?:die|croak|confess)\s+['"]\w*${param1}[^'"]*requires[^'"]*$param2/i) |
| 7408 | 100 | T | F | if $param1 eq $param2 |
| 7412 | 50 | T | F | if ($code =~ /(?:die|croak|confess)\s+['"]\w*${param1}[^'"]*requires[^'"]*$param2/i and $code =~ /if\s+\$param1\s+&&\s+!\$param2/) |
| 7457 | 100 | T | F | if $param1 eq $param2 |
| 7460 | 100 | T | F | if ($code =~ /(?:die|croak|confess)[^;]*if\s+\$$param1\s+&&\s+\$$param2\s*!=\s*(\d+)/) |
| 7475 | 50 | T | F | if ($code =~ /(?:die|croak|confess)[^;]*if\s+\$$param1\s+&&\s+\$$param2\s*<\s*(\d+)/) |
| 7490 | 100 | T | F | if ($code =~ /(?:die|croak|confess)[^;]*if\s+\$$param1\s+eq\s+['"]([^'"]+)['"]\s+&&\s+!\$$param2/) |
| 7520 | 50 | T | F | unless defined $self->{'output_dir'} |
| 7522 | 100 | T | F | unless -d $self->{'output_dir'} |
| 7531 | 50 | T | F | if ($self->{'_document'}) |
| 7533 | 100 | T | F | $package_stmt ? : |
| 7553 | 100 | T | F | if ($schema->{'input'}) |
| 7554 | 100 | T | F | if (scalar keys %{$$schema{'input'};}) { } |
| 7559 | 100 | T | F | if ($param->{'name'}) |
| 7561 | 50 | T | F | if ($name ne $param_name) |
| 7575 | 50 | T | F | if ($schema->{'output'} and scalar keys %{$$schema{"output"};}) |
| 7576 | 100 | T | F | if (ref $schema->{'output'}{'_error_handling'} eq "HASH" and scalar keys %{$$schema{"output"}{"_error_handling"};} == 0) |
| 7582 | 50 | T | F | if ($schema->{'output'}{'type'} and $schema->{'output'}{'type'} eq "scalar") |
| 7588 | 100 | T | F | if ($schema->{'new'}) |
| 7590 | 50 | T | F | if (ref $schema->{'new'} or $schema->{'new'} eq $package_name) { } |
| 7591 | 50 | T | F | $schema->{'new'} eq $package_name ? : |
| 7599 | 100 | T | F | unless (defined $schema->{'_confidence'}{'input'}{'level'}) |
| 7602 | 50 | T | F | unless (defined $schema->{'_confidence'}{'output'}{'level'}) |
| 7607 | 100 | T | F | if ($schema->{'relationships'} and @{$schema->{'relationships'};}) |
| 7611 | 50 | T | F | if ($schema->{'accessor'} and scalar keys %{$$schema{"accessor"};}) |
| 7621 | 100 | T | F | $schema->{'relationships'} ? : |
| 7623 | 100 | T | F | $schema->{'new'} ? : |
| 7662 | 100 | T | F | if ($schema->{'input'}) |
| 7667 | 100 | T | F | if ($p->{'semantic'}) |
| 7671 | 100 | T | F | if ($p->{'enum'}) |
| 7675 | 100 | T | F | if ($p->{'isa'}) |
| 7680 | 100 | T | F | if (@param_notes) |
| 7690 | 100 | T | F | if ($schema->{'relationships'} and @{$schema->{'relationships'};}) |
| 7702 | 100 | T | F | if ($schema->{'_notes'} and scalar @{$schema->{'_notes'};}) |
| 7710 | 100 | T | F | if ($schema->{'_analysis'}) |
| 7730 | 100 | T | F | if ($schema->{'input'}) |
| 7734 | 100 | T | F | if ($p->{'type'} and $p->{'type'} eq "coderef") |
| 7738 | 100 | T | F | if ($p->{'semantic'} and $p->{'semantic'} eq "filehandle") |
| 7742 | 100 | T | F | if ($p->{'isa'} and $p->{'isa'} =~ /DateTime/) |
| 7748 | 100 | T | F | if (@warnings) |
| 7795 | 100 | T | F | if defined $param->{$field} |
| 7799 | 100 | T | F | if (my $semantic = $param->{'semantic'}) |
| 7800 | 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') { } |
| 7843 | 50 | T | F | if ($param->{'enum'} and ref $param->{'enum'} eq "ARRAY") |
| 7851 | 100 | T | F | if ($param->{'enum'} and ref $param->{'enum'} eq "ARRAY") |
| 7854 | 50 | T | F | if ($param->{'memberof'} and ref $param->{'memberof'} eq "ARRAY") |
| 7859 | 100 | T | F | if ($param->{'isa'} and not $cleaned{'isa'}) |
| 7864 | 100 | T | F | if ($param->{'format'}) |
| 7895 | 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') { } |
| 7948 | 50 | T | F | unless $doc |
| 7952 | 100 | T | F | $package_stmt ? : |
| 7968 | 100 | T | F | if ($method_name eq "new") |
| 7972 | 50 | T | F | if ($method_name =~ /^(create|build|construct|init|DESTROY)$/i) |
| 7983 | 100 | T | F | if ($is_singleton) |
| 7995 | 100 | T | F | if ($is_instance_method and $is_instance_method->{'explicit_self'} || $is_instance_method->{'shift_self'} || $is_instance_method->{'accesses_object_data'}) |
| 8001 | 100 | T | F | if ($is_factory) |
| 8015 | 50 | T | F | if ($inheritance_info and $inheritance_info->{'use_parent_constructor'}) |
| 8027 | 100 | T | F | if ($constructor_needs) |
| 8041 | 50 | T | F | if ($needs_other_object) |
| 8045 | 0 | T | F | if $needs_other_object->{'package'} |
| 8051 | 0 | T | F | if $result->{'package'} |
| 8055 | 100 | T | F | if ($is_factory and not $skip_object) |
| 8061 | 50 | T | F | if $is_factory->{'returns_class'} |
| 8097 | 100 | T | F | if ($method_name =~ /^(create_|make_|build_|get_)/i) |
| 8102 | 50 | T | F | if ($method_body) |
| 8104 | 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) |
| 8109 | 100 | T | F | if ($class_name =~ /^\$(class|self|package)$/) { } |
| 50 | T | F | elsif ($class_name =~ /^\$/) { } |
| 8123 | 100 | T | F | if ($method_body =~ /return\s+([\$\w:]+)->new\(/s or $method_body =~ /([\$\w:]+)->new\(.*return/s) |
| 8128 | 50 | T | F | if ($target eq '$self' or $target eq 'shift' or $target =~ /^\$/) { } |
| 100 | T | F | elsif ($target =~ /::/) { } |
| 8144 | 50 | T | F | if ($method_body =~ /return\s+([\$\w:]+)->(create_|make_|build_|get_)/i or $method_body =~ /([\$\w:]+)->(create_|make_|build_|get_).*return/is) |
| 8153 | 100 | T | F | if ($method_info and ref $method_info eq "HASH" and $method_info->{'pod'}) |
| 8155 | 50 | T | F | if ($pod =~ /returns?\s+(?:an?\s+)?(object|instance|new\s+\w+)/i) |
| 8195 | 100 | T | F | unless $method_name =~ /^(instance|get_instance|singleton|shared_instance)$/i |
| 8202 | 50 | T | F | if ($method_body) |
| 8204 | 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) |
| 8211 | 100 | T | F | if ($method_body =~ /return\s+\$instance\s+if\s+(?:defined\s+)?\$instance/ or $method_body =~ /unless\s+\$instance.*?=\s*.*?new/) |
| 8218 | 100 | T | F | if ($method_body =~ /\$instance\s*\|\|=\s*.*?new/ or $method_body =~ /\$instance\s*=\s*.*?new\s+unless\s+(?:defined\s+)?\$instance/) |
| 8225 | 100 | T | F | if ($method_body =~ /return\s+\$instance;/) |
| 8227 | 50 | T | F | unless $singleton_info{'confidence'} |
| 8231 | 50 | T | F | if keys %singleton_info > 0 |
| 8266 | 100 | T | F | if ($method_body =~ /my\s*\(\s*\$self\s*[,)]/) { } |
| 100 | T | F | elsif ($method_body =~ /my\s+\$self\s*=\s*shift/) { } |
| 100 | T | F | elsif ($method_body =~ /\$self\s*->\s*(\w+|[\{\[])/) { } |
| 8285 | 100 | T | F | if ($method_body =~ /\$self\s*->\s*[\{\[]/) |
| 8287 | 100 | T | F | unless $instance_info{'confidence'} eq "high" |
| 8291 | 100 | T | F | if ($method_body =~ /\$self\s*->\s*(\w+)\s*\(/s) |
| 8296 | 50 | T | F | if @{$instance_info{'calls_instance_methods'};} |
| 8300 | 100 | T | F | if ($method_name =~ /^_/ and not $method_name =~ /^_new/) |
| 8303 | 50 | T | F | unless exists $instance_info{'confidence'} |
| 8306 | 100 | T | F | if keys %instance_info |
| 8339 | 50 | T | F | unless $doc |
| 8350 | 100 | T | F | if ($content =~ /use\s+(parent|base)\s+['"]?([\w:]+)['"]?/) |
| 8355 | 50 | T | F | if ($content =~ /use\s+(parent|base)\s+qw?[\(\[]?(.+?)[\)\]]?;/) |
| 8368 | 50 | T | F | if ($content =~ /(?:our\s+)?\@ISA\s*=\s*qw?[\(\[]?(.+?)[\)\]]?/) |
| 8380 | 100 | T | F | if ($content =~ /\@ISA\s*=\s*qw?[\(\[]?(.+?)[\)\]]?/) |
| 8389 | 100 | T | F | if ($method_body and $method_body =~ /SUPER::/) |
| 8391 | 50 | T | F | if ($method_body =~ /SUPER::new/) |
| 8398 | 100 | T | F | if $_[1]->isa("PPI::Statement::Sub") |
| 8402 | 100 | T | F | if ($has_own_new) { } |
| 50 | T | F | elsif (@parent_classes) { } |
| 8410 | 100 | T | F | if keys %inheritance_info |
| 8444 | 50 | T | F | unless $doc |
| 8448 | 50 | T | F | if ($target_package ne $current_package) |
| 8458 | 100 | T | F | if $_[1]->isa("PPI::Statement::Sub") |
| 8462 | 100 | T | F | unless $new_method |
| 8470 | 100 | T | F | if ($body =~ /my\s*\(\s*\$(self|class)\s*,\s*(.+?)\)\s*=\s*\@_/s) |
| 8474 | 100 | T | F | if (@param_names) |
| 8488 | 50 | T | F | if (@shift_params) |
| 8496 | 100 | T | F | if ($body =~ /croak.*unless.*(?:defined\s+)?\$(\w+)/g) |
| 8499 | 100 | T | F | if ($body =~ /die.*unless.*(?:defined\s+)?\$(\w+)/g) |
| 8503 | 100 | T | F | if (@required_params) |
| 8513 | 100 | T | F | if ($requirements{'parameters'}) |
| 8516 | 100 | T | F | if (defined $default) |
| 8523 | 100 | T | F | if (@optional_params) |
| 8528 | 100 | T | F | if keys %requirements |
| 8559 | 50 | T | F | unless $method_body |
| 8568 | 100 | T | F | if $class eq "main" or $class eq "__PACKAGE__" or $class =~ /^\$/ |
| 8572 | 100 | T | F | if ($dependency_info{'creates_objects'}) |
| 8580 | 100 | T | F | if ($method_body =~ /\$(\w+)->\w+\(/g) |
| 8590 | 50 | T | F | if ($method_body =~ /my\s+\$$var\s*=\s*(\w+(?:::\w+)+)->(?:new|create)/) { } |
| 0 | T | F | elsif ($method_body =~ /my\s+\$$var\s*=\s*(\w+(?:::\w+)+)->/) { } |
| 8597 | 50 | T | F | if (@object_classes) |
| 8599 | 50 | T | F | unless $dependency_info{'package'} |
| 8606 | 100 | T | F | if keys %dependency_info |
| 8629 | 50 | T | F | unless $doc |
| 8633 | 50 | T | F | if $_[1]->isa("PPI::Statement::Include") and $_[1]->type eq "use" and $_[1]->module =~ /^(parent|base)$/ |
| 8638 | 50 | T | F | if ($parent_stmt) |
| 8645 | 100 | T | F | if $_[1]->isa("PPI::Statement") |
| 8648 | 50 | T | F | if ($isa_stmt and $isa_stmt->content =~ /['"](\w+(?:::\w+)*)['"]/) |
| 8682 | 100 | T | F | unless $package_stmt |
| 8688 | 100 | T | F | if $_[1]->isa("PPI::Statement::Sub") |
| 8691 | 50 | T | F | if ($has_new) |
| 8697 | 0 | T | F | if $parent |
| 8733 | 50 | T | F | unless $param and $code |
| 8743 | 100 | T | F | if ($clean_code =~ /\$$param\s*=\s*(?:\$$param|\$[a-zA-Z_]\w*)\s*\|\|\s*([^;]+)/) |
| 8747 | 50 | T | F | if defined $default |
| 8751 | 100 | T | F | if ($clean_code =~ m[\$$param\s*//=\s*([^;]+)]) |
| 8755 | 100 | T | F | if defined $default |
| 8760 | 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*([^;]+)/) |
| 8764 | 50 | T | F | if defined $default |
| 8768 | 100 | T | F | if ($clean_code =~ /\$$param\s*=\s*([^;]+?)\s+unless\s+defined\s+(?:\$$param|\$[a-zA-Z_]\w*)/) |
| 8771 | 50 | T | F | if defined $default |
| 8775 | 100 | T | F | if ($clean_code =~ /\$$param\s*\|\|=\s*([^;]+)/) |
| 8779 | 50 | T | F | if defined $default |
| 8783 | 100 | T | F | if ($clean_code =~ m[\$$param\s*=\s*(?:\$$param|\$[a-zA-Z_]\w*)\s*//\s*([^;]+)]) |
| 8787 | 100 | T | F | if defined $default |
| 8791 | 100 | T | F | if ($clean_code =~ /if\s*\(\s*!defined\s+\$$param\s*\)\s*\{[^}]*\$$param\s*=\s*([^;]+)/s) |
| 8795 | 50 | T | F | if defined $default |
| 8799 | 100 | T | F | if ($clean_code =~ /unless\s*\(\s*defined\s+\$$param\s*\)\s*\{[^}]*\$$param\s*=\s*([^;]+)/s) |
| 8803 | 50 | T | F | if defined $default |
| 8840 | 100 | T | F | unless $code |
| 8847 | 100 | T | F | unless @{$hints{$k};} |
| 8874 | 100 | T | F | if ($code =~ /defined\s*\(\s*\$/) |
| 8879 | 100 | T | F | if ($code =~ /\beq\s*''/ or $code =~ /\blength\s*\(/) |
| 8884 | 100 | T | F | if ($code =~ /\$\w+\s*<\s*0/) |
| 8912 | 100 | T | F | if ($op eq '<') { } |
| 100 | T | F | elsif ($op eq '<=') { } |
| 100 | T | F | elsif ($op eq '>') { } |
| 50 | T | F | elsif ($op eq '>=') { } |
| 8949 | 100 | T | F | unless $pod |
| 8954 | 100 | T | F | unless $pod =~ /=head2\s+SYNOPSIS\s*(.+?)(?=\n=head|\z)/s |
| 8964 | 50 | T | F | defined $3 ? : |
| 100 | T | F | defined $2 ? : |
| 8968 | 100 | T | F | if %kv |
| 8976 | 100 | T | F | unless (scalar @examples) |
| 8985 | 50 | T | F | unless @args |
| 8996 | 50 | T | F | if (scalar @examples) |
| 9041 | 100 | T | F | unless defined $value |
| 9051 | 100 | T | F | if ($value =~ m[\|\||/{2}]) |
| 9061 | 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) { } |
| 9070 | 100 | T | F | if ($value =~ /^(['"])(.*)\1$/s) |
| 9073 | 100 | T | F | if ($from_code) |
| 9084 | 100 | T | F | unless ($from_code) |
| 9093 | 100 | T | F | unless ($value =~ /^\(/) |
| 9098 | 100 | T | F | if ($value =~ /^\{\s*\}$/) |
| 9103 | 100 | T | F | if ($value =~ /^\[\s*\]$/) |
| 9108 | 100 | T | F | if ($value =~ /^-?\d+(?:\.\d+)?$/) |
| 9109 | 100 | T | F | if ($value =~ /\./) { } |
| 9117 | 100 | T | F | if ($value =~ /^(true|false)$/i) |
| 9118 | 100 | T | F | lc $1 eq 'true' ? : |
| 9122 | 50 | T | F | if ($value eq '1') { } |
| 50 | T | F | elsif ($value eq '0') { } |
| 9129 | 100 | T | F | if ($value eq "undef") |
| 9134 | 100 | T | F | if ($value eq "__PACKAGE__") |
| 9142 | 100 | T | F | if ($value =~ /^\$[a-zA-Z_]/ or $value =~ /\(.*\)/) |
| 9143 | 100 | T | F | if $value =~ /^\$|\@|\%/ |
| 9193 | 100 | T | F | if (exists $pod_params->{$param} and not exists $code_params->{$param}) |
| 9198 | 50 | T | F | if (not exists $pod_params->{$param} and exists $code_params->{$param}) |
| 9199 | 100 | T | F | if ($method_name eq "new" and $param eq "class") |
| 9203 | 100 | T | F | if ($method_name ne "new" and $param eq "self") |
| 9212 | 100 | T | F | if ($pod->{'type'} and $code->{'type'} and $pod->{'type'} ne $code->{'type'}) |
| 9213 | 100 | T | F | if (not $self->_types_are_compatible($pod->{'type'}, $code->{'type'})) { } |
| 9221 | 50 | T | F | if (exists $pod->{'optional'} and exists $code->{'optional'} and $pod->{'optional'} != $code->{'optional'}) |
| 9223 | 0 | T | F | $pod->{'optional'} ? : |
| 9224 | 0 | T | F | $code->{'optional'} ? : |
| 9229 | 0 | T | F | if (defined $pod->{'min'} and defined $code->{'min'} and $pod->{'min'} != $code->{'min'}) |
| 9233 | 0 | T | F | if (defined $pod->{'max'} and defined $code->{'max'} and $pod->{'max'} != $code->{'max'}) |
| 9238 | 0 | T | F | if ($pod->{'matches'} and $code->{'matches'} and $pod->{'matches'} ne $code->{'matches'}) |
| 9267 | 100 | T | F | unless defined $val |
| 9270 | 100 | T | F | if $val =~ /^(0|off|none)$/i |
| 9271 | 100 | T | F | if $val =~ /^(1|warn|warning)$/i |
| 9272 | 100 | T | F | if $val =~ /^(2|fatal|die|error)$/i |
| 9298 | 100 | T | F | if $pod_type eq $code_type |
| 9311 | 100 | T | F | if (my $allowed = $compatible_types{$pod_type}) |
| 9316 | 50 | T | F | if (my $allowed = $compatible_types{$code_type}) |
| 9381 | 100 | T | F | if (my $errors = $schema->{'_pod_validation_errors'}) |
| 9383 | 50 | T | F | $schema->{'_pod_disagreement'} ? : |
| 9390 | 100 | T | F | if (@reports) { } |
| 9406 | 100 | T | F | if $self->{'verbose'} |