mirror of
https://github.com/nvim-treesitter/nvim-treesitter.git
synced 2026-07-21 12:50:09 -04:00
Add indent.propagate metadata
This allows multiple nodes which share the same line to contribute to indentation. (Primarily for lisp like languages)
This commit is contained in:
parent
6ba63e4844
commit
453d94ea3b
1 changed files with 3 additions and 1 deletions
|
|
@ -335,7 +335,9 @@ function M.get_indent(lnum)
|
|||
indent = indent
|
||||
end
|
||||
end
|
||||
is_processed = true
|
||||
if not metadata["indent.propagate"] then
|
||||
is_processed = true
|
||||
end
|
||||
if indent_is_absolute then
|
||||
-- don't allow further indenting by parent nodes, this is an absolute position
|
||||
return indent
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue