blib/lib/ExtUtils/XSpp/Exception/simple.pm

filter: Statementstmt 100% 19 / 19 Branchbran 50.0% 1 / 2 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 5 / 5 Podpod 50.0% 1 / 2 totaltotal 92.8% 26 / 28 CC 2 SCAR 2.9
CC
2
Cov
95%
handler_code
2.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.3
« blib/lib/ExtUtils/XSpp/Exception/unknown.pm ↑ Summary blib/lib/ExtUtils/XSpp/Exception/stdmessage.pm »
1 package ExtUtils::XSpp::Exception::simple;
2 21 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
3 21 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
4  
5 21 ▶use base 'ExtUtils::XSpp::Exception';
Subroutine BEGIN: called CC=1 SCAR=0.0
6  
7 2 ▶sub init {
Subroutine init: called CC=1 SCAR=0.0
Pod undocumented
8 2 my $this = shift;
9 2 $this->SUPER::init(@_);
10 }
11  
12 4 ▶sub handler_code {
Subroutine handler_code: called CC=2 SCAR=7.0
Pod documented
13 4 my $this = shift;
14 4 my $no_spaces_indent = shift;
15 4 ▶ $no_spaces_indent = 4 if not defined $no_spaces_indent;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $no_spaces_indent 4 0 4
16  
17 4 my $ctype = $this->cpp_type;
18 4 my $msg = "Caught C++ exception of type '$ctype'";
19 4 my $code = <<HERE;
20 catch ($ctype& e) {
21 croak("$msg");
22 }
23 HERE
24 4 return $this->indent_code($code, $no_spaces_indent);
25 }
26  
27 21 1;
« blib/lib/ExtUtils/XSpp/Exception/unknown.pm ↑ Summary blib/lib/ExtUtils/XSpp/Exception/stdmessage.pm »