summaryrefslogtreecommitdiff
path: root/pp.c
diff options
context:
space:
mode:
authorJarkko Hietaniemi <jhi@iki.fi>2001-03-26 22:01:18 +0000
committerJarkko Hietaniemi <jhi@iki.fi>2001-03-26 22:01:18 +0000
commit34d3ce40eab82fa6d52f54ff00b07b8cce11a920 (patch)
treef2a5a909171a605d2ae1d85a8c4be87d805b319c /pp.c
parentd8c7644ed9d0c74a190f456cd50d7fe4d4ff120c (diff)
downloadperl-34d3ce40eab82fa6d52f54ff00b07b8cce11a920.tar.gz
pp_ncmp() and pp_scmp() should return numeric values, not booleans.
Really need to benchmark this. p4raw-id: //depot/perl@9370
Diffstat (limited to 'pp.c')
-rw-r--r--pp.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/pp.c b/pp.c
index 337242868b..a79a1d4cb2 100644
--- a/pp.c
+++ b/pp.c
@@ -1786,7 +1786,7 @@ PP(pp_ncmp)
dSP; dTARGET; tryAMAGICbin(ncmp,0);
#ifndef NV_PRESERVES_UV
if (SvROK(TOPs) && SvROK(TOPm1s)) {
- SETs(boolSV(SvRV(TOPs) == SvRV(TOPm1s)));
+ SETi(PTR2UV(SvRV(TOPs)) - PTR2UV(SvRV(TOPm1s)));
RETURN;
}
#endif
@@ -1972,7 +1972,7 @@ PP(pp_scmp)
dSP; dTARGET; tryAMAGICbin(scmp,0);
#ifndef NV_PRESERVES_UV
if (SvROK(TOPs) && SvROK(TOPm1s)) {
- SETs(boolSV(SvRV(TOPs) == SvRV(TOPm1s)));
+ SETi(PTR2UV(SvRV(TOPs)) - PTR2UV(SvRV(TOPm1s)));
RETURN;
}
#endif