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.018'; | ||||||
5 | |||||||
6 | 1 | 1 | 68280 | use strict; | |||
1 | 8 | ||||||
1 | 29 | ||||||
7 | 1 | 1 | 5 | use warnings; | |||
1 | 1 | ||||||
1 | 22 | ||||||
8 | 1 | 1 | 510 | use Exporter::Tiny (); | |||
1 | 3255 | ||||||
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 | 91 | my $sub = shift; | ||
16 | return [ | ||||||
17 | 1 | 7 | lazy => 1, | ||||
18 | default => $sub, | ||||||
19 | ]; | ||||||
20 | } | ||||||
21 | |||||||
22 | 1; | ||||||
23 | |||||||
24 | __END__ |