mirror of
https://github.com/neovim/neovim.git
synced 2025-02-25 18:55:25 -06:00
regexp_nfa: Remove another has_mbyte/…-checking code
This commit is contained in:
parent
30561afe41
commit
372b6af8ea
@ -2772,15 +2772,10 @@ static int nfa_max_width(nfa_state_T *startstate, int depth)
|
|||||||
case NFA_ANY:
|
case NFA_ANY:
|
||||||
case NFA_START_COLL:
|
case NFA_START_COLL:
|
||||||
case NFA_START_NEG_COLL:
|
case NFA_START_NEG_COLL:
|
||||||
/* matches some character, including composing chars */
|
// Matches some character, including composing chars.
|
||||||
if (enc_utf8)
|
len += MB_MAXBYTES;
|
||||||
len += MB_MAXBYTES;
|
|
||||||
else if (has_mbyte)
|
|
||||||
len += 2;
|
|
||||||
else
|
|
||||||
++len;
|
|
||||||
if (state->c != NFA_ANY) {
|
if (state->c != NFA_ANY) {
|
||||||
/* skip over the characters */
|
// Skip over the characters.
|
||||||
state = state->out1->out;
|
state = state->out1->out;
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user