blib/lib/Regexp/Storable.pm

filter: Statementstmt 28.5% 2 / 7 Branchbran 0.0% 0 / 2 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 0.0% 0 / 2 Podpod n/a totaltotal 18.1% 2 / 11 CC 2 SCAR 15.4
CC
2
Cov
22%
STORABLE_thaw
6.0
STORABLE_freeze
2.0
CRAP 4.7
↑ Summary blib/lib/Regexp/Copy.pm »
1 package Regexp::Storable;
2  
3 1 our $VERSION = '0.06';
4  
5 package Regexp;
6  
7  
8 0 ▶sub STORABLE_freeze {
Subroutine STORABLE_freeze: not called CC=1 SCAR=6.9
9 0 my $serialized = substr($_[0], rindex($_[0],':')+1, -1);
10 0 return $serialized;
11 }
12  
13 0 ▶sub STORABLE_thaw {
Subroutine STORABLE_thaw: not called CC=2 SCAR=17.9
14 0 my ( $original, $cloning, $thaw ) = @_;
15 0 ▶ my $final = ($thaw) ? qr/$thaw/ : qr//;
Branch: 1 branch
BranchTrueFalseTotal
$thaw ? : 0 0 0
16 0 Regexp::Copy::re_copy($final, $original);
17 }
18  
19 1 1;
↑ Summary blib/lib/Regexp/Copy.pm »