line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
1
|
|
|
1
|
|
23500
|
use 5.012; |
|
1
|
|
|
|
|
5
|
|
|
1
|
|
|
|
|
36
|
|
2
|
1
|
|
|
1
|
|
5
|
use strict; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
34
|
|
3
|
1
|
|
|
1
|
|
6
|
use warnings; |
|
1
|
|
|
|
|
5
|
|
|
1
|
|
|
|
|
27
|
|
4
|
1
|
|
|
1
|
|
869
|
use Keyword::Simple (); |
|
1
|
|
|
|
|
44012
|
|
|
1
|
|
|
|
|
275
|
|
5
|
|
|
|
|
|
|
|
6
|
|
|
|
|
|
|
{ |
7
|
|
|
|
|
|
|
package Acme::Loopy; |
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
our $AUTHORITY = 'cpan:TOBYINK'; |
10
|
|
|
|
|
|
|
our $VERSION = '0.004'; |
11
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
sub import |
13
|
|
|
|
|
|
|
{ |
14
|
|
|
|
|
|
|
Keyword::Simple::define loop => sub { |
15
|
5
|
|
|
5
|
|
80
|
my ($ref) = @_; |
16
|
5
|
|
|
|
|
49
|
my $rand = 99_999 + int rand 900_000; |
17
|
5
|
|
|
|
|
471
|
substr($$ref, 0, 0) = |
18
|
|
|
|
|
|
|
q{ local ${^_LOOP_OLD} = ${^LOOP}; } . |
19
|
|
|
|
|
|
|
q{ local ${^_LOOP_CURRENT} = -1; } . |
20
|
|
|
|
|
|
|
q{ while ( ${^LOOP} = ++${^_LOOP_CURRENT}, my $__guard_}.$rand.q{ = Acme::Loopy::Guard->new(${^_LOOP_OLD}, \${^LOOP}) )}; |
21
|
1
|
|
|
1
|
|
17
|
}; |
22
|
|
|
|
|
|
|
} |
23
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
sub unimport |
25
|
|
|
|
|
|
|
{ |
26
|
0
|
|
|
0
|
|
0
|
Keyword::Simple::undefine loop => (); |
27
|
|
|
|
|
|
|
} |
28
|
|
|
|
|
|
|
} |
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
{ |
31
|
|
|
|
|
|
|
package Acme::Loopy::Guard; |
32
|
|
|
|
|
|
|
|
33
|
|
|
|
|
|
|
our $AUTHORITY = 'cpan:TOBYINK'; |
34
|
|
|
|
|
|
|
our $VERSION = '0.004'; |
35
|
|
|
|
|
|
|
|
36
|
|
|
|
|
|
|
sub new |
37
|
|
|
|
|
|
|
{ |
38
|
90
|
|
|
90
|
|
266
|
my $class = shift; |
39
|
90
|
|
|
|
|
342
|
bless \@_, $class; |
40
|
|
|
|
|
|
|
} |
41
|
|
|
|
|
|
|
|
42
|
|
|
|
|
|
|
sub DESTROY |
43
|
|
|
|
|
|
|
{ |
44
|
90
|
|
|
90
|
|
994
|
${$_[0][1]} = $_[0][0]; |
|
90
|
|
|
|
|
377
|
|
45
|
|
|
|
|
|
|
} |
46
|
|
|
|
|
|
|
} |
47
|
|
|
|
|
|
|
|
48
|
|
|
|
|
|
|
1; |
49
|
|
|
|
|
|
|
|
50
|
|
|
|
|
|
|
__END__ |