From 730f4c74d6a446d682f5a3ce09166277cf022b9e Mon Sep 17 00:00:00 2001 From: David Mitchell Date: Thu, 13 Sep 2012 20:28:01 +0100 Subject: [PATCH] regmatch(): remove remaining reads of reginput In the remaining place where the value of reginput is used, its value should always be equal to locinput, so it can be eliminated there. This is part of a campaign to eliminate the reginput variable. --- regexec.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/regexec.c b/regexec.c index c2aba47..316bcaf 100644 --- a/regexec.c +++ b/regexec.c @@ -6155,8 +6155,9 @@ no_silent: /* clean up; in particular, free all slabs above current one */ LEAVE_SCOPE(oldsave); - assert(!result || reginput - PL_bostr >= 0); - return result ? reginput - PL_bostr : -1; + assert(!result || reginput == locinput); + assert(!result || locinput - PL_bostr >= 0); + return result ? locinput - PL_bostr : -1; } /* -- 2.7.4