forked from qt-creator/qt-creator
ProjectExplorer: Remove SysRootKitInformation::hasSysRoot()
This function is exactly the same as SysrootKitInformation::sysroot(),
except that is returns a boolean. And it's always used like this:
if (SysRootKitInformation::hasSysRoot(k))
sysroot = SysRootKitInformation::SysrootKitInformation::sysroot(k);
Which means that the same code is executed twice in a row.
There is no point in this, so let's just remove it.
Change-Id: I95e4de101d6164ed48558b888e22ed8892fc6d9b
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
This commit is contained in:
@@ -223,7 +223,7 @@ QVariantMap DefaultPropertyProvider::autoGeneratedProperties(const ProjectExplor
|
||||
QVariantMap data = defaultData;
|
||||
|
||||
const QString sysroot = ProjectExplorer::SysRootKitInformation::sysRoot(k).toUserOutput();
|
||||
if (ProjectExplorer::SysRootKitInformation::hasSysRoot(k))
|
||||
if (!sysroot.isEmpty())
|
||||
data.insert(QLatin1String(QBS_SYSROOT), sysroot);
|
||||
|
||||
ProjectExplorer::ToolChain *tcC
|
||||
|
||||
Reference in New Issue
Block a user