| 1 | package MooseX::MethodAttributes::Role::AttrContainer::Inheritable; | ||||||||||
| 2 | # ABSTRACT: capture code attributes in the automatically initialized metaclass instance | ||||||||||
| 3 | |||||||||||
| 4 | 10 | our $VERSION = '0.32'; | |||||||||
| 5 | |||||||||||
| 6 | #pod =head1 DESCRIPTION | ||||||||||
| 7 | #pod | ||||||||||
| 8 | #pod This role extends C<MooseX::MethodAttributes::Role::AttrContainer> with the | ||||||||||
| 9 | #pod functionality of automatically initializing a metaclass for the caller and | ||||||||||
| 10 | #pod applying the meta roles relevant for capturing method attributes. | ||||||||||
| 11 | #pod | ||||||||||
| 12 | #pod =cut | ||||||||||
| 13 | |||||||||||
| 14 | 10 | ▶ | use Moose::Role; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 15 | 10 | ▶ | use MooseX::MethodAttributes (); | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 16 | |||||||||||
| 17 | 10 | ▶ | use namespace::autoclean; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 18 | |||||||||||
| 19 | 10 | with 'MooseX::MethodAttributes::Role::AttrContainer'; | |||||||||
| 20 | |||||||||||
| 21 | 24 | ▶ | before MODIFY_CODE_ATTRIBUTES => sub { | ||||||||
|
Subroutine
__ANON__: called CC=2 SCAR=7.1
| |||||||||||
| 22 | 24 | my ($class, $code, @attrs) = @_; | |||||||||
| 23 | 24 | ▶ | return unless @attrs; | ||||||||
|
Branch: 1 branch
| |||||||||||
| 24 | 24 | MooseX::MethodAttributes->init_meta( for_class => $class ); | |||||||||
| 25 | 10 | }; | |||||||||
| 26 | |||||||||||
| 27 | 10 | 1; | |||||||||
| 28 | |||||||||||
| 29 | __END__ | ||||||||||