aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorLianaHus <liana@ethdev.com>2015-10-01 23:59:01 +0800
committerLianaHus <liana@ethdev.com>2015-10-02 18:38:48 +0800
commit53d0684cb4dc7d7b5c9e92bf9e77383e14ecec8c (patch)
tree5312fb4944f243347de5ce8473ae1908721efa4e /test
parent2706846f43b8a274098a8a4564bddeba06059bb6 (diff)
downloaddexon-solidity-53d0684cb4dc7d7b5c9e92bf9e77383e14ecec8c.tar.gz
dexon-solidity-53d0684cb4dc7d7b5c9e92bf9e77383e14ecec8c.tar.zst
dexon-solidity-53d0684cb4dc7d7b5c9e92bf9e77383e14ecec8c.zip
-fixed the warning printing
-style fixes
Diffstat (limited to 'test')
-rw-r--r--test/libsolidity/SolidityNameAndTypeResolution.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/test/libsolidity/SolidityNameAndTypeResolution.cpp b/test/libsolidity/SolidityNameAndTypeResolution.cpp
index ad7b59ce..961c10b4 100644
--- a/test/libsolidity/SolidityNameAndTypeResolution.cpp
+++ b/test/libsolidity/SolidityNameAndTypeResolution.cpp
@@ -45,7 +45,7 @@ namespace
{
pair<ASTPointer<SourceUnit>, shared_ptr<Exception const>>
-parseAnalyseAndReturnError(string const& _source, bool _warning = false)
+parseAnalyseAndReturnError(string const& _source, bool _reportWarnings = false)
{
Parser parser;
ASTPointer<SourceUnit> sourceUnit;
@@ -76,12 +76,12 @@ parseAnalyseAndReturnError(string const& _source, bool _warning = false)
{
for (auto const& firstError: typeChecker.errors())
{
- if (!dynamic_pointer_cast<Warning const>(firstError))
+ if (_reportWarnings || !dynamic_pointer_cast<Warning const>(firstError))
{
err = firstError;
break;
}
- else if (_warning)
+ else if (_reportWarnings)
{
err = firstError;
break;