regexp_nfa: Remove another has_mbyte/…-checking code

This commit is contained in:
ZyX 2017-04-16 21:41:55 +03:00
parent 30561afe41
commit 372b6af8ea

View File

@ -2772,15 +2772,10 @@ static int nfa_max_width(nfa_state_T *startstate, int depth)
case NFA_ANY:
case NFA_START_COLL:
case NFA_START_NEG_COLL:
/* matches some character, including composing chars */
if (enc_utf8)
len += MB_MAXBYTES;
else if (has_mbyte)
len += 2;
else
++len;
// Matches some character, including composing chars.
len += MB_MAXBYTES;
if (state->c != NFA_ANY) {
/* skip over the characters */
// Skip over the characters.
state = state->out1->out;
continue;
}