Commit 736bbe4
refactor: wrap only the raw-hex hardware-address forms in the literal label (#501)
HARDWARE_ADDRESS wrapped its whole alternation in Labeled(Role.LITERAL),
but two branches — IPV4_ADDR and IPV6_ADDR — are already Labeled (IPv6 also
carries SemanticTag.IPV6). So an IP literal got a redundant second literal
region over the same span. Move the wrapper down onto just the raw-hex forms
(RAW_HARDWARE_ADDRESS) and let the already-labeled IP forms sit beside it, so
every accepted value now colours as exactly one region. No matching change.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>1 parent 92c10bd commit 736bbe4
2 files changed
Lines changed: 27 additions & 11 deletions
File tree
- src
- main/kotlin/net/sjrx/intellij/plugins/systemdunitfiles/semanticdata/optionvalues/grammar
- test/kotlin/net/sjrx/intellij/plugins/systemdunitfiles/semanticdata/optionvalues/grammar
Lines changed: 17 additions & 9 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
128 | 128 | | |
129 | 129 | | |
130 | 130 | | |
131 | | - | |
132 | | - | |
133 | | - | |
134 | | - | |
135 | | - | |
136 | | - | |
137 | | - | |
138 | | - | |
139 | | - | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
140 | 136 | | |
141 | 137 | | |
142 | 138 | | |
143 | 139 | | |
144 | 140 | | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
145 | 153 | | |
Lines changed: 10 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
78 | 78 | | |
79 | 79 | | |
80 | 80 | | |
81 | | - | |
82 | | - | |
| 81 | + | |
| 82 | + | |
83 | 83 | | |
84 | 84 | | |
85 | 85 | | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
86 | 94 | | |
0 commit comments