| line |
true |
false |
branch |
|
18
|
0 |
0 |
if (!class_name[0]) return &sv_payload_default_marker; |
|
19
|
0 |
0 |
payload_marker_t* marker = &sv_class_markers[class_name]; |
|
|
0 |
0 |
payload_marker_t* marker = &sv_class_markers[class_name]; |
|
20
|
0 |
0 |
if (!marker->svt_dup && dup_callback) marker->svt_dup = dup_callback; |
|
|
0 |
0 |
if (!marker->svt_dup && dup_callback) marker->svt_dup = dup_callback; |
|
26
|
0 |
0 |
GV* gv = CvGV(cv); |
|
28
|
0 |
0 |
std::string name = GvNAME(gv); |
|
29
|
0 |
0 |
std::string stashname = HvNAME(stash); |
|
|
0 |
0 |
std::string stashname = HvNAME(stash); |
|
|
0 |
0 |
std::string stashname = HvNAME(stash); |
|
|
0 |
0 |
std::string stashname = HvNAME(stash); |
|
|
0 |
0 |
std::string stashname = HvNAME(stash); |
|
|
0 |
0 |
std::string stashname = HvNAME(stash); |
|
|
0 |
0 |
std::string stashname = HvNAME(stash); |
|
30
|
0 |
0 |
std::string origxs = "_xs_orig_" + name; |
|
33
|
0 |
0 |
case NEXT_SUPER: next_code = "shift->SUPER::" + name; break; |
|
|
0 |
0 |
case NEXT_SUPER: next_code = "shift->SUPER::" + name; break; |
|
34
|
0 |
0 |
case NEXT_METHOD: next_code = "next::method"; break; |
|
35
|
0 |
0 |
case NEXT_MAYBE: next_code = "maybe::next::method"; break; |
|
37
|
0 |
0 |
if (!next_code.length()) throw std::invalid_argument("type"); |
|
|
0 |
0 |
if (!next_code.length()) throw std::invalid_argument("type"); |
|
39
|
0 |
0 |
"package " + stashname + ";\n" + |
|
|
0 |
0 |
"package " + stashname + ";\n" + |
|
|
0 |
0 |
"package " + stashname + ";\n" + |
|
40
|
0 |
0 |
"use feature 'state';\n" + |
|
41
|
0 |
0 |
"no warnings 'redefine';\n" + |
|
42
|
0 |
0 |
"BEGIN { *" + origxs + " = \\&" + name + "; }\n" + |
|
|
0 |
0 |
"BEGIN { *" + origxs + " = \\&" + name + "; }\n" + |
|
|
0 |
0 |
"BEGIN { *" + origxs + " = \\&" + name + "; }\n" + |
|
|
0 |
0 |
"BEGIN { *" + origxs + " = \\&" + name + "; }\n" + |
|
|
0 |
0 |
"BEGIN { *" + origxs + " = \\&" + name + "; }\n" + |
|
43
|
0 |
0 |
"sub " + name + " {\n" + |
|
|
0 |
0 |
"sub " + name + " {\n" + |
|
|
0 |
0 |
"sub " + name + " {\n" + |
|
44
|
0 |
0 |
" eval q!sub " + name + " { " + origxs + "(@_) } !;\n" + |
|
|
0 |
0 |
" eval q!sub " + name + " { " + origxs + "(@_) } !;\n" + |
|
|
0 |
0 |
" eval q!sub " + name + " { " + origxs + "(@_) } !;\n" + |
|
|
0 |
0 |
" eval q!sub " + name + " { " + origxs + "(@_) } !;\n" + |
|
|
0 |
0 |
" eval q!sub " + name + " { " + origxs + "(@_) } !;\n" + |
|
45
|
0 |
0 |
" " + next_code + "(@_);\n" + |
|
|
0 |
0 |
" " + next_code + "(@_);\n" + |
|
|
0 |
0 |
" " + next_code + "(@_);\n" + |
|
46
|
0 |
0 |
"}\n" + |
|
47
|
0 |
0 |
"\\&" + name; |
|
48
|
0 |
0 |
return eval_pv(code.c_str(), 1); |
|
53
|
0 |
0 |
if (CvFLAGS(cv) & CVf_NEXT_WRAPPER_CREATED) { // ensure module has a perl wrapper for cv |
|
55
|
0 |
0 |
PUSHMARK(SP); |
|
56
|
0 |
0 |
for (I32 i = 0; i < items; ++i) XPUSHs(*args++); |
|
|
0 |
0 |
for (I32 i = 0; i < items; ++i) XPUSHs(*args++); |
|
59
|
0 |
0 |
if (type == NEXT_SUPER) { |
|
61
|
0 |
0 |
GV* supergv = gv_fetchmethod_pvn_flags( |
|
66
|
0 |
0 |
count = call_method(type == NEXT_METHOD ? "next::method" : "maybe::next::method", flags|G_SCALAR); |
|
69
|
0 |
0 |
while (count--) ret = POPs; |
|
72
|
0 |
0 |
FREETMPS; LEAVE; |
|
77
|
0 |
0 |
PUSHMARK(SP); |
|
78
|
0 |
0 |
for (I32 i = 0; i < items; ++i) XPUSHs(*args++); |
|
|
0 |
0 |
for (I32 i = 0; i < items; ++i) XPUSHs(*args++); |
|
82
|
0 |
0 |
while (count--) ret = POPs; |
|
83
|
0 |
0 |
SvREFCNT_inc_simple_void(ret); |
|
85
|
0 |
0 |
FREETMPS; LEAVE; |
|
93
|
0 |
0 |
PUSHMARK(SP); |
|
94
|
0 |
0 |
if (first_arg) XPUSHs(first_arg); |
|
|
0 |
0 |
if (first_arg) XPUSHs(first_arg); |
|
95
|
0 |
0 |
for (I32 i = 0; i < rest_items; ++i) XPUSHs(*rest_args++); |
|
|
0 |
0 |
for (I32 i = 0; i < rest_items; ++i) XPUSHs(*rest_args++); |
|
97
|
0 |
0 |
if (maxret <= 0 && !aref) { flags |= G_DISCARD; maxret = 0; } |
|
|
0 |
0 |
if (maxret <= 0 && !aref) { flags |= G_DISCARD; maxret = 0; } |
|
99
|
0 |
0 |
I32 nret = count > maxret ? maxret : count; |
|
102
|
0 |
0 |
if (!aref) { |
|
103
|
0 |
0 |
while (count > maxret) { POPs; --count; } |
|
104
|
0 |
0 |
while (count > 0) ret[--count] = SvREFCNT_inc_NN(POPs); |
|
106
|
0 |
0 |
else if (count) { |
|
111
|
0 |
0 |
while (count--) svlist[count] = SvREFCNT_inc_NN(POPs); |
|
116
|
0 |
0 |
FREETMPS; LEAVE; |
|
118
|
0 |
0 |
if (aref && *aref) sv_2mortal((SV*)*aref); |
|
|
0 |
0 |
if (aref && *aref) sv_2mortal((SV*)*aref); |
|
119
|
0 |
0 |
else for (I32 i = 0; i < nret; ++i) sv_2mortal(ret[i]); |
|
126
|
0 |
0 |
if (SvROK(obj)) { |
|
128
|
0 |
0 |
if (SvOBJECT(sv)) stash = SvSTASH(sv); |
|
130
|
0 |
0 |
if (!stash) stash = gv_stashsv(obj, GV_ADD); |
|
141
|
0 |
0 |
if (perl_object) { |
|
150
|
0 |
0 |
while (*module) { |
|
151
|
0 |
0 |
if (*module == ':') { |
|
170
|
0 |
0 |
HV* inc = get_hv("INC", GV_ADD); |
|
171
|
0 |
0 |
SV** ref = hv_fetch(inc, source_module_path, source_module_path_len, 0); |
|
172
|
0 |
0 |
if (!ref) return false; |
|
176
|
0 |
0 |
hv_store(inc, module_path, module_path_len, SvREFCNT_inc(*ref), 0); |
|
190
|
0 |
0 |
av_push(get_av(module_isa, GV_ADD), newSVpv_share(parent, 0)); |
|
|
0 |
0 |
av_push(get_av(module_isa, GV_ADD), newSVpv_share(parent, 0)); |
|
|
0 |
0 |
av_push(get_av(module_isa, GV_ADD), newSVpv_share(parent, 0)); |
|
197
|
0 |
0 |
char* class_name = abi::__cxa_demangle(typeid(err).name(), NULL, NULL, &status); |
|
198
|
0 |
0 |
if (status != 0) croak("[error_sv] !critical! abi::__cxa_demangle error"); |
|
199
|
0 |
0 |
SV* errsv = newSVpvs("["); |
|
200
|
0 |
0 |
sv_catpv(errsv, class_name); |
|
201
|
0 |
0 |
sv_catpv(errsv, "] "); |
|
202
|
0 |
0 |
sv_catpv(errsv, err.what()); |
|
216
|
0 |
0 |
if (!var) return &PL_sv_undef; |
|
|
0 |
0 |
if (!var) return &PL_sv_undef; |
|
|
0 |
0 |
if (!var) return &PL_sv_undef; |
|
218
|
0 |
0 |
if (obase) { |
|
|
0 |
0 |
if (obase) { |
|
|
0 |
0 |
if (obase) { |
|
219
|
0 |
0 |
if (SvROK(obase)) { |
|
|
0 |
0 |
if (SvROK(obase)) { |
|
|
0 |
0 |
if (SvROK(obase)) { |
|
249
|
22 |
0 |
}; |
|
|
22 |
0 |
}; |