line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Parallel::Async; |
2
|
41
|
|
|
41
|
|
4979148
|
use 5.008005; |
|
41
|
|
|
|
|
165
|
|
|
41
|
|
|
|
|
1541
|
|
3
|
41
|
|
|
41
|
|
232
|
use strict; |
|
41
|
|
|
|
|
53
|
|
|
41
|
|
|
|
|
1243
|
|
4
|
41
|
|
|
41
|
|
238
|
use warnings; |
|
41
|
|
|
|
|
65
|
|
|
41
|
|
|
|
|
2061
|
|
5
|
|
|
|
|
|
|
|
6
|
|
|
|
|
|
|
our $VERSION = "0.03"; |
7
|
|
|
|
|
|
|
|
8
|
41
|
|
|
41
|
|
32180
|
use parent qw/Exporter/; |
|
41
|
|
|
|
|
11319
|
|
|
41
|
|
|
|
|
203
|
|
9
|
|
|
|
|
|
|
our @EXPORT = qw/async/; |
10
|
|
|
|
|
|
|
our @EXPORT_OK = qw/async_task/; |
11
|
|
|
|
|
|
|
|
12
|
41
|
|
|
41
|
|
443473
|
use Parallel::Async::Task; |
|
41
|
|
|
|
|
119
|
|
|
41
|
|
|
|
|
3299
|
|
13
|
|
|
|
|
|
|
our $TASK_CLASS = 'Parallel::Async::Task'; |
14
|
|
|
|
|
|
|
|
15
|
|
|
|
|
|
|
sub async_task (&) {## no critic |
16
|
96
|
|
|
96
|
0
|
83649
|
my $code = shift; |
17
|
96
|
|
|
|
|
1073
|
return $TASK_CLASS->new(code => $code); |
18
|
|
|
|
|
|
|
} |
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
# alias |
21
|
41
|
|
|
41
|
|
245
|
no warnings 'once'; |
|
41
|
|
|
|
|
87
|
|
|
41
|
|
|
|
|
2422
|
|
22
|
|
|
|
|
|
|
*async = \&async_task; |
23
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
1; |
25
|
|
|
|
|
|
|
__END__ |