forked from qt-creator/qt-creator
ClangCodeModel: Start a fallback clangd for files without a project
These were still being served by the old code model even when clangd support was enabled. Change-Id: I5f01b6a7071b90c374750f93435299755cabe3e9 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
This commit is contained in:
@@ -522,7 +522,9 @@ private:
|
||||
void addLanguageOptions()
|
||||
{
|
||||
// Determine file kind with respect to ambiguous headers.
|
||||
CppTools::ProjectFile::Kind fileKind = CppTools::ProjectFile::classify(m_filePath);
|
||||
CppTools::ProjectFile::Kind fileKind = CppTools::ProjectFile::Unclassified;
|
||||
if (!m_filePath.isEmpty())
|
||||
fileKind = CppTools::ProjectFile::classify(m_filePath);
|
||||
if (fileKind == CppTools::ProjectFile::AmbiguousHeader) {
|
||||
fileKind = m_projectPart.languageVersion <= ::Utils::LanguageVersion::LatestC
|
||||
? CppTools::ProjectFile::CHeader
|
||||
|
||||
Reference in New Issue
Block a user