| Age | Commit message (Collapse) | Author |
|
This avoids some stack overflows when a language includes itself.
This is a temporary solution, and will be addressed later when actually
managing our own parsers.
|
|
|
|
|
|
also fixes the memoize_by_buf_tick function
|
|
|
|
Allow the LanguageTree to be used as an option for highlighting.
Co-authored-by: Santos Gallegos <stsewd@protonmail.com>
Co-authored-by: Yazdani Kiyan <yazdani.kiyan@protonmail.com>
|
|
The following query will result in matches with only one node though it
requires two nodes to be a match.
```scheme
(function_definition
(comment) @function.inner.start
body: (block) @function.inner)
```
Why? First `insert_to_path` is called for `@function.inner.start` which
will result int the following table.
```lua
{ function = { inner = { start { node } } } }
```
`insert_to_path` will overwrite the result
```lua
{ function = { inner = { node } } }
```
Related #552
|
|
upstream now handles parsers by itself, so we don't need to do it
in this repo.
|
|
|
|
|
|
|
|
This implements https://github.com/neovim/neovim/pull/13059#issuecomment-704414189
This behaves like modelines and remove the use of the base_language map.
Also, this allows to fine-tune what we actually want to include per
query, which is better IMO.
|
|
Start adding highlights for
- C++
- Rust (including other scoped_identifier/scoped_type_identifier fixes)
- JS (only namespace_import)
Addresses #516
|
|
|
|
- Move select_* function to shell_command_selectors.lua.
- Rename select_args to select_compiler_args.
|
|
Use tar instead which should be available on default Unixes and Windows
|
|
|
|
|
|
|
|
|
|
chore(modules): remove refactor module
|
|
|
|
|
|
|
|
|
|
|
|
More and more Github repos are switching to "main" branch.
Example: `tree-sitter-wasm`
|
|
|
|
Compilers are selectable via 'nvim-treesitter.install'.compilers (list of compilers) or environment variable CC
Addresses #502
|
|
|
|
|
|
The files have the mli extension. The parser grammar uses the name
ocaml_interface, but since vim the underscore has a special meaning
ocamlinterface is used as the filetype.
|
|
@exception for Java/JS
|
|
|
|
|
|
These groups will be added for use with xml-like tags such as html and
jsx.
|
|
* Ignore tags file in project root
* Make :TSInstall work with Nix
This commit adds logic to determine where to install parsers, meaning
the *.so files. Until now the package path of the nvim-treesitter plugin
was used. But when installed with Nix, the plugin lands in "/nix/store",
which is read-only.
With this commit $XDG_DATA_HOME/nvim/site/parser/*.go will be used as
the parser installation path. The directory will be created if it
doesn't exist.
* Add generate_join function
The generate_join function is used to create two other functions, one
to join path segments, the other to join strings with a space for error
messages.
|
|
|
|
|
|
We use plural names for all query files except folds.
|
|
Reading the code, these functions should be named differently
https://github.com/nvim-treesitter/nvim-treesitter/blob/a755017dd52947672af458743b88e59a59cd592f/lua/nvim-treesitter/query.lua#L203-L203
|
|
|
|
|
|
- Don't load everything at startup
- Don't define an autocomand for each module and for each supported lang
(this creates nxm autocomand!)
|
|
This is more robust compared to the previous method where we walked
up the tree and matched on the directory name, which also required
that the repository was cloned in a directory named `nvim-treesitter`.
|
|
Paths were changed https://github.com/tree-sitter/tree-sitter-ocaml/pull/41
|
|
Even if it's an empty iterator.
|
|
|
|
|
|
|