aboutsummaryrefslogtreecommitdiff
path: root/runtime/lua/vim
diff options
context:
space:
mode:
Diffstat (limited to 'runtime/lua/vim')
-rw-r--r--runtime/lua/vim/treesitter/highlighter.lua6
1 files changed, 4 insertions, 2 deletions
diff --git a/runtime/lua/vim/treesitter/highlighter.lua b/runtime/lua/vim/treesitter/highlighter.lua
index e003cf577a..bf5bd791c3 100644
--- a/runtime/lua/vim/treesitter/highlighter.lua
+++ b/runtime/lua/vim/treesitter/highlighter.lua
@@ -85,8 +85,10 @@ function TSHighlighterQuery.new(lang, query_string)
hl = _link_default_highlight_once(lang .. hl, hl)
end
- rawset(table, capture, hl)
- return hl
+ local id = a.nvim_get_hl_id_by_name(hl)
+
+ rawset(table, capture, id)
+ return id
end
})