@@ -165,12 +165,12 @@ syn keyword pythonConditional if elif else
165165" we provide a dummy group here to avoid crashing pyrex.vim.
166166syn keyword pythonInclude import
167167syn keyword pythonImport import
168- syn match pythonImport " \( yield \)\@ <! \< from\> "
168+ syn keyword pythonImport from
169169syn keyword pythonException try except finally
170170syn keyword pythonOperator and in is not or
171- syn match pythonStatement " ^ \s *yield\> " display
171+ syn match pythonStatement " \s *\( [.,] \)\@ <! \< yield\> "
172172
173- syn match pythonIdentifier " [a-zA-Z_][a-zA-Z0-9_]*" nextgroup =FunctionParameters display
173+ syn match pythonIdentifier " [a-zA-Z_][a-zA-Z0-9_]*" nextgroup =FunctionParameters
174174
175175if s: Python2Syntax ()
176176 if ! s: Enabled (" g:python_print_as_function" )
@@ -180,12 +180,12 @@ if s:Python2Syntax()
180180 syn match pythonFunction " [a-zA-Z_][a-zA-Z0-9_]*" nextgroup =FunctionParameters display contained
181181else
182182 syn keyword pythonStatement as nonlocal
183- syn match pythonStatement " \v\s *<yield\s +from>" display
183+ syn match pythonStatement " \v\s *<yield\s +from>"
184184 syn match pythonStatement " \v (\. )@<!<await>"
185185 syn match pythonFunction " [a-zA-Z_][a-zA-Z0-9_]*" nextgroup =FunctionParameters display contained
186186 syn match pythonStatement " \< async\s\+ def\> " nextgroup =pythonFunction skipwhite
187- syn match pythonStatement " \< async\s\+ with\> " display
188- syn match pythonStatement " \< async\s\+ for\> " display
187+ syn match pythonStatement " \< async\s\+ with\> "
188+ syn match pythonStatement " \< async\s\+ for\> "
189189endif
190190
191191syn region FunctionParameters start =' (' end =' )' display contains =
0 commit comments