diff options
| author | Amaan Qureshi <amaanq12@gmail.com> | 2023-03-02 08:06:35 -0500 |
|---|---|---|
| committer | Amaan Qureshi <amaanq12@gmail.com> | 2023-03-05 17:15:32 -0500 |
| commit | 5a87bc98dabd0d38152a6fa774005f7ecbd40f1b (patch) | |
| tree | 941f6fdcddf4468c10212dd170bae3ff361f867c /queries/d/highlights.scm | |
| parent | docs: add `@comment.documentation` (diff) | |
| download | nvim-treesitter-5a87bc98dabd0d38152a6fa774005f7ecbd40f1b.tar nvim-treesitter-5a87bc98dabd0d38152a6fa774005f7ecbd40f1b.tar.gz nvim-treesitter-5a87bc98dabd0d38152a6fa774005f7ecbd40f1b.tar.bz2 nvim-treesitter-5a87bc98dabd0d38152a6fa774005f7ecbd40f1b.tar.lz nvim-treesitter-5a87bc98dabd0d38152a6fa774005f7ecbd40f1b.tar.xz nvim-treesitter-5a87bc98dabd0d38152a6fa774005f7ecbd40f1b.tar.zst nvim-treesitter-5a87bc98dabd0d38152a6fa774005f7ecbd40f1b.zip | |
feat: add `@comment.documentation` where applicable
Diffstat (limited to 'queries/d/highlights.scm')
| -rw-r--r-- | queries/d/highlights.scm | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/queries/d/highlights.scm b/queries/d/highlights.scm index 8bec1ca10..229a9bf55 100644 --- a/queries/d/highlights.scm +++ b/queries/d/highlights.scm @@ -4,7 +4,18 @@ (line_comment) (block_comment) (nesting_block_comment) -] @comment +] @comment @spell + +((line_comment) @comment.documentation + (#lua-match? @comment.documentation "^///[^/]")) +((line_comment) @comment.documentation + (#lua-match? @comment.documentation "^///$")) + +((block_comment) @comment.documentation + (#lua-match? @comment.documentation "^/[*][*][^*].*[*]/$")) + +((nesting_block_comment) @comment.documentation + (#lua-match? @comment.documentation "^/[+][+][^+].*[+]/$")) [ "(" ")" |
