Skip to content

Commit f5dfc7b

Browse files
committed
applies issue #167 part 4,
adds punctuation scope to start/end of here-string
1 parent f9308e3 commit f5dfc7b

File tree

1 file changed

+34
-2
lines changed

1 file changed

+34
-2
lines changed

PowerShellSyntax.tmLanguage

Lines changed: 34 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -136,9 +136,25 @@
136136
</dict>
137137
<dict>
138138
<key>begin</key>
139-
<string>\@["\x{201C}-\x{201E}]\s*$</string>
139+
<string>(@["\x{201C}-\x{201E}])\s*$</string>
140+
<key>beginCaptures</key>
141+
<dict>
142+
<key>1</key>
143+
<dict>
144+
<key>name</key>
145+
<string>punctuation.definition.string.begin.powershell</string>
146+
</dict>
147+
</dict>
140148
<key>end</key>
141149
<string>^["\x{201C}-\x{201E}]@</string>
150+
<key>endCaptures</key>
151+
<dict>
152+
<key>0</key>
153+
<dict>
154+
<key>name</key>
155+
<string>punctuation.definition.string.end.powershell</string>
156+
</dict>
157+
</dict>
142158
<key>name</key>
143159
<string>string.quoted.double.heredoc.powershell</string>
144160
<key>patterns</key>
@@ -159,9 +175,25 @@
159175
</dict>
160176
<dict>
161177
<key>begin</key>
162-
<string>\@['\x{2018}-\x{201B}]\s*$</string>
178+
<string>(@['\x{2018}-\x{201B}])\s*$</string>
179+
<key>beginCaptures</key>
180+
<dict>
181+
<key>1</key>
182+
<dict>
183+
<key>name</key>
184+
<string>punctuation.definition.string.begin.powershell</string>
185+
</dict>
186+
</dict>
163187
<key>end</key>
164188
<string>^['\x{2018}-\x{201B}]@</string>
189+
<key>endCaptures</key>
190+
<dict>
191+
<key>0</key>
192+
<dict>
193+
<key>name</key>
194+
<string>punctuation.definition.string.end.powershell</string>
195+
</dict>
196+
</dict>
165197
<key>name</key>
166198
<string>string.quoted.single.heredoc.powershell</string>
167199
</dict>

0 commit comments

Comments
 (0)