File Coverage

blib/lib/Char/Replace.pm
Criterion Covered Total %
statement 12 12 100.0
branch n/a
condition n/a
subroutine 4 4 100.0
pod 1 1 100.0
total 17 17 100.0


line stmt bran cond sub pod time code
1             # Copyright (c) 2018, cPanel, LLC.
2             # All rights reserved.
3             # http://cpanel.net
4             #
5             # This is free software; you can redistribute it and/or modify it under the
6             # same terms as Perl itself. See L.
7              
8             package Char::Replace;
9              
10 2     2   216313 use strict;
  2         13  
  2         57  
11 2     2   10 use warnings;
  2         5  
  2         104  
12              
13             # ABSTRACT: Perl naive XS character replacement as an alternate to substitute or transliterate
14              
15              
16             BEGIN {
17              
18 2     2   7 our $VERSION = '0.002'; # VERSION: generated by DZP::OurPkgVersion
19              
20 2         9 require XSLoader;
21 2         1032 XSLoader::load(__PACKAGE__);
22             }
23              
24             sub identity_map {
25 1     1 1 10973 my $MAP = [];
26 1         114 $MAP->[ $_ ] = chr($_) for 0..255;
27 1         68 return $MAP;
28             }
29              
30             1;
31              
32             __END__