Skip to content

Commit 700103b

Browse files
committed
Reorder scopes for f-strings; fixes issue #75.
1 parent b7d7f9d commit 700103b

File tree

3 files changed

+21
-21
lines changed

3 files changed

+21
-21
lines changed

Diff for: grammars/MagicPython.cson

+6-6
Original file line numberDiff line numberDiff line change
@@ -4448,7 +4448,7 @@ repository:
44484448
end: "(\\3)|((?<!\\\\)\\n)"
44494449
beginCaptures:
44504450
"1":
4451-
name: "string.quoted.single.python string.interpolated.python storage.type.string.python"
4451+
name: "storage.type.string.python string.quoted.single.python string.interpolated.python"
44524452
"2":
44534453
name: "invalid.illegal.prefix.python"
44544454
"3":
@@ -4480,7 +4480,7 @@ repository:
44804480
"1":
44814481
name: "invalid.illegal.prefix.python"
44824482
"2":
4483-
name: "string.quoted.single.python string.interpolated.python storage.type.string.python"
4483+
name: "storage.type.string.python string.quoted.single.python string.interpolated.python"
44844484
"3":
44854485
name: "string.quoted.single.python punctuation.definition.string.begin.python"
44864486
endCaptures:
@@ -4508,7 +4508,7 @@ repository:
45084508
end: "(\\2)|((?<!\\\\)\\n)"
45094509
beginCaptures:
45104510
"1":
4511-
name: "string.quoted.raw.single.python string.interpolated.python storage.type.string.python"
4511+
name: "storage.type.string.python string.quoted.raw.single.python string.interpolated.python"
45124512
"2":
45134513
name: "string.quoted.raw.single.python punctuation.definition.string.begin.python"
45144514
endCaptures:
@@ -4672,7 +4672,7 @@ repository:
46724672
end: "(\\3)"
46734673
beginCaptures:
46744674
"1":
4675-
name: "string.quoted.multi.python string.interpolated.python storage.type.string.python"
4675+
name: "storage.type.string.python string.quoted.multi.python string.interpolated.python"
46764676
"2":
46774677
name: "invalid.illegal.prefix.python"
46784678
"3":
@@ -4704,7 +4704,7 @@ repository:
47044704
"1":
47054705
name: "invalid.illegal.prefix.python"
47064706
"2":
4707-
name: "string.quoted.multi.python string.interpolated.python storage.type.string.python"
4707+
name: "storage.type.string.python string.quoted.multi.python string.interpolated.python"
47084708
"3":
47094709
name: "string.quoted.multi.python punctuation.definition.string.begin.python"
47104710
endCaptures:
@@ -4732,7 +4732,7 @@ repository:
47324732
end: "(\\2)"
47334733
beginCaptures:
47344734
"1":
4735-
name: "string.quoted.raw.multi.python string.interpolated.python storage.type.string.python"
4735+
name: "storage.type.string.python string.quoted.raw.multi.python string.interpolated.python"
47364736
"2":
47374737
name: "string.quoted.raw.multi.python punctuation.definition.string.begin.python"
47384738
endCaptures:

Diff for: grammars/MagicPython.tmLanguage

+6-6
Original file line numberDiff line numberDiff line change
@@ -7805,7 +7805,7 @@ indirectly through syntactic constructs
78057805
<key>1</key>
78067806
<dict>
78077807
<key>name</key>
7808-
<string>string.quoted.single.python string.interpolated.python storage.type.string.python</string>
7808+
<string>storage.type.string.python string.quoted.single.python string.interpolated.python</string>
78097809
</dict>
78107810
<key>2</key>
78117811
<dict>
@@ -7869,7 +7869,7 @@ indirectly through syntactic constructs
78697869
<key>2</key>
78707870
<dict>
78717871
<key>name</key>
7872-
<string>string.quoted.single.python string.interpolated.python storage.type.string.python</string>
7872+
<string>storage.type.string.python string.quoted.single.python string.interpolated.python</string>
78737873
</dict>
78747874
<key>3</key>
78757875
<dict>
@@ -7923,7 +7923,7 @@ indirectly through syntactic constructs
79237923
<key>1</key>
79247924
<dict>
79257925
<key>name</key>
7926-
<string>string.quoted.raw.single.python string.interpolated.python storage.type.string.python</string>
7926+
<string>storage.type.string.python string.quoted.raw.single.python string.interpolated.python</string>
79277927
</dict>
79287928
<key>2</key>
79297929
<dict>
@@ -8177,7 +8177,7 @@ indirectly through syntactic constructs
81778177
<key>1</key>
81788178
<dict>
81798179
<key>name</key>
8180-
<string>string.quoted.multi.python string.interpolated.python storage.type.string.python</string>
8180+
<string>storage.type.string.python string.quoted.multi.python string.interpolated.python</string>
81818181
</dict>
81828182
<key>2</key>
81838183
<dict>
@@ -8241,7 +8241,7 @@ indirectly through syntactic constructs
82418241
<key>2</key>
82428242
<dict>
82438243
<key>name</key>
8244-
<string>string.quoted.multi.python string.interpolated.python storage.type.string.python</string>
8244+
<string>storage.type.string.python string.quoted.multi.python string.interpolated.python</string>
82458245
</dict>
82468246
<key>3</key>
82478247
<dict>
@@ -8295,7 +8295,7 @@ indirectly through syntactic constructs
82958295
<key>1</key>
82968296
<dict>
82978297
<key>name</key>
8298-
<string>string.quoted.raw.multi.python string.interpolated.python storage.type.string.python</string>
8298+
<string>storage.type.string.python string.quoted.raw.multi.python string.interpolated.python</string>
82998299
</dict>
83008300
<key>2</key>
83018301
<dict>

Diff for: grammars/src/pyfstring.inc.syntax.yaml

+9-9
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@ repository:
55
begin: (\b[fF])([bBuU])?(${marker})
66
end: (\3)${guard}
77
beginCaptures:
8-
'1': {name: string.quoted.${line}.python
9-
string.interpolated.python
10-
storage.type.string.python}
8+
'1': {name: storage.type.string.python
9+
string.quoted.${line}.python
10+
string.interpolated.python}
1111
'2': {name: invalid.illegal.prefix.python}
1212
'3': {name: string.quoted.${line}.python
1313
string.interpolated.python
@@ -29,9 +29,9 @@ repository:
2929
end: (\3)${guard}
3030
beginCaptures:
3131
'1': {name: invalid.illegal.prefix.python}
32-
'2': {name: string.quoted.${line}.python
33-
string.interpolated.python
34-
storage.type.string.python}
32+
'2': {name: storage.type.string.python
33+
string.quoted.${line}.python
34+
string.interpolated.python}
3535
'3': {name: string.quoted.${line}.python
3636
punctuation.definition.string.begin.python}
3737
endCaptures:
@@ -50,9 +50,9 @@ repository:
5050
begin: (\b(?:[R][fF]|[fF][R]))(${marker})
5151
end: (\2)${guard}
5252
beginCaptures:
53-
'1': {name: string.quoted.raw.${line}.python
54-
string.interpolated.python
55-
storage.type.string.python}
53+
'1': {name: storage.type.string.python
54+
string.quoted.raw.${line}.python
55+
string.interpolated.python}
5656
'2': {name: string.quoted.raw.${line}.python
5757
punctuation.definition.string.begin.python}
5858
endCaptures:

0 commit comments

Comments
 (0)