line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
1
|
|
|
1
|
|
777
|
use 5.006; use strict; use warnings; |
|
1
|
|
|
1
|
|
3
|
|
|
1
|
|
|
1
|
|
4
|
|
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
19
|
|
|
1
|
|
|
|
|
4
|
|
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
230
|
|
2
|
|
|
|
|
|
|
|
3
|
|
|
|
|
|
|
package Object::Tiny::Lvalue; |
4
|
|
|
|
|
|
|
|
5
|
|
|
|
|
|
|
our $VERSION = '1.084'; |
6
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
sub import { |
8
|
3
|
50
|
|
3
|
|
1554
|
return unless shift eq __PACKAGE__; |
9
|
3
|
|
|
|
|
6
|
my $pkg = caller; |
10
|
|
|
|
|
|
|
eval join "\n", ( |
11
|
|
|
|
|
|
|
"package $pkg;", |
12
|
|
|
|
|
|
|
'our @ISA = "Object::Tiny::Lvalue" unless @ISA;', |
13
|
|
|
|
|
|
|
map { |
14
|
3
|
100
|
66
|
1
|
0
|
7
|
defined and /\A[^\W\d]\w*\z/ or die "Invalid accessor name '$_'"; |
|
5
|
|
|
1
|
0
|
36
|
|
|
1
|
|
|
3
|
0
|
491
|
|
|
1
|
|
|
1
|
0
|
453
|
|
|
3
|
|
|
|
|
3189
|
|
|
1
|
|
|
|
|
2958
|
|
15
|
4
|
|
|
|
|
215
|
"sub $_ : lvalue { \$_[0]->{$_} }"; |
16
|
|
|
|
|
|
|
} @_ |
17
|
|
|
|
|
|
|
); |
18
|
2
|
50
|
|
|
|
6
|
die "Failed to generate $pkg" if $@; |
19
|
2
|
|
|
|
|
49
|
return 1; |
20
|
|
|
|
|
|
|
} |
21
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
sub new { |
23
|
2
|
|
|
2
|
0
|
1431
|
my $class = shift; |
24
|
2
|
|
|
|
|
7
|
bless { @_ }, $class; |
25
|
|
|
|
|
|
|
} |
26
|
|
|
|
|
|
|
|
27
|
|
|
|
|
|
|
1; |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
__END__ |