blib/lib/ShiftJIS/X0213/MapUTF/Supplements.pm

filter: Statementstmt 100% 18 / 18 Branchbran 100% 4 / 4 Conditioncond 66.6% 4 / 6 MC/DCmcdc 50.0% 2 / 4 Subroutinesub 100% 5 / 5 Podpod 100% 2 / 2 totaltotal 89.7% 35 / 39 CC 5 SCAR 8.6
CC
5
Cov
93%
to_sjis0213_supplements
3.0
to_sjis2004_supplements
3.0
BEGIN
1.0
CRAP 2.4
↑ Summary tosj0213.h »
1 package ShiftJIS::X0213::MapUTF::Supplements;
2  
3 2 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 2 ▶use vars qw($VERSION @ISA @EXPORT @EXPORT_OK);
Subroutine BEGIN: called CC=1 SCAR=0.0
5 2 ▶use vars qw(%Supplements);
Subroutine BEGIN: called CC=1 SCAR=0.0
6  
7 2 require Exporter;
8 2 @ISA = qw(Exporter);
9  
10 2 @EXPORT = qw(to_sjis0213_supplements to_sjis2004_supplements);
11 2 @EXPORT_OK = qw(%Supplements);
12  
13 2 $VERSION = '0.40';
14  
15 2 %Supplements = (
16 0x00B5, # MICRO SIGN (ISO/IEC 8859-1 11/05)
17 "\x83\xCA", # GREEK SMALL LETTER MU (U+03BC)
18  
19 0x0110, # LATIN CAPITAL LETTER D WITH STROKE (ISO/IEC 8859-2 13/00)
20 "\x85\x66", # LATIN CAPITAL LETTER ETH (U+00D0)
21  
22 0x2015, # HORIZONTAL BAR
23 "\x81\x5C", # EM DASH (U+2014)
24  
25 0x2211, # N-ARY SUMMATION (Windows CP932 0x8794)
26 "\x83\xB0", # GREEK CAPITAL LETTER SIGMA (U+03A3)
27  
28 0x2985, # LEFT WHITE PARENTHESIS
29 "\x81\xD4", # FULLWIDTH LEFT WHITE PARENTHESIS (U+FF5F)
30  
31 0x2986, # RIGHT WHITE PARENTHESIS
32 "\x81\xD5", # FULLWIDTH RIGHT WHITE PARENTHESIS (U+FF60)
33  
34 0x3099, # COMBINING KATAKANA-HIRAGANA VOICED SOUND MARK
35 "\xDE", # HALFWIDTH KATAKANA VOICED SOUND MARK (U+FF9E) // NFKC
36  
37 0x309A, # COMBINING KATAKANA-HIRAGANA SEMI-VOICED SOUND MARK
38 "\xDF", # HALFWIDTH KATAKANA SEMI-VOICED SOUND MARK (U+FF9F) // NFKC
39  
40 0x4E44, # CJK UNIFIED IDEOGRAPH-4E44 (JIS X 0212 16-17)
41 "\x81\x59", # IDEOGRAPHIC CLOSING MARK (U+3006)
42  
43 0x9B1C, # CJK UNIFIED IDEOGRAPH-9B1C (for backward compatibility)
44 "\xFC\x5A", # CJK UNIFIED IDEOGRAPH-9B1C
45  
46 0x9B1D, # CJK UNIFIED IDEOGRAPH-9B1D (JIS X 0213:2000)
47 "\xFC\x5A", # CJK UNIFIED IDEOGRAPH-9B1C
48  
49 0xFF3C, # FULLWIDTH REVERSE SOLIDUS
50 "\x81\x5F", # REVERSE SOLIDUS (U+005C)
51  
52 0xFF5E, # FULLWIDTH TILDE
53 "\x81\xB0", # TILDE (U+007E)
54  
55 0xFFE0, # FULLWIDTH CENT SIGN
56 "\x81\x91", # CENT SIGN (U+00A2)
57  
58 0xFFE1, # FULLWIDTH POUND SIGN
59 "\x81\x92", # POUND SIGN (U+00A3)
60  
61 0xFFE2, # FULLWIDTH NOT SIGN
62 "\x81\xCA", # NOT SIGN (U+00AC)
63  
64 0xFFE4, # FULLWIDTH BROKEN BAR
65 "\x85\x44", # BROKEN BAR (U+00A6)
66 );
67  
68 56 ▶sub to_sjis0213_supplements { defined $_[0] && $Supplements{$_[0]} || '' }
Subroutine to_sjis0213_supplements: called CC=3 SCAR=11.1
Pod documented
Branch: 1 branch
BranchTrueFalseTotal
defined $_[0] and $ShiftJIS::X0213::MapUTF::Supplements::Supplements{$_[0]} or "" 48 8 56
Condition66%2/3
defined $_[0] and $ShiftJIS::X0213::MapUTF::Supplements::Supplements{$_[0]}
!ll&&!rl&&r
8048
MC/DC50%1/2
defined $_[0] and $ShiftJIS::X0213::MapUTF::Supplements::Supplements{$_[0]}
defined $_[0] $ShiftJIS::X0213::MapUTF::Supplements::Supplements{$_[0]}
Truth table66%2/3
A and B
A= defined $_[0]B= $ShiftJIS::X0213::MapUTF::Supplements::Supplements{$_[0]}
ABresult
0X0
100
111
69 56 ▶sub to_sjis2004_supplements { defined $_[0] && $Supplements{$_[0]} || '' }
Subroutine to_sjis2004_supplements: called CC=3 SCAR=11.1
Pod documented
Branch: 1 branch
BranchTrueFalseTotal
defined $_[0] and $ShiftJIS::X0213::MapUTF::Supplements::Supplements{$_[0]} or "" 48 8 56
Condition66%2/3
defined $_[0] and $ShiftJIS::X0213::MapUTF::Supplements::Supplements{$_[0]}
!ll&&!rl&&r
8048
MC/DC50%1/2
defined $_[0] and $ShiftJIS::X0213::MapUTF::Supplements::Supplements{$_[0]}
defined $_[0] $ShiftJIS::X0213::MapUTF::Supplements::Supplements{$_[0]}
Truth table66%2/3
A and B
A= defined $_[0]B= $ShiftJIS::X0213::MapUTF::Supplements::Supplements{$_[0]}
ABresult
0X0
100
111
70  
71 2 1;
72 __END__
↑ Summary tosj0213.h »