Skip to content
This repository has been archived by the owner on Dec 11, 2024. It is now read-only.

smartmatch reset issue #52

Open
atoomic opened this issue Jul 17, 2017 · 1 comment
Open

smartmatch reset issue #52

atoomic opened this issue Jul 17, 2017 · 1 comment

Comments

@atoomic
Copy link
Collaborator

atoomic commented Jul 17, 2017

This is a simplified version of xtestc/0274.t which is failing due to reset not working for a smartmatch

other tests impacted by this case:

  • xtestc/0274.t
  • op/reset.t
sub match { shift =~ m?xyz? ? 1 : 0; }

print "1..4\n";
print "ok 1 - first match succeeds\n" if match("xyz");
print "ok 2 - second match fails\n" unless match("xyz");
reset;
print "ok 3 - match after reset succeeds\n" if match("xyz"); # should match again
print "ok 4 - reset + match before => match fails\n" unless match("xyz");
atoomic added a commit that referenced this issue Jul 17, 2017
@toddr
Copy link
Member

toddr commented Jul 20, 2017

This worked before static PL_defstash but we don't really have a use case for fixing it.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Development

No branches or pull requests

2 participants