Add COMMIT support plus lots of tests.

This commit is contained in:
jzmaddock
2015-09-29 17:40:43 +01:00
parent 2580fb035f
commit c281c9cc40
10 changed files with 308 additions and 19 deletions

View File

@ -1149,6 +1149,7 @@ void basic_regex_creator<charT, traits>::create_startmap(re_syntax_base* state,
set_all_masks(l_map, mask);
return;
}
case syntax_element_accept:
case syntax_element_match:
{
// must be null, any character can match:
@ -1335,6 +1336,11 @@ void basic_regex_creator<charT, traits>::create_startmap(re_syntax_base* state,
state = state->next.p;
break;
case syntax_element_commit:
set_all_masks(l_map, mask);
// Continue scanning so we can figure out whether we can be null:
state = state->next.p;
break;
case syntax_element_startmark:
// need to handle independent subs as a special case:
if(static_cast<re_brace*>(state)->index == -3)