line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
2
|
|
|
2
|
|
12
|
use strict; |
|
2
|
|
|
|
|
14
|
|
|
2
|
|
|
|
|
63
|
|
2
|
2
|
|
|
2
|
|
10
|
use warnings; |
|
2
|
|
|
|
|
2
|
|
|
2
|
|
|
|
|
338
|
|
3
|
|
|
|
|
|
|
|
4
|
|
|
|
|
|
|
package #private |
5
|
|
|
|
|
|
|
Scalar::Boolean::Value; |
6
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
my $true = bless \do { ( my $data = 1 ) }, __PACKAGE__; |
8
|
|
|
|
|
|
|
my $false = bless \do { ( my $data = 0 ) }, __PACKAGE__; |
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
use overload |
11
|
0
|
0
|
|
0
|
|
0
|
'!' => sub { ${ $_[0] } ? $false : $true }, |
|
0
|
|
|
|
|
0
|
|
12
|
64
|
|
|
64
|
|
253
|
'bool' => sub { ${ $_[0] } }, |
|
64
|
|
|
|
|
198
|
|
13
|
15
|
50
|
|
15
|
|
1403
|
'eq' => sub { ${ $_[0] } eq $_[1] ? $true : $false }, |
|
15
|
|
|
|
|
123
|
|
14
|
2
|
0
|
|
2
|
|
1795
|
'==' => sub { ${ $_[0] } == $_[1] ? $true : $false }; |
|
2
|
|
|
0
|
|
1199
|
|
|
2
|
|
|
|
|
36
|
|
|
0
|
|
|
|
|
0
|
|
|
0
|
|
|
|
|
0
|
|
15
|
|
|
|
|
|
|
|
16
|
2
|
100
|
|
2
|
0
|
380
|
sub boolean($) { $_[0] ? $true : $false } |
17
|
12
|
|
|
12
|
0
|
74
|
sub true() { $true } |
18
|
13
|
|
|
13
|
0
|
87
|
sub false() { $false } |
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
1; |
21
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
__END__ |