Handling vim.error from omnifunc

If the omnifunc encounters a syntax error, we need to handle this without
showing a traceback to the user.
This commit is contained in:
Strahinja Val Markovic 2014-01-04 16:17:44 -08:00
parent e424d75c42
commit 91368c09ea

View File

@ -95,7 +95,7 @@ class OmniCompleter( Completer ):
raise TypeError( OMNIFUNC_NOT_LIST )
return filter( bool, items )
except ( TypeError, ValueError ) as error:
except ( TypeError, ValueError, vim.error ) as error:
vimsupport.PostVimMessage(
OMNIFUNC_RETURNED_BAD_VALUE + ' ' + str( error ) )
return []