summaryrefslogtreecommitdiffstats
path: root/runtime/autoload
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2018-07-21 05:56:22 +0200
committerBram Moolenaar <Bram@vim.org>2018-07-21 05:56:22 +0200
commita9604e61451707b38fdcb088fbfaeea2b922fef6 (patch)
tree0d7a758f4225fb7c02ba22c75b920894e890bdd5 /runtime/autoload
parent872e451e8c326d5dd3062ef621fcbf0a4c5bef78 (diff)
Update runtime files.
Diffstat (limited to 'runtime/autoload')
-rw-r--r--runtime/autoload/spellfile.vim11
1 files changed, 6 insertions, 5 deletions
diff --git a/runtime/autoload/spellfile.vim b/runtime/autoload/spellfile.vim
index e7fd1d8b17..886fd53939 100644
--- a/runtime/autoload/spellfile.vim
+++ b/runtime/autoload/spellfile.vim
@@ -22,6 +22,7 @@ function! spellfile#LoadFile(lang)
endif
return
endif
+ let lang = tolower(a:lang)
" If the URL changes we try all files again.
if s:spellfile_URL != g:spellfile_URL
@@ -30,13 +31,13 @@ function! spellfile#LoadFile(lang)
endif
" I will say this only once!
- if has_key(s:donedict, a:lang . &enc)
+ if has_key(s:donedict, lang . &enc)
if &verbose
echomsg 'spellfile#LoadFile(): Tried this language/encoding before.'
endif
return
endif
- let s:donedict[a:lang . &enc] = 1
+ let s:donedict[lang . &enc] = 1
" Find spell directories we can write in.
let [dirlist, dirchoices] = spellfile#GetDirChoices()
@@ -57,14 +58,14 @@ function! spellfile#LoadFile(lang)
endif
endif
- let msg = 'Cannot find spell file for "' . a:lang . '" in ' . &enc
+ let msg = 'Cannot find spell file for "' . lang . '" in ' . &enc
let msg .= "\nDo you want me to try downloading it?"
if confirm(msg, "&Yes\n&No", 2) == 1
let enc = &encoding
if enc == 'iso-8859-15'
let enc = 'latin1'
endif
- let fname = a:lang . '.' . enc . '.spl'
+ let fname = lang . '.' . enc . '.spl'
" Split the window, read the file into a new buffer.
" Remember the buffer number, we check it below.
@@ -95,7 +96,7 @@ function! spellfile#LoadFile(lang)
let newbufnr = winbufnr(0)
endif
- let fname = a:lang . '.ascii.spl'
+ let fname = lang . '.ascii.spl'
echo 'Could not find it, trying ' . fname . '...'
call spellfile#Nread(fname)
if getline(2) !~ 'VIMspell'