Skip to content

Commit 180a414

Browse files
committed
fix indented node slashdash
1 parent 673c16c commit 180a414

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

kdl.tmLanguage.json

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -55,10 +55,10 @@
5555
"include": "#slashdash_comment"
5656
},
5757
{
58-
"include": "#slashdash_node_with_children_comment"
58+
"include": "#slashdash_node_comment"
5959
},
6060
{
61-
"include": "#slashdash_node_comment"
61+
"include": "#slashdash_node_with_children_comment"
6262
},
6363
{
6464
"include": "#line_comment"
@@ -201,26 +201,26 @@
201201
"slashdash_comment": {
202202
"name": "comment.block.slashdash.kdl",
203203
"comment": "Slashdash inline comment",
204-
"begin": "(?<!^)/-",
204+
"begin": "(?<!^\\s*)/-",
205205
"end": "\\s"
206206
},
207207
"slashdash_node_comment": {
208208
"name": "comment.block.slashdash.kdl",
209209
"comment": "Slashdash node comment",
210-
"begin": "(?<=^)/-",
210+
"begin": "(?<=^\\s*)/-[^{]+$",
211211
"end": "(?:;|(?<!\\\\)$)"
212212
},
213213
"slashdash_node_with_children_comment": {
214214
"name": "comment.block.slashdash.kdl",
215215
"comment": "Slashdash node comment",
216-
"begin": "(?<=^)/-[^{]+{",
216+
"begin": "(?<=^\\s*)/-[^{]+{",
217217
"end": "\\}"
218218
},
219219
"slashdash_block_comment": {
220220
"name": "comment.block.slashdash.kdl",
221221
"comment": "Slashdash block comment",
222-
"begin": "/-(?:\\s*){",
223-
"end": "}"
222+
"begin": "/-\\s*{",
223+
"end": "\\}"
224224
}
225225
},
226226
"scopeName": "source.kdl"

0 commit comments

Comments
 (0)