mirror of
https://github.com/boostorg/regex.git
synced 2025-07-19 07:12:07 +02:00
Add missing optimization for leading .* repeats.
Fixes #7758. [SVN r81705]
This commit is contained in:
@ -1268,6 +1268,9 @@ bool perl_matcher<BidiIterator, Allocator, traits>::unwind_fast_dot_repeat(bool
|
|||||||
}while((count < rep->max) && (position != last) && !can_start(*position, rep->_map, mask_skip));
|
}while((count < rep->max) && (position != last) && !can_start(*position, rep->_map, mask_skip));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// remember where we got to if this is a leading repeat:
|
||||||
|
if((rep->leading) && (count < rep->max))
|
||||||
|
restart = position;
|
||||||
if(position == last)
|
if(position == last)
|
||||||
{
|
{
|
||||||
// can't repeat any more, remove the pushed state:
|
// can't repeat any more, remove the pushed state:
|
||||||
|
Reference in New Issue
Block a user