mirror of
https://github.com/zoriya/vim.git
synced 2026-05-29 18:03:01 +00:00
updated for version 7.2.422
Problem: May get E763 when using spell dictionaries.
Solution: Avoid utf-8 case folded character to be truncated to 8 bits and
differ from latin1. (Dominique Pelle)
This commit is contained in:
+8
-2
@@ -9780,10 +9780,16 @@ init_spell_chartab()
|
||||
{
|
||||
for (i = 128; i < 256; ++i)
|
||||
{
|
||||
int f = utf_fold(i);
|
||||
int u = utf_toupper(i);
|
||||
|
||||
spelltab.st_isu[i] = utf_isupper(i);
|
||||
spelltab.st_isw[i] = spelltab.st_isu[i] || utf_islower(i);
|
||||
spelltab.st_fold[i] = utf_fold(i);
|
||||
spelltab.st_upper[i] = utf_toupper(i);
|
||||
/* The folded/upper-cased value is different between latin1 and
|
||||
* utf8 for 0xb5, causing E763 for no good reason. Use the latin1
|
||||
* value for utf-8 to avoid this. */
|
||||
spelltab.st_fold[i] = (f < 256) ? f : i;
|
||||
spelltab.st_upper[i] = (u < 256) ? u : i;
|
||||
}
|
||||
}
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user