| line |
true |
false |
branch |
|
35
|
55 |
0 |
if (@args == 0) { } |
|
54
|
2 |
34 |
if ($IS_ROLE{$caller}) |
|
64
|
2 |
0 |
if (my $req = $REQUIRED_METHODS{$role}) |
|
78
|
0 |
13 |
unless exists $REQUIRED_METHODS{$caller} |
|
85
|
5 |
0 |
unless exists $EXCLUDED_ROLES{$caller} |
|
91
|
2 |
47 |
ref $class ? : |
|
96
|
45 |
4 |
unless $METHOD_ALIASES{$target_class} |
|
110
|
0 |
1 |
ref $class ? : |
|
111
|
0 |
1 |
unless $APPLIED_ROLES{$target_class} |
|
140
|
390 |
83 |
if $SKIP_METHODS{$name} |
|
141
|
2 |
81 |
if $name =~ /^[A-Z_]+$/ |
|
143
|
4 |
77 |
unless defined *{$glob;}{"CODE"} |
|
153
|
9 |
43 |
if exists $CAN_HANDLE_ATTR_CACHE{$class} |
|
156
|
0 |
43 |
if ($class->can('can_handle_attributes')) { } |
|
|
11 |
32 |
elsif ($class->can('has') and $class->can('extends')) { } |
|
157
|
0 |
0 |
$class->can_handle_attributes ? : |
|
164
|
0 |
32 |
grep({$_ eq 'Class::More';} @{"${class}::ISA";}) ? : |
|
172
|
8 |
51 |
if $ROLE_LOAD_CACHE{$role} |
|
174
|
6 |
45 |
unless ($IS_ROLE{$role}) |
|
177
|
2 |
4 |
if ($@) |
|
195
|
20 |
6 |
if $SKIP_METHODS{$name} |
|
196
|
0 |
6 |
if $name =~ /^[A-Z_]+$/ |
|
198
|
0 |
6 |
unless defined *{$glob;}{"CODE"} |
|
208
|
54 |
1 |
unless defined &{"${caller}::with";} |
|
213
|
49 |
8 |
if $class->can("new") |
|
214
|
0 |
8 |
unless $INC{'Class.pm'} |
|
217
|
8 |
0 |
unless grep {$_ eq "Class";} @{"${class}::ISA";} |
|
226
|
2 |
57 |
if (ref $arg eq 'HASH' and $arg->{'role'}) { } |
|
229
|
2 |
0 |
if ($arg->{'alias'} and ref $arg->{'alias'} eq "HASH") |
|
247
|
0 |
0 |
if (@_) |
|
261
|
0 |
55 |
if ($APPLIED_ROLES{$class} and grep {$_ eq $role;} @{$APPLIED_ROLES{$class};}) |
|
268
|
5 |
50 |
if (my $excluded = $EXCLUDED_ROLES{$role}) |
|
270
|
3 |
2 |
if (@violated) |
|
282
|
52 |
0 |
unless ($IS_ROLE{$class}) |
|
288
|
41 |
11 |
unless $ROLE_METHODS_CACHE{$role} |
|
295
|
6 |
1 |
unless ($class->can($method) or $role_provides{$method}) |
|
299
|
5 |
47 |
if (@missing) |
|
308
|
47 |
0 |
$METHOD_ALIASES{$class} ? : |
|
310
|
37 |
10 |
unless $ROLE_METHODS_CACHE{$role} |
|
317
|
15 |
41 |
if ($class->can($install_name)) |
|
320
|
9 |
6 |
if $origin eq $class or $origin eq $role |
|
323
|
1 |
5 |
if ($install_name ne $name) { } |
|
344
|
5 |
42 |
if (@conflicts) |
|
349
|
1 |
4 |
if ($first->{'is_alias'}) { } |
|
361
|
42 |
0 |
unless ($IS_ROLE{$class}) |
|
366
|
9 |
40 |
if $class->can($install_name) |
|
374
|
42 |
0 |
unless grep {$_ eq $role;} @{"${class}::ISA";} |
|
385
|
0 |
52 |
if (not $can_handle_attributes and %$role_attrs) |
|
390
|
0 |
52 |
if $@ |
|
396
|
4 |
4 |
unless exists $Class::More::ATTRIBUTES{$class} |
|
399
|
8 |
0 |
unless (defined *{"${class}::$attr_name";}{"CODE"}) |
|
402
|
0 |
10 |
if (@_) |
|
415
|
1 |
14 |
if exists $METHOD_ORIGIN_CACHE{$cache_key} |
|
420
|
14 |
0 |
if (defined &{"${class}::$method";}) |
|
422
|
14 |
0 |
if ($APPLIED_ROLES{$class}) |
|
428
|
14 |
2 |
if (defined &{"${role}::$original_name";} or exists $reverse_aliases{$method}) |
|
440
|
0 |
0 |
if ($parent->can($method)) |
|
450
|
0 |
20 |
unless $IS_ROLE{$role} |
|
452
|
16 |
4 |
if grep {$_ eq $role;} @{"${class}::ISA";} |
|
454
|
0 |
4 |
if $APPLIED_ROLES{$class} and grep {$_ eq $role;} @{$APPLIED_ROLES{$class};} |