aboutsummaryrefslogtreecommitdiff
path: root/runtime/lua/vim
diff options
context:
space:
mode:
Diffstat (limited to 'runtime/lua/vim')
-rw-r--r--runtime/lua/vim/filetype.lua4
-rw-r--r--runtime/lua/vim/filetype/detect.lua2
-rw-r--r--runtime/lua/vim/lsp/protocol.lua2
3 files changed, 3 insertions, 5 deletions
diff --git a/runtime/lua/vim/filetype.lua b/runtime/lua/vim/filetype.lua
index d2840b3a7e..fa792422ba 100644
--- a/runtime/lua/vim/filetype.lua
+++ b/runtime/lua/vim/filetype.lua
@@ -2285,8 +2285,6 @@ end
---
--- See $VIMRUNTIME/lua/vim/filetype.lua for more examples.
---
---- Note that Lua filetype detection is disabled when |g:do_legacy_filetype| is set.
----
--- Example:
--- <pre>
--- vim.filetype.add({
@@ -2323,7 +2321,7 @@ end
--- })
--- </pre>
---
---- To add a fallback match on contents (see |new-filetype-scripts|), use
+--- To add a fallback match on contents, use
--- <pre>
--- vim.filetype.add {
--- pattern = {
diff --git a/runtime/lua/vim/filetype/detect.lua b/runtime/lua/vim/filetype/detect.lua
index 7fc7f1b7ca..23fa1c5068 100644
--- a/runtime/lua/vim/filetype/detect.lua
+++ b/runtime/lua/vim/filetype/detect.lua
@@ -181,7 +181,7 @@ function M.cls(bufnr)
return vim.g.filetype_cls
end
local line = getlines(bufnr, 1)
- if line:find('^%%') then
+ if line:find('^[%%\\]') then
return 'tex'
elseif line:find('^#') and line:lower():find('rexx') then
return 'rexx'
diff --git a/runtime/lua/vim/lsp/protocol.lua b/runtime/lua/vim/lsp/protocol.lua
index 4034753322..7442c8f005 100644
--- a/runtime/lua/vim/lsp/protocol.lua
+++ b/runtime/lua/vim/lsp/protocol.lua
@@ -637,7 +637,7 @@ function protocol.make_client_capabilities()
codeActionLiteralSupport = {
codeActionKind = {
valueSet = (function()
- local res = vim.tbl_values(protocol.CodeActionKind)
+ local res = vim.tbl_values(constants.CodeActionKind)
table.sort(res)
return res
end)(),