line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
#include "cbor_free_boolean.h" |
2
|
|
|
|
|
|
|
|
3
|
|
|
|
|
|
|
static HV *boolean_stash = NULL; |
4
|
|
|
|
|
|
|
|
5
|
14
|
|
|
|
|
|
HV *cbf_get_boolean_stash() { |
6
|
14
|
100
|
|
|
|
|
if (!boolean_stash) { |
7
|
|
|
|
|
|
|
dTHX; |
8
|
|
|
|
|
|
|
|
9
|
5
|
|
|
|
|
|
boolean_stash = gv_stashpv(BOOLEAN_CLASS, 0); |
10
|
|
|
|
|
|
|
|
11
|
5
|
100
|
|
|
|
|
if (!boolean_stash) { |
12
|
1
|
|
|
|
|
|
SV *modname = newSVpvs(LOAD_BOOLEAN_CLASS); |
13
|
1
|
|
|
|
|
|
load_module(PERL_LOADMOD_NOIMPORT, modname, NULL); |
14
|
|
|
|
|
|
|
|
15
|
1
|
|
|
|
|
|
boolean_stash = gv_stashpv(BOOLEAN_CLASS, 0); |
16
|
|
|
|
|
|
|
|
17
|
1
|
50
|
|
|
|
|
if (!boolean_stash) { |
18
|
0
|
|
|
|
|
|
_croak("Loaded Types::Serialiser but didn’t find stash!"); |
19
|
|
|
|
|
|
|
} |
20
|
|
|
|
|
|
|
} |
21
|
|
|
|
|
|
|
} |
22
|
|
|
|
|
|
|
|
23
|
14
|
|
|
|
|
|
return boolean_stash; |
24
|
|
|
|
|
|
|
} |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
static SV *stored_false = NULL; |
27
|
|
|
|
|
|
|
static SV *stored_true = NULL; |
28
|
|
|
|
|
|
|
|
29
|
3
|
|
|
|
|
|
SV *cbf_get_false() { |
30
|
3
|
100
|
|
|
|
|
if (!stored_false) { |
31
|
|
|
|
|
|
|
dTHX; |
32
|
2
|
|
|
|
|
|
cbf_get_boolean_stash(); |
33
|
2
|
|
|
|
|
|
stored_false = get_sv("Types::Serialiser::false", 0); |
34
|
|
|
|
|
|
|
} |
35
|
|
|
|
|
|
|
|
36
|
3
|
|
|
|
|
|
return stored_false; |
37
|
|
|
|
|
|
|
} |
38
|
|
|
|
|
|
|
|
39
|
6
|
|
|
|
|
|
SV *cbf_get_true() { |
40
|
6
|
100
|
|
|
|
|
if (!stored_true) { |
41
|
|
|
|
|
|
|
dTHX; |
42
|
3
|
|
|
|
|
|
cbf_get_boolean_stash(); |
43
|
3
|
|
|
|
|
|
stored_true = get_sv("Types::Serialiser::true", 0); |
44
|
|
|
|
|
|
|
} |
45
|
|
|
|
|
|
|
|
46
|
6
|
|
|
|
|
|
return stored_true; |
47
|
|
|
|
|
|
|
} |