diff --git a/python/completers/all/identifier_completer.py b/python/completers/all/identifier_completer.py index 7d0a7882..90bc77ff 100644 --- a/python/completers/all/identifier_completer.py +++ b/python/completers/all/identifier_completer.py @@ -17,7 +17,7 @@ # You should have received a copy of the GNU General Public License # along with YouCompleteMe. If not, see . -from completer import Completer +from completers.completer import Completer import vim import vimsupport import ycm_core diff --git a/python/completer.py b/python/completers/completer.py similarity index 100% rename from python/completer.py rename to python/completers/completer.py diff --git a/python/completers/cpp/clang_completer.py b/python/completers/cpp/clang_completer.py index 2901b2cb..4d952ffd 100644 --- a/python/completers/cpp/clang_completer.py +++ b/python/completers/cpp/clang_completer.py @@ -17,7 +17,7 @@ # You should have received a copy of the GNU General Public License # along with YouCompleteMe. If not, see . -from completer import Completer +from completers.completer import Completer import vim import vimsupport import ycm_core diff --git a/python/ycm.py b/python/ycm.py index 66d0e7e2..3333c83b 100644 --- a/python/ycm.py +++ b/python/ycm.py @@ -100,6 +100,12 @@ class YouCompleteMe( object ): return False + def GetDiagnosticsForCurrentFile( self ): + if self.FiletypeCompletionEnabledForCurrentFile(): + return self.GetFiletypeCompleterForCurrentFile().GetDiagnosticsForCurrentFile() + return [] + + def OnCurrentIdentifierFinished( self ): self.identcomp.OnCurrentIdentifierFinished() @@ -107,12 +113,6 @@ class YouCompleteMe( object ): self.GetFiletypeCompleterForCurrentFile().OnCurrentIdentifierFinished() - def GetDiagnosticsForCurrentFile( self ): - if self.FiletypeCompletionEnabledForCurrentFile(): - return self.GetFiletypeCompleterForCurrentFile().GetDiagnosticsForCurrentFile() - return [] - - def _PathToCompletersFolder(): dir_of_current_script = os.path.dirname( os.path.abspath( __file__ ) ) return os.path.join( dir_of_current_script, 'completers' ) @@ -122,7 +122,6 @@ def _PathToFiletypeCompleterPluginLoader( filetype ): return os.path.join( _PathToCompletersFolder(), filetype, 'hook.py' ) - def CompletionStartColumn(): """Returns the 0-based index where the completion string should start. So if the user enters: