blib/lib/Language/Farnsworth/Units/Standard.pm

filter: Statementstmt 100% 11 / 11 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 2 / 2 Podpod 0.0% 0 / 1 totaltotal 92.8% 13 / 14 CC 1 SCAR 0.0
CC
1
Cov
100%
BEGIN
1.0
init
1.0
CRAP 1.0
« blib/lib/Language/Farnsworth/Docs/Syntax.pm ↑ Summary blib/lib/Language/Farnsworth/Parser/Extra.pm »
1 package Language::Farnsworth::Units::Standard;
2  
3 4 ▶use Encode;
Subroutine BEGIN: called CC=1 SCAR=0.0
4  
5 sub init
6 4 ▶{
Subroutine init: called CC=1 SCAR=0.0
Pod undocumented
7 4 my $env = shift;
8
9 # while(<DATA>)
10 # {
11 # $_=decode('UTF-8', $_); #fixes unicode variables
12 # chomp;
13 # s|//.*$||;
14 # s|\s*$||;
15 # $env->eval($_) if ($_ !~ /^\s*$/);
16 # }
17  
18 {
19 4 local $/;
20 4 undef $/;
21 4 my $data = <DATA>;
22 4 $env->eval($data);
23 }
24  
25 4 close(DATA); #this helps prevent annoyces in error messages
26 }
27  
28 4 1;
29 __DATA__
« blib/lib/Language/Farnsworth/Docs/Syntax.pm ↑ Summary blib/lib/Language/Farnsworth/Parser/Extra.pm »