Fix: member initializer for 'm_fooBar' is redundant

warning: member initializer for 'm_isValid' is redundant
[modernize-use-default-member-init]

Change-Id: Icd521e7d77054512bc0ed6b95cf08440320b0ce0
Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
Alessandro Portale
2018-07-12 00:49:23 +02:00
parent 8eda99afcb
commit ad474f5fcb
9 changed files with 7 additions and 17 deletions

View File

@@ -168,7 +168,6 @@ public:
IconCommandParameter(int keyword, ShapeValueF::Unit unit, ShapeValueF::Origin origin = ShapeValueF::OriginSmart)
: m_keyword(keyword),
m_type(ShapeValue),
m_unit(unit),
m_origin(origin)
{

View File

@@ -77,8 +77,7 @@ TestRunner *TestRunner::instance()
}
TestRunner::TestRunner(QObject *parent) :
QObject(parent),
m_executingTests(false)
QObject(parent)
{
connect(&m_futureWatcher, &QFutureWatcher<TestResultPtr>::resultReadyAt,
this, [this](int index) { emit testResultReady(m_futureWatcher.resultAt(index)); });

View File

@@ -44,7 +44,7 @@ CMakeConfigItem::CMakeConfigItem() = default;
CMakeConfigItem::CMakeConfigItem(const CMakeConfigItem &other) :
key(other.key), type(other.type), isAdvanced(other.isAdvanced),
inCMakeCache(false), isUnset(other.isUnset), value(other.value),
isUnset(other.isUnset), value(other.value),
documentation(other.documentation), values(other.values)
{}

View File

@@ -108,8 +108,7 @@ public:
m_executable(executable),
m_isAutoRun(autoRun),
m_autoCreateBuildDirectory(autoCreate),
m_autodetected(autodetected),
m_changed(true)
m_autodetected(autodetected)
{}
CMakeToolTreeItem() = default;

View File

@@ -43,7 +43,6 @@ namespace Internal {
CppUseSelectionsUpdater::CppUseSelectionsUpdater(TextEditor::TextEditorWidget *editorWidget)
: m_editorWidget(editorWidget)
, m_runnerRevision(-1)
{
m_timer.setSingleShot(true);
m_timer.setInterval(updateUseSelectionsInternalInMs);

View File

@@ -464,7 +464,7 @@ public:
};
RegisterItem::RegisterItem(DebuggerEngine *engine, const Register &reg)
: m_engine(engine), m_reg(reg), m_changed(true)
: m_engine(engine), m_reg(reg)
{
if (m_reg.kind == UnknownRegister)
m_reg.guessMissingData();

View File

@@ -910,7 +910,7 @@ QDebug operator<<(QDebug ts, const Range &range)
ExCommand::ExCommand(const QString &c, const QString &a, const Range &r)
: cmd(c), hasBang(false), args(a), range(r), count(1)
: cmd(c), args(a), range(r)
{}
bool ExCommand::matches(const QString &min, const QString &full) const

View File

@@ -450,8 +450,7 @@ bool AbstractMsvcToolChain::operator ==(const ToolChain &other) const
AbstractMsvcToolChain::WarningFlagAdder::WarningFlagAdder(const QString &flag,
WarningFlags &flags) :
m_flags(flags),
m_triggered(false)
m_flags(flags)
{
if (flag.startsWith(QLatin1String("-wd"))) {
m_doesEnable = false;

View File

@@ -518,7 +518,7 @@ class NodeMetaInfoPrivate
{
public:
typedef QSharedPointer<NodeMetaInfoPrivate> Pointer;
NodeMetaInfoPrivate();
NodeMetaInfoPrivate() = default;
~NodeMetaInfoPrivate() {}
bool isValid() const;
@@ -669,11 +669,6 @@ NodeMetaInfoPrivate::Pointer NodeMetaInfoPrivate::create(Model *model, const Typ
return newData;
}
NodeMetaInfoPrivate::NodeMetaInfoPrivate() : m_isValid(false)
{
}
NodeMetaInfoPrivate::NodeMetaInfoPrivate(Model *model, TypeName type, int maj, int min)
: m_qualfiedTypeName(type)
, m_majorVersion(maj)