diff options
| author | 2021-01-24 13:30:26 +0100 | |
|---|---|---|
| committer | 2021-01-24 13:30:26 +0100 | |
| commit | 7d55efb32e845c910177c083e095956765fd5c17 (patch) | |
| tree | f3beaae96546f9cfabb25f3c456216acb89ca6ef | |
| parent | 228f38d2592dcce72274018a4ae9a745dc0f8005 (diff) | |
| download | OneRoll-7d55efb32e845c910177c083e095956765fd5c17.tar.gz OneRoll-7d55efb32e845c910177c083e095956765fd5c17.zip | |
Remove build warnings.
| -rw-r--r-- | booleancondition.h | 2 | ||||
| -rw-r--r-- | node/groupnode.h | 8 | ||||
| -rw-r--r-- | result/stringresult.h | 2 | ||||
| -rw-r--r-- | tests/dice/tst_dice.cpp | 5 |
4 files changed, 10 insertions, 7 deletions
diff --git a/booleancondition.h b/booleancondition.h index f420adf..88bab30 100644 --- a/booleancondition.h +++ b/booleancondition.h @@ -49,7 +49,7 @@ public: void setOperator(LogicOperator m); void setValueNode(ExecutionNode*); - QString toString(); + QString toString() override; virtual Dice::CONDITION_STATE isValidRangeSize(const std::pair<qint64, qint64>& range) const override; /** diff --git a/node/groupnode.h b/node/groupnode.h index 84ff2bb..d037080 100644 --- a/node/groupnode.h +++ b/node/groupnode.h @@ -48,10 +48,10 @@ class GroupNode : public ExecutionNode { public: GroupNode(bool complexOutput= false); - void run(ExecutionNode* previous); - virtual QString toString(bool withLabel) const; - virtual qint64 getPriority() const; - virtual ExecutionNode* getCopy() const; + void run(ExecutionNode* previous) override; + virtual QString toString(bool withLabel) const override; + virtual qint64 getPriority() const override; + virtual ExecutionNode* getCopy() const override; int getGroupValue() const; void setGroupValue(qint64 groupValue); diff --git a/result/stringresult.h b/result/stringresult.h index f1029c7..bd8956b 100644 --- a/result/stringresult.h +++ b/result/stringresult.h @@ -22,7 +22,7 @@ public: void finished(); QString getText() const; virtual QVariant getResult(Dice::RESULT_TYPE) override; - virtual QString toString(bool); + virtual QString toString(bool) override; virtual void setHighLight(bool); virtual bool hasHighLight() const; diff --git a/tests/dice/tst_dice.cpp b/tests/dice/tst_dice.cpp index 0ede904..910fb4d 100644 --- a/tests/dice/tst_dice.cpp +++ b/tests/dice/tst_dice.cpp @@ -707,8 +707,9 @@ void TestDice::countTest() QVector<ValidatorList::LogicOperation> vector; bool first= true; - for(auto i : condition) + for(const auto& i : condition) { + Q_UNUSED(i) if(!first) { first= !first; @@ -989,6 +990,8 @@ void TestDice::ifTest_data() QTest::addRow("cmd9") << QVector<int>({25, 8, 14}) << onScalar << 1 << "False"; QTest::addRow("cmd10") << QVector<int>({25, 8, 14}) << onScalar << 47 << "True"; + + QTest::addRow("cmd11") << QVector<int>({25, 8, 14}) << onEachValue << 47 << "True"; } void TestDice::paintTest() {} |