forked from qt-creator/qt-creator
Remove spaces in initializer lists
Format initializer lists code style like. Change-Id: Ib82c235e4ba7dc75ee96a7abc0c47eff7b0a9013 Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
@@ -60,8 +60,8 @@ using namespace WinRt::Internal::Constants;
|
||||
static QString extractToolchainPrefix(QString *compilerName)
|
||||
{
|
||||
QString prefix;
|
||||
const QStringList candidates = { QLatin1String("g++"), QLatin1String("clang++"),
|
||||
QLatin1String("gcc"), QLatin1String("clang") };
|
||||
const QStringList candidates = {QLatin1String("g++"), QLatin1String("clang++"),
|
||||
QLatin1String("gcc"), QLatin1String("clang")};
|
||||
foreach (const QString &candidate, candidates) {
|
||||
const QString suffix = Utils::HostOsInfo::withExecutableSuffix(QLatin1Char('-')
|
||||
+ candidate);
|
||||
|
||||
@@ -274,28 +274,28 @@ QString QbsBuildConfiguration::equivalentCommandLine(const BuildStep *buildStep)
|
||||
const StepProxy stepProxy(buildStep);
|
||||
Utils::QtcProcess::addArg(&commandLine, stepProxy.command());
|
||||
const QString buildDir = buildDirectory().toUserOutput();
|
||||
Utils::QtcProcess::addArgs(&commandLine, QStringList({ "-d", buildDir }));
|
||||
Utils::QtcProcess::addArgs(&commandLine, QStringList({"-d", buildDir}));
|
||||
Utils::QtcProcess::addArgs(&commandLine, QStringList("-f")
|
||||
<< buildStep->project()->projectFilePath().toUserOutput());
|
||||
if (QbsProjectManagerSettings::useCreatorSettingsDirForQbs()) {
|
||||
Utils::QtcProcess::addArgs(&commandLine, QStringList({ "--settings-dir",
|
||||
QDir::toNativeSeparators(QbsProjectManagerSettings::qbsSettingsBaseDir()) }));
|
||||
Utils::QtcProcess::addArgs(&commandLine, QStringList({"--settings-dir",
|
||||
QDir::toNativeSeparators(QbsProjectManagerSettings::qbsSettingsBaseDir())}));
|
||||
}
|
||||
if (stepProxy.dryRun())
|
||||
Utils::QtcProcess::addArg(&commandLine, QLatin1String("--dry-run"));
|
||||
if (stepProxy.keepGoing())
|
||||
Utils::QtcProcess::addArg(&commandLine, QLatin1String("--keep-going"));
|
||||
if (stepProxy.showCommandLines())
|
||||
Utils::QtcProcess::addArgs(&commandLine, QStringList({ "--command-echo-mode",
|
||||
"command-line" }));
|
||||
Utils::QtcProcess::addArgs(&commandLine, QStringList({"--command-echo-mode",
|
||||
"command-line"}));
|
||||
if (stepProxy.noInstall())
|
||||
Utils::QtcProcess::addArg(&commandLine, QLatin1String("--no-install"));
|
||||
if (stepProxy.cleanInstallRoot())
|
||||
Utils::QtcProcess::addArg(&commandLine, QLatin1String("--clean-install-root"));
|
||||
const int jobCount = stepProxy.jobCount();
|
||||
if (jobCount > 0) {
|
||||
Utils::QtcProcess::addArgs(&commandLine, QStringList({ "--jobs",
|
||||
QString::number(jobCount) }));
|
||||
Utils::QtcProcess::addArgs(&commandLine, QStringList({"--jobs",
|
||||
QString::number(jobCount)}));
|
||||
}
|
||||
const QString profileName = QbsManager::instance()->profileForKit(buildStep->target()->kit());
|
||||
const QString buildVariant = qbsConfiguration()
|
||||
|
||||
@@ -849,7 +849,7 @@ QList<ProjectExplorer::BuildStepInfo> QbsBuildStepFactory::availableSteps(Projec
|
||||
if (parent->id() == ProjectExplorer::Constants::BUILDSTEPS_BUILD
|
||||
&& qobject_cast<QbsBuildConfiguration *>(parent->parent())
|
||||
&& qobject_cast<QbsProject *>(parent->target()->project()))
|
||||
return {{ Constants::QBS_BUILDSTEP_ID, tr("Qbs Build") }};
|
||||
return {{Constants::QBS_BUILDSTEP_ID, tr("Qbs Build")}};
|
||||
|
||||
return {};
|
||||
}
|
||||
|
||||
@@ -309,7 +309,7 @@ QList<ProjectExplorer::BuildStepInfo> QbsCleanStepFactory::availableSteps(Projec
|
||||
{
|
||||
if (parent->id() == ProjectExplorer::Constants::BUILDSTEPS_CLEAN
|
||||
&& qobject_cast<QbsBuildConfiguration *>(parent->parent()))
|
||||
return {{ Constants::QBS_CLEANSTEP_ID, tr("Qbs Clean") }};
|
||||
return {{Constants::QBS_CLEANSTEP_ID, tr("Qbs Clean")}};
|
||||
return {};
|
||||
}
|
||||
|
||||
|
||||
@@ -474,7 +474,7 @@ void QbsProjectManagerPlugin::buildFiles(QbsProject *project, const QStringList
|
||||
|
||||
void QbsProjectManagerPlugin::buildSingleFile(QbsProject *project, const QString &file)
|
||||
{
|
||||
buildFiles(project, QStringList(file), QStringList({ "obj", "hpp" }));
|
||||
buildFiles(project, QStringList(file), QStringList({"obj", "hpp"}));
|
||||
}
|
||||
|
||||
void QbsProjectManagerPlugin::buildProducts(QbsProject *project, const QStringList &products)
|
||||
|
||||
Reference in New Issue
Block a user