lib/Template/Stash/XS.pm

filter: Statementstmt 76.9% 20 / 26 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 85.7% 6 / 7 Podpod n/a totaltotal 78.7% 26 / 33 CC 1 SCAR 1.3
CC
1
Cov
77%
AUTOLOAD
2.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.1
« lib/Template/Plugin/View.pm ↑ Summary blib/lib/Template/Toolkit.pm »
1 #============================================================= -*-Perl-*-
2 #
3 # Template::Stash::XS
4 #
5 # DESCRIPTION
6 #
7 # Perl bootstrap for XS module. Inherits methods from
8 # Template::Stash when not implemented in the XS module.
9 #
10 #========================================================================
11  
12 package Template::Stash::XS;
13  
14 100 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
15 100 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
16 100 ▶use Template;
Subroutine BEGIN: called CC=1 SCAR=0.0
17 100 ▶use Template::Stash;
Subroutine BEGIN: called CC=1 SCAR=0.0
18 100 ▶use XSLoader;
Subroutine BEGIN: called CC=1 SCAR=0.0
19  
20 100 our $AUTOLOAD;
21  
22 100 our @ISA = qw( Template::Stash );
23  
24 100 XSLoader::load 'Template::Stash::XS', $Template::VERSION;
25  
26 1760 ▶sub DESTROY {
Subroutine DESTROY: called CC=1 SCAR=0.0
27 # no op
28 1760 1;
29 }
30  
31 # catch missing method calls here so perl doesn't barf
32 # trying to load *.al files
33  
34 0 ▶sub AUTOLOAD {
Subroutine AUTOLOAD: not called CC=1 SCAR=6.9
35 0 my ($self, @args) = @_;
36 0 my @c = caller(0);
37 0 my $auto = $AUTOLOAD;
38  
39 0 $auto =~ s/.*:://;
40 0 $self =~ s/=.*//;
41  
42 0 die "Can't locate object method \"$auto\"" .
43 " via package \"$self\" at $c[1] line $c[2]\n";
44 }
45  
46 100 1;
47  
48 __END__
« lib/Template/Plugin/View.pm ↑ Summary blib/lib/Template/Toolkit.pm »