Highlight class variables inside f-strings

Fixes #56
This commit is contained in:
nfnty
2020-12-02 19:57:28 +00:00
parent 2ccfb142e7
commit 0ad21fd728
2 changed files with 2 additions and 1 deletions

View File

@@ -103,7 +103,7 @@ else
syn match pythonStatement '\<async\s\+def\>' nextgroup=pythonFunction skipwhite
syn match pythonStatement '\<async\s\+with\>'
syn match pythonStatement '\<async\s\+for\>'
syn cluster pythonExpression contains=pythonStatement,pythonRepeat,pythonConditional,pythonOperator,pythonNumber,pythonHexNumber,pythonOctNumber,pythonBinNumber,pythonFloat,pythonString,pythonFString,pythonRawString,pythonRawFString,pythonBytes,pythonBoolean,pythonNone,pythonSingleton,pythonBuiltinObj,pythonBuiltinFunc,pythonBuiltinType
syn cluster pythonExpression contains=pythonStatement,pythonRepeat,pythonConditional,pythonOperator,pythonNumber,pythonHexNumber,pythonOctNumber,pythonBinNumber,pythonFloat,pythonString,pythonFString,pythonRawString,pythonRawFString,pythonBytes,pythonBoolean,pythonNone,pythonSingleton,pythonBuiltinObj,pythonBuiltinFunc,pythonBuiltinType,pythonClassVar
endif

View File

@@ -251,6 +251,7 @@ fr'this {that}'
f"{f'{1+1}'}"
'{{ }}'
f"{"{test}"}" # FIXME: syntax error that should not be highlighted
f'{self.__name__}
# Doctests.