lib/TUI/toolkit/UO/Base.pm

filter: Statementstmt 100% 35 / 35 Branchbran 62.5% 5 / 8 Conditioncond 33.3% 1 / 3 MC/DCmcdc 0.0% 0 / 2 Subroutinesub 100% 10 / 10 Podpod n/a totaltotal 87.9% 51 / 58 CC 6 SCAR 7.5
CC
6
Cov
89%
DESTROY
4.0
BEGIN
2.1
BEGIN
2.1
CRAP 2.1
« lib/TUI/ColorSel/MonoSelector.pm ↑ Summary lib/TUI/toolkit/boolean.pm »
1 package TUI::toolkit::UO::Base;
2 # ABSTRACT: Derived UNIVERSAL::Object class for TUI::toolkit
3
4 115 ▶use 5.008;
Subroutine BEGIN: called CC=1 SCAR=0.0
5 115 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
6 115 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
7
8 115 our $VERSION = '0.02';
9 115 our $AUTHORITY = 'cpan:BRICKPOOL';
10
11 115 ▶use Hash::Util ();
Subroutine BEGIN: called CC=1 SCAR=0.0
12 115 ▶use UNIVERSAL::Object;
Subroutine BEGIN: called CC=1 SCAR=0.0
13
14 115 ▶BEGIN { require Devel::GlobalDestruction unless $] >= 5.014 }
Subroutine BEGIN: called CC=2 SCAR=7.6
Branch: 1 branch
BranchTrueFalseTotal
unless $] >= "5.014" 0 115 115
15 115 ▶BEGIN { $] >= 5.010 ? require mro : require MRO::Compat }
Subroutine BEGIN: called CC=2 SCAR=7.6
Branch: 1 branch
BranchTrueFalseTotal
$] >= 5.01 ? : 115 0 115
16
17 115 our @ISA;
18 115 ▶BEGIN { @ISA = ( 'UNIVERSAL::Object' ) }
Subroutine BEGIN: called CC=1 SCAR=0.0
19
20 54 ▶sub DESTROY {
Subroutine DESTROY: called CC=4 SCAR=14.0
21 54 my $self = shift;
22 54 ▶ my $class = ref $self || $self;
Condition33%1/3
ref $self || $self
l!l&&r!l&&!r
5400
MC/DC0%0/2
ref $self || $self
ref $self $self
Truth table33%1/3
A || B
A= ref $selfB= $self
ABresult
1X1
011
000
23
24 54 Hash::Util::unlock_keys( %$self );
25
26 54 ▶ my $in_global_destruction = defined ${^GLOBAL_PHASE}
Branch: 1 branch
BranchTrueFalseTotal
defined ${^GLOBAL_PHASE} ? : 54 0 54
27 ? ${^GLOBAL_PHASE} eq 'DESTRUCT'
28 : Devel::GlobalDestruction::in_global_destruction();
29
30 # Call all DEMOLISH methods starting with the derived classes.
31 DEMOLISHALL: {
32 115 ▶ no strict 'refs';
Subroutine BEGIN: called CC=1 SCAR=0.0
33 map {
34 223 my $demolish = *{ $_ . '::DEMOLISH' }{CODE};
35 223 ▶ $demolish->( $self, $in_global_destruction ) if $demolish;
Branch: 1 branch
BranchTrueFalseTotal
if $demolish 33 190 223
36 54 } @{ mro::get_linear_isa( $class ) };
37 }
38 54 return;
39 }
40
41 115 1
42
43 __END__
« lib/TUI/ColorSel/MonoSelector.pm ↑ Summary lib/TUI/toolkit/boolean.pm »