CppEditor: Do not save clangd file path in settings

... if it is the default value.

Change-Id: I5efde72abe5a1979144352d09d461642f936224a
Reviewed-by: David Schulz <david.schulz@qt.io>
This commit is contained in:
Christian Kandeler
2021-10-19 15:00:19 +02:00
parent ac2906cd60
commit 575ca89b3e

View File

@@ -402,7 +402,8 @@ QVariantMap ClangdSettings::Data::toMap() const
{
QVariantMap map;
map.insert(useClangdKey(), useClangd);
map.insert(clangdPathKey(), executableFilePath.toString());
if (executableFilePath != fallbackClangdFilePath())
map.insert(clangdPathKey(), executableFilePath.toString());
map.insert(clangdIndexingKey(), enableIndexing);
map.insert(clangdThreadLimitKey(), workerThreadLimit);
map.insert(clangdDocumentThresholdKey(), documentUpdateThreshold);