projects
/
p5sagit/Devel-BeginLift.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
Return a nullop if the liftee returns a null sv.
[p5sagit/Devel-BeginLift.git]
/
BeginLift.xs
diff --git
a/BeginLift.xs
b/BeginLift.xs
index
dd68f18
..
0030357
100644
(file)
--- a/
BeginLift.xs
+++ b/
BeginLift.xs
@@
-84,6
+84,11
@@
STATIC OP *lift_cb(pTHX_ OP *o, CV *cv, void *user_data) {
if (type == OP_RV2GV)
return newGVOP(OP_GV, 0, (GV*)sv);
+ if (SvTYPE(sv) == SVt_NULL) {
+ op_free(o);
+ return newOP(OP_NULL, 0);
+ }
+
return newSVOP(OP_CONST, 0, sv);
} else {
/* this bit not lifted, handles the 'sub doesn't return stuff' case