blib/lib/Regexp/Match/Any.pm

filter: Statementstmt 100% 19 / 19 Branchbran n/a Conditioncond 100% 2 / 2 MC/DCmcdc 100% 1 / 1 Subroutinesub 100% 4 / 4 Podpod 0.0% 0 / 1 totaltotal 96.3% 26 / 27 CC 2 SCAR 3.4
CC
2
Cov
100%
match_any
2.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.4
↑ Summary
1 package Regexp::Match::Any;
2  
3 1 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 1 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
5  
6 1 require Exporter;
7 1 ▶use vars qw($VERSION @ISA @EXPORT @EXPORT_OK);
Subroutine BEGIN: called CC=1 SCAR=0.0
8  
9 1 $Regexp::Match::Any::VERSION = 0.03;
10 1 @ISA = qw(Exporter);
11 1 @EXPORT = qw(&match_any);
12 1 @EXPORT_OK = qw(&match_any);
13  
14 4 ▶sub match_any {
Subroutine match_any: called CC=2 SCAR=6.9
Pod undocumented
15 4 my $ref = shift;
16 4 ▶ my $opt = shift || '';
Condition100%2/2
shift() || ''
l!l
22
MC/DC100%1/1
shift() || ''
shift()
Truth table100%2/2
A
A= shift()
Aresult
11
00
17 4 my $regex = join('|', @{$ref});
18 4 return qq{(?$opt:$regex)};
19 }
20 __END__
↑ Summary