nvim-treesitter/queries/devicetree/highlights.scm
Jędrzej Boczar 517c62d3e5
Add devicetree parser with queries (#900)
* Add devicetree parser with queries

* [docgen] Update README.md
skip-checks: true

* queries/devicetree: update highlight capture groups

* minor fix in CONTRIBUTING.md

* Revert "minor fix in CONTRIBUTING.md"

This reverts commit 23622b49db.

* queries/devicetree: add self as maintainer

* [docgen] Update README.md
skip-checks: true

Co-authored-by: Github Actions <actions@github>
2021-02-10 22:18:38 +01:00

35 lines
674 B
Scheme

(comment) @comment
[
(preproc_include)
(dtsi_include)
] @include
(preproc_def) @constant.macro
(preproc_function_def) @function.macro
[
(memory_reservation)
(file_version)
] @attribute
[
(string_literal)
(byte_string_literal)
(system_lib_string)
] @string
(integer_literal) @number
(identifier) @variable
(node (identifier) @namespace)
(property (identifier) @property)
(labeled_item (identifier) @label)
(call_expression (identifier) @function.macro)
(reference) @label ; referencing labeled_item.identifier
(unit_address) @constant
[ "=" ] @operator
[ "(" ")" "[" "]" "{" "}" "<" ">" ] @punctuation.bracket
[ ";" ":" "," "@" ] @punctuation.delimiter