summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSantos Gallegos <stsewd@protonmail.com>2021-10-30 11:50:56 -0500
committerStephan Seitz <stephan.seitz@fau.de>2021-10-31 10:22:43 +0100
commit0dd147e6b7bcd9735940e32f211ac03416b1a74b (patch)
treebecafb497697a0466517f5916a292d27444a2325
parentbd1399105026c7b067dc197b31ccdb2602700a86 (diff)
D: fix duplicate `@namespace` capture
The previous query was highlighting everything inside that node, but we only want to highlight the identifiers. Ref https://github.com/nvim-treesitter/nvim-treesitter/pull/1930/files#r735105675
-rw-r--r--queries/d/highlights.scm6
1 files changed, 2 insertions, 4 deletions
diff --git a/queries/d/highlights.scm b/queries/d/highlights.scm
index de98cff7..d7787ce6 100644
--- a/queries/d/highlights.scm
+++ b/queries/d/highlights.scm
@@ -250,10 +250,8 @@
(fundamental_type) @type.builtin
-[
- (module_name)
- (module_fully_qualified_name)
-] @namespace
+(module_fully_qualified_name (packages (package_name) @namespace))
+(module_name) @namespace
(at_attribute) @attribute