summaryrefslogtreecommitdiff
path: root/op.c
diff options
context:
space:
mode:
authorGurusamy Sarathy <gsar@cpan.org>2000-02-19 17:33:05 +0000
committerGurusamy Sarathy <gsar@cpan.org>2000-02-19 17:33:05 +0000
commit87d7fd28459b8274079ce3260d3e07e306aa70d8 (patch)
treedb649fffb15247d6a5230e15695e8e67bb1bf420 /op.c
parentfe52b3b7bda653f279f0cacf2b55156e66a0d71d (diff)
downloadperl-87d7fd28459b8274079ce3260d3e07e306aa70d8.tar.gz
more B fixups to cope with empty GVs (these can only happen in pads)
p4raw-id: //depot/perl@5150
Diffstat (limited to 'op.c')
-rw-r--r--op.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/op.c b/op.c
index 32eb7b06ed..eb60ec1876 100644
--- a/op.c
+++ b/op.c
@@ -1412,18 +1412,19 @@ Perl_mod(pTHX_ OP *o, I32 type)
if (kid->op_type == OP_METHOD_NAMED
|| kid->op_type == OP_METHOD)
{
- OP *newop;
+ UNOP *newop;
if (kid->op_sibling || kid->op_next != kid) {
yyerror("panic: unexpected optree near method call");
break;
}
- NewOp(1101, newop, 1, OP);
+ NewOp(1101, newop, 1, UNOP);
newop->op_type = OP_RV2CV;
newop->op_ppaddr = PL_ppaddr[OP_RV2CV];
- newop->op_next = newop;
- kid->op_sibling = newop;
+ newop->op_first = Nullop;
+ newop->op_next = (OP*)newop;
+ kid->op_sibling = (OP*)newop;
newop->op_private |= OPpLVAL_INTRO;
break;
}