diff --git a/queries/highlights.scm b/queries/highlights.scm index af38e25..9541314 100644 --- a/queries/highlights.scm +++ b/queries/highlights.scm @@ -24,6 +24,13 @@ ; Declarations {{{ (identifier) @variable + +(module + type: (identifier) @module) + +(module + (property + field: (identifier) @variable.member)) ; }}} ; vim: sw=2 foldmethod=marker diff --git a/test/highlight/modules.bp b/test/highlight/modules.bp new file mode 100644 index 0000000..248acdf --- /dev/null +++ b/test/highlight/modules.bp @@ -0,0 +1,21 @@ +foo {} +// <- module + +foo () +// <- module + +foo { +// <- module + field: 12, + // <- variable.member + another_field: 27, + // <- variable.member +} + +foo ( +// <- module + field = 42, + // <- variable.member + done = false, + // <- variable.member +)