1
0
forked from aniani/vim

patch 8.2.1926: cannot use a space in 'spellfile'

Problem:    Cannot use a space in 'spellfile'. (Filipe Brandenburger)
Solution:   Permit using a space. (closes #7230)
This commit is contained in:
Bram Moolenaar
2020-10-30 19:25:09 +01:00
parent 6d967125ad
commit b2620202c7
3 changed files with 4 additions and 2 deletions

View File

@@ -4340,7 +4340,7 @@ valid_spellfile(char_u *val)
char_u *s; char_u *s;
for (s = val; *s != NUL; ++s) for (s = val; *s != NUL; ++s)
if (!vim_isfilec(*s) && *s != ',') if (!vim_isfilec(*s) && *s != ',' && *s != ' ')
return FALSE; return FALSE;
return TRUE; return TRUE;
} }

View File

@@ -130,7 +130,7 @@ let test_values = {
\ 'selectmode': [['', 'mouse', 'key,cmd'], ['xxx']], \ 'selectmode': [['', 'mouse', 'key,cmd'], ['xxx']],
\ 'sessionoptions': [['', 'blank', 'help,options,slash'], ['xxx']], \ 'sessionoptions': [['', 'blank', 'help,options,slash'], ['xxx']],
\ 'signcolumn': [['', 'auto', 'no'], ['xxx', 'no,yes']], \ 'signcolumn': [['', 'auto', 'no'], ['xxx', 'no,yes']],
\ 'spellfile': [['', 'file.en.add'], ['xxx', '/tmp/file']], \ 'spellfile': [['', 'file.en.add', '/tmp/dir\ with\ space/en.utf-8.add'], ['xxx', '/tmp/file']],
\ 'spelllang': [['', 'xxx', 'sr@latin'], ['not&lang', "that\\\rthere"]], \ 'spelllang': [['', 'xxx', 'sr@latin'], ['not&lang', "that\\\rthere"]],
\ 'spelloptions': [['', 'camel'], ['xxx']], \ 'spelloptions': [['', 'camel'], ['xxx']],
\ 'spellsuggest': [['', 'best', 'double,33'], ['xxx']], \ 'spellsuggest': [['', 'best', 'double,33'], ['xxx']],

View File

@@ -750,6 +750,8 @@ static char *(features[]) =
static int included_patches[] = static int included_patches[] =
{ /* Add new patch number below this line */ { /* Add new patch number below this line */
/**/
1926,
/**/ /**/
1925, 1925,
/**/ /**/