Ensuring filename is a plain Python string

We don't want to send a unicode string to the user's ycm_extra_conf.py file.
This should fix problems with sending the filename to YCM's CompilationDatabase
API.
This commit is contained in:
Strahinja Val Markovic 2013-11-05 10:28:40 -08:00
parent aa0ccdb925
commit 207a0779c3

View File

@ -243,7 +243,7 @@ class ClangCompleter( Completer ):
def _FlagsForRequest( self, request_data ):
filename = request_data[ 'filepath' ]
filename = ToUtf8IfNeeded( request_data[ 'filepath' ] )
if 'compilation_flags' in request_data:
return PrepareFlagsForClang( request_data[ 'compilation_flags' ],
filename )