summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTony Cook <tony@develop-help.com>2015-02-19 15:03:58 +1100
committerDavid Mitchell <davem@iabyn.com>2015-03-19 14:51:52 +0000
commit72e5fb6312b534c67eb2da0525dd3c09b5f9222b (patch)
tree761e34da3bcdac7b1421346b60f44acff2e67f55
parentb1741c2a17ce2a6a029d3c316c75e44569dfe66e (diff)
downloadperl-72e5fb6312b534c67eb2da0525dd3c09b5f9222b.tar.gz
update PL_stack_sp when we exit matcher_matches_sv()
-rw-r--r--pp_ctl.c6
-rw-r--r--t/op/smartmatch.t1
2 files changed, 5 insertions, 2 deletions
diff --git a/pp_ctl.c b/pp_ctl.c
index f7cb2167ab..23094e805d 100644
--- a/pp_ctl.c
+++ b/pp_ctl.c
@@ -4507,6 +4507,7 @@ STATIC bool
S_matcher_matches_sv(pTHX_ PMOP *matcher, SV *sv)
{
dSP;
+ bool result;
PERL_ARGS_ASSERT_MATCHER_MATCHES_SV;
@@ -4515,7 +4516,10 @@ S_matcher_matches_sv(pTHX_ PMOP *matcher, SV *sv)
PUTBACK;
(void) Perl_pp_match(aTHX);
SPAGAIN;
- return (SvTRUEx(POPs));
+ result = SvTRUEx(POPs);
+ PUTBACK;
+
+ return result;
}
STATIC void
diff --git a/t/op/smartmatch.t b/t/op/smartmatch.t
index f51884d39f..9db20693b6 100644
--- a/t/op/smartmatch.t
+++ b/t/op/smartmatch.t
@@ -136,7 +136,6 @@ sub NOT_DEF() { undef }
{
# [perl #123860]
# this can but might not crash
- local $::TODO = "not yet fixed...";
# This can but might not crash
#
# The second smartmatch would leave a &PL_sv_no on the stack for