line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package latest::feature; |
2
|
|
|
|
|
|
|
|
3
|
|
|
|
|
|
|
BEGIN { |
4
|
2
|
|
|
2
|
|
32077
|
eval 'require feature'; |
5
|
2
|
50
|
|
|
|
11
|
if ( $@ ) { |
6
|
0
|
|
|
|
|
0
|
eval 'sub import {}'; # NOP if we don't have feature |
7
|
|
|
|
|
|
|
} |
8
|
|
|
|
|
|
|
else { |
9
|
2
|
|
|
|
|
33
|
our @ISA = qw( feature ); |
10
|
2
|
|
|
0
|
|
97
|
eval 'sub unknown_feature_bundle {}'; # Ignore unknown bundle errors |
|
0
|
|
|
|
|
0
|
|
11
|
|
|
|
|
|
|
} |
12
|
|
|
|
|
|
|
} |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
package latest; |
15
|
|
|
|
|
|
|
|
16
|
2
|
|
|
2
|
|
9
|
use warnings; |
|
2
|
|
|
|
|
3
|
|
|
2
|
|
|
|
|
79
|
|
17
|
2
|
|
|
2
|
|
10
|
use strict; |
|
2
|
|
|
|
|
3
|
|
|
2
|
|
|
|
|
77
|
|
18
|
2
|
|
|
2
|
|
2128
|
use version; |
|
2
|
|
|
|
|
4657
|
|
|
2
|
|
|
|
|
11
|
|
19
|
|
|
|
|
|
|
|
20
|
2
|
|
|
2
|
|
116
|
use Carp; |
|
2
|
|
|
|
|
7
|
|
|
2
|
|
|
|
|
410
|
|
21
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
=head1 NAME |
23
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
latest - Use the latest Perl features |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
=head1 VERSION |
27
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
This document describes latest version 0.03 |
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
=cut |
31
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
our $VERSION = '0.03'; |
33
|
|
|
|
|
|
|
|
34
|
|
|
|
|
|
|
=head1 SYNOPSIS |
35
|
|
|
|
|
|
|
|
36
|
|
|
|
|
|
|
use latest; |
37
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
=head1 DESCRIPTION |
39
|
|
|
|
|
|
|
|
40
|
|
|
|
|
|
|
The line |
41
|
|
|
|
|
|
|
|
42
|
|
|
|
|
|
|
use latest; |
43
|
|
|
|
|
|
|
|
44
|
|
|
|
|
|
|
is roughly equivalent to |
45
|
|
|
|
|
|
|
|
46
|
|
|
|
|
|
|
use strict; |
47
|
|
|
|
|
|
|
use warnings; |
48
|
|
|
|
|
|
|
use $]; |
49
|
|
|
|
|
|
|
|
50
|
|
|
|
|
|
|
except that 'use $]' doesn't work. |
51
|
|
|
|
|
|
|
|
52
|
|
|
|
|
|
|
The main use case is to |
53
|
|
|
|
|
|
|
|
54
|
|
|
|
|
|
|
use latest; |
55
|
|
|
|
|
|
|
|
56
|
|
|
|
|
|
|
at the top of your tests to shake out any obscure problems that might |
57
|
|
|
|
|
|
|
result from your code being used by a program that requires the latest |
58
|
|
|
|
|
|
|
Perl version. |
59
|
|
|
|
|
|
|
|
60
|
|
|
|
|
|
|
=cut |
61
|
|
|
|
|
|
|
|
62
|
|
|
|
|
|
|
sub import { |
63
|
2
|
|
|
2
|
|
38
|
strict->import; |
64
|
2
|
|
|
|
|
25
|
warnings->import; |
65
|
2
|
|
|
|
|
41
|
( my $v = version->new( $] )->normal ) =~ s/^v/:/; |
66
|
2
|
|
|
|
|
313
|
latest::feature->import( $v ); |
67
|
|
|
|
|
|
|
} |
68
|
|
|
|
|
|
|
|
69
|
|
|
|
|
|
|
1; |
70
|
|
|
|
|
|
|
__END__ |