File Coverage

blib/lib/XML/SAX/PurePerl/UnicodeExt.pm
Criterion Covered Total %
statement 7 7 100.0
branch n/a
condition n/a
subroutine 3 3 100.0
pod 0 1 0.0
total 10 11 90.9


line stmt bran cond sub pod time code
1             # $Id$
2              
3             package XML::SAX::PurePerl;
4 14     14   94 use strict;
  14         22  
  14         425  
5              
6 14     14   69 no warnings 'utf8';
  14         30  
  14         1337  
7              
8             sub chr_ref {
9 2     2 0 10 return chr(shift);
10             }
11              
12             if ($] >= 5.007002) {
13             require Encode;
14            
15             Encode::define_alias( "UTF-16" => "UCS-2" );
16             Encode::define_alias( "UTF-16BE" => "UCS-2" );
17             Encode::define_alias( "UTF-16LE" => "ucs-2le" );
18             Encode::define_alias( "UTF16LE" => "ucs-2le" );
19             }
20              
21             1;
22