projects
/
p5sagit/Devel-BeginLift.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
(parent:
5e5bdeb
)
Return a nullop if the liftee returns a null sv.
Florian Ragwitz [Sat, 25 Oct 2008 10:16:32 +0000 (10:16 +0000)]
BeginLift.xs
patch
|
blob
|
blame
|
history
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