mirror of
https://github.com/nvim-treesitter/nvim-treesitter.git
synced 2026-07-02 03:26:52 -04:00
fix(indent): set only one autocmd for binding indentexpr (#3190)
This commit is contained in:
parent
a5709e685b
commit
7e0651cd56
1 changed files with 0 additions and 4 deletions
|
|
@ -195,10 +195,6 @@ local indent_funcs = {}
|
|||
function M.attach(bufnr)
|
||||
indent_funcs[bufnr] = vim.bo.indentexpr
|
||||
vim.bo.indentexpr = "nvim_treesitter#indent()"
|
||||
vim.api.nvim_create_autocmd("Filetype", {
|
||||
pattern = vim.bo.filetype,
|
||||
command = "setlocal indentexpr=nvim_treesitter#indent()",
|
||||
})
|
||||
end
|
||||
|
||||
function M.detach(bufnr)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue