Stephan Seitz

Results 462 comments of Stephan Seitz

@clason should we merge this? This is also part of nvim-treesitter being a better citizen and installing parsers in random locations.

Nix can configure a location for the parsers or handle the installation of the parsers via nix (instead of using the installation routine of this plugin) or use the installation...

will root even use `/root/.local/share/nvim/` or rather `/usr/local/share/nvim`? What does `:lua print(require'nvim-treesitter.utils'.get_package_path())` or `:lua print(require'nvim-treesitter.utils'.get_cache_dir())` return?

I think this is the same issue as with #2497 and Lua earlier where a `")" @indent_end` might help to end the aligned indent

@dchuri you can try to apply a similar fixed like: https://github.com/nvim-treesitter/nvim-treesitter/pull/2505#discussion_r802876518 so making `[")" "]" "}"] @indent_end`

In any case, those additional queries will be a opt-in module. Normal people don't have to fear any impact by semantic queries.

- avoiding `iter_prepared_matches` and `is_definition` (avoid allocation and destructuring of unnecessary tables, this should be the main speed up) - using dictionaries instead of walking lists for look up -...

@steelsojka we could, I tried to start this. But there is so much that relies on `iter_prepared_matches` and how it arranges data. So it could involve some work. It would...

Using it on a 80k C++ file with `highlight_definition` and `updatetime=100`. no problem :sunglasses: . ```lua function M.highlight_usages(bufnr) M.clear_usage_highlights(bufnr) local node_at_point = ts_utils.get_node_at_cursor() local references = locals.get_references(bufnr) if not node_at_point...

Am advantage of this implementation is that the last definition (if multiple) is taken... needs to be fixed