summaryrefslogtreecommitdiff
path: root/op.c
diff options
context:
space:
mode:
authorStephen McCamant <smcc@mit.edu>1998-08-02 11:33:18 -0500
committerGurusamy Sarathy <gsar@cpan.org>1998-08-08 22:27:15 +0000
commit51e247a3115dfbe56609ebd8c14d882747724db8 (patch)
tree074ce6c5f76c6873bb98a8416b3e4f05209ced5e /op.c
parentc5987ebb451d843cbf0a792310f25ebaec3f7378 (diff)
downloadperl-51e247a3115dfbe56609ebd8c14d882747724db8.tar.gz
Eliminate superfluous RV2p[AH]Vs in oops[AH]V()
Message-ID: <13764.55116.921952.837027@alias-2.pr.mcs.net> p4raw-id: //depot/perl@1763
Diffstat (limited to 'op.c')
-rw-r--r--op.c22
1 files changed, 2 insertions, 20 deletions
diff --git a/op.c b/op.c
index 3aac3bba41..d72d31389c 100644
--- a/op.c
+++ b/op.c
@@ -4055,7 +4055,7 @@ oopsAV(OP *o)
case OP_PADSV:
o->op_type = OP_PADAV;
o->op_ppaddr = ppaddr[OP_PADAV];
- return ref(newUNOP(OP_RV2AV, 0, scalar(o)), OP_RV2AV);
+ return ref(o, OP_RV2AV);
case OP_RV2SV:
o->op_type = OP_RV2AV;
@@ -4078,7 +4078,7 @@ oopsHV(OP *o)
case OP_PADAV:
o->op_type = OP_PADHV;
o->op_ppaddr = ppaddr[OP_PADHV];
- return ref(newUNOP(OP_RV2HV, 0, scalar(o)), OP_RV2HV);
+ return ref(o, OP_RV2HV);
case OP_RV2SV:
case OP_RV2AV:
@@ -5191,24 +5191,6 @@ peep(register OP *o)
o->op_seq = PL_op_seqmax++;
break;
- case OP_PADAV:
- if (o->op_next->op_type == OP_RV2AV
- && (o->op_next->op_flags & OPf_REF))
- {
- null(o->op_next);
- o->op_next = o->op_next->op_next;
- }
- break;
-
- case OP_PADHV:
- if (o->op_next->op_type == OP_RV2HV
- && (o->op_next->op_flags & OPf_REF))
- {
- null(o->op_next);
- o->op_next = o->op_next->op_next;
- }
- break;
-
case OP_MAPWHILE:
case OP_GREPWHILE:
case OP_AND: