aboutsummaryrefslogtreecommitdiffstats
path: root/libsolidity/codegen
diff options
context:
space:
mode:
authorAlex Beregszaszi <alex@rtfs.hu>2017-09-20 15:41:44 +0800
committerGitHub <noreply@github.com>2017-09-20 15:41:44 +0800
commitd6bc0a0631897f893c06dcc9382bf29f23db6b26 (patch)
treebd4fba85b391e7005d2c69e88b7a25b5ab37c700 /libsolidity/codegen
parent137b214be471dd690aeadaf0e02b9ad0915d9e84 (diff)
parentf958463416e88a769d0904ca3da48dac8a9c1c5a (diff)
downloaddexon-solidity-d6bc0a0631897f893c06dcc9382bf29f23db6b26.tar
dexon-solidity-d6bc0a0631897f893c06dcc9382bf29f23db6b26.tar.gz
dexon-solidity-d6bc0a0631897f893c06dcc9382bf29f23db6b26.tar.bz2
dexon-solidity-d6bc0a0631897f893c06dcc9382bf29f23db6b26.tar.lz
dexon-solidity-d6bc0a0631897f893c06dcc9382bf29f23db6b26.tar.xz
dexon-solidity-d6bc0a0631897f893c06dcc9382bf29f23db6b26.tar.zst
dexon-solidity-d6bc0a0631897f893c06dcc9382bf29f23db6b26.zip
Merge pull request #2929 from ethereum/cppcheck
Another set of improvements found by cppcheck
Diffstat (limited to 'libsolidity/codegen')
-rw-r--r--libsolidity/codegen/ContractCompiler.h4
-rw-r--r--libsolidity/codegen/ExpressionCompiler.cpp2
-rw-r--r--libsolidity/codegen/ExpressionCompiler.h2
3 files changed, 4 insertions, 4 deletions
diff --git a/libsolidity/codegen/ContractCompiler.h b/libsolidity/codegen/ContractCompiler.h
index 38c1e045..7c5ee59f 100644
--- a/libsolidity/codegen/ContractCompiler.h
+++ b/libsolidity/codegen/ContractCompiler.h
@@ -96,8 +96,8 @@ private:
virtual bool visit(IfStatement const& _ifStatement) override;
virtual bool visit(WhileStatement const& _whileStatement) override;
virtual bool visit(ForStatement const& _forStatement) override;
- virtual bool visit(Continue const& _continue) override;
- virtual bool visit(Break const& _break) override;
+ virtual bool visit(Continue const& _continueStatement) override;
+ virtual bool visit(Break const& _breakStatement) override;
virtual bool visit(Return const& _return) override;
virtual bool visit(Throw const& _throw) override;
virtual bool visit(VariableDeclarationStatement const& _variableDeclarationStatement) override;
diff --git a/libsolidity/codegen/ExpressionCompiler.cpp b/libsolidity/codegen/ExpressionCompiler.cpp
index 631a25ff..c94baa10 100644
--- a/libsolidity/codegen/ExpressionCompiler.cpp
+++ b/libsolidity/codegen/ExpressionCompiler.cpp
@@ -1819,7 +1819,7 @@ void ExpressionCompiler::setLValueToStorageItem(Expression const& _expression)
setLValue<StorageItem>(_expression, *_expression.annotation().type);
}
-bool ExpressionCompiler::cleanupNeededForOp(Type::Category _type, Token::Value _op) const
+bool ExpressionCompiler::cleanupNeededForOp(Type::Category _type, Token::Value _op)
{
if (Token::isCompareOp(_op) || Token::isShiftOp(_op))
return true;
diff --git a/libsolidity/codegen/ExpressionCompiler.h b/libsolidity/codegen/ExpressionCompiler.h
index 5f6c3d64..cdfa096e 100644
--- a/libsolidity/codegen/ExpressionCompiler.h
+++ b/libsolidity/codegen/ExpressionCompiler.h
@@ -119,7 +119,7 @@ private:
/// @returns true if the operator applied to the given type requires a cleanup prior to the
/// operation.
- bool cleanupNeededForOp(Type::Category _type, Token::Value _op) const;
+ static bool cleanupNeededForOp(Type::Category _type, Token::Value _op);
/// @returns the CompilerUtils object containing the current context.
CompilerUtils utils();