Commit | Line | Data |
df1df145 |
1 | package Encode::Internal; |
2 | use strict; |
3 | our $VERSION = do {my @r=(q$Revision: 0.30 $ =~ /\d+/g); sprintf "%d."."%02d" x $#r, @r}; |
4 | use base 'Encode::Encoding'; |
5 | |
6 | # Dummy package that provides the encode interface but leaves data |
7 | # as UTF-X encoded. It is here so that from_to() works. |
8 | |
9 | __PACKAGE__->Define('Internal'); |
10 | |
11 | Encode::define_alias( 'Unicode' => 'Internal' ) if ord('A') == 65; |
12 | |
13 | sub decode |
14 | { |
15 | my ($obj,$str,$chk) = @_; |
16 | utf8::upgrade($str); |
17 | $_[1] = '' if $chk; |
18 | return $str; |
19 | } |
20 | |
21 | *encode = \&decode; |
22 | 1; |
23 | __END__ |