| 1 | ; Zig has no separate parameter/capture *use* coloring without scope tracking: |
| 2 | ; highlights.scm colors the binding, locals resolve the references. Only |
| 3 | ; parameters and `|capture|` payloads are defined here — `const`/`var` names are |
| 4 | ; left to highlights.scm because Zig reuses `const Name = struct/enum/error{…}` |
| 5 | ; for type definitions, which must stay @type, not resolve to a variable. |
| 6 | |
| 7 | [ |
| 8 | (function_declaration) |
| 9 | (block) |
| 10 | (for_statement) |
| 11 | (while_statement) |
| 12 | (if_statement) |
| 13 | (catch_expression) |
| 14 | (switch_case) |
| 15 | ] @local.scope |
| 16 | |
| 17 | (parameter name: (identifier) @local.definition.variable.parameter) |
| 18 | (payload (identifier) @local.definition.variable.parameter) |
| 19 | |
| 20 | (identifier) @local.reference |