diff options
| author | Fabian <f.vioel@gmail.com> | 2021-12-18 22:49:30 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-12-18 16:49:30 -0500 |
| commit | e01c7ce9727b9d18b71b41cc792cb4719e469598 (patch) | |
| tree | c082cddee304089a402eca397db0a9a95c222d60 /queries/python/locals.scm | |
| parent | Update lockfile.json (diff) | |
| download | nvim-treesitter-e01c7ce9727b9d18b71b41cc792cb4719e469598.tar nvim-treesitter-e01c7ce9727b9d18b71b41cc792cb4719e469598.tar.gz nvim-treesitter-e01c7ce9727b9d18b71b41cc792cb4719e469598.tar.bz2 nvim-treesitter-e01c7ce9727b9d18b71b41cc792cb4719e469598.tar.lz nvim-treesitter-e01c7ce9727b9d18b71b41cc792cb4719e469598.tar.xz nvim-treesitter-e01c7ce9727b9d18b71b41cc792cb4719e469598.tar.zst nvim-treesitter-e01c7ce9727b9d18b71b41cc792cb4719e469598.zip | |
highlights(python): Improve self and cls highlight (#2134)
1. This function simplifies an unnecessary lua-match usage.
2. Fixes an accidental change, where "cls" was changed to "class" (fe4f320b66)
3. Match functions, which have have a decorator.
4. But exclude @staticmethod
5. Only highlight "cls" as @variable.builtin when the decorator is @classmethod
This might be a bit to complicated and some of this not to useful,
as this existing rule:
```scm
((identifier) @variable.builtin
(#eq? @variable.builtin "self"))
```
overwrites the queries anyway.
Diffstat (limited to 'queries/python/locals.scm')
0 files changed, 0 insertions, 0 deletions
