diff options
author | Alex Beregszaszi <alex@rtfs.hu> | 2017-06-26 19:49:05 +0800 |
---|---|---|
committer | Alex Beregszaszi <alex@rtfs.hu> | 2017-06-28 23:57:32 +0800 |
commit | 8b0c866f025f3b48db36b0e48451062806a1ab06 (patch) | |
tree | b6dd46f48b66478feefc7e1c1810535c6bd1f700 /libsolidity/analysis | |
parent | 79d13366874c432c2f8f2adf3cd8cc00638c6a98 (diff) | |
download | dexon-solidity-8b0c866f025f3b48db36b0e48451062806a1ab06.tar.gz dexon-solidity-8b0c866f025f3b48db36b0e48451062806a1ab06.tar.zst dexon-solidity-8b0c866f025f3b48db36b0e48451062806a1ab06.zip |
Add hasHexPrefix() to AST::Literal
Diffstat (limited to 'libsolidity/analysis')
-rw-r--r-- | libsolidity/analysis/TypeChecker.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libsolidity/analysis/TypeChecker.cpp b/libsolidity/analysis/TypeChecker.cpp index b276a2d4..436d960b 100644 --- a/libsolidity/analysis/TypeChecker.cpp +++ b/libsolidity/analysis/TypeChecker.cpp @@ -1886,7 +1886,7 @@ void TypeChecker::expectType(Expression const& _expression, Type const& _expecte { auto literal = dynamic_cast<Literal const*>(&_expression); - if (literal && !boost::starts_with(literal->value(), "0x")) + if (literal && !literal->hasHexPrefix()) m_errorReporter.warning( _expression.location(), "Decimal literal assigned to bytesXX variable will be left-aligned. " |