File tree Expand file tree Collapse file tree 1 file changed +18
-7
lines changed
Expand file tree Collapse file tree 1 file changed +18
-7
lines changed Original file line number Diff line number Diff line change @@ -360,12 +360,7 @@ patterns:
360360
361361- include : ' #dotted_name'
362362
363- - begin : (\()
364- end : (\))
365- patterns :
366- - include : $self
367-
368- - match : (\[)(\s*(\]))\b
363+ - match : \b(\[)(\s*(\]))\b
369364 captures :
370365 ' 1 ' : {name: punctuation.definition.list.begin.python}
371366 ' 2 ' : {name: meta.empty-list.python}
@@ -388,12 +383,28 @@ patterns:
388383 - include : $self
389384
390385- name : meta.structure.tuple.python
391- match : (\()(\s*(\)))
386+ match : \b (\()(\s*(\)))\b
392387 captures :
393388 ' 1 ' : {name: punctuation.definition.tuple.begin.python}
394389 ' 2 ' : {name: meta.empty-tuple.python}
395390 ' 3 ' : {name: punctuation.definition.tuple.end.python}
396391
392+ - name : meta.structure.tuple.python
393+ begin : \b(\()
394+ beginCaptures :
395+ ' 1 ' : {name: punctuation.definition.tuple.begin.python}
396+ end : (\))\b
397+ endCaptures :
398+ ' 1 ' : {name: punctuation.definition.tuple.end.python}
399+ patterns :
400+ - contentName : meta.structure.tuple.item.python
401+ begin : (?<=\(|\,)\s*(?![\),])
402+ end : \s*(?:(,)|(?=\)))
403+ endCaptures :
404+ ' 1 ' : {name: punctuation.separator.tuple.python}
405+ patterns :
406+ - include : $self
407+
397408- name : meta.structure.dictionary.python
398409 match : (\{)(\s*(\}))
399410 captures :
You can’t perform that action at this time.
0 commit comments