Add support for PRUNE and SKIP (no MARK's though).

This commit is contained in:
jzmaddock
2015-10-01 18:34:59 +01:00
parent 83140ddbed
commit 9a36e035f2
7 changed files with 132 additions and 20 deletions

View File

@ -1001,7 +1001,16 @@ template <class BidiIterator, class Allocator, class traits>
bool perl_matcher<BidiIterator, Allocator, traits>::match_commit()
{
m_can_backtrack = false;
restart = last;
int action = static_cast<const re_commit*>(pstate)->action;
switch(action)
{
case commit_commit:
restart = last;
break;
case commit_skip:
restart = position;
break;
}
pstate = pstate->next.p;
return true;
}