forked from qt-creator/qt-creator
ToolChains: Check typeId first before doing expensive checks
This should speed up toolchain auto-detection a lot. Change-Id: Id732ed359a4c9de1d49cb658cc91c2e7c9d1b7a6 Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
This commit is contained in:
@@ -356,8 +356,8 @@ static AndroidToolChain *findToolChain(Utils::FileName &compilerPath, const QLis
|
||||
{
|
||||
return static_cast<AndroidToolChain *>(
|
||||
Utils::findOrDefault(alreadyKnown, [compilerPath](ToolChain *tc) {
|
||||
return tc->compilerCommand() == compilerPath
|
||||
&& tc->typeId() == Constants::ANDROID_TOOLCHAIN_ID;
|
||||
return tc->typeId() == Constants::ANDROID_TOOLCHAIN_ID
|
||||
&& tc->compilerCommand() == compilerPath;
|
||||
}));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user