blib/lib/Attribute/Benchmark.pm

filter: Statementstmt 90.0% 27 / 30 Branchbran 33.3% 2 / 6 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 88.8% 8 / 9 Podpod 0.0% 0 / 1 totaltotal 80.4% 37 / 46 CC 4 SCAR 7.9
CC
4
Cov
81%
Benchmark
6.0
END
2.1
import
2.0
CRAP 2.2
↑ Summary
1 1 ▶use 5.008;
Subroutine BEGIN: called CC=1 SCAR=0.0
2 1 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
3 1 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
4  
5 package Attribute::Benchmark;
6  
7 1 ▶use Attribute::Handlers ();
Subroutine BEGIN: called CC=1 SCAR=0.0
8 1 ▶use Benchmark ();
Subroutine BEGIN: called CC=1 SCAR=0.0
9  
10 1 our $AUTHORITY = 'cpan:TOBYINK';
11 1 our $VERSION = '0.001';
12  
13 1 my %cmp = ();
14 1 my $iter = -3;
15 1 ▶END { Benchmark::cmpthese($iter, \%cmp) if keys %cmp };
Subroutine END: called CC=2 SCAR=7.6
Branch: 1 branch
BranchTrueFalseTotal
if keys %cmp 0 1 1
16  
17 sub import
18 1 ▶{
Subroutine import: called CC=2 SCAR=7.0
19 1 shift;
20 1 ▶ $iter = $_[0] if @_;
Branch: 1 branch
BranchTrueFalseTotal
if @_ 0 1 1
21 1 strict->import;
22 1 warnings->import(FATAL => 'all');
23 }
24  
25 0 ▶sub UNIVERSAL::Benchmark :ATTR()
Subroutine Benchmark: not called CC=2 SCAR=17.9
Pod undocumented
26 {
27 0 ▶ (my $name = $_[4] ? $_[4][0] : substr(*{$_[1]}, 1))
Branch: 1 branch
BranchTrueFalseTotal
$_[4] ? : 0 0 0
28 =~ s/\Amain:://;
29 0 $cmp{$name} = $_[2];
30 1 ▶}
Subroutine BEGIN: called CC=1 SCAR=0.0
31  
32 1 1;
33  
34 __END__
↑ Summary