python-syntax icon indicating copy to clipboard operation
python-syntax copied to clipboard

Add support for match expression

Open mdomke opened this issue 2 years ago • 3 comments

This is based on the work of @g15ecb

https://github.com/g15ecb/python-syntax/commit/988efe9edcfeed9e762102fcb315a4fd47db4c00

mdomke avatar Apr 27 '22 07:04 mdomke

Have been using this for a while (copy-pasted your syntax file). Works fine for me so far.

lukelbd avatar Jun 24 '22 19:06 lukelbd

Seems to need approval from @nfnty?

lukelbd avatar Jun 24 '22 19:06 lukelbd

I have an alternate version of this https://github.com/vim-python/python-syntax/commit/5d79f24dfe2b629f123cdfca74707d98c8dc03e4

Mine is slightly more expensive as it avoids highlighting non keyword versions of the match case.

One note on this PR is that match / case should not appear in the pythonExpression cluster. pythonExpression is exclusively used by fstring highlighting and there is no expression form of match.

cdonovick avatar Apr 25 '23 23:04 cdonovick