void CodeCompletionManager::DoUpdateCompilationDatabase() { // Create a worker thread (detached thread) that // will initialize the database now that the compilation has ended CompilationDatabase db; ClangCompilationDbThread* thr = new ClangCompilationDbThread( db.GetFileName().GetFullPath() ); thr->Start(); }
void ClangCodeCompletion::OnBuildEnded(clBuildEvent& e) { e.Skip(); CHECK_CLANG_ENABLED_RET(); // Clear environment variables previously set by this class ::wxUnsetEnv(wxT("CL_COMPILATION_DB")); ::wxUnsetEnv(wxT("CXX")); ::wxUnsetEnv(wxT("CC")); // Create a worker thread (detached thread) that // will initialize the database now that the compilation is ended CompilationDatabase db; ClangCompilationDbThread* thr = new ClangCompilationDbThread( db.GetFileName().GetFullPath() ); thr->Start(); // Clear the TU cache ClearCache(); }