Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions PythonImproved.YAML-tmLanguage
Original file line number Diff line number Diff line change
Expand Up @@ -73,14 +73,14 @@ patterns:
match: \b(None|True|False|Ellipsis|NotImplemented)\b

- name: storage.modifier.declaration.python
match: \b(global|nonlocal)\b
match: \b(global|nonlocal|async)\b

- name: keyword.control.import.python
match: \b(?:(import|from|as))\b

- comment: keywords that delimit flow blocks or alter flow from within a block
name: keyword.control.flow.python
match: \b(elif|else|except|finally|for|if|try|while|with|break|continue|pass|raise|return|yield)\b
match: \b(elif|else|except|finally|for|if|try|while|with|break|continue|pass|raise|return|yield|await)\b

- comment: keyword operators that evaluate to True or False
name: keyword.operator.logical.python
Expand All @@ -97,10 +97,10 @@ patterns:
match: <\=|>\=|\=\=|<|>|\!\=

- name: keyword.operator.assignment.augmented.python
match: \+\=|-\=|\*\=|/\=|//\=|%\=|&\=|\|\=|\^\=|>>\=|<<\=|\*\*\=
match: \+\=|-\=|\*\=|/\=|//\=|%\=|&\=|\|\=|\^\=|>>\=|<<\=|\*\*\=|@\=

- name: keyword.operator.arithmetic.python
match: \+|\-|\*|\*\*|/|//|%|<<|>>|&|\||\^|~
match: \+|\-|\*|\*\*|/|//|%|<<|>>|&|\||\^|~|(?!^)@

- name: keyword.operator.assignment.python
match: \=
Expand Down Expand Up @@ -622,7 +622,7 @@ repository:

illegal_names:
name: invalid.illegal.name.python
match: \b(and|as|assert|break|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|nonlocal|not|or|pass|print|raise|return|try|while|with|yield)\b
match: \b(and|as|assert|break|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|nonlocal|not|or|pass|print|raise|return|try|while|with|yield|async|await)\b

keyword_arguments:
begin: \b([a-zA-Z_][a-zA-Z_0-9]*)\s*(=)(?!=)
Expand Down
10 changes: 5 additions & 5 deletions PythonImproved.tmLanguage
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@
</dict>
<dict>
<key>match</key>
<string>\b(global|nonlocal)\b</string>
<string>\b(global|nonlocal|async)\b</string>
<key>name</key>
<string>storage.modifier.declaration.python</string>
</dict>
Expand All @@ -195,7 +195,7 @@
<key>comment</key>
<string>keywords that delimit flow blocks or alter flow from within a block</string>
<key>match</key>
<string>\b(elif|else|except|finally|for|if|try|while|with|break|continue|pass|raise|return|yield)\b</string>
<string>\b(elif|else|except|finally|for|if|try|while|with|break|continue|pass|raise|return|yield|await)\b</string>
<key>name</key>
<string>keyword.control.flow.python</string>
</dict>
Expand Down Expand Up @@ -229,13 +229,13 @@
</dict>
<dict>
<key>match</key>
<string>\+\=|-\=|\*\=|/\=|//\=|%\=|&amp;\=|\|\=|\^\=|&gt;&gt;\=|&lt;&lt;\=|\*\*\=</string>
<string>\+\=|-\=|\*\=|/\=|//\=|%\=|&amp;\=|\|\=|\^\=|&gt;&gt;\=|&lt;&lt;\=|\*\*\=|@\=</string>
<key>name</key>
<string>keyword.operator.assignment.augmented.python</string>
</dict>
<dict>
<key>match</key>
<string>\+|\-|\*|\*\*|/|//|%|&lt;&lt;|&gt;&gt;|&amp;|\||\^|~</string>
<string>\+|\-|\*|\*\*|/|//|%|&lt;&lt;|&gt;&gt;|&amp;|\||\^|~|(?!^)@</string>
<key>name</key>
<string>keyword.operator.arithmetic.python</string>
</dict>
Expand Down Expand Up @@ -1858,7 +1858,7 @@
<key>illegal_names</key>
<dict>
<key>match</key>
<string>\b(and|as|assert|break|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|nonlocal|not|or|pass|print|raise|return|try|while|with|yield)\b</string>
<string>\b(and|as|assert|break|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|nonlocal|not|or|pass|print|raise|return|try|while|with|yield|async|await)\b</string>
<key>name</key>
<string>invalid.illegal.name.python</string>
</dict>
Expand Down