line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
############################################################################### |
2
|
|
|
|
|
|
|
# The receiver class can reshape the data at any given rule match. |
3
|
|
|
|
|
|
|
############################################################################### |
4
|
|
|
|
|
|
|
package JSONY::Receiver; |
5
|
3
|
|
|
3
|
|
21
|
use base 'Pegex::Tree'; |
|
3
|
|
|
|
|
6
|
|
|
3
|
|
|
|
|
1240
|
|
6
|
3
|
|
|
3
|
|
11828
|
use boolean; |
|
3
|
|
|
|
|
7789
|
|
|
3
|
|
|
|
|
17
|
|
7
|
|
|
|
|
|
|
|
8
|
29
|
|
|
29
|
0
|
36574
|
sub got_top_seq_entry { $_[1][0][0] } |
9
|
0
|
|
|
0
|
0
|
0
|
sub got_top_map { $_[0]->got_map([$_[1]]) } |
10
|
1
|
|
|
1
|
0
|
658
|
sub got_seq { $_[1]->[0] } |
11
|
0
|
|
|
0
|
0
|
0
|
sub got_map { +{ map {($_->[0], $_->[1])} @{$_[1]->[0]} } } |
|
0
|
|
|
|
|
0
|
|
|
0
|
|
|
|
|
0
|
|
12
|
0
|
|
|
0
|
0
|
0
|
sub got_string {"$_[1]"} |
13
|
|
|
|
|
|
|
sub got_bare { |
14
|
33
|
|
|
33
|
0
|
19306
|
$_ = pop; |
15
|
33
|
100
|
|
|
|
344
|
/^true$/ ? true : |
|
|
50
|
|
|
|
|
|
|
|
50
|
|
|
|
|
|
|
|
50
|
|
|
|
|
|
16
|
|
|
|
|
|
|
/^false$/ ? false : |
17
|
|
|
|
|
|
|
/^null$/ ? undef : |
18
|
|
|
|
|
|
|
/^( |
19
|
|
|
|
|
|
|
-? |
20
|
|
|
|
|
|
|
(?: 0 | [1-9] [0-9]* ) |
21
|
|
|
|
|
|
|
(?: \. [0-9]* )? |
22
|
|
|
|
|
|
|
(?: [eE] [\-\+]? [0-9]+ )? |
23
|
|
|
|
|
|
|
)$/x ? ($_ + 0) : |
24
|
|
|
|
|
|
|
"$_" |
25
|
|
|
|
|
|
|
} |
26
|
|
|
|
|
|
|
|
27
|
|
|
|
|
|
|
1; |