Skip to content

Commit e77ecf2

Browse files
committed
fix not actually a negate operator
1 parent 27d43c9 commit e77ecf2

File tree

1 file changed

+16
-14
lines changed

1 file changed

+16
-14
lines changed

PowerShellSyntax.tmLanguage

Lines changed: 16 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -3881,12 +3881,12 @@
38813881
<key>1</key>
38823882
<dict>
38833883
<key>name</key>
3884-
<string>keyword.operator.arithmetic.unary.increment.powershell</string>
3884+
<string>keyword.operator.arithmetic.postfix.unary.increment.powershell</string>
38853885
</dict>
38863886
<key>2</key>
38873887
<dict>
38883888
<key>name</key>
3889-
<string>keyword.operator.arithmetic.unary.decrement.powershell</string>
3889+
<string>keyword.operator.arithmetic.postfix.unary.decrement.powershell</string>
38903890
</dict>
38913891
</dict>
38923892
</dict>
@@ -3904,12 +3904,12 @@
39043904
<key>1</key>
39053905
<dict>
39063906
<key>name</key>
3907-
<string>keyword.operator.arithmetic.unary.increment.powershell</string>
3907+
<string>keyword.operator.arithmetic.prefix.unary.increment.powershell</string>
39083908
</dict>
39093909
<key>2</key>
39103910
<dict>
39113911
<key>name</key>
3912-
<string>keyword.operator.arithmetic.unary.decrement.powershell</string>
3912+
<string>keyword.operator.arithmetic.prefix.unary.decrement.powershell</string>
39133913
</dict>
39143914
</dict>
39153915
<key>end</key>
@@ -3943,15 +3943,15 @@
39433943
<key>name</key>
39443944
<string>keyword.operator.bitwise.unary.bnot.powershell</string>
39453945
</dict>
3946-
<key>4</key>
3946+
<key>3</key>
39473947
<dict>
39483948
<key>name</key>
3949-
<string>keyword.operator.logical.unary.not.powershell</string>
3949+
<string>keyword.operator.arithmetic.unary.negate.powershell</string>
39503950
</dict>
3951-
<key>3</key>
3951+
<key>4</key>
39523952
<dict>
39533953
<key>name</key>
3954-
<string>keyword.operator.arithmetic.unary.negate.powershell</string>
3954+
<string>keyword.operator.logical.unary.not.powershell</string>
39553955
</dict>
39563956
</dict>
39573957
<key>end</key>
@@ -3980,10 +3980,6 @@
39803980
<key>include</key>
39813981
<string>#operators_postUnary</string>
39823982
</dict>
3983-
<dict>
3984-
<key>include</key>
3985-
<string>#operators_preUnary</string>
3986-
</dict>
39873983
<dict>
39883984
<key>begin</key>
39893985
<string>[\x{2013}-\x{2015}-](?i:is(?:not)?|as)(?!\p{L})</string>
@@ -4079,7 +4075,7 @@
40794075
</dict>
40804076
<dict>
40814077
<key>begin</key>
4082-
<string>[\x{2013}-\x{2015}-]((?i:and|or|not|xor))(?!\p{L})</string>
4078+
<string>[\x{2013}-\x{2015}-]((?i:and|or|xor))(?!\p{L})</string>
40834079
<key>beginCaptures</key>
40844080
<dict>
40854081
<key>0</key>
@@ -4193,7 +4189,7 @@
41934189
</dict>
41944190
<dict>
41954191
<key>begin</key>
4196-
<string>[+%*/\x{2013}-\x{2015}-]</string>
4192+
<string>[+%*/]|[\x{2013}-\x{2015}-](?![\p{L}\x{2013}-\x{2015}-])</string>
41974193
<key>beginCaptures</key>
41984194
<dict>
41994195
<key>0</key>
@@ -4255,6 +4251,12 @@
42554251
</dict>
42564252
</array>
42574253
</dict>
4254+
<dict>
4255+
<key>comment</key>
4256+
<string>included last only because preunary also includes the negate `!` and `-b?not` operators</string>
4257+
<key>include</key>
4258+
<string>#operators_preUnary</string>
4259+
</dict>
42584260
</array>
42594261
</dict>
42604262
<key>notCode</key>

0 commit comments

Comments
 (0)