fix: Do not consider underscores and middle dash hard

This commit is contained in:
Clément Renault 2019-09-24 20:14:20 +02:00
parent ca818e12a9
commit 175b3dcb75
No known key found for this signature in database
GPG Key ID: 92ADA4E935E71FA4

View File

@ -39,8 +39,8 @@ fn is_separator(c: char) -> bool {
fn classify_separator(c: char) -> Option<SeparatorCategory> {
match c {
' ' | '\'' | ':' | '"' => Some(Soft),
'.' | ';' | ',' | '!' | '?' | '-' | '_' | '(' | ')' => Some(Hard),
' ' | '-' | '_' | '\'' | ':' | '"' => Some(Soft),
'.' | ';' | ',' | '!' | '?' | '(' | ')' => Some(Hard),
_ => None,
}
}