| line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
|
1
|
|
|
|
|
|
|
|
|
2
|
|
|
|
|
|
|
use strict; |
|
3
|
177
|
|
|
177
|
|
103956
|
use warnings; |
|
|
177
|
|
|
|
|
328
|
|
|
|
177
|
|
|
|
|
4528
|
|
|
4
|
177
|
|
|
177
|
|
805
|
|
|
|
177
|
|
|
|
|
301
|
|
|
|
177
|
|
|
|
|
6286
|
|
|
5
|
|
|
|
|
|
|
our $VERSION = '1.2019'; |
|
6
|
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
use feature (); |
|
8
|
177
|
|
|
177
|
|
925
|
use utf8; |
|
|
177
|
|
|
|
|
343
|
|
|
|
177
|
|
|
|
|
3011
|
|
|
9
|
177
|
|
|
177
|
|
85671
|
use IO::File (); |
|
|
177
|
|
|
|
|
2158
|
|
|
|
177
|
|
|
|
|
844
|
|
|
10
|
177
|
|
|
177
|
|
71201
|
use IO::Handle (); |
|
|
177
|
|
|
|
|
1255093
|
|
|
|
177
|
|
|
|
|
3691
|
|
|
11
|
177
|
|
|
177
|
|
1121
|
use Try::Tiny::ByClass; |
|
|
177
|
|
|
|
|
322
|
|
|
|
177
|
|
|
|
|
2659
|
|
|
12
|
177
|
|
|
177
|
|
72505
|
use Catmandu::Error (); |
|
|
177
|
|
|
|
|
1260001
|
|
|
|
177
|
|
|
|
|
10215
|
|
|
13
|
177
|
|
|
177
|
|
68120
|
|
|
|
177
|
|
|
|
|
2209
|
|
|
|
177
|
|
|
|
|
23968
|
|
|
14
|
|
|
|
|
|
|
my $pkg = caller; |
|
15
|
|
|
|
|
|
|
strict->import; |
|
16
|
2880
|
|
|
2880
|
|
14737
|
warnings->import; |
|
17
|
2880
|
|
|
|
|
56503
|
feature->import(qw(:5.10)); |
|
18
|
2880
|
|
|
|
|
27492
|
utf8->import; |
|
19
|
2880
|
|
|
|
|
163903
|
Try::Tiny::ByClass->export_to_level(1, $pkg); |
|
20
|
2880
|
|
|
|
|
16116
|
} |
|
21
|
2880
|
|
|
|
|
308956
|
|
|
22
|
|
|
|
|
|
|
1; |
|
23
|
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
|
|
25
|
|
|
|
|
|
|
=pod |
|
26
|
|
|
|
|
|
|
|
|
27
|
|
|
|
|
|
|
=head1 NAME |
|
28
|
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
Catmandu::Sane - Package boilerplate |
|
30
|
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
=head1 SYNOPSIS |
|
32
|
|
|
|
|
|
|
|
|
33
|
|
|
|
|
|
|
use Catmandu::Sane; |
|
34
|
|
|
|
|
|
|
|
|
35
|
|
|
|
|
|
|
# Provides all the 5.10 features. |
|
36
|
|
|
|
|
|
|
say("what"); |
|
37
|
|
|
|
|
|
|
given($foo) { |
|
38
|
|
|
|
|
|
|
when(1) { say "1" } |
|
39
|
|
|
|
|
|
|
when([2,3]) { say "2 or 3" } |
|
40
|
|
|
|
|
|
|
when(/abc/) { say "has abc" } |
|
41
|
|
|
|
|
|
|
default { none of the above } |
|
42
|
|
|
|
|
|
|
} |
|
43
|
|
|
|
|
|
|
sub next_id{ |
|
44
|
|
|
|
|
|
|
state $id; |
|
45
|
|
|
|
|
|
|
++$id; |
|
46
|
|
|
|
|
|
|
} |
|
47
|
|
|
|
|
|
|
|
|
48
|
|
|
|
|
|
|
# Provides try/catch[/finally] try/catch_case[/finally] |
|
49
|
|
|
|
|
|
|
try { |
|
50
|
|
|
|
|
|
|
} catch {}; |
|
51
|
|
|
|
|
|
|
|
|
52
|
|
|
|
|
|
|
# Provides |
|
53
|
|
|
|
|
|
|
Catmandu::Error->throw("error"); |
|
54
|
|
|
|
|
|
|
Catmandu::BadVal->throw("eek val"); |
|
55
|
|
|
|
|
|
|
Catmandu::BadArg->throw("eek arg"); |
|
56
|
|
|
|
|
|
|
Catmandu::NotImplemented->throw("can't do that!"); |
|
57
|
|
|
|
|
|
|
|
|
58
|
|
|
|
|
|
|
=head1 DESCRIPTION |
|
59
|
|
|
|
|
|
|
|
|
60
|
|
|
|
|
|
|
Package boilerplate equivalent to: |
|
61
|
|
|
|
|
|
|
|
|
62
|
|
|
|
|
|
|
use strict; |
|
63
|
|
|
|
|
|
|
use warnings; |
|
64
|
|
|
|
|
|
|
use feature qw(:5.10); |
|
65
|
|
|
|
|
|
|
use utf8; |
|
66
|
|
|
|
|
|
|
use IO::File (); |
|
67
|
|
|
|
|
|
|
use IO::Handle (); |
|
68
|
|
|
|
|
|
|
use Try::Tiny::ByClass; |
|
69
|
|
|
|
|
|
|
use Catmandu::Error; |
|
70
|
|
|
|
|
|
|
|
|
71
|
|
|
|
|
|
|
=cut |