summaryrefslogtreecommitdiff
path: root/op.c
diff options
context:
space:
mode:
authorDave Mitchell <davem@fdisolutions.com>2006-12-16 02:53:59 +0000
committerDave Mitchell <davem@fdisolutions.com>2006-12-16 02:53:59 +0000
commitfbbb0949fb5d97bb5d3054c00542ffb2f1aed7cf (patch)
treee3bcb6feb52b91b5251399061ec64dbba25661e9 /op.c
parentca06c01c30b19d0094642f2e317dadf13d4509cd (diff)
downloadperl-fbbb0949fb5d97bb5d3054c00542ffb2f1aed7cf.tar.gz
don't include MAD code when its not needed
p4raw-id: //depot/perl@29561
Diffstat (limited to 'op.c')
-rw-r--r--op.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/op.c b/op.c
index 03f54b1311..2ed219811e 100644
--- a/op.c
+++ b/op.c
@@ -2826,9 +2826,12 @@ Perl_pmtrans(pTHX_ OP *o, OP *expr, OP *repl)
{
dVAR;
SV * const tstr = ((SVOP*)expr)->op_sv;
- SV * const rstr = (repl->op_type == OP_NULL)
- ? ((SVOP*)((LISTOP*)repl)->op_first)->op_sv
- : ((SVOP*)repl)->op_sv;
+ SV * const rstr =
+#ifdef PERL_MAD
+ (repl->op_type == OP_NULL)
+ ? ((SVOP*)((LISTOP*)repl)->op_first)->op_sv :
+#endif
+ ((SVOP*)repl)->op_sv;
STRLEN tlen;
STRLEN rlen;
const U8 *t = (U8*)SvPV_const(tstr, tlen);