Review/Types.pm

filter: Statementstmt 100% 22 / 22 Branchbran 50.0% 1 / 2 Conditioncond 33.3% 1 / 3 MC/DCmcdc 0.0% 0 / 2 Subroutinesub 100% 7 / 7 Podpod n/a totaltotal 86.1% 31 / 36 CC 3 SCAR 6.5
CC
3
Cov
89%
__ANON__
3.7
__ANON__
1.0
BEGIN
1.0
CRAP 1.9
« Review/Issue.pm ↑ Summary
1 package Claude::Agent::Code::Review::Types;
2  
3 7 ▶use 5.020;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 7 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
5 7 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
6  
7 7 ▶use Object::Proto ();
Subroutine BEGIN: called CC=1 SCAR=0.0
8  
9 7 our (@SEVERITIES, @CATEGORIES);
10  
11 7 ▶BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.1
12 7 @SEVERITIES = qw(critical high medium low info);
13 7 @CATEGORIES = qw(bugs security style performance maintainability);
14  
15 14 ▶ my $enum = sub {
Subroutine __ANON__: called CC=1 SCAR=0.4
16 14 my %ok = map { $_ => 1 } @_;
17 14 ▶ return sub { defined $_[0] && !ref $_[0] && $ok{$_[0]} };
Subroutine __ANON__: called CC=3 SCAR=13.1
Branch: 1 branch
BranchTrueFalseTotal
defined $_[0] and not ref $_[0] and $ok{$_[0]} 160 0 160
Condition33%1/3
defined $_[0] and not ref $_[0]
!ll&&!rl&&r
00160
MC/DC0%0/2
defined $_[0] and not ref $_[0]
defined $_[0] not ref $_[0]
Truth table33%1/3
A and not(B)
A= defined $_[0]B= not ref $_[0]
ABresult
0X0
100
111
18 7 };
19  
20 7 Object::Proto::register_type('ReviewSeverity', $enum->(@SEVERITIES));
21 7 Object::Proto::register_type('ReviewCategory', $enum->(@CATEGORIES));
22 }
23  
24 7 1;
25  
26 __END__
« Review/Issue.pm ↑ Summary