Jacode.pm

filter: Statementstmt 97.5% 40 / 41 Branchbran 70.0% 7 / 10 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 88.8% 8 / 9 Podpod n/a totaltotal 91.6% 55 / 60 CC 6 SCAR 7.7
CC
6
Cov
92%
__ANON__
4.0
BEGIN
2.0
AUTOLOAD
2.0
CRAP 2.2
« jacode.pl ↑ Summary
1 package Jacode;
2 ######################################################################
3 #
4 # Jacode - Perl program for Japanese character code conversion
5 #
6 # https://metacpan.org/dist/Jacode
7 #
8 # Copyright (c) 2018, 2019, 2020, 2022, 2023, 2026 INABA Hitoshi <ina.cpan@gmail.com> in a CPAN
9 ######################################################################
10  
11 459 $VERSION = '2.13.4.35';
12 459 $VERSION = $VERSION;
13  
14 459 ▶use 5.00503;
Subroutine BEGIN: called CC=1 SCAR=0.0
15 459 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
16 459 ▶BEGIN { $INC{'warnings.pm'} = '' if $] < 5.006 }; use warnings; local $^W=1;
Subroutine BEGIN: called CC=2 SCAR=7.0
Subroutine BEGIN: called CC=1 SCAR=0.0
Branch: 1 branch
BranchTrueFalseTotal
if $] < "5.006" 0 459 459
17 459 ▶use vars qw($AUTOLOAD);
Subroutine BEGIN: called CC=1 SCAR=0.0
18  
19 460 ▶sub AUTOLOAD {
Subroutine AUTOLOAD: called CC=2 SCAR=6.9
20 460 ▶ return if $AUTOLOAD =~ /::DESTROY$/;
Branch: 1 branch
BranchTrueFalseTotal
if $Jacode::AUTOLOAD =~ /::DESTROY$/ 0 460 460
21  
22 460 require File::Basename;
23 460 require "@{[File::Basename::dirname(__FILE__)]}/\L@{[__PACKAGE__]}\E.pl";
24 460 (my $callee = $AUTOLOAD) =~ s<^@{[__PACKAGE__]}::><\L@{[__PACKAGE__]}\E::>;
25  
26 459 ▶ no strict qw(refs);
Subroutine BEGIN: called CC=1 SCAR=0.0
27 460 ▶ *{$AUTOLOAD} = sub {
Subroutine __ANON__: called CC=4 SCAR=13.9
28 420081 require Carp;
29 420081 local $@;
30 420081 my @return = ();
31 420081 ▶ if (wantarray) {
Branch: 1 branch
BranchTrueFalseTotal
if (wantarray) { } 5 420076 420081
32 5 @return = eval {
33 5 &$callee;
34 };
35 }
36 else {
37 420076 $return[0] = eval {
38 420076 &$callee;
39 };
40 }
41 420081 ▶ if ($@) {
Branch: 1 branch
BranchTrueFalseTotal
if ($@) 0 420081 420081
42 0 Carp::croak($@);
43 }
44 420081 ▶ return wantarray ? @return : $return[0];
Branch: 1 branch
BranchTrueFalseTotal
wantarray ? : 5 420076 420081
45 460 };
46  
47 460 goto &$AUTOLOAD;
48 }
49  
50 0 ▶sub DESTROY { }
Subroutine DESTROY: not called CC=1 SCAR=0.0
51  
52 459 1;
53  
54 __END__
« jacode.pl ↑ Summary