blib/lib/MooX/Struct/Util.pm | |||
---|---|---|---|
Criterion | Covered | Total | % |
statement | 11 | 11 | 100.0 |
branch | n/a | ||
condition | n/a | ||
subroutine | 4 | 4 | 100.0 |
pod | 1 | 1 | 100.0 |
total | 16 | 16 | 100.0 |
line | stmt | bran | cond | sub | pod | time | code |
---|---|---|---|---|---|---|---|
1 | package MooX::Struct::Util; | ||||||
2 | |||||||
3 | our $AUTHORITY = 'cpan:TOBYINK'; | ||||||
4 | our $VERSION = '0.020'; | ||||||
5 | |||||||
6 | 1 | 1 | 67836 | use strict; | |||
1 | 7 | ||||||
1 | 29 | ||||||
7 | 1 | 1 | 5 | use warnings; | |||
1 | 1 | ||||||
1 | 23 | ||||||
8 | 1 | 1 | 500 | use Exporter::Tiny (); | |||
1 | 3346 | ||||||
1 | 85 | ||||||
9 | |||||||
10 | our @ISA = qw(Exporter::Tiny); | ||||||
11 | our @EXPORT = qw(lazy_default); | ||||||
12 | |||||||
13 | sub lazy_default (&) | ||||||
14 | { | ||||||
15 | 1 | 1 | 1 | 143 | my $sub = shift; | ||
16 | return [ | ||||||
17 | 1 | 7 | lazy => 1, | ||||
18 | default => $sub, | ||||||
19 | ]; | ||||||
20 | } | ||||||
21 | |||||||
22 | 1; | ||||||
23 | |||||||
24 | __END__ |