diff options
| author | Stephan Seitz <stephan.seitz@fau.de> | 2020-06-24 16:45:17 +0200 |
|---|---|---|
| committer | Kiyan Yazdani <yazdani.kiyan@protonmail.com> | 2020-06-26 13:52:59 +0200 |
| commit | 75bce1dc93293f4f1dfd1541386afb607f09d726 (patch) | |
| tree | 961b27574433bf9213cc395da1a803473a68f028 /queries/python | |
| parent | Python highlights: Add walrus operator (diff) | |
| download | nvim-treesitter-75bce1dc93293f4f1dfd1541386afb607f09d726.tar nvim-treesitter-75bce1dc93293f4f1dfd1541386afb607f09d726.tar.gz nvim-treesitter-75bce1dc93293f4f1dfd1541386afb607f09d726.tar.bz2 nvim-treesitter-75bce1dc93293f4f1dfd1541386afb607f09d726.tar.lz nvim-treesitter-75bce1dc93293f4f1dfd1541386afb607f09d726.tar.xz nvim-treesitter-75bce1dc93293f4f1dfd1541386afb607f09d726.tar.zst nvim-treesitter-75bce1dc93293f4f1dfd1541386afb607f09d726.zip | |
Python highlights: Reset highlighting in f-string interpolation
This solution is preferable to `(identifier) @Normal` since otherwise
everything without highlight will use string-highlighting.
Diffstat (limited to 'queries/python')
| -rw-r--r-- | queries/python/highlights.scm | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/queries/python/highlights.scm b/queries/python/highlights.scm index e238a9a8e..ca0f84387 100644 --- a/queries/python/highlights.scm +++ b/queries/python/highlights.scm @@ -1,9 +1,10 @@ ;; From tree-sitter-python licensed under MIT License ; Copyright (c) 2016 Max Brunsfeld -; Identifier naming conventions +; Reset highlighing in f-string interpolations +(interpolation) @Normal -(identifier) @Normal +; Identifier naming conventions ((identifier) @type (match? @type "^[A-Z]")) ((identifier) @constant |
