diff options
author | Gurusamy Sarathy <gsar@cpan.org> | 2000-01-23 21:19:31 +0000 |
---|---|---|
committer | Gurusamy Sarathy <gsar@cpan.org> | 2000-01-23 21:19:31 +0000 |
commit | 64aac5a92f5a6e49b46f320202aef13277e3640b (patch) | |
tree | dc769bae26728d6b9d6f8cb8fd32b0f2c89544a1 /op.c | |
parent | ef8040b067557994d471dfa4e5ac3900907e94ce (diff) | |
download | perl-64aac5a92f5a6e49b46f320202aef13277e3640b.tar.gz |
change#4866 was flawed; revert and add better fix for warning
p4raw-link: @4866 on //depot/perl: ef8040b067557994d471dfa4e5ac3900907e94ce
p4raw-id: //depot/perl@4867
Diffstat (limited to 'op.c')
-rw-r--r-- | op.c | 15 |
1 files changed, 4 insertions, 11 deletions
@@ -1098,7 +1098,7 @@ Perl_scalarvoid(pTHX_ OP *o) case OP_GGRGID: case OP_GETLOGIN: func_ops: - if (!(o->op_private & OPpLVAL_INTRO)) + if (!(o->op_private & (OPpLVAL_INTRO|OPpOUR_INTRO))) useless = PL_op_desc[o->op_type]; break; @@ -6292,17 +6292,10 @@ Perl_peep(pTHX_ register OP *o) case OP_GV: if (o->op_next->op_type == OP_RV2SV) { - /* don't execute our($foo) */ - if (o->op_next->op_private & OPpOUR_INTRO) { + if (!(o->op_next->op_private & OPpDEREF)) { null(o->op_next); - o->op_next = o->op_next->op_next; - null(o); - if (oldop && o->op_next) - oldop->op_next = o->op_next; - } - else if (!(o->op_next->op_private & OPpDEREF)) { - null(o->op_next); - o->op_private |= o->op_next->op_private & OPpLVAL_INTRO; + o->op_private |= o->op_next->op_private & (OPpLVAL_INTRO + | OPpOUR_INTRO); o->op_next = o->op_next->op_next; o->op_type = OP_GVSV; o->op_ppaddr = PL_ppaddr[OP_GVSV]; |