mirror of
https://github.com/nvim-treesitter/nvim-treesitter.git
synced 2026-07-17 10:50:06 -04:00
Remove get_parser logic
upstream now handles parsers by itself, so we don't need to do it in this repo.
This commit is contained in:
parent
25bdf0f00d
commit
e5d8b6ade7
1 changed files with 1 additions and 7 deletions
|
|
@ -377,13 +377,7 @@ function M.get_parser(bufnr, lang)
|
||||||
local lang = lang or M.get_buf_lang(buf)
|
local lang = lang or M.get_buf_lang(buf)
|
||||||
|
|
||||||
if M.has_parser(lang) then
|
if M.has_parser(lang) then
|
||||||
if not M[buf] then
|
return ts.get_parser(bufnr, lang)
|
||||||
M[buf] = {}
|
|
||||||
end
|
|
||||||
if not M[buf][lang] then
|
|
||||||
M[buf][lang] = ts.get_parser(buf, lang)
|
|
||||||
end
|
|
||||||
return M[buf][lang]
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue