aboutsummaryrefslogtreecommitdiff
path: root/runtime/lua/vim
diff options
context:
space:
mode:
authorMatthieu Coudron <mattator@gmail.com>2020-06-30 00:02:46 +0200
committerGitHub <noreply@github.com>2020-06-30 00:02:46 +0200
commit1920ba4b5597a872973de0a5d558cbbf23063fb6 (patch)
treed3c2cda699808a08493c6ce7883533b5186de46d /runtime/lua/vim
parentfd545d46fa9d9472159485ebc03e1f39417ee9c0 (diff)
parent69816f5e134f0e965352367b5928835794da1698 (diff)
downloadrneovim-1920ba4b5597a872973de0a5d558cbbf23063fb6.tar.gz
rneovim-1920ba4b5597a872973de0a5d558cbbf23063fb6.tar.bz2
rneovim-1920ba4b5597a872973de0a5d558cbbf23063fb6.zip
Merge pull request #12491 from vigoux/treesitter-set-ranges
[RDY] Treesitter set ranges
Diffstat (limited to 'runtime/lua/vim')
-rw-r--r--runtime/lua/vim/treesitter.lua6
1 files changed, 6 insertions, 0 deletions
diff --git a/runtime/lua/vim/treesitter.lua b/runtime/lua/vim/treesitter.lua
index c502e45bd0..f356673839 100644
--- a/runtime/lua/vim/treesitter.lua
+++ b/runtime/lua/vim/treesitter.lua
@@ -30,6 +30,12 @@ function Parser:_on_lines(bufnr, _, start_row, old_stop_row, stop_row, old_byte_
self.valid = false
end
+function Parser:set_included_ranges(ranges)
+ self._parser:set_included_ranges(ranges)
+ -- The buffer will need to be parsed again later
+ self.valid = false
+end
+
local M = {
parse_query = vim._ts_parse_query,
}