line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
9
|
|
|
9
|
|
3606
|
use 5.014; |
|
9
|
|
|
|
|
21
|
|
2
|
9
|
|
|
9
|
|
32
|
use strict; |
|
9
|
|
|
|
|
11
|
|
|
9
|
|
|
|
|
169
|
|
3
|
9
|
|
|
9
|
|
28
|
use warnings; |
|
9
|
|
|
|
|
11
|
|
|
9
|
|
|
|
|
474
|
|
4
|
|
|
|
|
|
|
|
5
|
|
|
|
|
|
|
package Kavorka::Sub::Around; |
6
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
our $AUTHORITY = 'cpan:TOBYINK'; |
8
|
|
|
|
|
|
|
our $VERSION = '0.037'; |
9
|
|
|
|
|
|
|
|
10
|
9
|
|
|
9
|
|
35
|
use Moo; |
|
9
|
|
|
|
|
9
|
|
|
9
|
|
|
|
|
50
|
|
11
|
|
|
|
|
|
|
with 'Kavorka::MethodModifier'; |
12
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
sub default_invocant |
14
|
|
|
|
|
|
|
{ |
15
|
5
|
|
|
5
|
0
|
8
|
my $self = shift; |
16
|
|
|
|
|
|
|
return ( |
17
|
5
|
|
|
|
|
90
|
'Kavorka::Parameter'->new( |
18
|
|
|
|
|
|
|
name => '$next', |
19
|
|
|
|
|
|
|
traits => { invocant => 1 }, |
20
|
|
|
|
|
|
|
), |
21
|
|
|
|
|
|
|
'Kavorka::Parameter'->new( |
22
|
|
|
|
|
|
|
name => '$self', |
23
|
|
|
|
|
|
|
traits => { invocant => 1 }, |
24
|
|
|
|
|
|
|
), |
25
|
|
|
|
|
|
|
); |
26
|
|
|
|
|
|
|
} |
27
|
|
|
|
|
|
|
|
28
|
6
|
|
|
6
|
0
|
17
|
sub method_modifier { 'around' } |
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
around inject_prelude => sub |
31
|
|
|
|
|
|
|
{ |
32
|
|
|
|
|
|
|
my $next = shift; |
33
|
|
|
|
|
|
|
my $self = shift; |
34
|
|
|
|
|
|
|
return join '' => ( |
35
|
|
|
|
|
|
|
'*{^NEXT} = \\$_[0];', |
36
|
|
|
|
|
|
|
$self->$next(@_), |
37
|
|
|
|
|
|
|
); |
38
|
|
|
|
|
|
|
}; |
39
|
|
|
|
|
|
|
|
40
|
|
|
|
|
|
|
1; |