diff options
author | sumneko <sumneko@hotmail.com> | 2021-12-06 12:59:49 +0800 |
---|---|---|
committer | sumneko <sumneko@hotmail.com> | 2021-12-06 12:59:49 +0800 |
commit | 1a067225e1a168c41b34279eb08587306734decb (patch) | |
tree | 62d254b301ff155d576ef7acbd1425be08acb192 /script/encoder/utf16.lua | |
parent | 8a67a44f6001d02bbd51a17c5ebcc718dee937c5 (diff) | |
download | lua-language-server-1a067225e1a168c41b34279eb08587306734decb.zip |
fix #844
Diffstat (limited to 'script/encoder/utf16.lua')
-rw-r--r-- | script/encoder/utf16.lua | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/script/encoder/utf16.lua b/script/encoder/utf16.lua index 744da174..7b08e082 100644 --- a/script/encoder/utf16.lua +++ b/script/encoder/utf16.lua @@ -92,6 +92,8 @@ local function utf8next(s, n) return n+3, utf8byte(s, n) elseif strmatch(s, "^[\xED][\x80-\x9F][\x80-\xBF]", n) then return n+3, utf8byte(s, n) + elseif strmatch(s, "^[\xEE-\xEF][\x80-\xBF][\x80-\xBF]", n) then + return n+3, utf8byte(s, n) elseif strmatch(s, "^[\xF0][\x90-\xBF][\x80-\xBF][\x80-\xBF]", n) then return n+4, utf8byte(s, n) elseif strmatch(s, "^[\xF1-\xF3][\x80-\xBF][\x80-\xBF][\x80-\xBF]", n) then |