Categorize _ as a word char, not punctuation
This commit is contained in:
parent
0dde5f2cae
commit
2cc30cd07c
1 changed files with 2 additions and 2 deletions
|
@ -189,10 +189,10 @@ fn categorize(ch: char) -> Category {
|
|||
Category::Eol
|
||||
} else if ch.is_ascii_whitespace() {
|
||||
Category::Whitespace
|
||||
} else if is_word(ch) {
|
||||
Category::Word
|
||||
} else if ch.is_ascii_punctuation() {
|
||||
Category::Punctuation
|
||||
} else if ch.is_ascii_alphanumeric() {
|
||||
Category::Word
|
||||
} else {
|
||||
unreachable!()
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue