line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package MooseX::BuildArgs::Meta::ToRole; |
2
|
|
|
|
|
|
|
|
3
|
|
|
|
|
|
|
$MooseX::BuildArgs::Meta::ToRole::VERSION = '0.07'; |
4
|
|
|
|
|
|
|
|
5
|
2
|
|
|
2
|
|
15993
|
use Moose::Role; |
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
19
|
|
6
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
around apply => sub{ |
8
|
|
|
|
|
|
|
my $orig = shift; |
9
|
|
|
|
|
|
|
my $self = shift; |
10
|
|
|
|
|
|
|
my $from_role = shift; |
11
|
|
|
|
|
|
|
my $to_role = shift; |
12
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
$to_role = Moose::Util::MetaRole::apply_metaroles( |
14
|
|
|
|
|
|
|
for => $to_role, |
15
|
|
|
|
|
|
|
role_metaroles => { |
16
|
|
|
|
|
|
|
application_to_class => ['MooseX::BuildArgs::Meta::ToClass'], |
17
|
|
|
|
|
|
|
application_to_role => ['MooseX::BuildArgs::Meta::ToRole'], |
18
|
|
|
|
|
|
|
}, |
19
|
|
|
|
|
|
|
); |
20
|
|
|
|
|
|
|
|
21
|
|
|
|
|
|
|
return $self->$orig( $from_role, $to_role ); |
22
|
|
|
|
|
|
|
}; |
23
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
1; |