line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package List::Utils::MoveElement; |
2
|
|
|
|
|
|
|
|
3
|
1
|
|
|
1
|
|
1419
|
use 5.008; |
|
1
|
|
|
|
|
4
|
|
4
|
1
|
|
|
1
|
|
5
|
use strict; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
24
|
|
5
|
1
|
|
|
1
|
|
11
|
use warnings; |
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
40
|
|
6
|
1
|
|
|
1
|
|
7
|
use Exporter; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
202
|
|
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
BEGIN { |
9
|
1
|
|
|
1
|
|
3
|
our $VERSION = qw/0.03/; |
10
|
1
|
|
|
|
|
22
|
our @ISA = qw/Exporter/; |
11
|
1
|
|
|
|
|
6
|
our @EXPORT = qw/move_element_left move_element_right move_element_to_beginning move_element_to_end/; |
12
|
1
|
|
|
|
|
1
|
our $xs_loaded; |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
# Load XS version if available, otherwise load PP version |
15
|
1
|
|
|
|
|
2
|
local $@; |
16
|
|
|
|
|
|
|
eval { |
17
|
1
|
|
|
|
|
7
|
require XSLoader; |
18
|
1
|
|
|
|
|
600
|
XSLoader::load('List::Utils::MoveElement', $VERSION); |
19
|
1
|
|
|
|
|
10
|
$xs_loaded = 1; |
20
|
1
|
50
|
|
|
|
2
|
} or do { |
21
|
0
|
|
|
|
|
0
|
require List::Utils::MoveElement::PP; |
22
|
1
|
|
|
1
|
|
9
|
no strict 'refs'; |
|
1
|
|
|
|
|
8
|
|
|
1
|
|
|
|
|
113
|
|
23
|
0
|
|
|
|
|
0
|
*left = \&{'List::Utils::MoveElement::PP::left'}; |
|
0
|
|
|
|
|
0
|
|
24
|
0
|
|
|
|
|
0
|
*right = \&{'List::Utils::MoveElement::PP::right'}; |
|
0
|
|
|
|
|
0
|
|
25
|
0
|
|
|
|
|
0
|
*to_beginning = \&{'List::Utils::MoveElement::PP::to_beginning'}; |
|
0
|
|
|
|
|
0
|
|
26
|
0
|
|
|
|
|
0
|
*to_end = \&{'List::Utils::MoveElement::PP::to_end'}; |
|
0
|
|
|
|
|
0
|
|
27
|
|
|
|
|
|
|
}; |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
# Alias long names to short names |
30
|
|
|
|
|
|
|
{ |
31
|
1
|
|
|
1
|
|
7
|
no strict 'refs'; |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
94
|
|
|
1
|
|
|
|
|
2
|
|
32
|
1
|
|
|
|
|
2
|
*move_element_left = \&{__PACKAGE__ . '::left'}; |
|
1
|
|
|
|
|
4
|
|
33
|
1
|
|
|
|
|
2
|
*move_element_right = \&{__PACKAGE__ . '::right'}; |
|
1
|
|
|
|
|
12
|
|
34
|
1
|
|
|
|
|
2
|
*move_element_to_beginning = \&{__PACKAGE__ . '::to_beginning'}; |
|
1
|
|
|
|
|
2
|
|
35
|
1
|
|
|
|
|
2
|
*move_element_to_end = \&{__PACKAGE__ . '::to_end'}; |
|
1
|
|
|
|
|
37
|
|
36
|
|
|
|
|
|
|
} |
37
|
|
|
|
|
|
|
} |
38
|
|
|
|
|
|
|
|
39
|
|
|
|
|
|
|
1; |
40
|
|
|
|
|
|
|
|
41
|
|
|
|
|
|
|
__END__ |